/* Gonzo's Quest 2 Demo - El Dorado Theme CSS */
/* Naming: Temple/Jungle/Quest Theme */

:root {
    --temple-gold: #C9A227;
    --temple-gold-dark: #9a7b1d;
    --jungle-deep: #2D5A27;
    --jungle-light: #3d7a37;
    --stone-brown: #8B4513;
    --stone-light: #a5623d;
    --void-jungle: #1a2e1a;
    --void-deeper: #0f1a0f;
    --moss: #2a3d2a;
    --ancient-text: #e8e4d4;
    --ancient-dim: #a09a8a;
    --vine: #3a5a3a;
    --ruby-gem: #c41e3a;
    
    --font-quest: 'Segoe UI', Tahoma, Geneva, sans-serif;
    --font-scroll: Georgia, 'Times New Roman', serif;
    
    --temple-gap: clamp(1rem, 3vw, 2rem);
    --ruin-radius: 6px;
    --shadow-deep: 0 4px 20px rgba(0,0,0,0.5);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: var(--font-scroll);
    background: var(--void-jungle);
    color: var(--ancient-text);
    line-height: 1.7;
    padding-top: 100px;
    min-height: 100vh;
}

/* RG Banner */
.quest-warning {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2000;
    background: linear-gradient(90deg, var(--jungle-deep) 0%, var(--stone-brown) 100%);
    color: #fff;
    padding: 8px 16px;
    font-size: 13px;
    text-align: center;
    font-family: var(--font-quest);
}

.quest-warning a { color: var(--temple-gold); text-decoration: underline; }

/* Header */
.temple-header {
    position: fixed;
    top: 0px;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(180deg, var(--void-jungle) 0%, var(--void-deeper) 100%);
    border-bottom: 2px solid var(--jungle-deep);
    padding: 18px 0 18px;
    transition: box-shadow 0.3s ease;
}

.temple-header.scrolled { box-shadow: var(--shadow-deep); }

.header-ruins {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--temple-gap);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.quest-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--ancient-text);
}

.quest-brand img { height: 60px; width: auto; }

.quest-brand span {
    font-family: var(--font-quest);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--temple-gold);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Navigation */
.jungle-nav {
    display: flex;
    gap: 8px;
}

.jungle-nav a {
    color: var(--ancient-dim);
    text-decoration: none;
    padding: 8px 16px;
    font-family: var(--font-quest);
    font-size: 0.9rem;
    border-radius: var(--ruin-radius);
    transition: all 0.2s ease;
}

.jungle-nav a:hover, .jungle-nav a.active {
    background: var(--jungle-deep);
    color: var(--temple-gold);
}

/* Mobile Toggle */
.vine-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.vine-toggle span {
    width: 24px;
    height: 2px;
    background: var(--temple-gold);
    transition: all 0.3s ease;
}

/* Hero Section */
.discovery-hero {
    position: relative;
    padding: 4rem var(--temple-gap);
    background: linear-gradient(135deg, var(--void-deeper) 0%, var(--void-jungle) 50%, var(--moss) 100%);
    overflow: hidden;
}

.discovery-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="%233a5a3a" opacity="0.3"/><circle cx="80" cy="40" r="1.5" fill="%233a5a3a" opacity="0.2"/><circle cx="50" cy="80" r="2.5" fill="%233a5a3a" opacity="0.25"/></svg>');
    background-size: 100px 100px;
    opacity: 0.4;
    pointer-events: none;
}

.hero-temple {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-scroll h1 {
    font-family: var(--font-quest);
    font-size: clamp(2rem, 5vw, 3rem);
    color: var(--temple-gold);
    line-height: 1.2;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-scroll h1 span {
    display: block;
    font-size: 0.5em;
    color: var(--ancient-dim);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 0.5rem;
}

.hero-tale {
    font-size: 1.1rem;
    color: var(--ancient-dim);
    margin-bottom: 2rem;
    max-width: 540px;
}

.quest-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-artifact {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    font-family: var(--font-quest);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: var(--ruin-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.btn-artifact.golden {
    background: linear-gradient(135deg, var(--temple-gold) 0%, var(--stone-brown) 100%);
    color: var(--void-jungle);
}

.btn-artifact.golden:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(201, 162, 39, 0.4);
}

.btn-artifact.stone {
    background: transparent;
    border: 2px solid var(--temple-gold);
    color: var(--temple-gold);
}

.btn-artifact.stone:hover {
    background: var(--temple-gold);
    color: var(--void-jungle);
}

.hero-artifact picture img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    /* border: 3px solid var(--jungle-deep); */
    box-shadow: var(--shadow-deep);
}

/* Stats Strip */
.treasure-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--jungle-deep);
    border-radius: var(--ruin-radius);
    overflow: hidden;
    margin-top: 2rem;
}

.stat-gem {
    background: var(--moss);
    padding: 1rem;
    text-align: center;
}

.stat-gem .label {
    display: block;
    font-size: 0.75rem;
    color: var(--ancient-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.stat-gem .value {
    font-family: var(--font-quest);
    font-size: 1.25rem;
    color: var(--temple-gold);
    font-weight: 700;
}

/* Content Sections */
.ruin-section {
    padding: 4rem var(--temple-gap);
    max-width: 1200px;
    margin: 0 auto;
}

.ruin-section:nth-child(even) { background: var(--moss);
    margin-top: 2rem;
    padding-top: 2rem;
    margin-bottom: 2rem;
}

.ruin-section a{color:var(--temple-gold)}

.section-inscription {
    font-family: var(--font-quest);
    font-size: clamp(1.5rem, 3vw, 2rem);
    color: var(--temple-gold);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--jungle-deep);
}

.section-inscription::before { content: '🏛️ '; }

/* Table Wrapper - Mobile Responsive */
.table-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 1.5rem 0;
    position: relative;
}

.table-wrapper::after {
    content: '→';
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255,255,255,0.4);
    font-size: 1.2rem;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s;
}

@media (max-width: 768px) {
    .table-wrapper::after { opacity: 1; }
    .table-wrapper.scrolled::after { opacity: 0; }
}

/* Tables */
.ancient-table {
    width: 100%;
    min-width: 500px;
    border-collapse: collapse;
    background: var(--moss);
    border-radius: var(--ruin-radius);
    overflow: hidden;
}

.ancient-table thead { background: var(--jungle-deep); }

.ancient-table th {
    padding: 14px 16px;
    text-align: left;
    font-family: var(--font-quest);
    color: var(--temple-gold);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ancient-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--vine);
    color: var(--ancient-dim);
}

.ancient-table tbody tr:last-child td { border-bottom: none; }
.ancient-table tbody tr:nth-child(even) { background: rgba(45, 90, 39, 0.15); }
.ancient-table tbody tr:hover { background: rgba(201, 162, 39, 0.1); }
.ancient-table .golden { color: var(--temple-gold); font-weight: 600; }

.table-wisdom {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--void-deeper);
    border-left: 3px solid var(--jungle-deep);
    font-size: 0.95rem;
    color: var(--ancient-dim);
}

/* Features Grid */
.power-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.power-stone {
    background: linear-gradient(145deg, var(--moss) 0%, var(--void-deeper) 100%);
    border: 1px solid var(--jungle-deep);
    border-radius: var(--ruin-radius);
    padding: 1.5rem;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.power-stone:hover {
    transform: translateY(-4px);
    border-color: var(--temple-gold);
}

.power-stone h3 {
    font-family: var(--font-quest);
    color: var(--temple-gold);
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
}

.power-stone p {
    color: var(--ancient-dim);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* FAQ Section */
.scroll-list { margin-top: 1.5rem; }

.scroll-item {
    background: var(--moss);
    border: 1px solid var(--jungle-deep);
    border-radius: var(--ruin-radius);
    margin-bottom: 1rem;
    overflow: hidden;
}

.scroll-question {
    width: 100%;
    background: none;
    border: none;
    padding: 1.25rem;
    text-align: left;
    font-family: var(--font-quest);
    font-size: 1rem;
    color: var(--temple-gold);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.scroll-question::after {
    content: '−';
    font-size: 1.5rem;
    color: var(--jungle-deep);
}

.scroll-answer {
    padding: 0 1.25rem 1.25rem;
    color: var(--ancient-dim);
    line-height: 1.7;
}

/* Screenshots Gallery */
.artifact-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.artifact-piece {
    position: relative;
    border-radius: var(--ruin-radius);
    overflow: hidden;
    border: 2px solid var(--jungle-deep);
}

.artifact-piece img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.4s ease;
}

.artifact-piece:hover img { transform: scale(1.03); }

.artifact-label {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(26, 46, 26, 0.95));
    padding: 2rem 1rem 1rem;
    color: var(--ancient-dim);
    font-size: 0.9rem;
}

/* Form */
.contact-form{margin:2rem 0}
.form-field{margin-bottom:1.5rem}
.form-field label{display:block;color:var(--temple-gold);margin-bottom:0.5rem;font-weight:600}
.form-field input,.form-field textarea{width:100%;padding:12px;background:rgba(201,162,39,0.05);border:1px solid var(--jungle-deep);border-radius:6px;color:var(--ancient-text);font-family:inherit;font-size:1rem}
.form-field textarea{min-height:150px;resize:vertical}
.form-submit{padding:14px 32px;background:var(--temple-gold);color:var(--void-jungle);font-weight:600;border:none;border-radius:6px;cursor:pointer;font-size:1rem}
.form-submit:hover{background:#8B4513;color:#fff}
.jungle-footer{background:rgba(0,0,0,0.3);border-top:2px solid var(--jungle-deep);padding:2rem 1.5rem;margin-top:3rem}
.footer-ancient{text-align:center;color:rgba(232,228,212,0.6);font-size:0.85rem}

/* CTA Section */
.treasure-cta {
    background: linear-gradient(135deg, var(--moss) 0%, var(--void-deeper) 100%);
    padding: 3rem var(--temple-gap);
    text-align: center;
    border-top: 2px solid var(--jungle-deep);
    border-bottom: 2px solid var(--jungle-deep);
}

.treasure-cta h2 {
    font-family: var(--font-quest);
    color: var(--temple-gold);
    font-size: 1.75rem;
    margin-bottom: 1rem;
}

.treasure-cta p {
    color: var(--ancient-dim);
    margin-bottom: 1.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Footer */
.jungle-footer {
    background: var(--void-deeper);
    padding: 3rem var(--temple-gap) 1.5rem;
    border-top: 2px solid var(--jungle-deep);
}

.footer-ruins {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.footer-pillar h4 {
    font-family: var(--font-quest);
    color: var(--temple-gold);
    font-size: 1rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-pillar ul { list-style: none; }
.footer-pillar li { margin-bottom: 0.5rem; }

.footer-pillar a {
    color: var(--ancient-dim);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.footer-pillar a:hover { color: var(--temple-gold); }

.footer-pillar p {
    color: var(--ancient-dim);
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-ancient {
    max-width: 1200px;
    margin: 2rem auto 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--vine);
    text-align: center;
    color: var(--ancient-dim);
    font-size: 0.85rem;
}

.footer-ancient a { color: var(--jungle-deep); text-decoration: none; }

/* Demo Modal */
.quest-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 3000;
    align-items: center;
    justify-content: center;
}

.quest-overlay.active { display: flex; }

.quest-chamber {
    position: relative;
    width: 95%;
    max-width: 1200px;
    aspect-ratio: 16/9;
    background: #000;
    border-radius: 8px;
    border: 3px solid var(--jungle-deep);
    overflow: hidden;
}

.quest-chamber iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.quest-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 44px;
    height: 44px;
    background: rgba(45, 90, 39, 0.8);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.quest-close:hover { background: var(--jungle-light); }

/* Mobile Sticky CTA */
.mobile-treasure {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1500;
    background: linear-gradient(180deg, transparent, var(--void-deeper) 20%);
    padding: 1rem;
    padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0));
}

.mobile-treasure .btn-artifact { width: 100%; justify-content: center; }

/* Responsive */
@media (max-width: 900px) {
    .hero-temple { grid-template-columns: 1fr; text-align: center; }
    .hero-scroll { order: 1; }
    .hero-artifact { order: 0; max-width: 500px; margin: 0 auto; }
    .quest-actions { justify-content: center; }
    .treasure-stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    body { padding-top: 90px; }
    
    .jungle-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--void-deeper);
        flex-direction: column;
        padding: 1rem;
        border-top: 1px solid var(--jungle-deep);
    }
    
    .jungle-nav.open { display: flex; }
    .vine-toggle { display: flex; }
    
    .vine-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
    .vine-toggle.active span:nth-child(2) { opacity: 0; }
    .vine-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
    
    .mobile-treasure { display: block; }
    .artifact-gallery { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .treasure-stats { grid-template-columns: 1fr 1fr; }
    .hero-scroll h1 { font-size: 1.75rem; }
    .quest-actions { flex-direction: column; }
    .btn-artifact { width: 100%; justify-content: center; }
}

:focus-visible { outline: 3px solid var(--temple-gold); outline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

@media print {
    .temple-header, .quest-warning, .mobile-treasure, .quest-overlay, .quest-actions { display: none !important; }
    body { padding-top: 0; background: #fff; color: #000; }
}
