/* The short description wraps around the difficulty indicator. */
#description {
    padding-right: 90px; /* Space for the difficulty icon */
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Leaflet needs an explicit, non-zero height or the map renders 0px tall. */
#map {
    max-width: 100%;
    height: 40vh;
    min-height: 260px;
    margin-top: 60px;
    border-radius: var(--radius-md);
}

/* Mapy.com require their logo to stay visible, at least 30px tall. */
.mapy-logo img {
    height: 30px;
    display: block;
}

.map-fallback {
    margin-top: 60px;
}

/* Keep the embedded video inside the page on narrow screens. */
.video-wrapper {
    position: relative;
    width: 100%;
    max-width: 560px;
    margin-inline: auto;
    aspect-ratio: 16 / 9;
}

.video-wrapper iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.event-description p:last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    #map {
        width: 100%;
    }

    .difficulty-icon {
        width: 40px;
    }

    #description {
        padding-right: 50px; /* Less space needed for smaller icon */
    }
}



#logo {
    max-width: 100%;
    height: auto;
}

/* Difficulty icons - shared styles */
.difficulty-image {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

/* Event page specific */
.event-difficulty {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}



/* --- redesign additions ------------------------------------------------- */

.event-lead {
    font-family: var(--font-display);
    font-size: var(--text-lg);
    font-weight: var(--weight-semibold);
    color: var(--text-primary);
    margin-bottom: var(--space-5);
}

.event-facts {
    width: 100%;
    max-width: var(--measure);
    border-collapse: collapse;
    margin-bottom: var(--space-6);
    font-size: var(--text-sm);
}

.event-facts th,
.event-facts td {
    padding: var(--space-3) var(--space-2);
    text-align: left;
    vertical-align: middle;
    border-bottom: var(--border-hair) solid var(--border-subtle);
}

.event-facts th {
    width: 9rem;
    font-weight: var(--weight-medium);
    color: var(--text-secondary);
}

.event-facts img {
    height: 26px;
    width: auto;
    vertical-align: middle;
    margin-right: var(--space-2);
}

.event-description {
    max-width: var(--measure);
    margin-bottom: var(--space-6);
}

.event-top {
    display: flex;
    align-items: flex-start;
    gap: var(--space-5);
    margin-bottom: var(--space-2);
}

.event-top .difficulty {
    margin-top: var(--space-2);
}

.event-podium {
    margin-bottom: var(--space-6);
}

.event-podium h2 {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--space-3);
    font-size: var(--text-lg);
}

.event-podium-count {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: var(--weight-regular);
    color: var(--text-secondary);
}

.event-entry {
    margin-bottom: var(--space-6);
}
