/* =====================================================================
   REDESIGN LAYER (trial, 2026-10-16)
   Deep-navy + electric-blue "glow" look with scroll animations.
   It only adds on top of the existing styles. To switch it off, remove
   the two lines marked "REDESIGN" in index.html / software.html
   (this stylesheet and assets/js/reveal.js).
   Colours apply in dark mode only; light mode keeps the original look.
   ===================================================================== */

:root {
    --rd-navy: #000B1D;
    --rd-navy-2: #021230;
    --rd-blue: #1E6BFF;
    --rd-blue-2: #0047D6;
    --rd-cyan: #3FB6FF;
    --rd-line: rgba(255, 255, 255, 0.09);
    --rd-line-2: rgba(120, 170, 255, 0.28);
    --rd-text: #EAF0FF;
    --rd-muted: rgba(220, 230, 255, 0.62);
}

/* ---------- typography: Plus Jakarta Sans headings ---------- */
.hero h1, .showcase h2, .ps-title, .app-card h3, .desk-card h3,
.group-title, .st-title, #learn-tibetan h2, .newsletter-card h3,
.software-support h3, .statement p {
    font-family: 'Plus Jakarta Sans', 'Bricolage Grotesque', sans-serif !important;
}
.hero h1 { letter-spacing: -0.035em; }

/* ---------- page background ---------- */
html.dark body {
    background:
        radial-gradient(900px 600px at 85% -5%, rgba(30, 107, 255, 0.16), transparent 70%),
        radial-gradient(800px 700px at -10% 45%, rgba(30, 107, 255, 0.10), transparent 70%),
        var(--rd-navy);
    background-attachment: fixed;
}
html.dark .site-header {
    background: rgba(0, 11, 29, 0.78);
    -webkit-backdrop-filter: saturate(140%) blur(14px);
    backdrop-filter: saturate(140%) blur(14px);
}

/* ---------- hero: framed panel with living blue glow ---------- */
html.dark .hero {
    margin: 14px clamp(10px, 1.6vw, 22px) 0;
    border-radius: 30px;
    border: 1px solid var(--rd-line);
    overflow: hidden;
    background:
        radial-gradient(70% 80% at 12% 25%, rgba(30, 107, 255, 0.62), transparent 62%),
        radial-gradient(55% 70% at 92% 85%, rgba(0, 71, 214, 0.45), transparent 65%),
        linear-gradient(180deg, #001335, var(--rd-navy) 85%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 40px 120px -40px rgba(30, 107, 255, 0.45);
}
html.dark .hero::before {            /* fine grid texture */
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background-image:
        linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 40%, #000 30%, transparent 75%);
    mask-image: radial-gradient(ellipse at 50% 40%, #000 30%, transparent 75%);
}
html.dark .hero-glow .g1 { background: radial-gradient(circle, rgba(63, 182, 255, 0.35), transparent 65%); }
html.dark .hero-glow .g2 { background: radial-gradient(circle, rgba(30, 107, 255, 0.40), transparent 65%); }
html.dark .hero-glow .g3 { background: radial-gradient(circle, rgba(227, 184, 90, 0.14), transparent 70%); }
.hero-glow .g1 { animation: rd-drift-a 16s ease-in-out infinite alternate; }
.hero-glow .g2 { animation: rd-drift-b 20s ease-in-out infinite alternate; }
.hero-glow .g3 { animation: rd-drift-a 24s ease-in-out infinite alternate-reverse; }
@keyframes rd-drift-a { from { transform: translate(0, 0) scale(1); } to { transform: translate(60px, 40px) scale(1.15); } }
@keyframes rd-drift-b { from { transform: translate(0, 0) scale(1.1); } to { transform: translate(-70px, -30px) scale(0.92); } }
html.dark .hero-pill {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.18);
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
html.dark .hero-sub { color: var(--rd-muted); }
.hero-logo img { animation: rd-float 7s ease-in-out infinite; }
@keyframes rd-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ---------- pill eyebrows ---------- */
html.dark .eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 7px 16px; border-radius: 999px;
    border: 1px solid var(--rd-line-2);
    background: rgba(30, 107, 255, 0.10);
    color: #CFE0FF; letter-spacing: 0.14em;
}
html.dark .eyebrow::before {
    content: ''; width: 7px; height: 7px; border-radius: 50%;
    background: var(--rd-cyan); box-shadow: 0 0 10px var(--rd-cyan);
}
html.dark .showcase-lede { color: var(--rd-muted); }

/* ---------- Mobile / Computer switcher: glass + electric blue ---------- */
html.dark .ps-tile {
    background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.015));
    border-color: var(--rd-line);
}
html.dark .ps-tile:hover { border-color: var(--rd-line-2); background: rgba(30, 107, 255, 0.08); }
html.dark .ps-tile.active {
    background: linear-gradient(135deg, var(--rd-blue), var(--rd-blue-2));
    color: #fff;
    box-shadow: 0 22px 50px -18px rgba(30, 107, 255, 0.85), inset 0 1px 0 rgba(255,255,255,0.25);
}
html.dark .ps-tile.active .ps-icon { background: rgba(255,255,255,0.16); color: #fff; border-color: rgba(255,255,255,0.25); }
html.dark .ps-tile.active .ps-count, html.dark .ps-tile.active .ps-arrow { background: rgba(255,255,255,0.18); }
html.dark .ps-icon {
    background: linear-gradient(145deg, rgba(30,107,255,0.35), rgba(0,71,214,0.15));
    border-color: var(--rd-line-2); color: #CFE0FF;
}

/* ---------- cards: thin light rim + cursor-following glow ---------- */
.app-card, .desk-card, .software-teaser, .ps-tile, .newsletter-card, .software-support {
    --mx: 50%; --my: 50%;
}
.app-card::before, .desk-card::before {
    content: ''; position: absolute; inset: 0; z-index: 2; pointer-events: none;
    border-radius: inherit;
    background: radial-gradient(420px circle at var(--mx) var(--my), rgba(255,255,255,0.16), transparent 45%);
    opacity: 0; transition: opacity 0.35s ease;
}
.app-card:hover::before, .desk-card:hover::before { opacity: 1; }
html.dark .app-card, html.dark .desk-card {
    outline: 1px solid rgba(255, 255, 255, 0.10); outline-offset: -1px;
}
.app-card { transition: transform 0.45s cubic-bezier(.2,.7,.2,1), box-shadow 0.45s ease; }
.app-card:hover { transform: translateY(-8px); }

html.dark .software-teaser {
    background: radial-gradient(130% 160% at 100% 0%, rgba(30,107,255,0.30), rgba(0,71,214,0.12) 55%, rgba(255,255,255,0.02));
    border-color: var(--rd-line-2);
}
html.dark .st-eyebrow { color: #9CC3FF; }
html.dark .st-cta { color: var(--rd-blue-2); }

/* ---------- learn / statement / newsletter / footer ---------- */
html.dark .newsletter-card {
    background:
        radial-gradient(80% 120% at 0% 0%, rgba(30,107,255,0.55), transparent 60%),
        radial-gradient(70% 120% at 100% 100%, rgba(63,182,255,0.30), transparent 60%),
        #021232 !important;
    border: 1px solid var(--rd-line-2);
    box-shadow: 0 40px 100px -40px rgba(30,107,255,0.6);
}
html.dark .site-footer { border-top: 1px solid var(--rd-line); }

/* =====================================================================
   SCROLL REVEAL  (classes added by assets/js/reveal.js)
   Only active once the script runs, so content is never hidden without JS.
   ===================================================================== */
html.rd-anim [data-reveal] {
    opacity: 0;
    transform: translate3d(0, 34px, 0);
    transition: opacity 0.9s cubic-bezier(.2,.7,.2,1), transform 0.9s cubic-bezier(.2,.7,.2,1);
    transition-delay: var(--rd-delay, 0ms);
    will-change: opacity, transform;
}
html.rd-anim [data-reveal="zoom"] { transform: scale(0.92); }
html.rd-anim [data-reveal="left"] { transform: translate3d(-40px, 0, 0); }
html.rd-anim [data-reveal="right"] { transform: translate3d(40px, 0, 0); }
html.rd-anim [data-reveal].rd-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    html.rd-anim [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
    .hero-glow .g1, .hero-glow .g2, .hero-glow .g3, .hero-logo img { animation: none !important; }
}
