:root {
    --bg: #f5ede2;
    --surface: rgba(251, 246, 240, 0.84);
    --surface-strong: #fbf6f0;
    --surface-accent: #efe2d3;
    --text: #3a1a0a;
    --muted: #7a5a46;
    --line: rgba(178, 121, 96, 0.18);
    --primary: #642a16;
    --primary-dark: #4b1d0f;
    --gold: #bc8653;
    --green: #8c8a67;
    --shadow: 0 18px 40px rgba(100, 42, 22, 0.12);
    --radius-lg: 28px;
    --radius-md: 18px;
    --radius-sm: 12px;
    --shell: min(1120px, calc(100vw - 32px));
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Manrope", sans-serif;
    background:
        radial-gradient(circle at top, rgba(188, 134, 83, 0.15), transparent 34%),
        radial-gradient(circle at 85% 20%, rgba(140, 138, 103, 0.1), transparent 30%),
        linear-gradient(180deg, #fbf3ea 0%, #f5ede2 48%, #ead9c9 100%);
    color: var(--text);
    line-height: 1.6;
}

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

a {
    color: inherit;
}

h1,
h2,
h3 {
    margin: 0 0 12px;
    font-family: "Cormorant Garamond", serif;
    line-height: 1.1;
}

p {
    margin: 0;
}

code {
    font-family: Consolas, monospace;
}

.shell {
    width: var(--shell);
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(16px);
    background: rgba(245, 237, 226, 0.88);
    border-bottom: 1px solid var(--line);
}

.nav-shell,
.footer-shell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px 0;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--gold));
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.brand-text {
    font-weight: 700;
    letter-spacing: 0.03em;
}

.nav-toggle {
    display: none;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(251, 246, 240, 0.88);
    color: var(--primary);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

.site-nav a {
    text-decoration: none;
    color: var(--muted);
    font-weight: 600;
}

.site-nav a:hover {
    color: var(--primary);
}

.section {
    padding: 72px 0;
}

.section-accent {
    background: rgba(188, 134, 83, 0.1);
    border-top: 1px solid rgba(188, 134, 83, 0.18);
    border-bottom: 1px solid rgba(188, 134, 83, 0.18);
}

.section-heading {
    max-width: 760px;
    margin-bottom: 32px;
}

.section-heading h1,
.section-heading h2,
.hero-content h1,
.lineage-copy h1 {
    font-size: clamp(2.6rem, 5vw, 4.9rem);
    letter-spacing: -0.03em;
}

.section-copy,
.hero-copy,
.panel p,
.profile-card p {
    color: var(--muted);
    font-size: 1rem;
}

.eyebrow {
    margin-bottom: 10px;
    color: var(--gold);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 50px;
    padding: 0 24px;
    border-radius: 999px;
    border: none;
    text-decoration: none;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.button:hover {
    transform: translateY(-2px);
}

.button-primary {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 12px 28px rgba(100, 42, 22, 0.24);
}

.button-secondary {
    background: rgba(251, 246, 240, 0.14);
    color: #fff;
    border: 1px solid rgba(240, 217, 200, 0.42);
}

.button-whatsapp {
    background: var(--green);
    color: #fff;
    box-shadow: 0 12px 28px rgba(140, 138, 103, 0.24);
}

.button-secondary-dark {
    background: #7a4b31;
    color: #fff;
    box-shadow: 0 12px 28px rgba(100, 42, 22, 0.2);
}

.panel {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow);
}

.panel-head {
    margin-bottom: 20px;
}

.hero {
    position: relative;
    min-height: calc(100vh - 77px);
    overflow: hidden;
    display: grid;
    place-items: center;
}

.hero-video,
.hero-overlay {
    position: absolute;
    inset: 0;
}

.hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.hero-video.is-active {
    opacity: 1;
}

.hero-overlay {
    background:
        linear-gradient(180deg, rgba(58, 26, 10, 0.24), rgba(58, 26, 10, 0.82)),
        radial-gradient(circle at center, rgba(188, 134, 83, 0.2), transparent 38%);
}

.hero-content {
    position: relative;
    z-index: 1;
    color: #fff;
    text-align: center;
    padding: 32px 0;
}

.hero-copy {
    max-width: 720px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.08rem;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 28px;
    flex-wrap: wrap;
}

.feature-layout {
    display: grid;
    grid-template-columns: 1.3fr 0.9fr;
    gap: 24px;
}

.video-panel,
.news-card,
.join-form,
.category-panel,
.order-panel,
.profile-card,
.biography-panel,
.empty-state {
    padding: 28px;
}

.video-frame {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    padding-top: 56.25%;
    background: #3a1a0a;
}

.youtube-player-shell {
    position: absolute;
    inset: 0;
}

.video-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.video-complete-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(58, 26, 10, 0.78);
    backdrop-filter: blur(8px);
}

.video-complete-overlay[hidden] {
    display: none;
}

.video-complete-card {
    max-width: 360px;
    padding: 24px;
    border-radius: 24px;
    background: rgba(251, 246, 240, 0.96);
    box-shadow: 0 18px 40px rgba(58, 26, 10, 0.18);
    text-align: center;
}

.video-complete-card h4 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.video-complete-card p {
    color: var(--muted);
    margin-bottom: 18px;
}

.video-complete-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.news-stack {
    display: grid;
    gap: 18px;
}

.join-layout {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 28px;
    align-items: start;
}

.contact-list {
    display: grid;
    gap: 14px;
    margin-top: 24px;
}

.contact-item {
    padding: 16px 18px;
    border-radius: var(--radius-md);
    background: rgba(251, 246, 240, 0.68);
    border: 1px solid var(--line);
}

.contact-item span {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--gold);
    font-weight: 700;
    margin-bottom: 6px;
}

.join-form {
    display: grid;
    gap: 16px;
}

.join-form label {
    display: grid;
    gap: 8px;
}

.join-form span {
    font-weight: 700;
}

.join-form input,
.join-form select,
.join-form textarea,
.quantity-input {
    width: 100%;
    border: 1px solid rgba(178, 121, 96, 0.18);
    border-radius: 14px;
    background: rgba(251, 246, 240, 0.94);
    color: var(--text);
    padding: 14px 16px;
    font: inherit;
}

.join-form textarea {
    resize: vertical;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 22px;
}

.gallery-grid-wide {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.media-tabs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
    padding: 6px;
    border-radius: 999px;
    background: rgba(251, 246, 240, 0.72);
    border: 1px solid var(--line);
}

.tab-button {
    min-height: 46px;
    padding: 0 20px;
    border: none;
    border-radius: 999px;
    background: transparent;
    color: var(--muted);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.tab-button:hover {
    transform: translateY(-1px);
}

.tab-button.is-active {
    background: var(--primary);
    color: #fff;
}

.tab-panel[hidden] {
    display: none;
}

.gallery-card {
    overflow: hidden;
    border-radius: 22px;
    background: rgba(251, 246, 240, 0.78);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.gallery-card img {
    width: 100%;
    aspect-ratio: 5 / 4;
    object-fit: cover;
}

.video-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 320px));
    gap: 22px;
    justify-content: start;
}

.video-gallery-card {
    overflow: hidden;
    border-radius: 22px;
    background: rgba(251, 246, 240, 0.78);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.video-gallery-frame {
    position: relative;
    overflow: hidden;
    border-radius: 22px 22px 0 0;
    background: #3a1a0a;
}

.video-gallery-frame iframe {
    display: block;
    width: 100%;
    aspect-ratio: 5 / 4;
    border: 0;
}

.video-gallery-copy {
    display: grid;
    gap: 12px;
    padding: 18px 18px 20px;
}

.video-gallery-copy h2 {
    font-size: 1.7rem;
}

.video-gallery-copy .button {
    width: 100%;
}

.products-layout {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr;
    gap: 24px;
    align-items: start;
}

.catalog-stack {
    display: grid;
    gap: 22px;
}

.product-list {
    display: grid;
    gap: 18px;
}

.product-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.product-row:first-child {
    padding-top: 0;
    border-top: 0;
}

.product-copy h3 {
    font-size: 1.7rem;
}

.quantity-control {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.quantity-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: rgba(100, 42, 22, 0.08);
    color: var(--primary);
    font-size: 1.3rem;
    font-weight: 700;
    cursor: pointer;
}

.quantity-input {
    width: 72px;
    text-align: center;
    padding: 10px 12px;
}

.order-summary {
    display: grid;
    gap: 12px;
    min-height: 140px;
    margin-bottom: 20px;
    color: var(--muted);
}

.summary-line {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--line);
}

.order-button {
    width: 100%;
}

.lineage-hero-grid {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    gap: 28px;
    align-items: center;
}

.lineage-image-wrap {
    padding: 16px;
    border-radius: 32px;
    background: linear-gradient(180deg, rgba(188, 134, 83, 0.18), rgba(178, 121, 96, 0.08));
}

.lineage-hero-image {
    width: 100%;
    height: 100%;
    min-height: 420px;
    object-fit: cover;
    border-radius: 24px;
}

.lineage-title,
.profile-title,
.muted-note {
    color: var(--gold);
}

.pill-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 24px 0 28px;
}

.lineage-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
}

.pill {
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(100, 42, 22, 0.08);
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 700;
}

.profile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 22px;
}

.compact-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.profile-card {
    text-align: left;
}

.profile-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    object-position: center top;
    border-radius: 20px;
    margin-bottom: 18px;
    background: #ead9c9;
}

.small-image {
    aspect-ratio: 4 / 4.2;
}

.profile-card h3 {
    font-size: 1.8rem;
}

.social-links {
    display: flex;
    gap: 14px;
    margin-top: 16px;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(100, 42, 22, 0.08);
    color: var(--primary);
    text-decoration: none;
}

.biography-panel {
    max-width: 840px;
}

.biography-panel p + p {
    margin-top: 14px;
}

.intro-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: grid;
    place-items: center;
    padding: 24px;
}

.intro-modal[hidden] {
    display: none;
}

.intro-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(58, 26, 10, 0.62);
    backdrop-filter: blur(6px);
}

.intro-modal-dialog {
    position: relative;
    z-index: 1;
    width: min(880px, 100%);
    max-height: min(90vh, 100%);
    overflow: auto;
}

.intro-modal-dialog .biography-panel {
    max-width: none;
}

.intro-modal-close {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 2;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border: none;
    border-radius: 50%;
    background: rgba(100, 42, 22, 0.08);
    color: var(--primary);
    cursor: pointer;
}

.empty-state {
    text-align: center;
}

.site-footer {
    border-top: 1px solid var(--line);
    background: rgba(239, 226, 211, 0.78);
}

.footer-title {
    font-weight: 800;
}

.footer-copy {
    color: var(--muted);
}

@media (max-width: 900px) {
    .shell {
        width: min(1120px, calc(100vw - 24px));
    }

    .feature-layout,
    .join-layout,
    .products-layout,
    .lineage-hero-grid {
        grid-template-columns: 1fr;
    }

    .lineage-hero-image {
        min-height: 340px;
    }
}

@media (max-width: 720px) {
    .shell {
        width: min(1120px, calc(100vw - 20px));
    }

    .nav-shell {
        flex-wrap: wrap;
        align-items: center;
        gap: 14px;
        padding: 14px 0;
    }

    .footer-shell {
        flex-direction: column;
        align-items: flex-start;
    }

    .brand {
        min-width: 0;
    }

    .brand-text {
        font-size: 0.95rem;
    }

    .nav-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .site-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 0;
        padding-top: 8px;
        border-top: 1px solid var(--line);
    }

    .site-nav.is-open {
        display: flex;
    }

    .site-nav a {
        display: block;
        width: 100%;
        padding: 12px 0;
    }

    .section {
        padding: 52px 0;
    }

    .hero {
        min-height: 72vh;
    }

    .hero-content {
        padding: 56px 0 44px;
    }

    .hero-copy {
        font-size: 1rem;
    }

    .hero-actions {
        gap: 12px;
    }

    .hero-actions .button {
        width: 100%;
    }

    .product-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .quantity-control {
        width: 100%;
        justify-content: space-between;
    }

    .video-panel,
    .news-card,
    .join-form,
    .category-panel,
    .order-panel,
    .profile-card,
    .biography-panel,
    .empty-state {
        padding: 22px;
    }

    .video-complete-card {
        padding: 20px;
    }

    .video-complete-card h4 {
        font-size: 1.7rem;
    }

    .lineage-image-wrap {
        padding: 12px;
        border-radius: 24px;
    }

    .lineage-hero-image {
        min-height: 280px;
        border-radius: 18px;
    }

    .pill-row {
        margin: 20px 0 22px;
    }

    .lineage-actions {
        width: 100%;
    }

    .lineage-actions .button {
        width: 100%;
    }

    .profile-card h3,
    .product-copy h3,
    .video-gallery-copy h2 {
        font-size: 1.55rem;
    }

    .media-tabs {
        display: flex;
        width: 100%;
    }

    .tab-button {
        flex: 1 1 0;
    }

    .video-gallery-copy .button {
        width: 100%;
    }

    .intro-modal {
        padding: 14px;
    }

    .intro-modal-close {
        top: 12px;
        right: 12px;
    }
}

@media (max-width: 520px) {
    .brand-mark {
        width: 36px;
        height: 36px;
        font-size: 0.85rem;
    }

    .button {
        width: 100%;
        padding: 0 18px;
    }

    .section-heading h1,
    .section-heading h2,
    .hero-content h1,
    .lineage-copy h1 {
        font-size: clamp(2.1rem, 10vw, 3.2rem);
    }

    .video-complete-card h4 {
        font-size: 1.45rem;
    }

    .summary-line {
        flex-direction: column;
        gap: 6px;
    }

    .quantity-input {
        width: 64px;
    }

    .profile-grid,
    .compact-grid,
    .gallery-grid,
    .gallery-grid-wide,
    .video-gallery-grid {
        grid-template-columns: 1fr;
    }
}
