html, body {
    margin: 20px;
    padding: 0;
    height: 100%;
    font-family: 'Inter';
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 500;
}

table {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
}

th, td {
    border: 1px solid #ddd;
    padding: 8px 12px;
    text-align: left;
    vertical-align: top;
}

th {
    background-color: #f0f0f0;
    text-align: left;
}

a {
    color: #0077cc;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

table {
}

.container {
    max-width: 800px;
    margin: 2rem auto;
    background: #fff;
}

img { max-width: 100%; border-radius: 8px; }

h1 { font-size: 3em; margin-top: 16px; margin-bottom:0;}

.section { margin-top: 2rem; line-height: 1.3em; }

.tags span {
    display: inline-block; background: #eee; border-radius: 20px;
    padding: 0.3rem 0.6rem; margin: 0.2rem; font-size: 0.9rem;
}

.genre-tags span { background-color: #e0f0ff; color: #005080; }

.event-type-tags span { background-color: #ffe0f0; color: #800050; }


.meta { color: #666; font-size: 1.4rem; margin: 0.5rem 0;}


.tag {
    display: inline-block;
    padding: 2px 6px;
    margin: 2px;
    border-radius: 12px;
    font-size: 0.75em;
}

.event-type {
    background-color: #ffe0f0;
    color: #800050;
}

.genre {
    background-color: #e0f0ff;
    color: #005080;
}

.event-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.event-grid a {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.event-tile {
    position: relative;
    width: 100%;
    padding-top: 75%; /* 4:3 ratio */
    background-size: cover;
    background-position: center;
    background-color: #ccc;
}

.overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    box-sizing: border-box;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
    color: white;
    padding: 6px;
    font-size: 0.85em;
    line-height: 1.4;
    font-family: sans-serif;
    overflow: hidden;
}

.overlay span, h1 {
    background-color: rgba(255, 255, 255, 0.9);
    color: black;
    padding: 2px 4px;
    display: inline-block;
    margin-bottom: 2px;
    white-space: nowrap;
}

.overlay h1 {
    font-size: 1.6em;
    margin-top: 0;
}

@media (max-width: 1280px) {
    .event-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
}

@media (max-width: 960px) {
    .event-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

@media (max-width: 640px) {
    .event-grid {
        display: grid;
        grid-template-columns: repeat(1, 1fr);
        gap: 16px;
    }
}
