/* =========================================================
   ROOT VARIABLES & RESET
========================================================= */
:root {
    --bg-dark: #020612;
    --bg-card: rgba(8, 18, 34, 0.75);
    --cyan-glow: #00e5ff;
    --cyan-bright: #38bdf8;
    --blue-accent: #1d4ed8;
    --text-main: #ffffff;
    --text-muted: #cbd5e1;
    --text-sub: #8493a8;
    --border-glass: rgba(56, 189, 248, 0.18);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    min-height: 100vh;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    overflow-y: auto;
}

/* =========================================================
   BACKGROUND WAVE & NEON GLOWS
========================================================= */
.bg-scene {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
    background: url("../images/main_home_bg.png") no-repeat center right / cover;
}

/* =========================================================
   PAGE PRELOADER ANIMATION
========================================================= */
#page-preloader {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: #020612;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

#page-preloader.fade-out {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.preloader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.preloader-spinner {
    position: relative;
    width: 68px;
    height: 68px;
    display: grid;
    place-items: center;
}

.spinner-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid rgba(0, 229, 255, 0.15);
    border-top-color: #00e5ff;
    border-right-color: #38bdf8;
    animation: spin 0.9s linear infinite;
    box-shadow: 0 0 20px rgba(0, 229, 255, 0.4);
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.preloader-db-icon {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: #00e5ff;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 0 8px #00e5ff);
}

.preloader-text {
    font-size: 1.1rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    color: #ffffff;
}

.preloader-text span {
    color: var(--cyan-glow);
}

/* =========================================================
   PAGE CONTAINER (SINGLE VIEWPORT 100VH FIT)
========================================================= */
.page-container {
    position: relative;
    z-index: 10;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    max-width: 1440px;
    margin: 0 auto;
    padding: 18px 40px;
    overflow-x: hidden;
}

/* =========================================================
   NAVBAR HEADER
========================================================= */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    height: 52px;
}

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

.brand-logo-box {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, #00e5ff 0%, #0284c7 100%);
    display: grid;
    place-items: center;
    box-shadow: 0 0 20px rgba(0, 229, 255, 0.5);
}

.brand-db-svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: #ffffff;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-size: 1.2rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    color: #ffffff;
    line-height: 1.1;
}

.brand-title span {
    color: var(--cyan-glow);
}

.brand-subtitle {
    font-size: 0.56rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    color: var(--text-sub);
    margin-top: 2px;
}

/* Nav Right Actions */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 14px;
}

.btn-nav-login {
    height: 38px;
    padding: 0 24px;
    border-radius: 99px;
    background: rgba(12, 26, 46, 0.7);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #ffffff;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.btn-nav-login:hover {
    background: rgba(24, 44, 74, 0.85);
    border-color: var(--cyan-bright);
    box-shadow: 0 0 15px rgba(0, 229, 255, 0.25);
}

.btn-nav-register {
    height: 38px;
    padding: 0 26px;
    border-radius: 99px;
    background: linear-gradient(90deg, #00e5ff 0%, #00b0ff 100%);
    color: #020612;
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(0, 229, 255, 0.45);
    transition: all 0.3s ease;
}

.btn-nav-register:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 229, 255, 0.65);
}

/* =========================================================
   HERO SECTION GRID
========================================================= */
.hero-section {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex: 1;
    padding: 10px 0;
}

/* Left Hero Content */
.hero-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: 600px;
}

/* First-fold helpers: transparent on desktop so desktop layout is 100% untouched */
.hero-first-fold {
    display: contents;
}

#bgNetworkCanvas {
    display: none;
}

.hero-mobile-db-stage {
    display: none;
}

.hero-mobile-canvas-box {
    display: none;
}

.hero-text-group {
    display: contents;
}

.hero-spacer-anim {
    display: none;
}

.hero-actions-container {
    display: contents;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 14px;
    border-radius: 99px;
    background: rgba(0, 229, 255, 0.06);
    border: 1px solid rgba(0, 229, 255, 0.3);
    font-family: 'Fira Code', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    color: var(--cyan-bright);
    margin-bottom: 20px;
}

.badge-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 10px #22c55e;
    animation: pulseDot 2.4s ease-in-out infinite;
}

@keyframes pulseDot {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 8px #22c55e;
    }

    50% {
        transform: scale(1.25);
        box-shadow: 0 0 14px #22c55e, 0 0 20px rgba(34, 197, 94, 0.4);
    }
}

.hero-headline {
    font-size: 3.8rem;
    font-weight: 900;
    line-height: 1.08;
    letter-spacing: -0.02em;
    color: #ffffff;
    margin-bottom: 18px;
}

.hero-headline span {
    color: var(--cyan-glow);
    text-shadow: 0 0 25px rgba(0, 229, 255, 0.6);
}

.hero-subtitle {
    font-size: 1.05rem;
    font-weight: 400;
    line-height: 1.55;
    color: var(--text-muted);
    margin-bottom: 30px;
}

/* Hero Action Buttons */
.hero-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 8px;
    margin-bottom: 38px;
    width: 100%;
}

.btn-hero-primary {
    height: 46px;
    padding: 0 24px;
    border-radius: 12px;
    background: linear-gradient(90deg, #00e5ff 0%, #00b0ff 100%);
    color: #020612;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 0.92rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    box-shadow: 0 4px 18px rgba(0, 229, 255, 0.35);
    transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
}

.btn-hero-primary:hover {
    transform: translateY(-2px);
    filter: brightness(1.08);
    box-shadow: 0 8px 24px rgba(0, 229, 255, 0.55);
}

.btn-hero-primary:active {
    transform: translateY(0);
}

.btn-cta-arrow {
    width: 17px;
    height: 17px;
    stroke: #020612;
    fill: none;
    stroke-width: 2.4;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.2s ease;
}

.btn-hero-primary:hover .btn-cta-arrow {
    transform: translateX(3px);
}

.btn-hero-secondary {
    height: 46px;
    padding: 0 24px;
    border-radius: 12px;
    background: rgba(10, 24, 46, 0.75);
    border: 1px solid rgba(56, 189, 248, 0.28);
    color: #ffffff;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 0.90rem;
    font-weight: 700;
    transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease, transform 0.22s ease;
}

.btn-hero-secondary:hover {
    background: rgba(18, 38, 70, 0.9);
    border-color: rgba(56, 189, 248, 0.6);
    box-shadow: 0 0 16px rgba(56, 189, 248, 0.25);
    transform: translateY(-2px);
    color: #ffffff;
}

.btn-hero-secondary:active {
    transform: translateY(0);
}

.btn-cta-icon {
    width: 17px;
    height: 17px;
    stroke: var(--cyan-bright);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.2s ease;
}

.btn-hero-secondary:hover .btn-cta-icon {
    transform: translateX(2px);
}

/* Hero Feature Bar (3 Stats) */
.hero-features-bar {
    display: flex;
    align-items: center;
    gap: 28px;
    padding-top: 20px;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    width: 100%;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.feature-item-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(0, 229, 255, 0.08);
    border: 1px solid rgba(0, 229, 255, 0.25);
    display: grid;
    place-items: center;
}

.feature-item-icon svg {
    width: 18px;
    height: 18px;
    stroke: var(--cyan-glow);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.feature-item-text {
    display: flex;
    flex-direction: column;
}

.feature-item-title {
    font-size: 0.82rem;
    font-weight: 700;
    color: #ffffff;
}

.feature-item-desc {
    font-size: 0.68rem;
    color: var(--text-sub);
    margin-top: 1px;
}

/* =========================================================
   BOTTOM FEATURE CARDS GRID (4 CARDS)
========================================================= */
.bottom-features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-bottom: 6px;
}

.feature-card {
    padding: 18px 20px;
    border-radius: 16px;
    background: rgba(5, 20, 38, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.14);
    backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

/* Card 1 — Cyan */
.feature-card:nth-child(1) .card-icon-wrapper {
    background: rgba(6, 182, 212, .10);
    border-color: rgba(6, 182, 212, .30);
}

.feature-card:nth-child(1) .card-icon-wrapper svg {
    stroke: #22D3EE;
}

.feature-card:nth-child(1):hover {
    border-color: rgba(6, 182, 212, .38);
    box-shadow: 0 14px 32px rgba(6, 182, 212, .14);
}

.feature-card:nth-child(1):hover .card-icon-wrapper {
    background: rgba(6, 182, 212, .18);
    border-color: rgba(6, 182, 212, .55);
}

/* Card 2 — Violet */
.feature-card:nth-child(2) .card-icon-wrapper {
    background: rgba(139, 92, 246, .10);
    border-color: rgba(139, 92, 246, .30);
}

.feature-card:nth-child(2) .card-icon-wrapper svg {
    stroke: #a78bfa;
}

.feature-card:nth-child(2):hover {
    border-color: rgba(139, 92, 246, .38);
    box-shadow: 0 14px 32px rgba(139, 92, 246, .14);
}

.feature-card:nth-child(2):hover .card-icon-wrapper {
    background: rgba(139, 92, 246, .18);
    border-color: rgba(139, 92, 246, .55);
}

/* Card 3 — Amber */
.feature-card:nth-child(3) .card-icon-wrapper {
    background: rgba(245, 158, 11, .10);
    border-color: rgba(245, 158, 11, .28);
}

.feature-card:nth-child(3) .card-icon-wrapper svg {
    stroke: #fbbf24;
}

.feature-card:nth-child(3):hover {
    border-color: rgba(245, 158, 11, .36);
    box-shadow: 0 14px 32px rgba(245, 158, 11, .12);
}

.feature-card:nth-child(3):hover .card-icon-wrapper {
    background: rgba(245, 158, 11, .18);
    border-color: rgba(245, 158, 11, .52);
}

/* Card 4 — Emerald */
.feature-card:nth-child(4) .card-icon-wrapper {
    background: rgba(16, 185, 129, .10);
    border-color: rgba(16, 185, 129, .28);
}

.feature-card:nth-child(4) .card-icon-wrapper svg {
    stroke: #34d399;
}

.feature-card:nth-child(4):hover {
    border-color: rgba(16, 185, 129, .36);
    box-shadow: 0 14px 32px rgba(16, 185, 129, .12);
}

.feature-card:nth-child(4):hover .card-icon-wrapper {
    background: rgba(16, 185, 129, .18);
    border-color: rgba(16, 185, 129, .50);
}

.feature-card:hover {
    transform: translateY(-4px);
}

.card-icon-wrapper {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    transition: background 0.28s ease, border-color 0.28s ease, box-shadow 0.28s ease;
}

.card-icon-wrapper svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.feature-card-info {
    display: flex;
    flex-direction: column;
}

.feature-card-title {
    font-size: 0.90rem;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.2;
}

.feature-card-desc {
    font-size: 0.70rem;
    color: var(--text-sub);
    margin-top: 3px;
}

/* =========================================================
   STAGGERED ENTRANCE ANIMATIONS
========================================================= */
@keyframes fadeSlideUp {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.anim-enter {
    opacity: 0;
    animation: fadeSlideUp 0.52s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Delay utilities */
.anim-d1 {
    animation-delay: 0.08s;
}

.anim-d2 {
    animation-delay: 0.18s;
}

.anim-d3 {
    animation-delay: 0.30s;
}

.anim-d4 {
    animation-delay: 0.42s;
}

.anim-d5 {
    animation-delay: 0.54s;
}

.anim-d6 {
    animation-delay: 0.66s;
}

.anim-d7 {
    animation-delay: 0.78s;
}

.anim-d8 {
    animation-delay: 0.90s;
}

.anim-d9 {
    animation-delay: 1.02s;
}

.anim-d10 {
    animation-delay: 1.14s;
}

/* Respect user preference */
@media (prefers-reduced-motion: reduce) {
    .anim-enter {
        animation: none;
        opacity: 1;
    }
}

/* =========================================================
   RESPONSIVE DESIGN (TABLETS, MOBILES, SMALL SCREENS)
========================================================= */

/* Tablet & Smaller Desktop */
@media (max-width: 1100px) {
    .bottom-features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

@media (max-width: 860px) {
    .page-container {
        padding: 16px 24px;
    }

    .hero-section {
        padding: 18px 0;
    }

    .hero-headline {
        font-size: 2.85rem;
    }

    .hero-subtitle {
        font-size: 0.98rem;
    }

    .hero-features-bar {
        gap: 18px;
        flex-wrap: wrap;
    }
}

/* Mobile & Small Screens (<= 768px): Dedicated clean mobile background & first-screen viewport structure */
@media (max-width: 768px) {
    .bg-scene {
        background: url("../images/mobile_home_bg.jpg") no-repeat center top / cover;
    }

    .bg-scene::after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(180deg, rgba(2, 6, 18, 0.35) 0%, rgba(2, 6, 18, 0.75) 100%);
    }

    .page-container {
        padding: 12px 18px 24px 18px;
        min-height: 100vh;
        height: auto;
    }

    .navbar {
        height: auto;
        min-height: 50px;
        padding: 6px 14px;
        border-radius: 99px;
        background: rgba(4, 14, 28, 0.65);
        border: 1px solid rgba(0, 229, 255, 0.18);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
        margin-bottom: 2px;
    }

    .brand-logo-box {
        width: 36px;
        height: 36px;
        border-radius: 10px;
    }

    .brand-db-svg {
        width: 18px;
        height: 18px;
    }

    .brand-title {
        font-size: 1.02rem;
    }

    .brand-subtitle {
        font-size: 0.48rem;
    }

    .nav-actions {
        gap: 8px;
    }

    .btn-nav-login {
        height: 32px;
        padding: 0 15px;
        font-size: 0.78rem;
    }

    .btn-nav-register {
        height: 32px;
        padding: 0 17px;
        font-size: 0.78rem;
    }

    .hero-section {
        padding: 0;
        width: 100%;
        display: block;
    }

    .hero-content {
        width: 100%;
        max-width: 100%;
        display: flex;
        flex-direction: column;
    }

    /* FIRST SCREEN VIEWPORT ON MOBILE */
    .hero-first-fold {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        min-height: calc(100svh - 78px);
        min-height: calc(100vh - 78px);
        padding-top: 2px;
        padding-bottom: 12px;
        width: 100%;
    }

    /* FULL SCREEN CYBER NETWORK BACKGROUND CANVAS (MOBILE) */
    #bgNetworkCanvas {
        position: fixed;
        inset: 0;
        width: 100vw;
        height: 100vh;
        z-index: 0;
        pointer-events: none;
        opacity: 0.70;
        display: block;
    }

    /* ANIMATED SQL DATABASE CLUSTER ENGINE (UPPER MOBILE HERO GRAPHIC) */
    .hero-mobile-db-stage {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 100%;
        flex: 1 1 auto;
        min-height: 180px;
        max-height: 280px;
        position: relative;
        margin: 2px 0 10px 0;
        border-radius: 20px;
        overflow: visible;
        perspective: 900px;
    }

    .db-stage-glow {
        position: absolute;
        width: 180px;
        height: 180px;
        border-radius: 50%;
        background: radial-gradient(circle, rgba(0, 229, 255, 0.22) 0%, rgba(37, 99, 235, 0.12) 50%, transparent 75%);
        filter: blur(28px);
        pointer-events: none;
        z-index: 1;
        animation: dbPulseGlow 4s ease-in-out infinite alternate;
    }

    @keyframes dbPulseGlow {
        0% { transform: scale(0.9); opacity: 0.6; }
        100% { transform: scale(1.15); opacity: 0.95; }
    }

    /* FLOATING SQL CODE BADGES */
    .floating-sql-pill {
        position: absolute;
        z-index: 4;
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 5px 12px;
        border-radius: 99px;
        background: rgba(6, 18, 38, 0.85);
        border: 1px solid rgba(0, 229, 255, 0.28);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45), 0 0 12px rgba(0, 229, 255, 0.15);
        font-family: 'Fira Code', monospace;
        font-size: 0.62rem;
        white-space: nowrap;
        pointer-events: none;
    }

    .sql-pill-left {
        top: 6px;
        left: 2px;
        animation: floatPillLeft 4s ease-in-out infinite alternate;
    }

    .sql-pill-right {
        top: 24px;
        right: 2px;
        animation: floatPillRight 4.5s ease-in-out infinite alternate;
    }

    @keyframes floatPillLeft {
        0% { transform: translateY(0) rotate(-1deg); }
        100% { transform: translateY(-6px) rotate(1deg); }
    }

    @keyframes floatPillRight {
        0% { transform: translateY(0) rotate(1deg); }
        100% { transform: translateY(-7px) rotate(-1.5deg); }
    }

    .sql-code-icon {
        font-size: 0.72rem;
        color: #facc15;
    }

    .kw-select {
        color: #00e5ff;
        font-weight: 700;
    }

    .kw-from {
        color: #a78bfa;
        font-weight: 700;
    }

    .sql-pulse-dot {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #22c55e;
        box-shadow: 0 0 8px #22c55e;
        animation: pulseDot 2s ease-in-out infinite;
    }

    .sql-metric {
        font-size: 0.58rem;
        font-weight: 600;
        color: #94a3b8;
        letter-spacing: 0.04em;
    }

    /* 3D ISOMETRIC CYLINDER CORE */
    .db-cluster-core {
        position: relative;
        z-index: 2;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
        padding-top: 6px;
    }

    /* SCANNING LASER BEAM */
    .db-scan-beam {
        position: absolute;
        width: 140px;
        height: 2px;
        background: linear-gradient(90deg, transparent, #00e5ff, #ffffff, #00e5ff, transparent);
        box-shadow: 0 0 14px #00e5ff, 0 0 24px rgba(0, 229, 255, 0.8);
        border-radius: 99px;
        z-index: 5;
        top: 12px;
        animation: scanVertical 3.2s ease-in-out infinite;
        pointer-events: none;
    }

    @keyframes scanVertical {
        0% { top: 10px; opacity: 0.2; transform: scaleX(0.7); }
        50% { top: 88px; opacity: 1; transform: scaleX(1.05); }
        100% { top: 10px; opacity: 0.2; transform: scaleX(0.7); }
    }

    /* INDIVIDUAL DATABASE CYLINDER TIERS */
    .db-cylinder-tier {
        position: relative;
        width: 126px;
        height: 30px;
        filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.6));
    }

    .tier-1 { animation: tierFloat1 5s ease-in-out infinite alternate; }
    .tier-2 { animation: tierFloat2 5s ease-in-out infinite alternate 0.4s; }
    .tier-3 { animation: tierFloat3 5s ease-in-out infinite alternate 0.8s; }

    @keyframes tierFloat1 {
        0% { transform: translateY(0); }
        100% { transform: translateY(-3px); }
    }
    @keyframes tierFloat2 {
        0% { transform: translateY(0); }
        100% { transform: translateY(-1.5px); }
    }
    @keyframes tierFloat3 {
        0% { transform: translateY(0); }
        100% { transform: translateY(0); }
    }

    .cylinder-top {
        position: absolute;
        top: 0;
        left: 0;
        width: 126px;
        height: 20px;
        border-radius: 50%;
        background: radial-gradient(ellipse at 50% 40%, rgba(0, 229, 255, 0.40) 0%, rgba(14, 38, 70, 0.95) 75%);
        border: 1px solid rgba(0, 229, 255, 0.6);
        box-shadow: inset 0 0 10px rgba(0, 229, 255, 0.35), 0 0 12px rgba(0, 229, 255, 0.25);
        z-index: 2;
    }

    .cylinder-body {
        position: absolute;
        top: 10px;
        left: 0;
        width: 126px;
        height: 19px;
        border-radius: 0 0 63px 63px / 0 0 15px 15px;
        background: linear-gradient(180deg, rgba(14, 38, 70, 0.98) 0%, rgba(6, 18, 36, 0.98) 100%);
        border: 1px solid rgba(0, 229, 255, 0.35);
        border-top: none;
        box-shadow: inset 0 -4px 8px rgba(0, 0, 0, 0.6);
        z-index: 1;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0 14px 2px 14px;
    }

    .db-server-lights {
        display: flex;
        align-items: center;
        gap: 5px;
    }

    .db-led {
        width: 4px;
        height: 4px;
        border-radius: 50%;
    }

    .led-green {
        background: #22c55e;
        box-shadow: 0 0 6px #22c55e;
        animation: ledBlink 1.4s ease-in-out infinite alternate;
    }

    .led-cyan {
        background: #00e5ff;
        box-shadow: 0 0 6px #00e5ff;
        animation: ledBlink 1.8s ease-in-out infinite alternate 0.3s;
    }

    .led-blue {
        background: #3b82f6;
        box-shadow: 0 0 6px #3b82f6;
        animation: ledBlink 2.2s ease-in-out infinite alternate 0.6s;
    }

    @keyframes ledBlink {
        0%, 100% { opacity: 0.35; transform: scale(0.85); }
        50% { opacity: 1; transform: scale(1.25); }
    }

    .db-track-line {
        width: 40px;
        height: 1px;
        background: linear-gradient(90deg, rgba(0, 229, 255, 0.1), rgba(0, 229, 255, 0.6), rgba(0, 229, 255, 0.1));
    }

    /* PEDESTAL RADAR RINGS UNDER DATABASE */
    .db-pedestal-ring {
        position: absolute;
        bottom: -10px;
        width: 155px;
        height: 26px;
        border-radius: 50%;
        border: 1px dashed rgba(0, 229, 255, 0.3);
        box-shadow: 0 0 16px rgba(0, 229, 255, 0.18);
        animation: spinSlow 20s linear infinite;
        pointer-events: none;
    }

    @keyframes spinSlow {
        100% { transform: rotate(360deg); }
    }

    .db-radar-pulse {
        position: absolute;
        bottom: -14px;
        width: 170px;
        height: 30px;
        border-radius: 50%;
        border: 1px solid rgba(0, 229, 255, 0.2);
        animation: radarRing 3s ease-out infinite;
        pointer-events: none;
    }

    @keyframes radarRing {
        0% { transform: scale(0.85); opacity: 0.8; }
        100% { transform: scale(1.35); opacity: 0; }
    }

    .db-bottom-tag {
        margin-top: 12px;
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 3px 10px;
        border-radius: 99px;
        background: rgba(4, 14, 28, 0.7);
        border: 1px solid rgba(0, 229, 255, 0.2);
        font-family: 'Fira Code', monospace;
        font-size: 0.54rem;
        z-index: 3;
    }

    .tag-accent {
        color: var(--cyan-bright);
        font-weight: 700;
        letter-spacing: 0.1em;
    }

    .tag-meta {
        color: #64748b;
        letter-spacing: 0.04em;
    }

    /* HERO TEXT GROUP (PLACED DIRECTLY ON TOP OF BUTTONS WITH TIGHT CLEAN SPACING) */
    .hero-text-group {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        width: 100%;
        margin-top: 0;
        margin-bottom: 10px;
    }

    .hero-badge {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        margin-bottom: 10px;
        font-family: 'Fira Code', monospace;
        font-size: 0.64rem;
        font-weight: 700;
        letter-spacing: 0.12em;
        padding: 5px 14px;
        border-radius: 99px;
        background: rgba(6, 20, 38, 0.75);
        border: 1px solid rgba(0, 229, 255, 0.28);
        box-shadow: 0 0 16px rgba(0, 229, 255, 0.12);
        color: #38bdf8;
        align-self: flex-start;
    }

    .hero-headline {
        font-size: clamp(2.05rem, 6.8vw, 2.35rem);
        font-weight: 850;
        line-height: 1.13;
        letter-spacing: -0.025em;
        text-align: left;
        margin-bottom: 10px;
        color: #ffffff;
    }

    .hero-headline span {
        color: var(--cyan-glow);
        text-shadow: 0 0 24px rgba(0, 229, 255, 0.65);
    }

    .hero-subtitle {
        font-size: clamp(0.85rem, 3.2vw, 0.92rem);
        line-height: 1.55;
        color: #94a3b8;
        text-align: left;
        margin-bottom: 0;
        max-width: 100%;
        letter-spacing: -0.01em;
    }

    /* Container for animation + CTAs placed directly below text content */
    .hero-actions-container {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        margin-top: 0;
        padding-top: 0;
    }

    /* Animated cyber spacer positioned directly on top of Get Started button */
    .hero-spacer-anim {
        display: inline-flex;
        align-items: center;
        gap: 9px;
        padding: 5px 14px;
        border-radius: 99px;
        background: rgba(6, 20, 38, 0.80);
        border: 1px solid rgba(0, 229, 255, 0.25);
        box-shadow: 0 0 16px rgba(0, 229, 255, 0.14);
        margin-bottom: 10px;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        width: fit-content;
    }

    .spacer-cyber-wave {
        display: flex;
        align-items: center;
        gap: 3px;
        height: 14px;
    }

    .wave-bar {
        width: 3px;
        border-radius: 2px;
        background: var(--cyan-glow);
        box-shadow: 0 0 6px var(--cyan-glow);
        animation: cyberWave 1.2s ease-in-out infinite alternate;
    }

    .wb-1 { height: 6px;  animation-delay: 0.1s; }
    .wb-2 { height: 12px; animation-delay: 0.3s; }
    .wb-3 { height: 8px;  animation-delay: 0.5s; }
    .wb-4 { height: 14px; animation-delay: 0.2s; }
    .wb-5 { height: 7px;  animation-delay: 0.4s; }

    @keyframes cyberWave {
        0% {
            height: 4px;
            opacity: 0.35;
        }
        100% {
            height: 14px;
            opacity: 1;
        }
    }

    .spacer-wave-text {
        font-family: 'Fira Code', monospace;
        font-size: 0.62rem;
        font-weight: 700;
        letter-spacing: 0.14em;
        color: var(--cyan-bright);
        text-transform: uppercase;
    }

    /* Action buttons positioned at the bottom of the first mobile screen */
    .hero-actions {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 10px;
        margin: 0;
        align-items: stretch;
    }

    .btn-hero-primary {
        width: 100%;
        justify-content: center;
        height: 50px;
        border-radius: 14px;
        font-size: 0.96rem;
        font-weight: 750;
        letter-spacing: 0.02em;
        background: linear-gradient(90deg, #00e5ff 0%, #00b0ff 100%);
        color: #020617;
        box-shadow: 0 4px 22px rgba(0, 229, 255, 0.45);
        border: none;
        transition: transform 0.15s ease, box-shadow 0.15s ease;
    }

    .btn-hero-primary:active {
        transform: scale(0.985);
    }

    .btn-hero-secondary {
        width: 100%;
        min-width: unset;
        justify-content: center;
        height: 50px;
        border-radius: 14px;
        font-size: 0.92rem;
        font-weight: 600;
        background: rgba(8, 22, 42, 0.75);
        border: 1px solid rgba(0, 229, 255, 0.24);
        color: #ffffff;
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        transition: transform 0.15s ease, background 0.15s ease;
    }

    .btn-hero-secondary:active {
        transform: scale(0.985);
        background: rgba(14, 34, 64, 0.85);
    }

    /* SHOWN ON SCROLL: 3 Stats Highlights strip */
    .hero-features-bar {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
        padding: 14px 8px;
        background: rgba(8, 20, 38, 0.65);
        border: 1px solid rgba(56, 189, 248, 0.18);
        border-radius: 14px;
        backdrop-filter: blur(12px);
        margin-top: 48px; /* Appears when scrolling down */
        margin-bottom: 24px;
        border-top: none;
    }

    .feature-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 6px;
    }

    .feature-item-icon {
        width: 34px;
        height: 34px;
        border-radius: 8px;
    }

    .feature-item-icon svg {
        width: 16px;
        height: 16px;
    }

    .feature-item-title {
        font-size: 0.72rem;
        white-space: nowrap;
    }

    .feature-item-desc {
        display: none;
    }

    /* SHOWN ON SCROLL: 4 Feature Cards */
    .bottom-features-grid {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 24px;
    }

    .feature-card {
        padding: 14px 16px;
        border-radius: 14px;
        gap: 14px;
        background: rgba(6, 18, 36, 0.72);
    }

    .card-icon-wrapper {
        width: 40px;
        height: 40px;
        border-radius: 11px;
    }

    .card-icon-wrapper svg {
        width: 20px;
        height: 20px;
    }

    .feature-card-title {
        font-size: 0.88rem;
    }

    .feature-card-desc {
        font-size: 0.70rem;
    }

    .home-footer {
        margin-top: 18px;
        padding: 14px 8px;
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

@media (max-width: 380px) {
    .brand-subtitle {
        display: none;
    }

    .btn-nav-login {
        padding: 0 12px;
        font-size: 0.75rem;
    }

    .btn-nav-register {
        padding: 0 14px;
        font-size: 0.75rem;
    }

    .hero-headline {
        font-size: 1.85rem;
    }

    .hero-badge {
        font-size: 0.58rem;
        padding: 4px 10px;
    }
}

/* =========================================================
   FOOTER (UNIFIED ACROSS ALL PAGES)
========================================================= */
.home-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px;
    border-top: 1px solid rgba(56, 189, 248, 0.10);
    color: #64748b;
    font-size: 0.78rem;
    width: 100%;
    margin-top: 32px;
}

.home-footer strong {
    color: #94a3b8;
    font-weight: 600;
}

.home-footer .footer-links {
    display: flex;
    align-items: center;
    gap: 20px;
}

.home-footer .footer-links a {
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.home-footer .footer-links a:hover {
    color: var(--cyan-glow);
}