/* index.css - Updated for full grid background with water ripple */
:root {
    --lime: #c8ff00;
    --lime2: #efff35;
    --green: #00e58a;
    --deep: #020b06;
    --glass: rgba(3, 20, 11, 0.76);
    --line: rgba(200, 255, 0, 0.34);
    --white: #f4ffe9;
    --muted: #9baa9d;
}

* { box-sizing: border-box; }

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
}

body {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    color: var(--white);
    font-family: "Segoe UI", Inter, Arial, sans-serif;
    background: #020904;
}

body::before {
    content: "";
    position: fixed;
    inset: -12px;
    z-index: -5;
    background: url("../assets/images/200.png") center center / cover no-repeat;
    transform-origin: center;
    animation: backgroundZoom 18s ease-in-out infinite alternate;
}

@keyframes backgroundZoom {
    from { transform: scale(1); }
    to { transform: scale(1.045); }
}

.bg-overlay {
    position: fixed;
    inset: 0;
    z-index: -4;
    pointer-events: none;
    background:
        radial-gradient(circle at 50% 46%, rgba(200,255,0,.055), transparent 35%),
        radial-gradient(circle at 12% 85%, rgba(0,229,138,.16), transparent 32%),
        linear-gradient(135deg, rgba(0,9,5,.68), rgba(0,13,7,.82), rgba(0,2,1,.91));
}

.bg-overlay::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(200,255,0,.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(200,255,0,.025) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: radial-gradient(circle at center, black, transparent 72%);
}

.rail-glow {
    position: fixed;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    filter: blur(90px);
    opacity: .10;
    pointer-events: none;
    z-index: -3;
    animation: glowFloat 12s ease-in-out infinite alternate;
}

.rail-glow-left { left: -140px; bottom: -100px; background: var(--green); }
.rail-glow-right { right: -130px; top: -100px; background: var(--lime); animation-delay: -5s; }

@keyframes glowFloat {
    from { transform: translate3d(0,0,0) scale(1); }
    to { transform: translate3d(35px,-25px,0) scale(1.12); }
}

/* =========================================================
   FULL BACKGROUND ABC-XYZ TEXT
   ========================================================= */
.spiral-text-layer {
    position: fixed;
    inset: 0;
    z-index: 5;
    overflow: hidden;
    pointer-events: none;
}

.spiral-text {
    position: fixed;
    white-space: nowrap;
    font-weight: 900;
    letter-spacing: 2px;
    color: rgba(205,255,15,.52);
    text-shadow: 0 0 7px rgba(200,255,0,.72), 0 0 20px rgba(0,229,138,.20);
    will-change: transform, opacity;
    user-select: none;
    transition: none;
}

/* =========================================================
   MAIN SCENE
   ========================================================= */
.login-scene {
    position: relative;
    z-index: 10;
    width: 100%;
    height: calc(100vh - 54px);
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px 20px 30px;
}

/* =========================================================
   LOGIN CARD
   ========================================================= */
.login-card {
    position: relative;
    width: min(485px, 92vw);
    max-height: calc(100vh - 78px);
    padding: clamp(22px, 3.2vh, 34px) clamp(25px, 4vw, 42px) 24px;
    border: 1px solid rgba(200,255,0,.45);
    border-radius: 26px;
    background:
        linear-gradient(145deg, rgba(10,35,20,.76), rgba(1,12,7,.88));
    backdrop-filter: blur(17px) saturate(130%);
    -webkit-backdrop-filter: blur(17px) saturate(130%);
    box-shadow:
        0 30px 90px rgba(0,0,0,.70),
        0 0 45px rgba(200,255,0,.11),
        inset 0 1px 0 rgba(255,255,255,.13),
        inset 0 -1px 0 rgba(0,229,138,.12);
    overflow: hidden;
    transform: perspective(1200px) translateZ(0);
    animation: cardEnter .85s cubic-bezier(.16,1,.3,1);
}

@keyframes cardEnter {
    from { opacity: 0; transform: perspective(1200px) translateY(30px) rotateX(7deg) scale(.96); }
    to { opacity: 1; transform: perspective(1200px) translateY(0) rotateX(0) scale(1); }
}

.login-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background:
        linear-gradient(90deg, transparent, rgba(200,255,0,.045), transparent),
        radial-gradient(circle at 50% 0%, rgba(200,255,0,.10), transparent 35%);
}

.login-card::after {
    content: "";
    position: absolute;
    left: 8%;
    right: 8%;
    top: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--lime), transparent);
    box-shadow: 0 0 15px var(--lime);
    animation: topPulse 3s ease-in-out infinite;
}

@keyframes topPulse {
    0%,100% { opacity: .45; }
    50% { opacity: 1; }
}

.card-scanline {
    position: absolute;
    inset: -100% 0 auto;
    height: 70%;
    background: linear-gradient(to bottom, transparent, rgba(200,255,0,.025), transparent);
    transform: translateY(0);
    pointer-events: none;
    animation: scan 7s linear infinite;
}

@keyframes scan {
    to { transform: translateY(250%); }
}

.card-corner {
    position: absolute;
    width: 26px;
    height: 26px;
    border-color: rgba(200,255,0,.68);
    pointer-events: none;
}
.corner-tl { top: 10px; left: 10px; border-top: 1px solid; border-left: 1px solid; border-radius: 9px 0 0 0; }
.corner-tr { top: 10px; right: 10px; border-top: 1px solid; border-right: 1px solid; border-radius: 0 9px 0 0; }
.corner-bl { bottom: 10px; left: 10px; border-bottom: 1px solid; border-left: 1px solid; border-radius: 0 0 0 9px; }
.corner-br { bottom: 10px; right: 10px; border-bottom: 1px solid; border-right: 1px solid; border-radius: 0 0 9px 0; }

/* =========================================================
   LOGO + TITLE
   ========================================================= */
.logo-wrapper {
    position: relative;
    width: 82px;
    height: 82px;
    margin: 0 auto 11px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-halo {
    position: absolute;
    inset: 0;
    border: 1px solid rgba(200,255,0,.48);
    border-radius: 50%;
    box-shadow: 0 0 25px rgba(200,255,0,.14), inset 0 0 18px rgba(200,255,0,.05);
    animation: logoSpin 11s linear infinite;
}

.logo-halo::before,
.logo-halo::after {
    content: "";
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--lime);
    box-shadow: 0 0 12px var(--lime);
}
.logo-halo::before { top: 4px; left: 19px; }
.logo-halo::after { right: 12px; bottom: 13px; background: var(--green); box-shadow: 0 0 12px var(--green); }

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

.logo-circle {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #081006;
    background: linear-gradient(135deg, var(--lime2), var(--lime));
    box-shadow: 0 0 30px rgba(200,255,0,.24), inset 0 1px 0 rgba(255,255,255,.55);
    font-size: 25px;
}

.title-block { text-align: center; margin-bottom: 21px; }
.brand {
    font-size: clamp(40px, 6vw, 56px);
    line-height: .92;
    font-weight: 950;
    font-style: italic;
    letter-spacing: 7px;
    color: var(--lime2);
    text-shadow: 0 0 10px rgba(200,255,0,.68), 0 0 32px rgba(200,255,0,.18);
}

.title-block h1 {
    margin: 9px 0 10px;
    color: rgba(248,255,242,.92);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.1px;
}

.title-rule {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
}
.title-rule span { width: 80px; height: 1px; background: linear-gradient(90deg, transparent, rgba(200,255,0,.65)); }
.title-rule span:last-child { background: linear-gradient(90deg, rgba(200,255,0,.65), transparent); }
.title-rule b { color: var(--lime); font-size: 10px; letter-spacing: 4px; white-space: nowrap; }

/* =========================================================
   FORM
   ========================================================= */
.field-group { margin-bottom: 16px; }
.field-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 7px 3px;
    color: rgba(239,249,235,.86);
    font-size: 12px;
    font-weight: 700;
}
.field-group label i { color: var(--lime); font-size: 11px; }

.input-shell { position: relative; }
.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    color: #819184;
    pointer-events: none;
    transition: .25s ease;
}

.form-control {
    height: 48px;
    padding: 0 45px 0 43px;
    color: var(--white);
    background: rgba(0,10,5,.66);
    border: 1px solid rgba(200,255,0,.30);
    border-radius: 11px;
    font-size: 12px;
    transition: .25s ease;
}
.form-control::placeholder { color: #667569; }
.form-control:hover { border-color: rgba(200,255,0,.50); }
.form-control:focus {
    color: var(--white);
    background: rgba(2,17,9,.84);
    border-color: var(--lime);
    box-shadow: 0 0 0 3px rgba(200,255,0,.07), 0 0 22px rgba(200,255,0,.08);
}
.input-shell.focused .input-icon { color: var(--lime); filter: drop-shadow(0 0 6px rgba(200,255,0,.55)); }

.input-status {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--green);
    font-size: 11px;
    opacity: 0;
    pointer-events: none;
}
.form-control:not(:placeholder-shown) ~ .input-status { opacity: .82; }

.password-toggle {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 35px;
    height: 35px;
    border: 0;
    border-radius: 8px;
    color: #7d8d80;
    background: transparent;
    cursor: pointer;
    transition: .25s ease;
}
.password-toggle:hover { color: var(--lime); background: rgba(200,255,0,.07); }

/* =========================================================
   LOGIN BUTTON
   ========================================================= */
.btn-login {
    position: relative;
    width: 100%;
    height: 48px;
    margin-top: 3px;
    border: 0;
    border-radius: 11px;
    overflow: hidden;
    color: #071006;
    background: linear-gradient(110deg, var(--lime), var(--lime2), var(--lime));
    background-size: 220% 100%;
    font-size: 13px;
    font-weight: 950;
    letter-spacing: 2px;
    box-shadow: 0 12px 30px rgba(200,255,0,.18), inset 0 1px 0 rgba(255,255,255,.60);
    cursor: pointer;
    transition: .28s ease;
}
.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 34px rgba(200,255,0,.26), 0 0 25px rgba(200,255,0,.10);
    animation: buttonGradient 2s linear infinite;
}
.btn-login:active { transform: translateY(0) scale(.985); }
.btn-login:disabled { opacity: .70; cursor: wait; transform: none; }
.btn-login i { margin-right: 8px; }
.button-shine {
    position: absolute;
    top: 0;
    left: -60%;
    width: 35%;
    height: 100%;
    transform: skewX(-22deg);
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.50), transparent);
    transition: left .65s ease;
}
.btn-login:hover .button-shine { left: 135%; }
@keyframes buttonGradient { to { background-position: 200% 50%; } }

.button-loader { display: inline-flex; align-items: center; gap: 8px; }

/* =========================================================
   STATUS + SECURITY + METRICS
   ========================================================= */
.login-status {
    display: none;
    margin-top: 10px;
    padding: 8px 10px;
    border-radius: 9px;
    text-align: center;
    font-size: 10px;
    font-weight: 600;
}
.login-status.error { color: #ffbcbc; background: rgba(255,55,55,.08); border: 1px solid rgba(255,55,55,.25); }
.login-status.success { color: #e8ffad; background: rgba(200,255,0,.06); border: 1px solid rgba(200,255,0,.25); }

.secure-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    margin-top: 17px;
    min-height: 43px;
    border: 1px solid rgba(200,255,0,.36);
    border-radius: 9px;
    color: var(--lime2);
    background: rgba(3,18,9,.58);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .2px;
    box-shadow: inset 0 0 18px rgba(200,255,0,.025);
}
.secure-bar i { color: var(--lime); }

.metrics {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 26px;
    margin-top: 20px;
}
.metric { display: flex; flex-direction: column; align-items: center; gap: 5px; min-width: 65px; color: #d8e4d6; font-size: 10px; }
.metric i { color: var(--lime); font-size: 19px; filter: drop-shadow(0 0 6px rgba(200,255,0,.35)); }
.metric-divider { width: 1px; height: 34px; background: rgba(200,255,0,.30); box-shadow: 0 0 8px rgba(200,255,0,.12); }

/* =========================================================
   FOOTER
   ========================================================= */
.app-footer {
    position: fixed;
    left: 50%;
    bottom: 10px;
    transform: translateX(-50%);
    z-index: 30;
    width: min(700px, calc(100vw - 28px));
    min-height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 7px 17px;
    border: 1px solid rgba(200,255,0,.25);
    border-radius: 13px;
    color: #d7e4d4;
    background: rgba(1,10,5,.78);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    font-size: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.05);
}
.app-footer i { color: var(--lime); margin-right: 5px; }
.app-footer b { width: 5px; height: 5px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 10px var(--lime); }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 600px) {
    .login-scene { height: calc(100vh - 48px); padding: 12px 12px 52px; }
    .login-card { width: min(440px, 94vw); padding: 21px 20px 20px; border-radius: 21px; }
    .logo-wrapper { width: 66px; height: 66px; }
    .logo-circle { width: 50px; height: 50px; font-size: 21px; }
    .brand { font-size: 38px; }
    .title-block h1 { font-size: 9px; letter-spacing: .7px; }
    .title-rule b { font-size: 8px; letter-spacing: 2.5px; }
    .title-rule span { width: 40px; }
    .secure-bar { font-size: 9px; }
    .metrics { gap: 13px; }
    .app-footer { bottom: 6px; font-size: 8px; gap: 8px; }
    .spiral-text { opacity: .28; }
}

@media (max-height: 680px) {
    .login-card { padding-top: 17px; padding-bottom: 15px; }
    .logo-wrapper { width: 58px; height: 58px; margin-bottom: 6px; }
    .logo-circle { width: 44px; height: 44px; font-size: 18px; }
    .title-block { margin-bottom: 13px; }
    .field-group { margin-bottom: 10px; }
    .form-control, .btn-login { height: 43px; }
    .secure-bar { margin-top: 11px; min-height: 36px; }
    .metrics { margin-top: 12px; }
}

@media (prefers-reduced-motion: reduce) {
    body::before, .rail-glow, .login-card, .logo-halo, .btn-login, .card-scanline { animation: none !important; }
    .spiral-text-layer { display: none; }
}