/* ============================================================================
   OakTree Games — Landing Page Styles
   Hero, feature showcase, tier ladder, gallery, CTA
   ============================================================================ */

/* ---------- HERO ---------- */
.hero {
    position: relative;
    min-height: calc(100vh - 64px);
    display: flex;
    align-items: center;
    overflow: hidden;
    padding: var(--sp-9) 0;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: var(--sp-9);
    align-items: center;
    position: relative;
    z-index: 2;
}
@media (max-width: 980px) {
    .hero-grid { grid-template-columns: 1fr; gap: var(--sp-6); }
    .hero { min-height: auto; padding: var(--sp-7) 0; }
}

.hero-eyebrow {
    display: inline-flex; align-items: center; gap: 10px;
    font-family: var(--font-pixel);
    font-size: 10px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--accent-oak);
    background: rgba(124,192,134,0.08);
    border: 1px solid var(--line-soft);
    padding: 6px 12px;
    margin-bottom: var(--sp-4);
}
.hero-eyebrow span.dot {
    width: 8px; height: 8px; background: var(--accent-oak);
    box-shadow: 0 0 10px var(--accent-oak);
    animation: pulse-dot 2.4s ease-in-out infinite;
}
@keyframes pulse-dot { 50% { opacity: 0.35; } }

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(40px, 7vw, 96px);
    line-height: 0.95;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    margin-bottom: var(--sp-5);
    color: var(--text-pri);
}
.hero-title .accent {
    background: linear-gradient(120deg, var(--accent-oak), var(--accent-aurora), var(--accent-cosmic));
    background-size: 200% 100%;
    background-position: 0 50%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    animation: shift-gradient 8s ease-in-out infinite;
}
@keyframes shift-gradient { 50% { background-position: 100% 50%; } }

.hero-sub {
    font-size: clamp(15px, 1.4vw, 19px);
    color: var(--text-sec);
    max-width: 56ch;
    margin-bottom: var(--sp-6);
    line-height: 1.65;
}

.hero-ctas {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-3);
    margin-bottom: var(--sp-6);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-5);
    padding-top: var(--sp-5);
    border-top: 1px dashed var(--line-soft);
}
.hero-meta-item {
    display: flex; flex-direction: column;
    gap: 2px;
    font-size: 13px;
}
.hero-meta-item strong {
    font-family: var(--font-pixel);
    font-size: 16px;
    color: var(--accent-oak);
    letter-spacing: 0.04em;
}
.hero-meta-item span {
    color: var(--text-mute);
    text-transform: uppercase;
    font-size: 10px;
    letter-spacing: 0.1em;
}

/* HERO PREVIEW (right column) */
.hero-preview {
    position: relative;
    aspect-ratio: 1 / 1;
    max-width: 560px;
    margin-left: auto;
    width: 100%;
}
@media (max-width: 980px) {
    .hero-preview { margin: 0 auto; max-width: 420px; }
}

.hero-preview-frame {
    position: absolute;
    inset: 0;
    border: 2px solid var(--line-soft);
    background: var(--bg-panel);
    box-shadow: 0 18px 60px rgba(0,0,0,0.55), 0 0 60px rgba(124,192,134,0.15);
    overflow: hidden;
}
.hero-preview-frame img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center;
}
.hero-preview-frame::after {
    content: "";
    position: absolute; inset: 0;
    background:
        linear-gradient(135deg, transparent 60%, rgba(124,192,134,0.12) 80%, transparent 100%),
        repeating-linear-gradient(0deg, rgba(255,255,255,0.02) 0 2px, transparent 2px 4px);
    pointer-events: none;
}

.hero-preview-overlay {
    position: absolute;
    z-index: 3;
    background: rgba(4,6,13,0.92);
    border: 1px solid var(--line-soft);
    padding: 12px 14px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.hero-preview-overlay--tl {
    top: 16px; left: 16px;
    font-family: var(--font-pixel);
    font-size: 9px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent-aurora);
    animation: float-up-down 6s ease-in-out infinite;
}
.hero-preview-overlay--br {
    bottom: 16px; right: 16px;
    display: flex; align-items: center; gap: 10px;
    animation: float-up-down 7s ease-in-out infinite reverse;
}
.hero-preview-overlay--br .badge-icon {
    width: 28px; height: 28px;
    background: var(--accent-oak);
    color: var(--bg-void);
    display: inline-flex; align-items: center; justify-content: center;
    font-family: var(--font-pixel); font-size: 12px;
}
.hero-preview-overlay--br .badge-text {
    font-family: var(--font-pixel);
    font-size: 9px;
    text-transform: uppercase;
    color: var(--text-pri);
    letter-spacing: 0.08em;
}
.hero-preview-overlay--br .badge-text small {
    display: block;
    color: var(--text-mute);
    font-size: 8px;
    margin-top: 2px;
    letter-spacing: 0.06em;
}
@keyframes float-up-down {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-6px); }
}

.hero-corner-emblem {
    position: absolute;
    inset: auto -4px -4px auto;
    width: 78px; height: 78px;
    background: var(--accent-cosmic);
    border: 2px solid var(--bg-void);
    transform: translate(28%, 28%) rotate(45deg);
    z-index: 1;
    box-shadow: var(--glow-cosm);
}
@media (max-width: 980px) {
    .hero-corner-emblem { width: 56px; height: 56px; }
}

/* ---------- TICKER ---------- */
.ticker {
    overflow: hidden;
    border-top: 1px solid var(--line-faint);
    border-bottom: 1px solid var(--line-faint);
    background: rgba(0,0,0,0.4);
    padding: 14px 0;
    margin-top: 0;
}
.ticker-track {
    display: flex;
    width: max-content;
    animation: ticker-slide 38s linear infinite;
    gap: var(--sp-6);
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-item {
    display: flex; align-items: center; gap: 10px;
    font-family: var(--font-pixel);
    font-size: 10px;
    color: var(--text-sec);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    white-space: nowrap;
}
.ticker-item::before {
    content: "▶";
    color: var(--accent-oak);
    font-size: 8px;
}
@keyframes ticker-slide {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ---------- FEATURE GRID ---------- */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--sp-5);
    margin-top: var(--sp-6);
}
@media (max-width: 880px) {
    .feature-grid { grid-template-columns: 1fr; }
}
.feature-card {
    background: var(--bg-panel);
    border: 1px solid var(--line-faint);
    padding: var(--sp-5);
    position: relative;
    transition: border-color 220ms ease, transform 220ms ease;
}
.feature-card:hover {
    border-color: var(--accent-oak);
    transform: translateY(-4px);
    box-shadow: var(--shadow-pixel-lg);
}
.feature-card .icon {
    width: 56px; height: 56px;
    display: inline-flex; align-items: center; justify-content: center;
    background: rgba(124,192,134,0.10);
    border: 1px solid var(--line-soft);
    color: var(--accent-oak);
    font-family: var(--font-pixel);
    font-size: 22px;
    margin-bottom: var(--sp-4);
}
.feature-card h3 {
    font-family: var(--font-pixel);
    font-size: 14px;
    letter-spacing: 0.04em;
    margin-bottom: var(--sp-3);
}
.feature-card p { font-size: 14px; line-height: 1.6; }

/* ---------- TIER LADDER ----------
   Eight tier-cards laid out as a grid that wraps responsively. Each
   card has its own --tier-bg color (passed inline) plus a layered
   background that includes a per-tier radial glow + a pixel-grid
   pattern for texture. Hover is instant (no easing delay on
   transform) so the user gets immediate feedback. */
.tier-ladder {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 8px;
    margin-top: var(--sp-6);
}
@media (max-width: 980px) {
    .tier-ladder { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 540px) {
    .tier-ladder { grid-template-columns: repeat(2, 1fr); }
}
.tier-card {
    position: relative;
    padding: var(--sp-4) var(--sp-3);
    text-align: center;
    border: 1px solid var(--line-faint);
    background:
        radial-gradient(ellipse 100% 60% at 50% 100%,
            color-mix(in srgb, var(--tier-bg, var(--accent-oak)) 14%, transparent),
            transparent 70%),
        linear-gradient(180deg,
            color-mix(in srgb, var(--tier-bg, var(--accent-oak)) 6%, var(--bg-panel)) 0%,
            var(--bg-panel) 100%);
    overflow: hidden;
    cursor: default;
    /* Snappier hover: transform is 110ms (was 220ms) so the lift fires
       immediately on cursor entry. Color/border transitions stay 200ms
       for a softer glow. */
    transition: transform 110ms cubic-bezier(.16, 1, .32, 1),
                border-color 200ms ease,
                box-shadow 200ms ease;
    will-change: transform;
}
/* top bar in tier color */
.tier-card::before {
    content: "";
    position: absolute; inset: 0 0 auto 0;
    height: 3px;
    background: var(--tier-bg, var(--accent-oak));
    box-shadow: 0 0 12px color-mix(in srgb, var(--tier-bg, var(--accent-oak)) 50%, transparent);
}
/* faint pixel-grid texture overlay */
.tier-card::after {
    content: "";
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
    background-size: 8px 8px;
    pointer-events: none;
    opacity: 0.5;
    transition: opacity 200ms ease;
}
.tier-card:hover {
    /* instant lift */
    transform: translateY(-6px);
    border-color: var(--tier-bg, var(--accent-oak));
    box-shadow:
        0 8px 24px rgba(0, 0, 0, 0.4),
        0 0 0 1px color-mix(in srgb, var(--tier-bg, var(--accent-oak)) 30%, transparent),
        0 0 28px color-mix(in srgb, var(--tier-bg, var(--accent-oak)) 35%, transparent);
}
.tier-card:hover::after { opacity: 1; }
/* Keyboard focus parity */
.tier-card:focus-visible {
    outline: none;
    transform: translateY(-6px);
    border-color: var(--tier-bg, var(--accent-oak));
    box-shadow: 0 0 0 2px var(--tier-bg, var(--accent-oak));
}
.tier-card .label {
    position: relative; z-index: 1;
    font-family: var(--font-pixel);
    font-size: 11px;
    color: var(--tier-bg, var(--accent-oak));
    letter-spacing: 0.06em;
    text-shadow: 0 0 10px color-mix(in srgb, var(--tier-bg, var(--accent-oak)) 50%, transparent);
}
.tier-card .name {
    position: relative; z-index: 1;
    margin-top: var(--sp-2);
    font-size: 12px;
    color: var(--text-pri);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}
.tier-card .blurb {
    position: relative; z-index: 1;
    font-size: 11px;
    color: var(--text-mute);
    margin-top: var(--sp-2);
    line-height: 1.4;
}

/* ---------- BIOME PREVIEW STRIP ---------- */
.biome-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--sp-4);
    margin-top: var(--sp-6);
}
.biome-card {
    aspect-ratio: 4 / 5;
    background: var(--bg-panel);
    border: 1px solid var(--line-faint);
    position: relative;
    overflow: hidden;
    padding: var(--sp-4);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    cursor: pointer;
    transition: transform 220ms ease, border-color 220ms ease;
}
.biome-card:hover {
    transform: translateY(-4px);
    border-color: var(--biome-color, var(--accent-oak));
}
.biome-card::before {
    content: "";
    position: absolute; inset: 0;
    background: var(--biome-bg, linear-gradient(180deg, #2e4a2c, #1a2d18));
    opacity: 0.78;
}
.biome-card::after {
    content: "";
    position: absolute; inset: 0;
    background:
        radial-gradient(circle at 30% 25%, rgba(255,255,255,0.20), transparent 35%),
        radial-gradient(circle at 70% 70%, rgba(0,0,0,0.45), transparent 50%);
    mix-blend-mode: overlay;
}
.biome-card-content {
    position: relative;
    z-index: 2;
}
.biome-card-content h4 {
    font-family: var(--font-pixel);
    font-size: 11px;
    letter-spacing: 0.06em;
    color: #ffffff;
    text-shadow: 0 2px 0 rgba(0,0,0,0.5);
    margin-bottom: 4px;
}
.biome-card-content span {
    display: inline-block;
    padding: 2px 8px;
    font-family: var(--font-pixel);
    font-size: 8px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: rgba(0,0,0,0.5);
    color: rgba(255,255,255,0.8);
}

/* ---------- SHOWCASE / SCREENS STRIP ---------- */
.showcase {
    position: relative;
    padding: var(--sp-8) 0;
    background:
        linear-gradient(180deg, transparent, rgba(0,0,0,0.4), transparent);
}
.showcase-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: var(--sp-4);
    margin-top: var(--sp-6);
    min-height: 480px;
}
@media (max-width: 880px) {
    .showcase-grid { grid-template-columns: 1fr; min-height: 0; }
}
.showcase-tile {
    background: var(--bg-panel);
    border: 1px solid var(--line-faint);
    position: relative;
    overflow: hidden;
    transition: transform 240ms ease, border-color 240ms ease;
    min-height: 200px;
}
.showcase-tile:hover {
    transform: scale(1.02);
    border-color: var(--accent-oak);
    z-index: 2;
}
.showcase-tile-feature {
    grid-row: span 2;
}
.showcase-tile img {
    width: 100%; height: 100%;
    object-fit: cover;
}
.showcase-tile .label {
    position: absolute;
    bottom: 12px; left: 12px;
    background: rgba(4,6,13,0.92);
    border: 1px solid var(--line-soft);
    padding: 6px 10px;
    font-family: var(--font-pixel);
    font-size: 9px;
    letter-spacing: 0.08em;
    color: var(--text-pri);
    text-transform: uppercase;
}

/* ---------- ARIA QUOTE ---------- */
.aria-quote {
    margin-top: var(--sp-8);
    padding: var(--sp-6);
    background: linear-gradient(135deg, rgba(102,224,198,0.06), rgba(165,131,255,0.04));
    border: 1px solid var(--line-soft);
    position: relative;
    overflow: hidden;
}
.aria-quote::before {
    content: "ARIA";
    position: absolute;
    top: 8px; right: 16px;
    font-family: var(--font-pixel);
    font-size: 9px;
    letter-spacing: 0.14em;
    color: var(--accent-aurora);
    opacity: 0.7;
}
.aria-quote::after {
    content: "";
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: var(--accent-aurora);
    box-shadow: 0 0 16px var(--accent-aurora);
}
.aria-quote p {
    font-family: var(--font-mono);
    font-size: 16px;
    color: var(--text-pri);
    line-height: 1.7;
    max-width: 64ch;
}
.aria-quote .signoff {
    display: block;
    margin-top: var(--sp-3);
    font-family: var(--font-pixel);
    font-size: 9px;
    letter-spacing: 0.14em;
    color: var(--accent-aurora);
}

/* ---------- BIG CTA ---------- */
.cta-big {
    padding: var(--sp-9) 0;
    text-align: center;
    background:
        radial-gradient(ellipse at 50% 50%, rgba(124,192,134,0.12), transparent 60%),
        linear-gradient(180deg, transparent, rgba(0,0,0,0.5));
    position: relative;
}
.cta-big h2 {
    font-size: clamp(32px, 5vw, 60px);
    margin-bottom: var(--sp-4);
}
.cta-big p {
    margin: 0 auto var(--sp-6) auto;
    max-width: 56ch;
    color: var(--text-sec);
    font-size: 17px;
}
.cta-row {
    display: inline-flex; gap: var(--sp-3); flex-wrap: wrap; justify-content: center;
}

/* ---------- PIXEL ART FRAME WRAPPER ---------- */
.pix-frame {
    padding: 8px;
    background: var(--bg-panel-hi);
    border: 1px solid var(--line-soft);
    position: relative;
}
.pix-frame::before,
.pix-frame::after {
    content: "";
    position: absolute;
    background: var(--accent-oak);
    width: 8px; height: 8px;
}
.pix-frame::before { top: -1px; left: -1px; }
.pix-frame::after  { bottom: -1px; right: -1px; }

/* ---------- TILT WRAPPER (for hero preview hover lean) ---------- */
.tilt-wrap {
    perspective: 1200px;
    transform-style: preserve-3d;
}
.tilt-target {
    /* No baseline transition. The JS sets transform on every mousemove
       via rAF; a CSS transition here would fight those updates and
       cause visible lag/jitter — same anti-pattern that made the biome
       wheel feel inconsistent. The snap-back transition is added by
       JS only on mouseleave (see initTilt in js/main.js). */
    transition: none;
    will-change: transform;
    transform-style: preserve-3d;
}

/* ---------- KARDASHEV TEASE (home page) ---------- */
/* Two-column layout: pitch copy on the left, inline SVG scale on the right.
   The SVG pulses on its inner ring to signal "you are here". */
.kardashev-tease {
    position: relative;
    overflow: hidden;
}
.kardashev-tease::before {
    /* Faint star-field backdrop so the section feels celestial without
       overpowering the diagram. Pure CSS, no asset cost. */
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(2px 2px at 14% 22%, rgba(255,216,107,0.5) 0, transparent 50%),
        radial-gradient(1px 1px at 78% 18%, rgba(102,224,198,0.55) 0, transparent 50%),
        radial-gradient(1px 1px at 32% 78%, rgba(165,131,255,0.4) 0, transparent 50%),
        radial-gradient(2px 2px at 88% 64%, rgba(255,255,255,0.45) 0, transparent 50%),
        radial-gradient(1px 1px at 50% 50%, rgba(102,224,198,0.3) 0, transparent 50%);
    pointer-events: none;
    z-index: 0;
}
.kardashev-tease > .container { position: relative; z-index: 1; }
.kardashev-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-6);
    align-items: center;
}
@media (max-width: 880px) {
    .kardashev-grid { grid-template-columns: 1fr; }
}
.kardashev-visual {
    display: flex;
    align-items: center;
    justify-content: center;
}
.kardashev-visual svg {
    width: 100%;
    max-width: 360px;
    height: auto;
}
