/* ========================================
   CSS RESET & BASE
   ======================================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --white: #ffffff;
    --off-white: #fafaf8;
    --rule: #e8e4df;
    --sienna: #9e5e3a;
    --sienna-light: #c4896a;
    --dark: #1a1614;
    --text: #2a2420;
    --text-light: #7a6f6a;
    --font-serif: 'Playfair Display', Georgia, serif;
    --font-body: 'Cormorant Garamond', Georgia, serif;
    --section-pad: 100px;
    --grid-gap: 2px;
}

@media (max-width: 768px) {
    :root {
        --section-pad: 60px;
        --grid-gap: 2px;
    }
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    color: var(--text);
    background: var(--white);
    line-height: 1.7;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.25s ease;
}

/* ========================================
   NAVIGATION
   ======================================== */
.nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--rule);
    transition: border-color 0.3s ease;
}

.nav.scrolled { border-bottom-color: var(--rule); }

.nav-inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav-logo {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 400;
    color: var(--dark);
    letter-spacing: 0.04em;
}

.nav-links {
    display: flex;
    gap: 40px;
    list-style: none;
}

.nav-links a {
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--text-light);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 4px 0;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 0; height: 1px;
    background: var(--dark);
    transition: width 0.3s ease;
}

.nav-links a:hover { color: var(--dark); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }
.nav-links a.active { color: var(--dark); }

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav-toggle span {
    display: block;
    width: 22px; height: 1px;
    background: var(--dark);
    margin: 6px 0;
    transition: all 0.3s ease;
}

@media (max-width: 900px) {
    .nav-inner { padding: 0 24px; height: 56px; }
    .nav-toggle { display: block; }

    .nav-links {
        position: fixed;
        top: 56px; left: 0; right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(12px);
        flex-direction: column;
        align-items: center;
        gap: 0;
        padding: 24px 0;
        transform: translateY(-110%);
        transition: transform 0.4s ease;
        border-bottom: 1px solid var(--rule);
    }

    .nav-links.open { transform: translateY(0); }
    .nav-links li { width: 100%; text-align: center; }
    .nav-links a { display: block; padding: 14px 20px; }

    .nav-toggle.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
    .nav-toggle.open span:nth-child(2) { opacity: 0; }
    .nav-toggle.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
}

/* ========================================
   HERO — full bleed, text below image
   ======================================== */
.hero {
    position: relative;
    background: var(--off-white);
}

.hero-slides-wrap {
    position: relative;
    width: 100%;
    height: calc(100vh - 64px);
    min-height: 520px;
    max-height: 960px;
    overflow: hidden;
    margin-top: 64px;
}

#heroSlides {
    width: 100%;
    height: 100%;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.4s ease;
}

.hero-slide.active { opacity: 1; }

.hero-slide img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center top;
}

/* Text band below image */
.hero-band {
    background: var(--white);
    padding: 36px 48px 28px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    border-bottom: 1px solid var(--rule);
}

.hero-text {}

.hero-title {
    font-family: var(--font-serif);
    font-size: clamp(1.8rem, 3.5vw, 3rem);
    font-weight: 400;
    color: var(--dark);
    letter-spacing: 0.04em;
    line-height: 1.15;
}

.hero-subtitle {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--text-light);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-top: 8px;
}

.hero-dots {
    display: flex;
    gap: 8px;
    padding-bottom: 4px;
}

.hero-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--rule);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.hero-dot.active { background: var(--dark); }

@media (max-width: 900px) {
    .hero-slides-wrap {
        height: 60vw;
        min-height: 300px;
        max-height: 600px;
        margin-top: 56px;
    }
    .hero-band {
        padding: 24px;
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
}

/* ========================================
   SECTIONS
   ======================================== */
.section { padding: var(--section-pad) 0; background: var(--white); }
.section-alt { background: var(--off-white); }

.container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 48px;
}

@media (max-width: 768px) { .container { padding: 0 24px; } }

.section-header {
    display: flex;
    align-items: baseline;
    gap: 24px;
    margin-bottom: 56px;
}

.section-title {
    font-family: var(--font-serif);
    font-size: clamp(1.4rem, 2.5vw, 2rem);
    font-weight: 400;
    color: var(--dark);
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.section-line {
    flex: 1;
    height: 1px;
    background: var(--rule);
}

/* ========================================
   GALLERY TABS
   ======================================== */
.gallery-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--rule);
}

.gallery-tab {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 12px 24px;
    border: none;
    border-bottom: 2px solid transparent;
    background: transparent;
    cursor: pointer;
    transition: all 0.25s ease;
    margin-bottom: -1px;
}

.gallery-tab:hover { color: var(--dark); }
.gallery-tab.active {
    color: var(--dark);
    border-bottom-color: var(--dark);
}

/* ========================================
   GALLERY GRID — editorial layout
   ======================================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--grid-gap);
}

@media (max-width: 1024px) {
    .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .gallery-grid { grid-template-columns: 1fr; }
}

.gallery-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    background: var(--off-white);
}

.gallery-item img {
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.5s ease, transform 0.7s ease;
}

.gallery-item img.loaded { opacity: 1; }
.gallery-item:hover img { transform: scale(1.04); }

.gallery-item-overlay {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 48px 20px 20px;
    background: linear-gradient(transparent, rgba(26, 22, 20, 0.65));
    opacity: 0;
    transition: opacity 0.35s ease;
}

.gallery-item:hover .gallery-item-overlay { opacity: 1; }

.gallery-item-title {
    font-family: var(--font-serif);
    font-size: 1rem;
    color: #fff;
    font-weight: 400;
    font-style: italic;
}

.gallery-item-meta {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: rgba(255,255,255,0.65);
    margin-top: 3px;
    letter-spacing: 0.05em;
}

.gallery-content { display: none; }
.gallery-content.active { display: block; }

/* ========================================
   LIGHTBOX
   ======================================== */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: var(--white);
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active { display: flex; flex-direction: column; }
.lightbox.visible { opacity: 1; }

.lightbox-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 32px;
    flex-shrink: 0;
    border-bottom: 1px solid var(--rule);
}

.lightbox-counter {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--text-light);
    letter-spacing: 0.08em;
}

.lightbox-close {
    width: 40px; height: 40px;
    background: none; border: none;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    color: var(--text);
    font-size: 1.2rem;
    transition: color 0.2s ease;
}

.lightbox-close:hover { color: var(--sienna); }

.lightbox-body {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 80px;
    position: relative;
    overflow: hidden;
    min-height: 0;
}

.lightbox-image-wrapper {
    max-width: 100%; max-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-image-wrapper img {
    max-width: 100%;
    max-height: calc(100vh - 180px);
    object-fit: contain;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px; height: 44px;
    background: none;
    border: 1px solid var(--rule);
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    color: var(--text-light);
    font-size: 1rem;
    transition: all 0.2s ease;
    z-index: 10;
}

.lightbox-nav:hover { border-color: var(--dark); color: var(--dark); }
.lightbox-prev { left: 24px; }
.lightbox-next { right: 24px; }

.lightbox-footer {
    text-align: center;
    padding: 16px 32px;
    flex-shrink: 0;
    border-top: 1px solid var(--rule);
}

.lightbox-title {
    font-family: var(--font-serif);
    font-size: 1rem;
    color: var(--dark);
    font-style: italic;
}

.lightbox-meta {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 3px;
    letter-spacing: 0.06em;
}

@media (max-width: 768px) {
    .lightbox-body { padding: 0 16px; }
    .lightbox-prev { left: 8px; }
    .lightbox-next { right: 8px; }
}

/* ========================================
   ABOUT
   ======================================== */
.about-content {
    display: grid;
    grid-template-columns: 1fr 2fr 1.2fr;
    gap: 60px;
    align-items: start;
}

.about-portrait img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    object-position: center top;
    display: block;
}

.about-text p {
    font-size: 1.2rem;
    line-height: 1.85;
    color: var(--text);
    margin-bottom: 1.3em;
}

.about-text p:last-child { margin-bottom: 0; }

.about-details { padding-top: 6px; }

.about-detail-block { margin-bottom: 40px; }
.about-detail-block:last-child { margin-bottom: 0; }

.about-detail-block h3 {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--rule);
}

.about-detail-block ul { list-style: none; }

.about-detail-block li {
    font-size: 1rem;
    color: var(--text);
    padding: 5px 0;
    line-height: 1.5;
}

.collections-list { columns: 1; }

@media (max-width: 1024px) {
    .about-content {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }
    .about-portrait { grid-column: span 2; max-width: 400px; }
}

@media (max-width: 640px) {
    .about-content { grid-template-columns: 1fr; gap: 32px; }
    .about-portrait { grid-column: span 1; max-width: 100%; }
}

/* ========================================
   EXHIBITIONS
   ======================================== */
.exhibitions-content { max-width: 900px; }

.exhibitions-toggle {
    display: flex;
    gap: 0;
    margin-bottom: 48px;
    border-bottom: 1px solid var(--rule);
}

.exhibitions-toggle button {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 12px 28px;
    border: none;
    border-bottom: 2px solid transparent;
    background: transparent;
    cursor: pointer;
    transition: all 0.25s ease;
    margin-bottom: -1px;
}

.exhibitions-toggle button:hover { color: var(--dark); }
.exhibitions-toggle button.active {
    color: var(--dark);
    border-bottom-color: var(--dark);
}

.exhibition-list { display: none; }
.exhibition-list.active { display: block; }

.exhibition-year {
    font-family: var(--font-body);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-light);
    margin-top: 36px;
    margin-bottom: 14px;
}

.exhibition-year:first-child { margin-top: 0; }

.exhibition-entry {
    padding: 10px 0;
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--text);
    border-bottom: 1px solid var(--rule);
}

.exhibition-entry:last-of-type { border-bottom: none; }

.exhibition-entry .venue {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 400;
}

.exhibition-entry .location {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* ========================================
   PRESS — editorial layout
   ======================================== */
.press-content { max-width: 960px; }

.press-list { list-style: none; }

.press-item {
    display: grid;
    grid-template-columns: 80px 1fr auto;
    align-items: baseline;
    gap: 32px;
    padding: 20px 0;
    border-bottom: 1px solid var(--rule);
}

.press-item:first-child { border-top: 1px solid var(--rule); }

.press-year {
    font-family: var(--font-body);
    font-size: 0.78rem;
    color: var(--text-light);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding-top: 2px;
}

.press-publication {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    color: var(--dark);
    font-style: italic;
    line-height: 1.4;
}

.press-title {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text-light);
    margin-top: 4px;
    line-height: 1.5;
}

.press-link {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: var(--text-light);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    white-space: nowrap;
    transition: color 0.2s ease;
}

.press-link:hover { color: var(--dark); }

@media (max-width: 768px) {
    .press-item {
        grid-template-columns: 1fr;
        gap: 6px;
        padding: 18px 0;
    }
}

/* ========================================
   CONTACT
   ======================================== */
.contact-content { max-width: 600px; }

.contact-intro {
    font-size: 1.15rem;
    line-height: 1.85;
    color: var(--text);
    margin-bottom: 40px;
}

.contact-social {
    margin-bottom: 48px;
    display: flex;
    gap: 24px;
}

.contact-social a {
    font-family: var(--font-body);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-light);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: color 0.2s ease;
}

.contact-social a:hover { color: var(--dark); }
.contact-social a svg { width: 18px; height: 18px; fill: currentColor; }

.contact-form { text-align: left; }
.form-group { margin-bottom: 24px; }

.form-group label {
    display: block;
    font-family: var(--font-body);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-light);
    margin-bottom: 8px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 0;
    font-family: var(--font-body);
    font-size: 1.05rem;
    color: var(--text);
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--rule);
    border-radius: 0;
    outline: none;
    transition: border-color 0.25s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus { border-bottom-color: var(--dark); }

.form-group textarea { height: 100px; resize: none; }

.form-group select {
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a6f6a' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0 center;
    background-size: 16px;
    padding-right: 24px;
}

.form-submit {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--white);
    background: var(--dark);
    border: none;
    padding: 16px 48px;
    cursor: pointer;
    transition: background 0.25s ease;
    margin-top: 8px;
}

.form-submit:hover { background: var(--sienna); }
.form-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.form-message {
    margin-top: 20px;
    padding: 16px 0;
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    display: none;
}

.form-message.success {
    display: block;
    color: var(--text);
    border-top: 1px solid var(--rule);
}

.form-message.error {
    display: block;
    color: var(--sienna);
    border-top: 1px solid var(--sienna);
}

/* ========================================
   FOOTER — full column layout
   ======================================== */
.footer {
    background: var(--dark);
    color: rgba(255,255,255,0.5);
    padding: 64px 48px 40px;
}

.footer-inner {
    max-width: 1440px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 48px;
    padding-bottom: 48px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-col h4 {
    font-family: var(--font-body);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: rgba(255,255,255,0.35);
    margin-bottom: 20px;
}

.footer-col-name {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    font-weight: 400;
    color: rgba(255,255,255,0.85);
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.footer-col-tagline {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: rgba(255,255,255,0.35);
    letter-spacing: 0.06em;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    padding: 4px 0;
}

.footer-col ul li a {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: rgba(255,255,255,0.5);
    transition: color 0.2s ease;
}

.footer-col ul li a:hover { color: rgba(255,255,255,0.85); }

.footer-social-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255,255,255,0.5);
    transition: color 0.2s ease;
}

.footer-social-link:hover { color: rgba(255,255,255,0.85); }
.footer-social-link svg { width: 16px; height: 16px; fill: currentColor; }

.footer-bottom {
    max-width: 1440px;
    margin: 0 auto;
    padding-top: 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-bottom p {
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: rgba(255,255,255,0.25);
    letter-spacing: 0.06em;
}

@media (max-width: 900px) {
    .footer { padding: 48px 24px 32px; }
    .footer-inner { grid-template-columns: 1fr 1fr; gap: 36px; }
    .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

@media (max-width: 600px) {
    .footer-inner { grid-template-columns: 1fr; }
}

[id] { scroll-margin-top: 64px; }
