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

:root {
    --color-bg: #faf9f6;
    --color-surface: #ffffff;
    --color-text: #1a1a1a;
    --color-text-muted: #6b6b6b;
    --color-border: #e2e0db;
    --color-accent: #1a1a1a;
    --color-accent-hover: #333;
    --color-dark: #141414;
    --font-display: 'EB Garamond', Georgia, serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --max-width: 1100px;
    --nav-height: 64px;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--nav-height);
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ---- NAV ---- */

nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: rgba(250, 249, 246, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-border);
    z-index: 1000;
    transition: box-shadow 0.3s ease, background 0.3s ease;
}

nav.scrolled {
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06);
}

nav.nav-dark {
    background: rgba(20, 20, 20, 0.85);
    border-bottom-color: rgba(255, 255, 255, 0.08);
}

nav.nav-dark .nav-logo {
    color: #fff;
}

nav.nav-dark .nav-links a {
    color: rgba(255, 255, 255, 0.7);
}

nav.nav-dark .nav-links a:hover {
    color: #fff;
}

nav.nav-dark .nav-toggle span {
    background: #fff;
}

.nav-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--color-text);
    text-decoration: none;
    letter-spacing: 0.01em;
    transition: color 0.3s ease;
}

.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--color-text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: var(--color-text);
}

.nav-links a.active:not(.nav-cta) {
    color: var(--color-text);
}

.nav-links a.active:not(.nav-cta)::after {
    content: '';
    display: block;
    height: 1px;
    background: currentColor;
    margin-top: 2px;
}

nav.nav-dark .nav-links a.active:not(.nav-cta) {
    color: #fff;
}

.nav-links .nav-cta {
    background: var(--color-accent);
    color: #fff;
    padding: 0.5rem 1.25rem;
    border-radius: 4px;
}

.nav-links .nav-cta:hover {
    background: var(--color-accent-hover);
    color: #fff;
}

.nav-links .nav-cta.active {
    box-shadow: 0 0 0 2px var(--color-bg), 0 0 0 3.5px var(--color-accent);
}

nav.nav-dark .nav-links .nav-cta.active {
    box-shadow: 0 0 0 2px rgba(20, 20, 20, 0.85), 0 0 0 3.5px #fff;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    flex-direction: column;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--color-text);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
}

/* ---- BUTTONS ---- */

.btn {
    display: inline-block;
    text-decoration: none;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    padding: 0.75rem 1.75rem;
    border-radius: 4px;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--color-accent);
    color: #fff;
}

.btn-primary:hover {
    background: var(--color-accent-hover);
}

.btn-outline {
    background: transparent;
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

.btn-outline:hover {
    border-color: var(--color-text);
}

.btn-outline-light {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.btn-outline-light:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1rem;
}

/* ---- HERO ---- */

#hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    text-align: center;
    padding: calc(var(--nav-height) + 3rem) 1.5rem 4rem;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(10, 10, 10, 0.75) 0%,
        rgba(10, 10, 10, 0.6) 40%,
        rgba(10, 10, 10, 0.35) 70%,
        rgba(10, 10, 10, 0.5) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 640px;
}

.hero-tag {
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 1.25rem;
}

.hero-content h1 {
    font-family: var(--font-display);
    font-size: clamp(3rem, 8vw, 5rem);
    font-weight: 400;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.01em;
    color: #fff;
}

.hero-sub {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.7;
    margin-bottom: 2.5rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ---- SECTIONS ---- */

section {
    padding: 6rem 1.5rem;
}

.section-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

section h2 {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 400;
    text-align: center;
    letter-spacing: -0.015em;
    margin-bottom: 0.75rem;
}

section h2::after {
    content: '';
    display: block;
    width: 40px;
    height: 1px;
    background: var(--color-border);
    margin: 1rem auto 0;
}

#contact h2::after {
    background: rgba(255, 255, 255, 0.2);
}

.section-subtitle {
    text-align: center;
    color: var(--color-text-muted);
    font-size: 1rem;
    margin-bottom: 3.5rem;
}

/* ---- ABOUT ---- */

#about {
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
}

.about-content {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
    align-items: center;
    margin-top: 2rem;
}

.about-photo {
    border-radius: 6px;
    overflow: hidden;
}

.about-photo img {
    width: 100%;
    height: auto;
    display: block;
}

.about-text {
    max-width: 560px;
}

.about-text p {
    color: var(--color-text-muted);
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 1rem;
}

.about-text p:first-child {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-style: italic;
    color: var(--color-text);
    line-height: 1.7;
    border-left: 2px solid var(--color-border);
    padding-left: 1.25rem;
}

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

/* ---- ENSEMBLES ---- */

#ensembles {
    background: var(--color-bg);
}

.ensemble-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.ensemble-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.ensemble-card:hover {
    border-color: #bbb;
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.ensemble-media {
    width: 100%;
}

.ensemble-media .video-wrap {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    background: var(--color-dark);
    cursor: pointer;
    overflow: hidden;
}

.ensemble-media .video-wrap img {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: translate(-50%, -50%);
    transition: transform 0.4s ease, filter 0.4s ease;
}

.ensemble-media .video-wrap:hover img {
    transform: translate(-50%, -50%) scale(1.03);
    filter: brightness(0.8);
}

.play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.9);
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
    z-index: 1;
}

.play-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 54%;
    transform: translate(-50%, -50%);
    border-style: solid;
    border-width: 8px 0 8px 14px;
    border-color: transparent transparent transparent rgba(255, 255, 255, 0.9);
}

.video-wrap:hover .play-btn {
    background: rgba(0, 0, 0, 0.55);
    border-color: #fff;
    transform: translate(-50%, -50%) scale(1.08);
}

.ensemble-media .video-wrap iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.ensemble-body {
    padding: 1.5rem 1.75rem 1.75rem;
}

.ensemble-card h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.ensemble-card p {
    color: var(--color-text-muted);
    font-size: 0.925rem;
    line-height: 1.7;
}

.ensemble-more {
    text-align: center;
    margin-top: 2.5rem;
}

/* ---- CONTACT (merged book + contact) ---- */

#contact {
    background: var(--color-dark);
    color: #fff;
}

#contact h2 {
    color: #fff;
}

#contact .section-subtitle {
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 2.5rem;
}

.contact-section {
    text-align: center;
    max-width: 560px;
}

#contact .btn-primary {
    background: #fff;
    color: var(--color-dark);
}

#contact .btn-primary:hover {
    background: rgba(255, 255, 255, 0.88);
}

.contact-email {
    margin-top: 2.5rem;
}

.contact-email a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.contact-email a:hover {
    color: #fff;
}

/* ---- FOOTER ---- */

footer {
    border-top: 1px solid var(--color-border);
    padding: 2.5rem 1.5rem;
}

.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

.footer-nav,
.footer-socials {
    display: flex;
    gap: 2rem;
}

.footer-nav a,
.footer-socials a {
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 0.8rem;
    transition: color 0.2s ease;
}

.footer-nav a:hover,
.footer-socials a:hover {
    color: var(--color-text);
}

.footer-nav a {
    font-weight: 500;
    letter-spacing: 0.02em;
}

.footer-socials {
    gap: 1.5rem;
}

.footer-copy {
    margin-top: 0.25rem;
}

/* ---- FOCUS STYLES ---- */

:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

#contact :focus-visible,
nav.nav-dark :focus-visible {
    outline-color: #fff;
}

/* ---- FADE-IN ANIMATION ---- */

.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---- REDUCED MOTION ---- */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .fade-in {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .ensemble-card,
    nav,
    .btn,
    .nav-links,
    .nav-toggle span,
    .nav-logo,
    .nav-links a,
    .contact-email a,
    .footer-nav a,
    .footer-socials a,
    .video-wrap img,
    .play-btn {
        transition: none;
    }
}

/* ---- RESPONSIVE ---- */

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: var(--nav-height);
        left: 0;
        right: 0;
        background: rgba(250, 249, 246, 0.98);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        flex-direction: column;
        padding: 2rem 1.5rem;
        gap: 1.5rem;
        border-bottom: 1px solid var(--color-border);
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.3s ease, opacity 0.3s ease;
    }

    nav.nav-dark .nav-links {
        background: rgba(20, 20, 20, 0.98);
        border-bottom-color: rgba(255, 255, 255, 0.08);
    }

    .nav-links.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .nav-links a {
        font-size: 1rem;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    #hero {
        min-height: 85vh;
        padding-top: calc(var(--nav-height) + 4rem);
    }

    section {
        padding: 4rem 1.25rem;
    }

    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .about-photo {
        max-width: 260px;
        margin: 0 auto;
    }

    .about-text p:first-child {
        border-left: none;
        padding-left: 0;
    }

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

    .footer-nav,
    .footer-socials {
        gap: 1.25rem;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        text-align: center;
        max-width: 280px;
    }
}
