﻿
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0
}

:root {
    --accent: #3b82f6;
    --accent2: #06b6d4;
    --danger: #ef4444;
    --success: #22c55e;
    --font: 'DM Sans',sans-serif;
    --mono: 'Space Mono',monospace;
}

html, body {
    height: 100%;
    font-family: var(--font);
    overflow: hidden;
    transition: background .4s
}

/* ─── BACKGROUNDS ─── */
body {
    background: #070d1a
}

    body.light {
        background: #c8d8f0
    }

.bg-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden
}
/* dark animated gradient */
.bg-dark {
    background: radial-gradient(ellipse 80% 60% at 20% 40%,rgba(59,130,246,.18) 0%,transparent 60%),radial-gradient(ellipse 60% 50% at 80% 70%,rgba(6,182,212,.12) 0%,transparent 55%),radial-gradient(ellipse 50% 60% at 50% 10%,rgba(139,92,246,.1) 0%,transparent 50%),linear-gradient(135deg,#060c1a 0%,#0d1520 40%,#070e1c 100%)
}

.bg-light {
    display: none;
    background: radial-gradient(ellipse 80% 60% at 20% 40%,rgba(59,130,246,.25) 0%,transparent 60%),radial-gradient(ellipse 60% 50% at 80% 70%,rgba(6,182,212,.2) 0%,transparent 55%),linear-gradient(135deg,#c8d8f0 0%,#dce9f8 50%,#c2d4ed 100%)
}

body.light .bg-dark {
    display: none
}

body.light .bg-light {
    display: block
}

.bg-dark, .bg-light {
    position: absolute;
    inset: 0
}

/* grid lines */
.bg-grid {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(59,130,246,.04) 1px,transparent 1px),linear-gradient(90deg,rgba(59,130,246,.04) 1px,transparent 1px);
    background-size: 40px 40px
}

body.light .bg-grid {
    background-image: linear-gradient(rgba(59,130,246,.08) 1px,transparent 1px),linear-gradient(90deg,rgba(59,130,246,.08) 1px,transparent 1px)
}

/* floating circles */
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: .3;
    animation: float 8s ease-in-out infinite
}

.orb1 {
    width: 300px;
    height: 300px;
    background: #3b82f6;
    top: -80px;
    left: -80px;
    animation-delay: 0s
}

.orb2 {
    width: 250px;
    height: 250px;
    background: #06b6d4;
    bottom: -60px;
    right: -60px;
    animation-delay: -3s
}

.orb3 {
    width: 200px;
    height: 200px;
    background: #8b5cf6;
    top: 50%;
    right: 10%;
    animation-delay: -5s
}

body.light .orb {
    opacity: .2
}

@keyframes float {
    0%,100% {
        transform: translateY(0) scale(1)
    }

    50% {
        transform: translateY(-20px) scale(1.05)
    }
}

/* ─── LAYOUT ─── */
.page {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px
}

/* ─── THEME TOGGLE ─── */
.theme-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,.15);
    background: rgba(255,255,255,.08);
    backdrop-filter: blur(12px);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,.7);
    font-size: 18px;
    transition: all .3s
}

    .theme-btn:hover {
        background: rgba(255,255,255,.15);
        color: #fff
    }

body.light .theme-btn {
    border-color: rgba(30,58,95,.2);
    background: rgba(255,255,255,.5);
    color: #1e3a5f
}

/* ─── GLASS CARD ─── */
.glass-card {
    width: 100%;
    max-width: 420px;
    background: rgba(255,255,255,.06);
    backdrop-filter: blur(24px) saturate(160%);
    -webkit-backdrop-filter: blur(24px) saturate(160%);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 20px;
    padding: 36px 32px;
    box-shadow: 0 24px 64px rgba(0,0,0,.4),inset 0 1px 0 rgba(255,255,255,.1)
}

body.light .glass-card {
    background: rgba(255,255,255,.55);
    border-color: rgba(255,255,255,.7);
    box-shadow: 0 24px 64px rgba(30,58,95,.15),inset 0 1px 0 rgba(255,255,255,.8)
}

/* top logo */
.card-logo {
    text-align: center;
    margin-bottom: 28px
}

.logo-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg,#3b82f6,#06b6d4);
    border-radius: 16px;
    font-size: 24px;
    color: #fff;
    margin-bottom: 12px;
    box-shadow: 0 8px 24px rgba(59,130,246,.4)
}

.card-title {
    font-size: 22px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px
}

.card-sub {
    font-size: 13px;
    color: rgba(255,255,255,.45);
    font-family: var(--mono)
}

body.light .card-title {
    color: #0f1c30
}

body.light .card-sub {
    color: #4a6080
}

/* ─── FORM ─── */
.form-group {
    margin-bottom: 16px
}

.form-label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: rgba(255,255,255,.6);
    margin-bottom: 6px
}

body.light .form-label {
    color: #4a6080
}

.input-wrap {
    position: relative
}

.input-icon {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 17px;
    color: rgba(255,255,255,.3);
    pointer-events: none;
    transition: color .2s
}

body.light .input-icon {
    color: #9baec4
}

.input-icon-r {
    position: absolute;
    right: 13px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 17px;
    color: rgba(255,255,255,.3);
    cursor: pointer;
    transition: color .2s
}

body.light .input-icon-r {
    color: #9baec4
}

.glass-input {
    width: 100%;
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 11px;
    padding: 11px 13px 11px 42px;
    font-size: 14px;
    color: #fff;
    font-family: var(--font);
    outline: none;
    transition: all .25s
}

    .glass-input::placeholder {
        color: rgba(255,255,255,.25)
    }

    .glass-input:focus {
        background: rgba(255,255,255,.1);
        border-color: rgba(59,130,246,.6);
        box-shadow: 0 0 0 3px rgba(59,130,246,.15)
    }

    .glass-input.has-right {
        padding-right: 42px
    }

    .glass-input.err {
        border-color: rgba(239,68,68,.6);
        box-shadow: 0 0 0 3px rgba(239,68,68,.1)
    }

body.light .glass-input {
    background: rgba(255,255,255,.6);
    border-color: rgba(30,58,95,.15);
    color: #0f1c30
}

    body.light .glass-input::placeholder {
        color: #9baec4
    }

    body.light .glass-input:focus {
        background: rgba(255,255,255,.8);
        border-color: #3b82f6;
        box-shadow: 0 0 0 3px rgba(59,130,246,.12)
    }

.form-hint-err {
    font-size: 11px;
    color: var(--danger);
    margin-top: 4px
}

/* remember row */
.remember-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px
}

.check-label {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 13px;
    color: rgba(255,255,255,.55);
    cursor: pointer
}

body.light .check-label {
    color: #4a6080
}

.check-label input {
    width: 15px;
    height: 15px;
    accent-color: var(--accent)
}

.forgot-link {
    font-size: 13px;
    color: rgba(59,130,246,.9);
    cursor: pointer;
    text-decoration: none;
    transition: color .2s
}

    .forgot-link:hover {
        color: #fff
    }

body.light .forgot-link {
    color: var(--accent)
}

    body.light .forgot-link:hover {
        color: #1e3a5f
    }

/* ─── GLASS BUTTON ─── */
.btn-submit {
    width: 100%;
    padding: 13px;
    border-radius: 11px;
    border: none;
    cursor: pointer;
    font-family: var(--font);
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all .25s;
    background: linear-gradient(135deg,#3b82f6,#2563eb);
    color: #fff;
    box-shadow: 0 4px 20px rgba(59,130,246,.4);
    margin-bottom: 16px
}

    .btn-submit:hover {
        transform: translateY(-1px);
        box-shadow: 0 8px 28px rgba(59,130,246,.5)
    }

    .btn-submit:active {
        transform: translateY(0)
    }

/* divider */
.divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 4px 0 16px;
    color: rgba(255,255,255,.25);
    font-size: 12px
}

body.light .divider {
    color: #9baec4
}

.divider::before, .divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255,255,255,.1)
}

body.light .divider::before, body.light .divider::after {
    background: rgba(30,58,95,.12)
}

/* social btns */
.social-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px
}

.btn-social {
    padding: 10px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.7);
    font-size: 13px;
    font-family: var(--font);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    transition: all .2s;
    backdrop-filter: blur(8px)
}

    .btn-social:hover {
        background: rgba(255,255,255,.12);
        color: #fff;
        border-color: rgba(255,255,255,.22)
    }

body.light .btn-social {
    background: rgba(255,255,255,.5);
    border-color: rgba(30,58,95,.15);
    color: #0f1c30
}

    body.light .btn-social:hover {
        background: rgba(255,255,255,.8)
    }

/* footer */
.card-footer {
    text-align: center;
    font-size: 13px;
    color: rgba(255,255,255,.4)
}

body.light .card-footer {
    color: #4a6080
}

.card-footer a {
    color: rgba(59,130,246,.9);
    text-decoration: none;
    font-weight: 500;
    transition: color .2s
}

    .card-footer a:hover {
        color: #fff
    }

body.light .card-footer a {
    color: var(--accent)
}

    body.light .card-footer a:hover {
        color: #1e3a5f
    }

/* ─── ALERT ─── */
.alert {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    border-radius: 10px;
    font-size: 13px;
    margin-bottom: 16px;
    background: rgba(239,68,68,.1);
    border: 1px solid rgba(239,68,68,.25);
    color: #fca5a5
}

body.light .alert {
    background: rgba(239,68,68,.08);
    border-color: rgba(239,68,68,.2);
    color: #dc2626
}

@media(max - width:480px) {
    .glass-card {
        padding: 28px 20px
    }
}


