/* ══════════════════════════════════════════
   AUTH DESIGN SYSTEM — VCodeShop
   Shared styles for login, register,
   forgot-password and reset-password
   ══════════════════════════════════════════ */

:root {
    --cyan:      #00e5ff;
    --cyan-dk:   #00b4d8;
    --blue:      #2962ff;
    --blue-dk:   #1e40af;
    --t1: #0f172a;
    --t2: #334155;
    --t3: #64748b;
    --t4: #94a3b8;
    --bg: #f8fafc;
    --wh: #ffffff;
    --danger: #ef4444;
    --success: #10b981;
    --info: #0ea5e9;
    --border: rgba(15,23,42,.08);
    --sh-card: 0 20px 60px rgba(15,23,42,.08), 0 1px 3px rgba(0,0,0,.04);
}

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

body.auth-body {
    font-family: 'Inter', -apple-system, sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    padding: 1rem;
    position: relative;
    overflow: hidden;
}

/* ── Animated background blobs ── */
body.auth-body::before,
body.auth-body::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    opacity: .25;
    z-index: 0;
    animation: blobFloat 12s ease-in-out infinite alternate;
}
body.auth-body::before {
    width: 420px; height: 420px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    top: -10%; left: -8%;
}
body.auth-body::after {
    width: 350px; height: 350px;
    background: linear-gradient(135deg, var(--cyan-dk), var(--blue-dk));
    bottom: -10%; right: -8%;
    animation-delay: 4s;
}

@keyframes blobFloat {
    0%   { transform: translate(0, 0) scale(1); }
    50%  { transform: translate(30px, -20px) scale(1.05); }
    100% { transform: translate(-20px, 15px) scale(.97); }
}

/* ── Auth Card ── */
.auth-card {
    width: 100%;
    max-width: 440px;
    background: rgba(255,255,255,.85);
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 44px 36px;
    box-shadow: var(--sh-card);
    position: relative;
    z-index: 1;
    animation: cardIn .6s cubic-bezier(.4,0,.2,1) both;
}

@keyframes cardIn {
    from { opacity: 0; transform: translateY(24px) scale(.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── Logo / Brand ── */
.auth-brand {
    text-align: center;
    margin-bottom: 24px;
}
.auth-brand a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-decoration: none;
}
.auth-brand img {
    height: 36px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(15,23,42,.08);
}
.auth-brand span {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--t1);
    letter-spacing: -0.5px;
}

/* ── Auth Icon (for forgot/reset pages) ── */
.auth-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, rgba(0,229,255,0.1), rgba(41,98,255,0.1));
    color: var(--blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin: 0 auto 24px;
    box-shadow: 0 4px 12px rgba(41,98,255,0.1);
    border: 1px solid rgba(41,98,255,0.15);
}

/* ── Titles ── */
.auth-title {
    text-align: center;
    color: var(--t1);
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 4px;
    font-family: 'Outfit', sans-serif;
}
.auth-subtitle {
    text-align: center;
    color: var(--t3);
    font-size: .88rem;
    margin-bottom: 28px;
}

/* ── Form Controls ── */
.auth-card .form-label {
    color: var(--t2);
    font-weight: 600;
    font-size: .82rem;
    margin-bottom: 6px;
    letter-spacing: .3px;
}

.auth-card .form-control {
    background: var(--wh);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    padding: 13px 16px;
    color: var(--t1);
    font-size: .92rem;
    font-family: 'Inter', sans-serif;
    transition: all .3s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 1px 3px rgba(15,23,42,.02);
}
.auth-card .form-control:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(0,229,255,.15), 0 1px 3px rgba(15,23,42,.04);
    outline: none;
}
.auth-card .form-control::placeholder {
    color: var(--t4);
}

/* ── Input with icon ── */
.input-icon-wrap {
    position: relative;
}
.input-icon-wrap .form-control {
    padding-left: 44px;
}
.input-icon-wrap .input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--t4);
    font-size: .88rem;
    transition: color .3s;
    pointer-events: none;
}
.input-icon-wrap .form-control:focus + .input-icon,
.input-icon-wrap .form-control:focus ~ .input-icon {
    color: var(--blue);
}

/* ── Password toggle ── */
.pw-toggle {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--t4);
    cursor: pointer;
    font-size: .92rem;
    padding: 0;
    transition: color .3s;
    z-index: 2;
}
.pw-toggle:hover { color: var(--blue); }

/* ── Checkbox ── */
.auth-card .form-check-input {
    border-radius: 6px;
    border: 1.5px solid rgba(15,23,42,.2);
    width: 18px; height: 18px;
    margin-top: 1px;
}
.auth-card .form-check-input:checked {
    background-color: var(--blue);
    border-color: var(--blue);
}
.auth-card .form-check-label {
    color: var(--t3);
    font-size: .85rem;
    margin-left: 4px;
}

/* ── Submit Button ── */
.btn-auth {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 50px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    color: #fff;
    font-weight: 600;
    font-size: .95rem;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all .35s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 6px 20px rgba(41,98,255,.25);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
}
.btn-auth::before {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(135deg, var(--cyan-dk), var(--blue-dk));
    opacity: 0; transition: opacity .3s;
}
.btn-auth i, .btn-auth span { position: relative; z-index: 1; }
.btn-auth:hover::before { opacity: 1; }
.btn-auth:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(41,98,255,.35);
}
.btn-auth:active {
    transform: translateY(0);
}

/* ── Divider ── */
.auth-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 24px 0;
    color: var(--t4);
    font-size: .8rem;
    font-weight: 500;
}
.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(15,23,42,.1), transparent);
}

/* ── Links ── */
.auth-link {
    text-align: center;
    font-size: .88rem;
    color: var(--t3);
}
.auth-link a {
    color: var(--blue);
    text-decoration: none;
    font-weight: 600;
    transition: color .2s;
}
.auth-link a:hover {
    color: var(--blue-dk);
}

.auth-forgot {
    color: var(--blue);
    font-size: .82rem;
    font-weight: 500;
    text-decoration: none;
    transition: color .2s;
}
.auth-forgot:hover { color: var(--blue-dk); }

/* ── Flash Messages ── */
.flash-msg {
    padding: 12px 16px;
    border-radius: 12px;
    font-size: .85rem;
    margin-bottom: 20px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    animation: fadeIn .4s ease;
}
.flash-error {
    background: rgba(239,68,68,.08);
    color: var(--danger);
    border: 1px solid rgba(239,68,68,.15);
}
.flash-success {
    background: rgba(16,185,129,.08);
    color: var(--success);
    border: 1px solid rgba(16,185,129,.15);
}
.flash-info {
    background: rgba(14,165,233,.08);
    color: var(--info);
    border: 1px solid rgba(14,165,233,.15);
}

/* ── Validation Errors ── */
.error-feedback {
    color: var(--danger);
    font-size: .78rem;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 4px;
}
.error-feedback::before {
    content: '\f06a';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: .7rem;
}
.input-error {
    border-color: var(--danger) !important;
    box-shadow: 0 0 0 3px rgba(239,68,68,.1) !important;
}

/* ── Back to home ── */
.auth-back {
    position: fixed;
    top: 24px;
    left: 28px;
    z-index: 10;
    color: var(--t3);
    text-decoration: none;
    font-size: .85rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 50px;
    background: rgba(255,255,255,.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(15,23,42,.06);
    transition: all .3s;
}
.auth-back:hover {
    color: var(--t1);
    border-color: rgba(15,23,42,.1);
    box-shadow: 0 4px 12px rgba(15,23,42,.06);
}

/* ── Animations ── */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Responsive ── */
@media (max-width: 480px) {
    .auth-card {
        padding: 32px 24px;
        border-radius: 20px;
    }
    .auth-back { display: none; }
    body.auth-body::before { width: 280px; height: 280px; }
    body.auth-body::after  { width: 220px; height: 220px; }
}
