* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
}

body {
    font-family: 'Times New Roman', Times, serif;
    background: #fff;
    color: #222;
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

/* Skip link - visible only on focus for keyboard users */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #000;
    color: #fff;
    padding: 8px 16px;
    z-index: 10000;
    text-decoration: none;
    font-size: 14px;
    transition: top 0.3s ease;
}

.skip-link:focus {
    top: 0;
}

/* Visually hidden - for screen readers only */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus styles for better keyboard navigation */
a:focus,
button:focus {
    outline: 2px solid #000;
    outline-offset: 2px;
}

/* Remove default button styles for back-to-top only */
button.back-to-top {
    padding: 0;
}

/* ============================================
   MENU BUTTON & SLIDE DOWN MENU
   ============================================ */
.menu-toggle {
    position: fixed;
    top: 20px;
    left: 20px;
    cursor: pointer;
    z-index: 2000;
    width: 24px;
    height: 24px;
    background: #fff;
    border: 2px solid #000;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 0;
    box-sizing: border-box;
    transition: all 0.3s ease;
}

.menu-toggle span {
    display: block;
    width: 12px;
    height: 1.5px;
    background-color: #000;
    transition: all 0.3s ease;
}

.menu-toggle:hover {
    background: #000;
}

.menu-toggle:hover span {
    background-color: #fff;
}

.menu-toggle:focus {
    outline: none;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 20px;
    left: 20px;
    cursor: pointer;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    font-family: 'Times New Roman', Times, serif;
    font-size: 12px;
    line-height: 1;
    color: #000;
    width: 24px;
    height: 24px;
    border: 2px solid #000;
    border-radius: 5px;
    background: #fff;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: all;
}

.back-to-top:hover {
    background: #000;
    color: #fff;
}

/* Social Icons */
.social-icon {
    position: fixed;
    left: 20px;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #000;
    transition: opacity 0.3s ease;
}

.social-icon:hover {
    opacity: 0.6;
}

.instagram-icon-link {
    top: 70px;
}

.email-icon-link {
    top: 102px; /* 70px + 24px icon + 8px gap */
}

.instagram-icon {
    width: 24px;
    height: 24px;
}

.email-at {
    font-family: 'Times New Roman', Times, serif;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid currentColor;
    border-radius: 5px;
    box-sizing: border-box;
    line-height: 1;
    padding-bottom: 2px; /* Optical adjustment - shift @ up slightly */
}

.menu-slide {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    transform: translateY(-100%);
    transition: transform 0.4s ease;
    z-index: 1000;
    padding: 25px 20px 25px;
}

.menu-slide.active {
    transform: translateY(0);
}

/* Hover trigger zone - matches menu height for dock-like behavior */
.menu-trigger-zone {
    position: fixed;
    top: 0;
    left: 60px; /* Start after burger button area */
    right: 0;
    height: 70px;
    z-index: 999;
}

/* Menu links container - horizontal on desktop */
.menu-links {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 25px 40px;
    max-width: 700px;
    margin: 0 auto;
}

.menu-slide a {
    text-decoration: none;
    color: #222;
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 2px;
    padding: 8px 0;
    transition: opacity 0.3s ease;
    position: relative;
}

.menu-slide a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: #000;
    transition: width 0.3s ease;
}

.menu-slide a:hover::after {
    width: 100%;
}

.menu-slide a:hover {
    opacity: 1;
}

.menu-slide a:focus {
    outline: none;
}

/* ============================================
   SECTION CONTAINER
   ============================================ */
.section {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
    background-color: #fff;
    position: relative;
}

/* Text sections - content centered vertically */
.text-section,
.form-section {
    padding-top: 80px;
    padding-bottom: 80px;
}

/* Films section - center the video content */
.films-section {
    align-items: center;
    justify-content: center;
}

/* ============================================
   HERO / LOGO
   ============================================ */
.logo-container {
    text-align: left;
    line-height: 0.7;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    height: 100vh;
    min-width: 450px;  /* Give it a minimum width so text is clearly left-aligned within the centered block */
}

.line1, .line2, .line3 {
    font-size: 120px;
    margin: 0;
    word-spacing: -20px;
}

.heart {
    color: #ff0000;
    font-size: 120px;
    position: relative;
    top: -5px;
}

.line2, .line3 {
    letter-spacing: 0px;
}

/* Language Toggle - Option D3 */
.language-toggle {
    margin-top: 30px;
    display: flex;
    gap: 10px;
    font-size: 13px;
}

.language-toggle button {
    background: none;
    border: none;
    font-family: 'Times New Roman', Times, serif;
    font-size: 13px;
    cursor: pointer;
    padding: 2px 5px;
    position: relative;
    transition: opacity 0.3s ease;
}

.language-toggle button::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 3px;
    background: #000;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.language-toggle button.active::after {
    opacity: 1;
}

.language-toggle button:hover {
    opacity: 0.6;
}

/* ============================================
   CONTENT SECTIONS
   ============================================ */
.content-container {
    max-width: 800px;
    width: 85%;
    margin: 0 auto;
    position: relative;
}

.text-section {
    padding-bottom: 80px;
}

.section-title {
    font-size: 22px;
    font-weight: bold;
    margin-bottom: 20px;
    text-align: left;
}

.exhibition-text {
    font-size: 18px;
    line-height: 1.5;
}

/* Language content visibility */
.lang-content {
    display: none;
}

.lang-content.active {
    display: block;
}

/* ============================================
   SELECTED WORKS - Newspaper Layout
   ============================================ */
.works-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    position: relative;
}

/* Center divider line */
.works-grid::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    background: #ddd;
    transform: translateX(-0.5px);
}

.works-column {
    font-size: 15px;
    line-height: 2;
}

.works-column-left {
    text-align: right;
    padding-right: 20px;
}

.works-column-left ul,
.works-column-left li,
.works-column-left strong {
    text-align: right;
}

.works-column-right {
    text-align: left;
    padding-left: 20px;
}

.works-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.works-column li {
    margin-bottom: 0;
}

/* Ensure list items inherit text alignment */
.works-column-left ul,
.works-column-left li {
    text-align: right;
}

.works-column-right ul,
.works-column-right li {
    text-align: left;
}

/* Mobile: stack columns */
@media (max-width: 768px) {
    .works-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .works-grid::before {
        display: none;
    }

    .works-column-left,
    .works-column-right {
        text-align: left;
        padding: 0;
    }

    .works-column-left {
        padding-bottom: 30px;
        border-bottom: 1px solid #ddd;
    }
}

/* ============================================
   FILMS SECTION
   ============================================ */
.films-section {
    padding-top: 80px;
    padding-bottom: 80px;
}

.film-grid {
    display: grid;
    gap: 20px;
    margin-top: 15px;
}

.film-slot {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 20px;
}

.video-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 1.2s ease-in-out;
}

.video-front {
    z-index: 2;
    opacity: 1;
}

.video-back {
    z-index: 1;
    opacity: 0;
}

/* Desktop: 3 columns */
@media (min-width: 900px) {
    .film-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px;
    }

    .film-slot {
        aspect-ratio: 9 / 16;
    }
}

/* Mobile: single column with crossfade */
@media (max-width: 899px) {
    .film-grid {
        position: relative;
        height: 70vh;
    }

    .film-slot {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
    }

    .film-slot.active .video-front {
        opacity: 1;
    }
}

/* ============================================
   GALLERY SECTION
   ============================================ */
.gallery-section {
    background-color: #fff;
    padding-top: 100px;
    padding-bottom: 80px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.gallery-item {
    background: #fff;
    border: 1px solid #ddd;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.gallery-slideshow {
    position: relative;
    width: 100%;
    height: 300px;
    overflow: hidden;
}

.gallery-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.gallery-image.active {
    opacity: 1;
}

.gallery-info {
    padding: 20px;
}

.gallery-info h3 {
    font-size: 18px;
    margin-bottom: 10px;
    font-weight: bold;
}

.gallery-info p {
    font-size: 14px;
    line-height: 1.5;
    color: #666;
}

/* ============================================
   MAP SECTION
   ============================================ */
.map-section {
    padding-bottom: 80px;
}

#map {
    height: 320px;
    width: 100%;
    border-radius: 15px;
    overflow: hidden;
    margin-top: 20px;
}

/* Custom popup styles */
.custom-popup {
    font-family: 'Times New Roman', Times, serif;
    max-width: 220px;
}

.custom-popup h3 {
    font-size: 14px;
    margin-bottom: 8px;
    font-weight: bold;
    line-height: 1.3;
}

.custom-popup p {
    font-size: 12px;
    margin-bottom: 8px;
    line-height: 1.4;
}

.custom-popup a {
    color: #000;
    text-decoration: underline;
    font-size: 11px;
    transition: opacity 0.3s ease;
}

.custom-popup a:hover {
    opacity: 0.6;
}

.custom-popup button {
    background: #000;
    color: #fff;
    border: none;
    padding: 8px 14px;
    cursor: pointer;
    font-family: 'Times New Roman', Times, serif;
    font-size: 12px;
    width: 100%;
    transition: background 0.3s ease;
    margin-top: 5px;
}

.custom-popup button:hover {
    background: #333;
}

/* Past exhibition marker styling */
.past-marker {
    opacity: 0.5;
}

/* Better popup padding and close button positioning */
.leaflet-popup-content-wrapper {
    border-radius: 8px;
    padding: 10px;
}

.leaflet-popup-content {
    margin: 8px 10px;
}

.leaflet-popup-close-button {
    padding: 8px 8px 0 0 !important;
}

/* ============================================
   FORM SECTION - Two-Column Newspaper Layout
   ============================================ */
.form-section {
    padding-bottom: 80px;
}

/* Two-column layout wrapper */
.form-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 60px;
    position: relative;
    align-items: start;
}

/* Centered separator line */
.form-wrapper::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    background: #ddd;
    transform: translateX(-0.5px);
}

/* Form column */
.form-column {
    display: flex;
    flex-direction: column;
}

.form-field {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}

.form-field label {
    font-size: 13px;
    color: #333;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    line-height: 1.4;
}

.form-field input,
.form-field select {
    width: 100%;
    padding: 12px;
    font-size: 15px;
    font-family: 'Times New Roman', Times, serif;
    border: 1px solid #ccc;
    border-radius: 0;
    background: #fff;
    line-height: 1.4;
}

.form-field input:focus,
.form-field select:focus {
    outline: none;
    border-color: #000;
}

.form-field select.highlight {
    background: #ffffcc;
    border-color: #ff0000;
    border-width: 2px;
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
}

.checkbox-item {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.checkbox-item input[type="checkbox"] {
    min-width: 18px;
    height: 18px;
    margin-top: 2px;
    cursor: pointer;
}

.checkbox-item label {
    font-size: 12px;
    line-height: 1.6;
    color: #666;
    cursor: pointer;
    margin-bottom: 0;
}

.submit-btn {
    background: #000;
    color: #fff;
    border: none;
    padding: 15px 30px;
    font-family: 'Times New Roman', Times, serif;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: background 0.3s ease;
    line-height: 1.4;
    align-self: flex-start;
    border-radius: 0;
}

.submit-btn:hover {
    background: #333;
}

.privacy-note {
    font-size: 11px;
    line-height: 1.6;
    color: #999;
    margin-top: 20px;
}

/* Text column */
.text-column {
    display: flex;
    flex-direction: column;
}

.text-column h3 {
    font-size: 16px;
    margin-bottom: 24px;
    font-weight: normal;
    font-style: italic;
    line-height: 1.4;
    padding-top: 1px;
}

.text-content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
}

.text-column p {
    font-size: 15px;
    line-height: 1.6;
    color: #333;
}

.text-column p + p {
    margin-top: 18px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .logo-container {
        text-align: center;
        align-items: center;
        min-width: auto;  /* Remove min-width on mobile */
    }

    .line1, .line2, .line3, .heart {
        font-size: 80px;
    }

    .menu-slide {
        padding: 20px 20px 20px;
    }

    /* Mobile menu - 2 column grid for compact layout */
    .menu-links {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 12px 30px;
        text-align: center;
    }

    .menu-slide a {
        font-size: 15px;
        letter-spacing: 1px;
    }

    /* Smaller trigger zone on mobile */
    .menu-trigger-zone {
        height: 50px;
        left: 55px;
    }

    /* Add left padding to avoid fixed icons */
    .content-container {
        padding-left: 15px;
        padding-right: 15px;
    }

    .section {
        padding-left: 55px;
        padding-right: 15px;
    }

    /* Hero section needs extra left space for icons */
    .logo-container {
        padding-left: 40px;
    }

    /* Mobile form - stack vertically */
    .form-wrapper {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .form-wrapper::before {
        display: none;
    }

    .text-column {
        order: -1; /* Text appears first on mobile */
        padding-bottom: 40px;
        border-bottom: 1px solid #ddd;
    }

    .form-column {
        padding-top: 0;
    }

    /* Smaller map on mobile */
    #map {
        height: 250px;
    }
}

/* Extra small screens */
@media (max-width: 400px) {
    .line1, .line2, .line3, .heart {
        font-size: 60px;
    }

    .menu-slide a {
        font-size: 16px;
        letter-spacing: 1px;
    }

    .section-title {
        font-size: 18px;
    }

    .exhibition-text {
        font-size: 16px;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .content-container {
        width: 95%;
    }
}
