:root {
    --bg-deep: #070f1a;
    --bg-mid: #0f1f35;
    --brand-dark: #11263e;
    --brand-blue: #0253f4;
    --brand-glow: #3b82ff;
    --text: #e8eef7;
    --text-muted: #8fa3bf;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    min-height: 100%;
}

body {
    font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
    color: var(--text);
    background: var(--bg-deep);
    overflow-x: hidden;
}

.page {
    position: relative;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.25rem;
    isolation: isolate;
}

.bg {
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(ellipse 80% 60% at 50% -10%, rgba(2, 83, 244, 0.22), transparent 55%),
        radial-gradient(ellipse 60% 50% at 100% 100%, rgba(17, 38, 62, 0.9), transparent 50%),
        linear-gradient(165deg, var(--bg-deep) 0%, var(--bg-mid) 45%, var(--brand-dark) 100%);
}

.bg-grid {
    position: fixed;
    inset: 0;
    z-index: -1;
    opacity: 0.35;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black, transparent);
    animation: grid-drift 24s linear infinite;
}

/* IoT background: charts + LCD panels */
.bg-iot {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
    mask-image: radial-gradient(ellipse 85% 75% at 50% 45%, black 20%, transparent 75%);
}

.iot-chart {
    position: absolute;
    opacity: 0.35;
}

.iot-chart-a {
    width: min(320px, 42vw);
    top: 12%;
    left: 4%;
    animation: iot-drift-a 22s ease-in-out infinite;
}

.iot-chart-b {
    width: min(260px, 36vw);
    bottom: 14%;
    right: 5%;
    animation: iot-drift-b 26s ease-in-out infinite;
}

.chart-grid-line {
    stroke: rgba(59, 130, 255, 0.12);
    stroke-width: 1;
}

.chart-line {
    fill: none;
    stroke: var(--brand-glow);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 400;
    stroke-dashoffset: 400;
    animation: chart-draw 6s ease-in-out infinite;
    filter: drop-shadow(0 0 6px rgba(59, 130, 255, 0.5));
}

.chart-dot {
    fill: var(--brand-glow);
    opacity: 0;
    animation: chart-dot-pulse 6s ease-in-out infinite;
}

.chart-bar {
    fill: rgba(2, 83, 244, 0.35);
    transform-origin: bottom center;
    animation: bar-pulse 3s ease-in-out infinite;
}

.chart-bar:nth-child(2) { animation-delay: 0.2s; }
.chart-bar:nth-child(3) { animation-delay: 0.4s; }
.chart-bar:nth-child(4) { animation-delay: 0.6s; }
.chart-bar:nth-child(5) { animation-delay: 0.8s; }
.chart-bar:nth-child(6) { animation-delay: 1s; }
.chart-bar:nth-child(7) { animation-delay: 1.2s; }

.lcd {
    position: absolute;
    padding: 0.65rem 0.9rem;
    border-radius: 8px;
    background: linear-gradient(145deg, rgba(17, 38, 62, 0.85), rgba(7, 15, 26, 0.95));
    border: 1px solid rgba(59, 130, 255, 0.25);
    box-shadow:
        inset 0 0 20px rgba(2, 83, 244, 0.08),
        0 8px 32px rgba(0, 0, 0, 0.35);
    font-family: "Consolas", "Courier New", monospace;
    opacity: 0.5;
}

.lcd-label {
    display: block;
    font-size: 0.55rem;
    letter-spacing: 0.15em;
    color: rgba(143, 163, 191, 0.8);
    margin-bottom: 0.25rem;
}

.lcd-value {
    display: flex;
    align-items: baseline;
    gap: 0.15rem;
    color: #4ade80;
    text-shadow: 0 0 12px rgba(74, 222, 128, 0.45);
}

.lcd-num {
    font-size: 1.1rem;
    font-weight: 700;
    animation: lcd-flicker 4s step-end infinite;
}

.lcd-unit {
    font-size: 0.65rem;
    color: rgba(74, 222, 128, 0.7);
}

.lcd-status {
    font-size: 0.75rem;
    font-weight: 700;
    align-items: center;
    gap: 0.4rem;
}

.lcd-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 8px #4ade80;
    animation: status-blink 1.8s ease-in-out infinite;
}

.lcd-a {
    top: 22%;
    right: 8%;
    animation: iot-drift-b 18s ease-in-out infinite;
}

.lcd-b {
    bottom: 28%;
    left: 7%;
    animation: iot-drift-a 20s ease-in-out infinite;
}

.lcd-c {
    top: 58%;
    right: 14%;
    animation: iot-drift-a 24s ease-in-out infinite reverse;
}

@media (max-width: 640px) {
    .iot-chart-a { top: 6%; left: -4%; opacity: 0.22; }
    .iot-chart-b { bottom: 8%; right: -6%; opacity: 0.22; }
    .lcd { opacity: 0.35; transform: scale(0.85); }
    .lcd-a { top: 16%; right: 2%; }
    .lcd-b { bottom: 20%; left: 2%; }
    .lcd-c { display: none; }
}

.orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: -1;
}

.orb-a {
    width: 320px;
    height: 320px;
    top: 10%;
    left: -80px;
    background: rgba(2, 83, 244, 0.18);
    animation: orb-float 14s ease-in-out infinite;
}

.orb-b {
    width: 280px;
    height: 280px;
    bottom: 5%;
    right: -60px;
    background: rgba(3, 85, 243, 0.14);
    animation: orb-float 18s ease-in-out infinite reverse;
}

.card {
    width: min(560px, 100%);
    text-align: center;
}

.logo-wrap {
    position: relative;
    width: min(220px, 72vw);
    margin: 0 auto 2rem;
    aspect-ratio: 1;
}

.logo-glow {
    position: absolute;
    inset: 8%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(2, 83, 244, 0.45) 0%, transparent 70%);
    filter: blur(24px);
    animation: glow-pulse 3.2s ease-in-out infinite;
}

.logo-ring {
    position: absolute;
    inset: -6%;
    border-radius: 50%;
    border: 1px solid rgba(59, 130, 255, 0.25);
    animation: ring-spin 20s linear infinite;
}

.logo-ring::before {
    content: "";
    position: absolute;
    inset: 12%;
    border-radius: 50%;
    border: 1px dashed rgba(255, 255, 255, 0.08);
    animation: ring-spin 28s linear infinite reverse;
}

.logo {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 12px 40px rgba(2, 83, 244, 0.35));
    animation: logo-float 4.5s ease-in-out infinite;
}

.badge {
    display: inline-block;
    margin-bottom: 1rem;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--brand-glow);
    background: rgba(2, 83, 244, 0.12);
    border: 1px solid rgba(59, 130, 255, 0.25);
    animation: badge-fade 2s ease-in-out infinite alternate;
}

h1 {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
}

.subtitle {
    font-size: clamp(0.95rem, 2.8vw, 1.1rem);
    line-height: 1.6;
    color: var(--text-muted);
    max-width: 28rem;
    margin: 0 auto 2rem;
}

.progress {
    height: 3px;
    width: min(240px, 70%);
    margin: 0 auto;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    width: 40%;
    border-radius: inherit;
    background: linear-gradient(90deg, transparent, var(--brand-blue), var(--brand-glow), transparent);
    animation: progress-slide 2.4s ease-in-out infinite;
}

.footer {
    margin-top: 2.5rem;
    font-size: 0.8rem;
    color: rgba(143, 163, 191, 0.7);
}

@keyframes logo-float {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-10px) scale(1.02); }
}

@keyframes glow-pulse {
    0%, 100% { opacity: 0.55; transform: scale(0.95); }
    50% { opacity: 1; transform: scale(1.08); }
}

@keyframes ring-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes orb-float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20px, -16px); }
}

@keyframes grid-drift {
    from { transform: translateY(0); }
    to { transform: translateY(48px); }
}

@keyframes badge-fade {
    from { opacity: 0.75; }
    to { opacity: 1; }
}

@keyframes progress-slide {
    0% { transform: translateX(-120%); }
    100% { transform: translateX(320%); }
}

@keyframes chart-draw {
    0% { stroke-dashoffset: 400; opacity: 0.3; }
    40% { stroke-dashoffset: 0; opacity: 1; }
    80% { stroke-dashoffset: 0; opacity: 1; }
    100% { stroke-dashoffset: -50; opacity: 0.3; }
}

@keyframes chart-dot-pulse {
    0%, 35% { opacity: 0; }
    45%, 75% { opacity: 1; }
    100% { opacity: 0; }
}

@keyframes bar-pulse {
    0%, 100% { opacity: 0.35; transform: scaleY(0.85); }
    50% { opacity: 0.7; transform: scaleY(1); }
}

@keyframes iot-drift-a {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(12px, -8px); }
}

@keyframes iot-drift-b {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-10px, 10px); }
}

@keyframes lcd-flicker {
    0%, 92%, 100% { opacity: 1; }
    93% { opacity: 0.85; }
    94% { opacity: 1; }
    95% { opacity: 0.9; }
}

@keyframes status-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
