/* ---------------------------------------------------------
   INDEX / LANDING (NEON FABRICATION) — LOOPING + CENTERED
--------------------------------------------------------- */

.landing-wrap {
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 18px;
}

.landing-card {
    width: min(1100px, 96vw);
    background: radial-gradient(1200px 500px at 50% 0%, rgba(0, 175, 255, 0.08), rgba(0,0,0,0) 60%),
                linear-gradient(180deg, rgba(2, 4, 8, 0.88), rgba(2, 4, 8, 0.68));
    border: 1px solid #00AFFF33;
    border-radius: 18px;
    box-shadow:
        0 0 30px rgba(0, 175, 255, 0.18),
        0 0 90px rgba(0, 175, 255, 0.08);
    overflow: hidden;
    position: relative;
}

.landing-inner {
    padding: 22px 22px 26px 22px;
}

.landing-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #7FE8FF;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.85;
    margin-bottom: 10px;
}

.landing-top .left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.landing-top .pip {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: rgba(0, 175, 255, 0.6);
    box-shadow: 0 0 12px rgba(0, 175, 255, 0.55);
}

/* optional logo watermark (from templates/logo.php) */
.landing-logo {
    position: absolute;
    top: 16px;
    right: 18px;
    opacity: 0.20;
    transform: scale(0.92);
    filter: drop-shadow(0 0 10px rgba(0,175,255,0.18));
    pointer-events: none;
}
.landing-logo svg,
.landing-logo img {
    max-width: 120px;
    height: auto;
    display: block;
}

/* --- sign stage --- */
.sign-stage {
    margin: 12px auto 18px;
    width: min(980px, 92vw);
    aspect-ratio: 16/6;
    background:
        radial-gradient(700px 220px at 50% 30%, rgba(0,175,255,0.08), rgba(0,0,0,0) 65%),
        linear-gradient(180deg, rgba(7, 10, 16, 0.8), rgba(2, 3, 6, 0.85));
    border: 1px solid rgba(0, 175, 255, 0.15);
    border-radius: 14px;
    position: relative;
    box-shadow:
        inset 0 0 0 1px rgba(0, 175, 255, 0.06),
        inset 0 0 35px rgba(0, 0, 0, 0.75),
        0 0 22px rgba(0, 175, 255, 0.12);
    overflow: hidden;

    /* live-tuned vars (JS drives these) */
    --alive: 1;
    --jit: 0;            /* small electrical jitter */
    --power: 1;          /* overall brightness */
    --sweep: 1;          /* mask sweep strength */
}

/* subtle "metal backing plate" texture */
.sign-stage:before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255,255,255,0.03), rgba(255,255,255,0) 18%, rgba(255,255,255,0.02) 35%, rgba(255,255,255,0) 55%, rgba(255,255,255,0.025) 72%, rgba(255,255,255,0) 100%),
        repeating-linear-gradient(0deg, rgba(255,255,255,0.02), rgba(255,255,255,0.02) 1px, rgba(0,0,0,0) 2px, rgba(0,0,0,0) 6px);
    opacity: 0.22;
    pointer-events: none;
}

.sign-stage:after {
    content: "";
    position: absolute;
    inset: -80px;
    background: radial-gradient(circle at 50% 55%, rgba(0,175,255,0.12), rgba(0,0,0,0) 60%);
    filter: blur(18px);
    opacity: 0.6;
    pointer-events: none;
}

/* corner bolts */
.bolt {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: rgba(0,175,255,0.18);
    border: 1px solid rgba(0,175,255,0.25);
    box-shadow: 0 0 10px rgba(0,175,255,0.18);
}
.b1 { left: 12px; top: 12px; }
.b2 { right: 12px; top: 12px; }
.b3 { left: 12px; bottom: 12px; }
.b4 { right: 12px; bottom: 12px; }

.sign-svg {
    position: absolute;
    inset: 0;
}

.neon-caption {
    text-align: center;
    color: #bfefff;
    opacity: 0.9;
    margin-top: 6px;
    font-size: 14px;
    line-height: 1.25;
}

.neon-caption .sub {
    display: block;
    margin-top: 2px;
    color: #7FE8FF;
    opacity: 0.75;
    font-size: 12px;
}

/* CTA */
.landing-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding-bottom: 6px;
}

.landing-actions .hint {
    color: rgba(127, 232, 255, 0.75);
    font-size: 12px;
}

.landing-actions a.neon-btn {
    min-width: 240px;
}

/* ---------------------------------------------------------
   NEON SIGN ANIMATION — LOOPING, NO DUPES, CENTERED
   Upgrade:
   - Keep your fabricate + sweep
   - Add layered glow + live jitter driven by rAF (non-periodic)
   - No "two-state" look
--------------------------------------------------------- */

:root {
    --tube: rgba(120, 220, 255, 0.26);   /* unlit glass */
    --lit:  rgba(170, 245, 255, 1);      /* lit tube */
    --glow: rgba(0, 175, 255, 0.80);
    --cycle: 3.4s;
}

/* text baseline styling */
.neon-text {
    font-family: "Segoe UI", "Montserrat", Arial, sans-serif;
    font-size: 58px;
    letter-spacing: 2.2px;
    text-anchor: middle;
    dominant-baseline: middle;
}

/* unlit glass tube always visible (faint) */
.glass {
    fill: none;
    stroke: var(--tube);
    stroke-width: 10;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.60;
}

/* reveal sweep mask rect (SVG transforms need transform-box/origin) */
.reveal-sweep {
    transform-box: fill-box;
    transform-origin: center;
    animation: reveal_sweep var(--cycle) linear infinite;
    opacity: calc(0.88 * var(--sweep));
}

/* lit tube base (core neon) */
.lit {
    fill: none;
    stroke: var(--lit);
    stroke-width: 10;
    stroke-linecap: round;
    stroke-linejoin: round;

    filter: none;                 /* Core stays sharp */
    opacity: 0.95;

    stroke-dasharray: 1400;
    stroke-dashoffset: 1400;

    animation:
        fabricate_draw var(--cycle) ease-in-out infinite,
        neon_flicker   var(--cycle) linear infinite;
}

.lit-glow1 {
    fill: none;
    stroke: rgba(170, 245, 255, 0.9);
    stroke-width: 14;
    filter: url(#neonGlowWide1);
    opacity: calc((0.55 + (var(--jit) * 0.12)) * var(--power));
    animation: neon_breathe 3.2s ease-in-out infinite;
}

.lit-glow2 {
    fill: none;
    stroke: rgba(0, 175, 255, 0.6);
    stroke-width: 26;
    filter: url(#neonGlowWide2);
    opacity: calc((0.25 + (var(--jit) * 0.08)) * var(--power));
    animation: neon_breathe 4.1s ease-in-out infinite reverse;
}

.lit-shimmer {
    fill: none;
    stroke: rgba(255,255,255,0.35);
    stroke-width: 7;
    filter: url(#neonGlowCore);
    opacity: calc((0.08 + (var(--jit) * 0.05)) * var(--power));
}


/* ---------------------------------------------------------
   Keyframes
--------------------------------------------------------- */

@keyframes reveal_sweep {
    0%   { transform: translateX(-120%); }
    8%   { transform: translateX(-120%); }
    28%  { transform: translateX(120%);  }
    100% { transform: translateX(120%);  }
}

@keyframes fabricate_draw {
    0%   { stroke-dashoffset: 1400; opacity: 0; }
    8%   { stroke-dashoffset: 1400; opacity: 0; }
    28%  { stroke-dashoffset: 0;    opacity: 1; }
    78%  { stroke-dashoffset: 0;    opacity: 1; }
    100% { stroke-dashoffset: 0;    opacity: 1; }
}

@keyframes neon_breathe {
    0%, 100% { filter: drop-shadow(0 0 10px rgba(0,175,255,0.55)) drop-shadow(0 0 22px rgba(0,175,255,0.25)); }
    50%      { filter: drop-shadow(0 0 14px rgba(0,175,255,0.80)) drop-shadow(0 0 34px rgba(0,175,255,0.32)); }
}

/* Flicker burst near power-up, inside the main loop */
@keyframes neon_flicker {
    0%   { opacity: 0; }
    10%  { opacity: 0; }
    14%  { opacity: 0.25; }
    16%  { opacity: 0.95; }
    18%  { opacity: 0.30; }
    21%  { opacity: 1; }
    24%  { opacity: 0.55; }
    27%  { opacity: 1; }
    30%  { opacity: 0.78; }
    33%  { opacity: 1; }
    40%  { opacity: 1; }
    100% { opacity: 1; }
}

/* occasional micro flicker later in the loop */
@keyframes neon_micro {
    0%, 90%, 100% { opacity: 1; }
    92% { opacity: 0.92; }
    94% { opacity: 1; }
    96% { opacity: 0.95; }
    98% { opacity: 1; }
}

@media (max-width: 740px) {
    .landing-inner { padding: 18px; }
    .neon-caption { font-size: 13px; }
    .landing-logo { opacity: 0.16; transform: scale(0.85); }
}

/* ---------------------------------------------------------
   Logo widget (templates/logo.php, rendered only on this page)
--------------------------------------------------------- */
:root {
    --pavilion-base: #111;
    --pavilion-lines: #222;
    --pavilion-accent: #00afff;
}

.logo-container {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.pavilion-wrapper {
    position: relative;
    width: 120px;
    height: 100px;
    transform: skewY(-12deg) scale(1.1);
}

.roof {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: linear-gradient(to bottom, #151515, #0e0e10);
    clip-path: polygon(0% 100%, 50% 0%, 100% 100%);
    border-bottom: 2px solid var(--pavilion-lines);
    z-index: 3;
}

.posts {
    position: absolute;
    top: 38px;
    left: 0;
    width: 100%;
    height: 60px;
    display: flex;
    justify-content: space-between;
    padding: 0 6px;
    z-index: 1;
}

.post {
    width: 6px;
    height: 100%;
    background: var(--pavilion-base);
    box-shadow: 1px 0 2px var(--pavilion-lines);
}

.floor {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 10px;
    background: var(--pavilion-base);
    border-top: 2px solid var(--pavilion-lines);
    z-index: 0;
}
