/* ============================================
   ÉLAN — Arquitetura & Design
   ============================================ */

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

:root {
    --purple-darkest: #1a0f33;
    --purple-dark: #2d1b4e;
    --purple-medium: #3d2563;
    --purple-light: #6b4a8e;
    --gold: #d4af37;
    --gold-light: #e6c75a;
    --beige: #f5f1e8;
    --white: #ffffff;
    --text-light: #f0e6ff;
    --text-muted: rgba(240, 230, 255, 0.65);

    --font-display: 'Playfair Display', 'Garamond', Georgia, serif;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    --max-width: 1400px;
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    font-weight: 300;
    color: var(--text-light);
    background-color: var(--purple-dark);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.6;
}

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

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

::selection {
    background: var(--gold);
    color: var(--purple-dark);
}

/* ─── Cursor Customizado ─── */
.custom-cursor {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: rgba(212, 175, 55, 0.5);
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.2s ease, background-color 0.2s ease;
    mix-blend-mode: difference;
    will-change: transform;
}

/* ─── Header ─── */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1.75rem 4rem;
    transition: padding 0.4s ease, background-color 0.4s ease, backdrop-filter 0.4s ease;
}

.header.scrolled {
    padding: 1.1rem 4rem;
    background-color: rgba(26, 15, 51, 0.85);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.08);
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: var(--max-width);
    margin: 0 auto;
}

.nav-brand {
    font-family: var(--font-display);
    font-size: 1.5rem;
    letter-spacing: 4px;
    color: var(--gold);
    font-weight: 400;
}

.nav-list {
    display: flex;
    gap: 2.75rem;
    align-items: center;
}

.nav-link {
    color: var(--text-light);
    font-size: 0.82rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: color 0.3s ease;
    position: relative;
    padding: 4px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background-color: var(--gold);
    transition: width 0.4s var(--ease-out);
}

.nav-link:hover,
.nav-link.active {
    color: var(--gold);
}

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

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

.menu-toggle span {
    width: 26px;
    height: 1.5px;
    background-color: var(--text-light);
    transition: all 0.3s ease;
    transform-origin: center;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
    background-color: var(--gold);
}

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

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
    background-color: var(--gold);
}

/* ─── Hero Section ─── */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 6%;
    gap: 4rem;
    background:
        radial-gradient(circle at 20% 30%, rgba(107, 74, 142, 0.35), transparent 60%),
        radial-gradient(circle at 80% 70%, rgba(212, 175, 55, 0.08), transparent 55%),
        linear-gradient(135deg, var(--purple-darkest) 0%, var(--purple-dark) 60%, var(--purple-medium) 100%);
    overflow: hidden;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(1px 1px at 20% 30%, rgba(255,255,255,0.25), transparent),
        radial-gradient(1px 1px at 70% 80%, rgba(255,255,255,0.18), transparent),
        radial-gradient(1px 1px at 40% 60%, rgba(255,255,255,0.22), transparent),
        radial-gradient(1px 1px at 85% 15%, rgba(255,255,255,0.15), transparent);
    pointer-events: none;
    opacity: 0.5;
}

.hero-content {
    flex: 0 0 36%;
    z-index: 10;
    position: relative;
}

.hero-subtitle {
    font-family: var(--font-sans);
    font-size: 0.78rem;
    letter-spacing: 3.5px;
    margin-bottom: 1.25rem;
    font-weight: 400;
    color: var(--gold);
    text-transform: uppercase;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(4.5rem, 9vw, 8rem);
    letter-spacing: 10px;
    font-weight: 400;
    color: var(--gold);
    line-height: 0.95;
    margin-bottom: 1.5rem;
    background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold) 70%, #a8821f 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-tagline {
    font-size: 1rem;
    font-weight: 300;
    color: var(--text-muted);
    max-width: 380px;
    margin-bottom: 2rem;
    line-height: 1.6;
    font-style: italic;
}

.hero-image-container {
    flex: 1;
    height: 80vh;
    max-width: 60vw;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: 1fr 1fr;
    grid-template-areas:
        "quadro quadro quadro chaise chaise chaise chaise chaise mesajantar mesajantar mesajantar mesajantar"
        "mesa mesa mesa mesa mesa mesa mesa lareira lareira lareira lareira lareira";
    gap: 1.5rem;
    padding: 1rem;
    z-index: 5;
}

/* ─── Imagens do Hero em grid (sem sobreposição) ─── */
.img-hero {
    position: relative;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    object-fit: cover;
    box-shadow:
        0 30px 60px rgba(0, 0, 0, 0.5),
        0 15px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.8s var(--ease-out), filter 0.6s ease, box-shadow 0.6s ease;
    border-radius: 6px;
    animation: float 8s ease-in-out infinite;
    will-change: translate;
}

/* Cada imagem em sua própria célula do grid — rotação leve e delay escalonado */
.img-quadro {
    grid-area: quadro;
    rotate: -2deg;
    filter: brightness(0.9);
    animation-delay: 0s;
}

.img-chaise {
    grid-area: chaise;
    rotate: 1deg;
    animation-delay: 1.5s;
}

.img-mesajantar {
    grid-area: mesajantar;
    rotate: 2deg;
    animation-delay: 3s;
}

.img-mesa {
    grid-area: mesa;
    rotate: -1deg;
    animation-delay: 2.2s;
}

.img-lareira {
    grid-area: lareira;
    rotate: 1.5deg;
    animation-delay: 0.8s;
}

/* Animação flutuante usando a propriedade `translate` (independente de `transform`),
   para não conflitar com o `transform: scale` do hover. */
@keyframes float {
    0%, 100% { translate: 0 0; }
    50%      { translate: 0 -12px; }
}

.img-hero:hover {
    transform: scale(1.025);
    z-index: 10;
    filter: brightness(1.1);
    box-shadow:
        0 40px 80px rgba(0, 0, 0, 0.6),
        0 20px 40px rgba(212, 175, 55, 0.15);
    animation-play-state: paused;
}

/* ─── Botão Hero ─── */
.btn-discover {
    display: inline-block;
    margin-top: 1rem;
    padding: 14px 36px;
    border: 1px solid var(--gold);
    color: var(--gold);
    letter-spacing: 2.5px;
    transition: all 0.4s var(--ease-out);
    font-size: 0.78rem;
    text-transform: uppercase;
    font-weight: 400;
    position: relative;
    overflow: hidden;
    background: transparent;
}

.btn-discover::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gold);
    transform: translateX(-101%);
    transition: transform 0.5s var(--ease-out);
    z-index: -1;
}

.btn-discover:hover {
    color: var(--purple-darkest);
}

.btn-discover:hover::before {
    transform: translateX(0);
}

/* ─── Scroll Indicator ─── */
.scroll-indicator {
    position: absolute;
    bottom: 2.5rem;
    left: 50%;
    translate: -50% 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    color: var(--text-muted);
    font-size: 0.7rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    opacity: 0.7;
    transition: opacity 0.3s ease, color 0.3s ease;
    z-index: 10;
}

.scroll-indicator:hover {
    opacity: 1;
    color: var(--gold);
}

.scroll-indicator-line {
    width: 1px;
    height: 50px;
    background: linear-gradient(to bottom, var(--gold), transparent);
    position: relative;
    overflow: hidden;
}

.scroll-indicator-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 30%;
    background: var(--gold);
    animation: scrollLine 2.2s var(--ease-out) infinite;
}

@keyframes scrollLine {
    0%   { transform: translateY(-100%); opacity: 0; }
    30%  { opacity: 1; }
    100% { transform: translateY(340%); opacity: 0; }
}

/* ─── Section Header ─── */
.section-header {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 5rem;
}

.section-eyebrow {
    font-size: 0.72rem;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 1.2rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.9rem;
}

.section-eyebrow::before,
.section-eyebrow::after {
    content: '';
    width: 28px;
    height: 1px;
    background: var(--gold);
    opacity: 0.6;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 4rem);
    text-align: center;
    margin-bottom: 1.5rem;
    letter-spacing: 2px;
    font-weight: 400;
    color: var(--text-light);
    line-height: 1.15;
}

.section-lede {
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.8;
    font-weight: 300;
    max-width: 620px;
    margin: 0 auto;
}

/* ─── Projetos Section ─── */
.projetos {
    padding: 9rem 4rem;
    background-color: var(--purple-medium);
    position: relative;
}

.projetos::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    translate: -50% 0;
    width: 80px;
    height: 1px;
    background: var(--gold);
    opacity: 0.3;
}

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

.projeto-card {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    aspect-ratio: 4/3;
    cursor: pointer;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
    background: var(--purple-dark);
}

.projeto-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s var(--ease-out), filter 0.6s ease;
}

.projeto-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(26, 15, 51, 0.75) 0%, rgba(26, 15, 51, 0.15) 50%, transparent 100%);
    opacity: 0.85;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.projeto-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 2.2rem 2rem;
    z-index: 2;
    transform: translateY(calc(100% - 4.5rem));
    transition: transform 0.5s var(--ease-out);
}

.projeto-tag {
    display: inline-block;
    font-size: 0.68rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.6rem;
    font-weight: 500;
}

.projeto-overlay h3 {
    font-family: var(--font-display);
    font-size: 1.6rem;
    color: var(--white);
    font-weight: 400;
    letter-spacing: 1px;
    margin-bottom: 0.8rem;
    line-height: 1.2;
}

.projeto-overlay p {
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.55;
    opacity: 0;
    transition: opacity 0.4s ease 0.1s;
    max-width: 92%;
}

.projeto-card:hover img {
    transform: scale(1.08);
    filter: brightness(0.85);
}

.projeto-card:hover::after {
    opacity: 1;
}

.projeto-card:hover .projeto-overlay {
    transform: translateY(0);
}

.projeto-card:hover .projeto-overlay p {
    opacity: 1;
}

/* ─── Estúdio Section ─── */
.estudio {
    padding: 9rem 4rem;
    background-color: var(--purple-dark);
    position: relative;
}

.estudio-content {
    max-width: 760px;
    text-align: center;
    margin: 0 auto;
}

.estudio-content .section-title {
    margin-bottom: 2.5rem;
}

.estudio-texto {
    font-size: 1.1rem;
    line-height: 1.95;
    color: var(--text-light);
    font-weight: 300;
    letter-spacing: 0.3px;
    margin-bottom: 1.5rem;
    opacity: 0.85;
}

.estudio-texto:last-of-type {
    margin-bottom: 0;
}

.pilares {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    max-width: var(--max-width);
    margin: 6rem auto 0;
    padding-top: 5rem;
    border-top: 1px solid rgba(212, 175, 55, 0.15);
}

.pilar {
    padding: 1rem;
    text-align: left;
    position: relative;
}

.pilar-num {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 300;
    color: var(--gold);
    display: block;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.pilar h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--text-light);
    margin-bottom: 0.9rem;
    letter-spacing: 1px;
}

.pilar p {
    font-size: 0.95rem;
    line-height: 1.75;
    color: var(--text-muted);
    font-weight: 300;
}

/* ─── Contato Section ─── */
.contato {
    padding: 9rem 4rem;
    background: linear-gradient(180deg, var(--purple-dark) 0%, var(--purple-darkest) 100%);
    position: relative;
    overflow: hidden;
}

.contato::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.3), transparent);
}

.contato-content {
    max-width: 820px;
    margin: 0 auto;
    text-align: center;
    position: relative;
}

.contato-content .section-title {
    margin-bottom: 1.5rem;
}

.contato-texto {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 3.5rem;
    line-height: 1.7;
    font-weight: 300;
}

.contato-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    max-width: 780px;
    margin: 0 auto;
}

.contato-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    padding: 2rem 1.2rem;
    border: 1px solid rgba(212, 175, 55, 0.18);
    border-radius: 6px;
    transition: all 0.4s var(--ease-out);
    background: rgba(107, 74, 142, 0.06);
}

.contato-link:hover {
    border-color: var(--gold);
    background: rgba(212, 175, 55, 0.08);
    transform: translateY(-4px);
}

.contato-link-label {
    font-size: 0.72rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--gold);
    font-weight: 500;
}

.contato-link-value {
    font-family: var(--font-display);
    font-size: 1.05rem;
    color: var(--text-light);
    font-weight: 300;
    word-break: break-word;
    text-align: center;
}

/* ─── Footer ─── */
.footer {
    background-color: var(--purple-darkest);
    padding: 4rem 4rem 2.5rem;
    border-top: 1px solid rgba(212, 175, 55, 0.12);
}

.footer-top {
    text-align: center;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.08);
}

.footer-logo {
    font-family: var(--font-display);
    font-size: 2.5rem;
    letter-spacing: 10px;
    color: var(--gold);
    font-weight: 400;
    margin-bottom: 0.7rem;
    padding-left: 10px;
}

.footer-tagline {
    font-size: 0.78rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--text-muted);
    font-weight: 400;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: var(--max-width);
    margin: 2.5rem auto 0;
    gap: 1rem;
    flex-wrap: wrap;
}

.footer-copy,
.footer-credit {
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 1px;
    opacity: 0.7;
}

/* ─── Responsive: Tablet ─── */
@media (max-width: 1024px) {
    .header,
    .header.scrolled {
        padding: 1.5rem 3rem;
    }

    .hero {
        flex-direction: column;
        padding: 9rem 4rem 5rem;
        text-align: center;
        gap: 2rem;
    }

    .hero-content {
        flex: none;
    }

    .hero-tagline {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-image-container {
        width: 100%;
        max-width: 100%;
        height: 55vh;
    }

    .scroll-indicator {
        display: none;
    }

    .projetos,
    .estudio,
    .contato {
        padding: 6rem 3rem;
    }

    .pilares {
        gap: 1.8rem;
        margin-top: 4rem;
        padding-top: 4rem;
    }
}

/* ─── Responsive: Mobile ─── */
@media (max-width: 768px) {
    .header,
    .header.scrolled {
        padding: 1.3rem 1.75rem;
    }

    .nav-brand {
        font-size: 1.3rem;
    }

    .nav-list {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(26, 15, 51, 0.98);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        flex-direction: column;
        justify-content: center;
        padding: 2rem;
        gap: 2.5rem;
        transform: translateX(100%);
        transition: transform 0.5s var(--ease-out);
        z-index: 998;
    }

    .nav-list.active {
        transform: translateX(0);
    }

    .nav-link {
        font-size: 1.4rem;
        letter-spacing: 3px;
    }

    .menu-toggle {
        display: flex;
        position: relative;
        z-index: 1001;
    }

    .hero {
        padding: 7rem 1.75rem 4rem;
        min-height: auto;
    }

    .hero-title {
        letter-spacing: 6px;
    }

    .hero-subtitle {
        font-size: 0.72rem;
        letter-spacing: 2.5px;
    }

    .hero-tagline {
        font-size: 0.95rem;
    }

    .hero-image-container {
        height: 60vh;
        width: 100%;
        max-width: 100%;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: repeat(3, 1fr);
        grid-template-areas:
            "quadro     chaise"
            "mesajantar mesa"
            "lareira    lareira";
        gap: 0.9rem;
        padding: 0.5rem;
    }

    .section-header {
        margin-bottom: 3.5rem;
    }

    .section-title {
        letter-spacing: 1.5px;
    }

    .projetos,
    .estudio,
    .contato {
        padding: 5rem 1.5rem;
    }

    .projetos-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .projeto-overlay {
        padding: 1.8rem 1.5rem;
        transform: translateY(calc(100% - 4rem));
    }

    .projeto-overlay h3 {
        font-size: 1.35rem;
    }

    .estudio-texto {
        font-size: 1rem;
    }

    .pilares {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        margin-top: 3rem;
        padding-top: 3rem;
    }

    .pilar {
        text-align: center;
        padding: 0;
    }

    .contato-links {
        grid-template-columns: 1fr;
        gap: 1rem;
        max-width: 400px;
    }

    .contato-link {
        padding: 1.4rem 1rem;
    }

    .contato-link-value {
        font-size: 0.95rem;
    }

    .footer {
        padding: 3rem 1.5rem 2rem;
    }

    .footer-logo {
        font-size: 2rem;
        letter-spacing: 8px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }

    .custom-cursor {
        display: none;
    }
}

/* ─── Acessibilidade: reduz animações ─── */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .img-hero {
        animation: none;
    }

    html {
        scroll-behavior: auto;
    }
}
