/* ═══════════════════════════════════════════
   AEGEAN MUSES — Mediterranean Atelier
   ═══════════════════════════════════════════ */

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

:root {
    --alabaster: #F7F3EE;
    --marble: #EFEBE5;
    --taupe: #B8A49A;
    --taupe-light: #D4C8C1;
    --gold: #C9A96E;
    --gold-pale: #DCC99E;
    --charcoal: #2A2522;
    --charcoal-soft: #3D3633;
    --terracotta: #D4A98A;
    --olive: #8A8572;
    --white: #FDFCFA;
    --shadow-warm: rgba(42, 37, 34, 0.08);
    --shadow-deep: rgba(42, 37, 34, 0.15);
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    font-family: 'Outfit', sans-serif;
    font-weight: 300;
    color: var(--charcoal);
    background: var(--charcoal);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background: var(--gold-pale);
    color: var(--charcoal);
}

::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--charcoal); }
::-webkit-scrollbar-thumb { background: var(--gold); border-radius: 3px; }

h1, h2, h3, h4 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 300;
    line-height: 1.15;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* ── Grain ── */
.grain {
    position: fixed;
    inset: 0;
    z-index: 9000;
    pointer-events: none;
    opacity: 0.02;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px;
}

/* ── Loader ── */
.loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--charcoal);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.loader.loaded {
    opacity: 0;
    visibility: hidden;
}

.loader-text {
    font-family: 'Italiana', serif;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    color: var(--gold);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    animation: loaderPulse 1.5s ease-in-out infinite;
}

@keyframes loaderPulse {
    0%, 100% { opacity: 0.3; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1); }
}

/* ════════════════════════════════════════
   NAVIGATION
   ════════════════════════════════════════ */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 1.5rem 3rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.5s cubic-bezier(0.33, 1, 0.68, 1);
}

.nav.scrolled {
    background: rgba(42, 37, 34, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 0.8rem 3rem;
    box-shadow: 0 1px 0 rgba(201, 169, 110, 0.1);
}

.nav-logo-text {
    font-family: 'Italiana', serif;
    font-size: 0.95rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
}

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

.nav-links a {
    font-family: 'Outfit', sans-serif;
    font-size: 0.72rem;
    font-weight: 400;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--taupe);
    position: relative;
    padding-bottom: 2px;
    transition: color 0.3s;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--gold);
    transition: width 0.4s cubic-bezier(0.33, 1, 0.68, 1);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--gold-pale);
}

.nav-links a.active::after,
.nav-links a:hover::after {
    width: 100%;
}

.nav-socials {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.nav-socials a {
    color: var(--taupe);
    transition: color 0.3s;
    display: flex;
}

.nav-socials a:hover {
    color: var(--gold);
}

.nav-socials svg {
    width: 16px;
    height: 16px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 101;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 1.5px;
    background: var(--taupe);
    transition: all 0.3s ease;
}

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

/* ════════════════════════════════════════
   HERO (Home only)
   ════════════════════════════════════════ */

.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: -15% 0 0 0;
    background-size: cover;
    background-position: center 30%;
    transform: scale(1.1);
    transition: transform 0.1s linear;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(42, 37, 34, 0.5) 0%,
        rgba(42, 37, 34, 0.2) 40%,
        rgba(42, 37, 34, 0.3) 70%,
        rgba(42, 37, 34, 0.8) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem;
}

.hero h1 {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(3.5rem, 9vw, 8rem);
    font-weight: 300;
    color: var(--white);
    line-height: 1;
    margin-bottom: 1rem;
    opacity: 0;
    transform: translateY(30px);
    animation: heroReveal 1.2s ease forwards 0.5s;
}

.hero h1 em {
    font-style: italic;
    color: var(--gold-pale);
}

.hero-tagline {
    font-size: 0.75rem;
    font-weight: 400;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--taupe-light);
    opacity: 0;
    transform: translateY(20px);
    animation: heroReveal 1s ease forwards 0.8s;
}

.hero-scroll {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    opacity: 0;
    animation: heroReveal 1s ease forwards 1.2s;
}

.scroll-line {
    display: block;
    width: 1px;
    height: 50px;
    background: var(--gold);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes heroReveal {
    to { opacity: 1; transform: translateY(0) translateX(0); }
}

.hero-scroll { animation: heroReveal 1s ease forwards 1.2s; }

@keyframes scrollPulse {
    0%, 100% { opacity: 0.2; transform: scaleY(0.5); transform-origin: top; }
    50% { opacity: 1; transform: scaleY(1); }
}

/* ════════════════════════════════════════
   FEATURED STRIP (Home)
   ════════════════════════════════════════ */

.featured {
    padding: 0;
    background: var(--charcoal);
}

.featured-strip {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    min-height: 50vh;
}

.featured-card {
    position: relative;
    overflow: hidden;
    display: block;
}

.featured-card img {
    width: 100%;
    height: 100%;
    min-height: 350px;
    object-fit: cover;
    filter: saturate(0.6) brightness(0.7);
    transition: all 0.8s cubic-bezier(0.33, 1, 0.68, 1);
}

.featured-card:hover img {
    filter: saturate(0.9) brightness(0.85);
    transform: scale(1.05);
}

.featured-label {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 2;
    pointer-events: none;
}

.featured-eyebrow {
    font-family: 'Outfit', sans-serif;
    font-size: 0.65rem;
    font-weight: 400;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.featured-label h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 300;
    color: var(--white);
    letter-spacing: 0.05em;
}

/* ════════════════════════════════════════
   PAGE HEADER (Inner pages)
   ════════════════════════════════════════ */

.page-header {
    padding: 10rem 3rem 4rem;
    text-align: center;
    background: var(--charcoal);
}

.page-eyebrow {
    font-family: 'Outfit', sans-serif;
    font-size: 0.7rem;
    font-weight: 400;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 1rem;
}

.page-header h1 {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 300;
    color: var(--white);
}

/* ── Page Hero (Portfolio) ── */

.page-hero {
    position: relative;
    height: 60vh;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.page-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center top;
}

.page-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.page-hero-content h1 {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 300;
    color: var(--white);
}

.page-hero-content .page-eyebrow {
    margin-bottom: 1rem;
}

/* ════════════════════════════════════════
   MASONRY (Portfolio)
   ════════════════════════════════════════ */

.masonry-section {
    padding: 3rem 2rem 5rem;
    background: var(--charcoal);
}

.masonry {
    max-width: 1400px;
    margin: 0 auto;
    columns: 3;
    column-gap: 1rem;
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 1rem;
    overflow: hidden;
    cursor: pointer;
    position: relative;
}

.masonry-item img {
    width: 100%;
    display: block;
    transition: transform 0.7s cubic-bezier(0.33, 1, 0.68, 1), filter 0.5s ease;
    filter: saturate(0.8) brightness(0.92);
}

.masonry-item:hover img {
    transform: scale(1.03);
    filter: saturate(1) brightness(1);
}

/* ════════════════════════════════════════
   MUSE SECTIONS (Gallery)
   ════════════════════════════════════════ */

.muse-section {
    padding: 4rem 2rem 2rem;
    background: var(--charcoal);
}

.muse-label {
    max-width: 1400px;
    margin: 0 auto 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(201, 169, 110, 0.15);
}

.muse-label h2 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 300;
    color: var(--gold-pale);
    font-style: italic;
}

.muse-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.muse-grid .masonry-item {
    margin-bottom: 0;
}

.muse-grid .masonry-item img {
    width: 100%;
    height: 100%;
    aspect-ratio: 3/4;
    object-fit: cover;
}

/* ════════════════════════════════════════
   VIDEOS
   ════════════════════════════════════════ */

.videos-section {
    padding: 3rem 2rem 5rem;
    background: var(--charcoal);
}

.videos-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem;
}

.video-card {
    text-align: center;
}

.video-wrap {
    position: relative;
    overflow: hidden;
    background: #000;
    border: 1px solid rgba(201, 169, 110, 0.1);
}

.video-wrap video {
    width: 100%;
    display: block;
    aspect-ratio: 9/16;
    object-fit: contain;
    background: #000;
}

.video-card h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--taupe-light);
    margin-top: 1rem;
    letter-spacing: 0.02em;
}

/* ════════════════════════════════════════
   LIGHTBOX
   ════════════════════════════════════════ */

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 8000;
    background: rgba(20, 18, 16, 0.96);
    display: none;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
}

.lightbox.active {
    display: flex;
}

.lightbox-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    cursor: default;
}

.lightbox-close {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    background: none;
    border: none;
    color: var(--taupe);
    font-size: 2rem;
    cursor: pointer;
    transition: color 0.3s;
    z-index: 2;
}

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

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--taupe);
    font-size: 3rem;
    cursor: pointer;
    transition: color 0.3s;
    padding: 1rem;
    z-index: 2;
}

.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }
.lightbox-prev:hover,
.lightbox-next:hover { color: var(--gold); }

/* ════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════ */

.footer {
    background: rgba(42, 37, 34, 1);
    border-top: 1px solid rgba(201, 169, 110, 0.08);
    padding: 2.5rem 3rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-logo {
    font-family: 'Italiana', serif;
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--taupe);
}

.footer-copy {
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    color: var(--olive);
}

.footer-socials {
    display: flex;
    gap: 1.2rem;
    align-items: center;
}

.footer-socials a {
    color: var(--taupe);
    display: flex;
    transition: color 0.3s;
}

.footer-socials a:hover { color: var(--gold); }
.footer-socials svg { width: 16px; height: 16px; }

/* ════════════════════════════════════════
   SCROLL REVEAL
   ════════════════════════════════════════ */

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.33, 1, 0.68, 1), transform 0.7s cubic-bezier(0.33, 1, 0.68, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════ */

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

@media (max-width: 768px) {
    .nav {
        padding: 1rem 1.5rem;
    }

    .nav.scrolled {
        padding: 0.7rem 1.5rem;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 260px;
        height: 100vh;
        background: var(--charcoal);
        flex-direction: column;
        justify-content: center;
        gap: 2rem;
        padding: 2rem;
        transition: right 0.5s cubic-bezier(0.33, 1, 0.68, 1);
        box-shadow: -10px 0 40px rgba(0,0,0,0.4);
    }

    .nav-links.open { right: 0; }
    .nav-links a { font-size: 0.85rem; }

    .nav-socials { display: none; }
    .nav-toggle { display: flex; }

    .featured-strip {
        grid-template-columns: 1fr;
    }

    .featured-card img {
        min-height: 250px;
    }

    .page-header { padding: 8rem 1.5rem 3rem; }
    .masonry-section { padding: 2rem 1rem 3rem; }
    .masonry { columns: 2; column-gap: 0.6rem; }
    .masonry-item { margin-bottom: 0.6rem; }

    .muse-section { padding: 3rem 1rem 1rem; }
    .muse-grid { grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }
    .muse-label { margin-bottom: 1.5rem; }

    .videos-section { padding: 2rem 1rem 3rem; }
    .videos-grid { grid-template-columns: 1fr; gap: 2rem; }

    .footer {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
        padding: 2rem 1.5rem;
    }

    .lightbox-prev,
    .lightbox-next { font-size: 2rem; }
}

@media (max-width: 480px) {
    .masonry { columns: 1; }
    .hero h1 { font-size: clamp(2.5rem, 12vw, 4rem); }
    .hero-emblem { width: 70px; height: 70px; }
    .nav-logo-text { font-size: 0.75rem; }
}
