/* ═══════════════════════════════════════════════════════
   BornaliaDNS — Auth Pages Dark 3D Theme
   Glassmorphism + Neon Glow
══════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@300;400;500;600;700&family=Inter:wght@400;600;700;800&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
a { color: var(--auth-primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--auth-purple); }
h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; color: var(--auth-text); letter-spacing: -0.02em; }
.gradient-text {
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-purple));
    -webkit-background-clip: text;
    background-clip: text;
}
@supports (-webkit-background-clip: text) or (background-clip: text) {
    .gradient-text { -webkit-text-fill-color: transparent; }
}

:root {
    --auth-primary: #00e5ff;
    --auth-primary-r: 0, 229, 255;
    --auth-purple: #8b5cf6;
    --auth-purple-r: 139, 92, 246;
    --auth-green: #10b981;
    --auth-danger: #f43f5e;
    --auth-text: #e8ecf4;
    --auth-text2: #8892a8;
    --auth-text3: #5a6478;
    --auth-border: rgba(255,255,255,0.06);
    --auth-radius: 14px;
    --auth-shadow: 0 8px 32px rgba(0,0,0,0.3), 0 0 0 1px rgba(255,255,255,0.04);
    --auth-shadow-hover: 0 16px 50px rgba(0,0,0,0.4), 0 0 40px rgba(var(--auth-primary-r),0.06);
}

.auth-body {
    background: #0a0e1a;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 70px 20px 40px;
    position: relative;
    overflow-x: hidden;
}

.auth-body canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0.2;
}

.auth-body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(0,229,255,0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,229,255,0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
    mask-image: radial-gradient(ellipse at 50% 40%, black 0%, transparent 60%);
    -webkit-mask-image: radial-gradient(ellipse at 50% 40%, black 0%, transparent 60%);
}

.auth-card {
    background: rgba(15, 20, 40, 0.75);
    border: 1px solid var(--auth-border);
    border-radius: 24px;
    padding: 44px 40px;
    width: 100%;
    max-width: 440px;
    position: relative;
    z-index: 1;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow: var(--auth-shadow);
    transition: box-shadow 0.35s ease;
    animation: fadeInUp 0.5s ease;
}

.auth-card:hover {
    box-shadow: var(--auth-shadow-hover);
    border-color: rgba(var(--auth-primary-r),0.1);
}

/* Logo */
.auth-logo {
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo .brand {
    font-size: 1.4rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.auth-logo .ver {
    font-size: 0.55em;
    font-weight: 700;
    opacity: 0.6;
    vertical-align: super;
    margin-left: 2px;
}

.auth-logo .tagline {
    color: var(--auth-text2);
    font-size: 0.88rem;
    margin-top: 6px;
    line-height: 1.4;
}

/* Brand (above card) */
.brand {
    font-size: 1.4rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

/* Tabs */
.auth-tabs {
    display: flex;
    gap: 4px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--auth-border);
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 28px;
}

.auth-tab {
    flex: 1;
    text-align: center;
    padding: 11px 10px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--auth-text2);
    transition: all 0.25s ease;
    user-select: none;
}

.auth-tab:hover { color: var(--auth-text); }

.auth-tab.active {
    background: rgba(var(--auth-primary-r),0.1);
    color: var(--auth-primary);
    box-shadow: 0 0 12px rgba(var(--auth-primary-r),0.08);
    border: 1px solid rgba(var(--auth-primary-r),0.15);
}

/* Form */
.form-group { margin-bottom: 18px; }

.form-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--auth-text);
}

.form-input {
    width: 100%;
    padding: 13px 16px;
    background: rgba(255,255,255,0.04);
    border: 1.5px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    color: var(--auth-text);
    font-size: 0.92rem;
    font-family: 'Hind Siliguri', 'Inter', sans-serif;
    transition: all 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--auth-primary);
    background: rgba(var(--auth-primary-r),0.04);
    box-shadow: 0 0 0 3px rgba(var(--auth-primary-r),0.1);
}

.form-input::placeholder { color: var(--auth-text3); }

/* Form validation */
.form-group.has-error .form-input {
    border-color: var(--auth-danger);
    background: rgba(244,63,94,0.04);
}
.form-group.has-error .form-input:focus {
    border-color: var(--auth-danger);
    box-shadow: 0 0 0 3px rgba(244,63,94,0.1);
}
.form-group.has-error .form-label { color: var(--auth-danger); }
.field-error {
    display: none;
    margin-top: 6px;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--auth-danger);
}

/* Primary Button */
.auth-btn {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-purple));
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 8px;
    font-family: 'Hind Siliguri', 'Inter', sans-serif;
    transition: all 0.25s ease;
    box-shadow:
        0 4px 20px rgba(var(--auth-primary-r),0.3),
        inset 0 1px 0 rgba(255,255,255,0.15);
    letter-spacing: 0.3px;
    position: relative;
    overflow: hidden;
}

.auth-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 200%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.6s;
}

.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow:
        0 8px 35px rgba(var(--auth-primary-r),0.4),
        inset 0 1px 0 rgba(255,255,255,0.2);
}
.auth-btn:hover::before { left: 100%; }
.auth-btn:active { transform: translateY(0); }
.auth-btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

/* Links */
.auth-footer {
    text-align: center;
    font-size: 0.85rem;
    color: var(--auth-text2);
    margin-top: 20px;
}
.auth-footer a {
    color: var(--auth-primary);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}
.auth-footer a:hover { color: var(--auth-purple); text-decoration: underline; }

/* Auth Links row (Forgot password + Create account) */
.auth-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
    white-space: nowrap;
    gap: 8px;
}
.auth-links a,
.auth-links span {
    white-space: nowrap;
    flex-shrink: 0;
}

/* Error / Success */
.auth-error,
.auth-success {
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 18px;
    display: none;
    animation: fadeInUp 0.3s ease;
}
.auth-error {
    background: rgba(244,63,94,0.06);
    border: 1px solid rgba(244,63,94,0.2);
    color: var(--auth-danger);
}
.auth-success {
    background: rgba(16,185,129,0.06);
    border: 1px solid rgba(16,185,129,0.2);
    color: var(--auth-green);
}
.auth-error.show,
.auth-success.show { display: block; }

/* Plan Select */
.plan-select-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}
.plan-opt {
    padding: 12px;
    border: 2px solid rgba(255,255,255,0.06);
    border-radius: 12px;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s ease;
    background: rgba(255,255,255,0.03);
}
.plan-opt:hover {
    border-color: rgba(var(--auth-primary-r),0.3);
    background: rgba(var(--auth-primary-r),0.04);
}
.plan-opt.selected {
    border-color: var(--auth-primary);
    background: rgba(var(--auth-primary-r),0.06);
    box-shadow: 0 0 0 3px rgba(var(--auth-primary-r),0.08);
}
.plan-opt .plan-n { font-weight: 700; font-size: 0.9rem; color: var(--auth-text); }
.plan-opt .plan-p { font-size: 0.75rem; color: var(--auth-text2); margin-top: 2px; }

/* Forgot Password Modal */
.forgot-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(10, 14, 26, 0.85);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}
.forgot-overlay.open { display: flex; }

/* ── Mobile ─────────────────────────────────────────── */
@media (max-width: 480px) {
    .auth-body { padding: 60px 12px 32px; }
    .auth-card { padding: 32px 22px; border-radius: 20px; }
    .plan-select-row { grid-template-columns: 1fr; }
    .auth-logo .brand { font-size: 1.5rem; }
    .auth-btn { padding: 13px; font-size: 0.93rem; }
    .auth-tabs { border-radius: 10px; }
    .auth-tab { padding: 10px 8px; font-size: 0.85rem; }
    .auth-links { font-size: 0.8rem; gap: 6px; }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalSlideUp { from { opacity: 0; transform: translate(-50%,-50%) scale(0.92); } to { opacity: 1; transform: translate(-50%,-50%) scale(1); } }
