
:root {
    --bg: #0b0f17;
    --text: #e7ecf3;
    --muted: #9aa6b2;
    --accent: #7aa2ff;
    --card: rgba(255, 255, 255, 0.04);
    --border: rgba(255, 255, 255, 0.08);
    --shadow: rgba(0, 0, 0, 0.25);
    --radius: 14px;
}

.hero-names {
    margin: 0.5rem 0 0;
    text-align: center;
    font-size: clamp(0.9rem, 0.4vw + 0.8rem, 1.05rem);
    color: var(--muted);
}

.intro-text {
    max-width: 1000px;
    margin: 0.5rem auto 0;
}
.intro-text p {
    margin: 0;
    text-align: center;
    font-size: clamp(1rem, 0.45vw + 0.95rem, 1.25rem);
    color: var(--text);
}


.demo-note {
    max-width: 1500px; 
    width: calc(100% - 48px); 
    margin: 0 auto;
    padding: 1rem 1.2rem;
    border-radius: 14px;
    background:
            linear-gradient(180deg, rgba(46, 200, 120, 0.10), rgba(46, 200, 120, 0.06));
    border: 1px solid rgba(46, 200, 120, 0.35);
    box-shadow:
            0 10px 30px var(--shadow),
            0 0 0 1px rgba(46, 200, 120, 0.12) inset;
    backdrop-filter: blur(8px) saturate(120%);
    -webkit-backdrop-filter: blur(8px) saturate(120%);
}
.demo-note p {
    margin: 0;
    color: var(--text);
    text-align: center;
    font-size: clamp(1rem, 0.4vw + 0.95rem, 1.2rem);
    line-height: 1.6;
}


.demo-note-section { padding-bottom: 0; }
.demo-note-section + .section { padding-top: 0; }
.demo-note-section + .section .game-shell,
.demo-note-section + .section .skate-shell,
.demo-note-section + .section .space-shell { margin-top: 6px; }
.demo-note-section + .section .playfield { margin-top: 0; }


.tech-used {
    max-width: 1200px;
    margin: 0.5rem auto 0;
    display: flex;
    flex-wrap: wrap;
    gap: 18px 24px;
    justify-content: center;
    align-items: center;
}
.tech-used img {
    height: 56px;
    width: auto;
    display: block;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 20px var(--shadow);
    border: 1px solid var(--border);
    background: rgba(255,255,255,0.03);
    padding: 6px 8px;
}
.tech-used img:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 12px 28px var(--shadow); }


.tech-tooltip {
  position: fixed;
  top: 0; left: 0;
  transform: translate(16px, -50%);
  pointer-events: none;
  z-index: 1000;
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 0.9rem;
    color: var(--text);
    background: linear-gradient(180deg, rgba(46,200,120,0.18), rgba(46,200,120,0.12));
    border: 1px solid rgba(46,200,120,0.4);
    box-shadow: 0 8px 24px var(--shadow), 0 0 0 1px rgba(46,200,120,0.18) inset;
    backdrop-filter: blur(8px) saturate(120%);
    -webkit-backdrop-filter: blur(8px) saturate(120%);
    white-space: nowrap;
}


.names-tooltip {
  position: fixed;
  top: 0; left: 0;
  transform: translate(16px, -50%);
  pointer-events: none;
  z-index: 1000;
  padding: 6px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(46,200,120,0.18), rgba(46,200,120,0.12));
  border: 1px solid rgba(46,200,120,0.4);
  box-shadow: 0 8px 24px var(--shadow), 0 0 0 1px rgba(46,200,120,0.18) inset;
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
}
.names-tooltip img {
  display: block;
  width: 160px; 
  max-width: 220px;
  height: auto;
  border-radius: 8px;
}
* { box-sizing: border-box; }
html, body { height: 100%; overscroll-behavior: none; }

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}


.page-bg {
    position: fixed;
    inset: 0;
    background:
            radial-gradient(1000px 600px at 15% 20%, rgba(85, 120, 255, 0.06), transparent 60%),
            radial-gradient(1200px 800px at 85% 10%, rgba(255, 100, 100, 0.05), transparent 60%),
            radial-gradient(900px 700px at 60% 85%, rgba(120, 255, 200, 0.04), transparent 60%);
    filter: saturate(1.1) contrast(1.05);
    pointer-events: none;
    z-index: 0; 
}


.bg-blobs {
    position: absolute;
    inset: 0;
    pointer-events: none;
    transition: opacity 1000ms ease;
}
.bg-blobs .blob {
    position: absolute;
    left: var(--x);
    top: var(--y);
    width: var(--w);
    height: var(--h);
    
    background: radial-gradient(closest-side, var(--c) 0%, rgba(0,0,0,0) 70%);
    opacity: var(--a);
    border-radius: 50%;
    
    filter: blur(140px);
    transform: translate(-50%, -50%);
    
    mix-blend-mode: screen;
    will-change: opacity, transform, filter;
}

.container {
    width: min(1100px, 92%);
    margin: 0 auto;
}


.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.6rem 1rem;
    margin: 8px 8px 0; 
    border-radius: var(--radius);
    background: rgba(12, 16, 24, 0.55); 
    -webkit-backdrop-filter: blur(10px) saturate(120%);
    backdrop-filter: blur(10px) saturate(120%); 
    border: 1px solid var(--border);
    box-shadow: 0 10px 30px var(--shadow);
    position: relative; 
}


.nav-highlight {
    position: absolute;
    top: 0; left: 0;
    width: 0; height: 0;
    border-radius: 12px;
    background: rgba(255,255,255,0.16);
    border: 1px solid rgba(255,255,255,0.38);
    box-shadow: 0 6px 18px var(--shadow);
    pointer-events: none;
    z-index: 0; 
    transition: transform 280ms cubic-bezier(.2,.6,.2,1), opacity 180ms ease; 
    opacity: 0;
    will-change: transform, width, height, opacity;
    transform: translate3d(0,0,0);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}


.brand, .nav-links, .nav-right { position: relative; z-index: 1; }

.brand {
    font-weight: 800;
    letter-spacing: 0.2px;
    cursor: pointer; 
    display: inline-flex;
    align-items: center;
    border-radius: 10px;
    padding: 2px 6px;             
    border: 1px solid transparent; 
}


.nav-links {
    flex: 1 1 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}
.nav-btn {
    appearance: none;
    border: 1px solid var(--border);
    background: rgba(255,255,255,0.06);
    color: var(--text);
    font: inherit;
    padding: 6px 10px;
    border-radius: 10px;
    cursor: pointer;
    transition: background 160ms ease, border-color 160ms ease, transform 120ms ease;
    position: relative;
    z-index: 1;
}
.nav-btn:hover { background: rgba(255,255,255,0.10); transform: translateY(-1px); }
.nav-btn:active { background: rgba(255,255,255,0.06); }

.nav-btn.active { background: transparent; border-color: transparent; }
.nav-btn.active:hover { background: transparent; border-color: transparent; }
.nav-btn.active:active { background: transparent; border-color: transparent; }

.nav-btn:focus { outline: none; }
.nav-btn:focus-visible { outline: 2px solid rgba(255,255,255,0.35); outline-offset: 2px; }

.nav-btn.active:focus-visible { outline: none; }


.brand.active { background: transparent; border-color: transparent; }


.brand img {
  display: block;
  height: 30px;        
  max-height: 32px;    
  width: auto;         
  object-fit: contain; 
  filter: sepia(1) saturate(6) hue-rotate(0deg);
  animation: logoHue 18s linear infinite;
}


.logo-img {
  filter: sepia(1) saturate(6) hue-rotate(0deg);
  animation: logoHue 18s linear infinite;
}

@keyframes logoHue {
  0% { filter: sepia(1) saturate(6) hue-rotate(0deg); }
  100% { filter: sepia(1) saturate(6) hue-rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .brand img, .logo-img { animation: none; }
}

.nav-links {
    display: flex;
    gap: 0.75rem;
{{ ... }}
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    padding: 0.45rem 0.7rem;
    border-radius: 10px;
    border: 1px solid transparent;
}

.nav-links a:hover {
    background: var(--card);
    border-color: var(--border);
}

.nav-toggle {
    display: none;
    background: transparent;
    border: 0;
    padding: 0.25rem;
    border-radius: 8px;
    cursor: pointer;
}

.nav-toggle .bar {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px 0;
    background: var(--text);
    border-radius: 1px;
}


.hero {
    padding: 4rem 0 3rem;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2rem;
    align-items: center;
}

.hero-text h1 {
    margin: 0 0 0.5rem;
    font-size: clamp(2rem, 2.8vw + 1rem, 3.2rem);
}

.hero-text p { color: var(--muted); }

.hero-cta { margin-top: 1.25rem; display: flex; gap: 0.75rem; flex-wrap: wrap; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1rem;
    border-radius: 12px;
    color: var(--text);
    text-decoration: none;
    background: var(--card);
    border: 1px solid var(--border);
}


.btn:disabled {
    color: var(--muted);
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.06);
    cursor: not-allowed;
    opacity: 0.6;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), #9cc2ff);
    color: #0b1220;
    border: none;
}

.hero-media img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: 0 20px 50px var(--shadow);
}


.section { padding: 3rem 0; }
.section.alt { background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.0)); }

.section h2 {
    margin: 0 0 1rem;
    font-size: clamp(1.4rem, 1.2vw + 1rem, 2rem);
}

.cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin-top: 1rem;
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
}



.info-text {
    max-width: 1000px;
    margin: 0 auto;
}
.info-text p {
    margin: 0.75rem 0 0; 
    font-size: clamp(1.05rem, 0.45vw + 1rem, 1.35rem); 
    color: var(--text);
    text-wrap: pretty;
    text-align: center;
}
.info-text p + p { margin-top: 1.6rem; } 


.info-heading {
    margin: 1.5rem auto 0.6rem; 
    text-align: center;
    font-weight: 800;
    font-size: clamp(1.1rem, 0.6vw + 1rem, 1.4rem);
    color: var(--text);
}


.equation-block {
    text-align: center;
    font-weight: 800;
    font-size: clamp(1.6rem, 2.4vw + 1rem, 2.6rem);
    line-height: 1.25;
    margin: 0.6rem auto 0.9rem;
    color: var(--text);
}


.bio-block {
    max-width: 1000px;
    margin: 1.5rem auto 1.25rem; 
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 18px;
    align-items: stretch; 
}
.bio-img {
    width: 100%;
    height: 100%; 
    display: block;
    object-fit: cover; 
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 6px 24px var(--shadow);
}
.bio-text p {
    margin: 0;
    text-align: left; 
}


.def-block {
    max-width: 1100px; 
    margin: 0 auto 0; 
    display: grid;
    grid-template-columns: 260px 1fr; 
    gap: 22px; 
    align-items: stretch;
}
.def-img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain; 
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 6px 24px var(--shadow);
    background: rgba(255,255,255,0.02); 
}
.def-text p { margin: 0; text-align: left; }


.logo-block {
    max-width: 900px;
    margin: 0.25rem auto 0; 
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 16px;
    align-items: center;
}
.logo-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 6px 24px var(--shadow);
    background: rgba(255,255,255,0.02);
    padding: 6px; 
}
.logo-text p {
    margin: 0;
    text-align: left;
    font-size: clamp(0.95rem, 0.35vw + 0.9rem, 1.05rem); 
}

@media (max-width: 680px) {
    .bio-block {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .bio-text p {
        text-align: center;
    }
    .def-block { grid-template-columns: 1fr; }
    .def-text p { text-align: center; }
    .logo-block { grid-template-columns: 1fr; }
    .logo-text p { text-align: center; }
    
    .logo-img { width: 120px; max-width: 120px; margin: 0 auto; }
}


.info-text > * + * {
    margin-top: 1.8rem; 
}


.sources-list { max-width: 100%; }
.sources-list li { max-width: 100%; overflow-wrap: anywhere; word-break: break-word; }
.sources-list a {
    display: inline-block;      
    max-width: 100%;
    white-space: normal;        
    overflow-wrap: anywhere;    
    word-break: break-word;     
    line-break: anywhere;       
    hyphens: auto;              
}
@media (max-width: 700px) {
  
  .sources-list a { word-break: break-all; }
}

.card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--border);
    box-shadow: 0 10px 30px var(--shadow);
}

.card h3 { margin: 0.75rem 0 0.25rem; }
.card p { color: var(--muted); margin: 0; }


.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.feature {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
}


.gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.gallery img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--border);
}


summary { cursor: pointer; }

.details, details {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.75rem 1rem;
}


.contact-form {
    display: grid;
    gap: 1rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

label span { display: block; font-weight: 600; margin-bottom: 0.25rem; }
input, textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    color: var(--text);
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: 10px;
}


.site-footer { padding: 2rem 0; color: var(--muted); }
.site-footer p { margin: 0; text-align: center; }


@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; }
    .cards { grid-template-columns: repeat(2, 1fr); }
    .feature-grid { grid-template-columns: repeat(2, 1fr); }
    .gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 700px) {
    .nav-links { display: none; }
    .nav-toggle { display: inline-block; }
    .nav-links.open {
        display: grid;
        position: absolute;
        top: calc(100% + 10px);
        right: 1rem;
        background: rgba(12, 16, 24, 0.7);
        -webkit-backdrop-filter: blur(10px) saturate(120%);
        backdrop-filter: blur(10px) saturate(120%);
        border: 1px solid var(--border);
        border-radius: 12px;
        padding: 0.5rem;
        gap: 0.25rem;
        min-width: 180px;
    }
    
    .nav-highlight { display: none !important; }
    .navbar { position: relative; }
    .form-row { grid-template-columns: 1fr; }
    .cards { grid-template-columns: 1fr; }
    .feature-grid { grid-template-columns: 1fr; }
    .gallery { grid-template-columns: 1fr; }
}


.game-shell {
    position: relative; 
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.75rem;
    box-shadow: 0 15px 40px var(--shadow);
}

.playfield {
    width: 100%;
    height: auto;
    aspect-ratio: 900 / 280;
    display: block;
    touch-action: none;
    -ms-touch-action: none;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
    
    background: #000; 
    border: 1px solid var(--border);
    border-radius: 10px;
    position: relative;
    z-index: 2; 
}


.skate-shell { position: relative; }
.skate-container { position: relative; }
.skatefield { aspect-ratio: 900 / 360; }
.spacefield { aspect-ratio: 900 / 360; }
.skate-hud {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 8px;
    z-index: 3; 
}
.ball-select { display: flex; gap: 8px; }
.ball-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 12px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    cursor: pointer;
    padding: 4px;
}
.ball-btn img { width: 100%; height: 100%; object-fit: contain; }
.ball-btn.selected { outline: 2px solid var(--accent); background: rgba(122,162,255,0.15); }

.skate-controls { display: grid; gap: 0.5rem; }
.slider-row { display: grid; gap: 0.25rem; }
.actions-row { display: flex; gap: 0.5rem; }

.magnet-tray {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: 10px;
    min-height: 100%;
}

.tray-magnet {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    background: linear-gradient(135deg, #ff5a5a, #ff8b8b);
    border: 1px solid rgba(255,255,255,0.35);
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.2), 0 8px 18px var(--shadow);
}

.tray-magnet.hidden { visibility: hidden; }

body.carrying, canvas.playfield.carrying:hover {
    cursor: none !important;
}

@media (max-width: 700px) {
    .game-shell { grid-template-columns: 1fr; }
    .magnet-tray { min-height: 120px; }
    
    .ball-btn { width: 40px; height: 40px; border-radius: 10px; padding: 3px; }
    .ball-select { gap: 6px; }
}



main {
    padding-top: 88px; 
}


.hero-intro {
    padding: 4rem 0 2rem;
}
.hero-title-wrap {
    display: grid;
    place-items: center;
}
.hero-title {
    margin: 0;
    font-size: clamp(2.2rem, 4.5vw + 1rem, 5rem);
    font-weight: 800;
    letter-spacing: 0.5px;
    text-align: center;
    line-height: 1.1;
    background: linear-gradient(180deg, #e7ecf3, #a9b7c7);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 0 8px 30px rgba(122,162,255,0.25);
    opacity: 0;
    transform: translate3d(0, 18px, 0) scale(0.98);
    backface-visibility: hidden; /* reduce flicker on Edge/Blink during animation */
    will-change: opacity, transform, text-shadow;
    animation: heroIn 900ms ease forwards, heroGlow 4.5s ease-in-out 900ms infinite alternate;
}

@keyframes heroIn {
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes heroGlow {
    0% { text-shadow: 0 8px 24px rgba(122,162,255,0.18); }
    100% { text-shadow: 0 14px 42px rgba(122,162,255,0.35); }
}
