/**
 * Varndean STS - Login Page Styles
 * Clean, professional login page design for staff
 * Neutral color palette with subtle accents
 */

/* ============================================
   Background & Layout
   ============================================ */

.login-back {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
    margin: unset;
}

/* Subtle background pattern for depth */
.login-back::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(129, 140, 248, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

/* ============================================
    Background Blob Decorations
    ============================================ */

.login-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.login-bg__blob {
    position: absolute;
    filter: blur(14px);
    opacity: 0.55;
    transform: translate3d(0, 0, 0);
    transition: transform 0.9s ease, opacity 0.9s ease;
    will-change: transform;
}

.login-bg__blob--one {
    top: 10%;
    left: 16%;
    width: 250px;
    height: 210px;
    border-radius: 55% 45% 62% 38% / 60% 40% 58% 42%;
    background: radial-gradient(circle at 30% 35%, rgba(59, 130, 246, 0.22), rgba(59, 130, 246, 0) 62%),
        radial-gradient(circle at 70% 65%, rgba(16, 185, 129, 0.16), rgba(16, 185, 129, 0) 58%);
    animation: blobFloatOne 22s ease-in-out infinite, blobMorph 18s ease-in-out infinite;
}

.login-bg__blob--two {
    top: 18%;
    right: 22%;
    width: 210px;
    height: 190px;
    border-radius: 48% 52% 38% 62% / 45% 55% 60% 40%;
    background: radial-gradient(circle at 35% 30%, rgba(167, 139, 250, 0.22), rgba(167, 139, 250, 0) 60%),
        radial-gradient(circle at 70% 70%, rgba(14, 165, 233, 0.16), rgba(14, 165, 233, 0) 55%);
    animation: blobFloatTwo 24s ease-in-out infinite, blobMorph 20s ease-in-out infinite;
}

.login-bg__blob--three {
    top: 38%;
    left: 24%;
    width: 230px;
    height: 200px;
    border-radius: 62% 38% 52% 48% / 55% 45% 40% 60%;
    background: radial-gradient(circle at 35% 40%, rgba(16, 185, 129, 0.18), rgba(16, 185, 129, 0) 60%),
        radial-gradient(circle at 70% 65%, rgba(99, 102, 241, 0.14), rgba(99, 102, 241, 0) 55%);
    animation: blobFloatThree 20s ease-in-out infinite, blobMorph 17s ease-in-out infinite;
}

.login-bg__blob--four {
    top: 52%;
    right: 28%;
    width: 200px;
    height: 180px;
    border-radius: 46% 54% 62% 38% / 52% 48% 58% 42%;
    background: radial-gradient(circle at 30% 35%, rgba(56, 189, 248, 0.2), rgba(56, 189, 248, 0) 60%),
        radial-gradient(circle at 70% 65%, rgba(148, 163, 184, 0.18), rgba(148, 163, 184, 0) 58%);
    animation: blobFloatFour 26s ease-in-out infinite, blobMorph 19s ease-in-out infinite;
}

.login-bg__blob--five {
    bottom: 18%;
    left: 30%;
    width: 220px;
    height: 190px;
    border-radius: 58% 42% 45% 55% / 60% 40% 50% 50%;
    background: radial-gradient(circle at 35% 35%, rgba(99, 102, 241, 0.18), rgba(99, 102, 241, 0) 60%),
        radial-gradient(circle at 70% 65%, rgba(16, 185, 129, 0.12), rgba(16, 185, 129, 0) 55%);
    animation: blobFloatFive 23s ease-in-out infinite, blobMorph 18s ease-in-out infinite;
}

.login-bg__blob--six {
    bottom: 14%;
    right: 20%;
    width: 240px;
    height: 200px;
    border-radius: 42% 58% 50% 50% / 46% 54% 62% 38%;
    background: radial-gradient(circle at 35% 35%, rgba(167, 139, 250, 0.2), rgba(167, 139, 250, 0) 60%),
        radial-gradient(circle at 70% 65%, rgba(14, 165, 233, 0.14), rgba(14, 165, 233, 0) 55%);
    animation: blobFloatSix 25s ease-in-out infinite, blobMorph 20s ease-in-out infinite;
}

.login-bg__blob--seven {
    top: 26%;
    left: 54%;
    width: 260px;
    height: 230px;
    border-radius: 50% 50% 60% 40% / 55% 45% 50% 50%;
    background: radial-gradient(circle at 30% 40%, rgba(148, 163, 184, 0.2), rgba(148, 163, 184, 0) 60%),
        radial-gradient(circle at 70% 60%, rgba(56, 189, 248, 0.14), rgba(56, 189, 248, 0) 55%);
    animation: blobFloatSeven 27s ease-in-out infinite, blobMorph 21s ease-in-out infinite;
}

@keyframes blobFloatOne {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(18px, -22px, 0) scale(1.05); }
}

@keyframes blobFloatTwo {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(-18px, 16px, 0) scale(1.05); }
}

@keyframes blobFloatThree {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(20px, 12px, 0) scale(1.05); }
}

@keyframes blobFloatFour {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(-16px, -18px, 0) scale(1.05); }
}

@keyframes blobFloatFive {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(18px, 10px, 0) scale(1.05); }
}

@keyframes blobFloatSix {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(-18px, 18px, 0) scale(1.05); }
}

@keyframes blobFloatSeven {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(14px, -20px, 0) scale(1.05); }
}

@keyframes blobMorph {
    0%, 100% { border-radius: 55% 45% 62% 38% / 60% 40% 58% 42%; }
    33% { border-radius: 62% 38% 48% 52% / 55% 45% 60% 40%; }
    66% { border-radius: 48% 52% 60% 40% / 50% 50% 45% 55%; }
}

/* ============================================
   Login Container
   ============================================ */

.login-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    width: 100%;
    max-width: 500px;
    position: relative;
    z-index: 1;
    animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Logo
   ============================================ */

.login-logo {
    max-width: 280px;
    height: auto;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.08));
}

/* ============================================
   Login Card
   ============================================ */

.login-card {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.04),
        0 4px 12px -2px rgba(0, 0, 0, 0.06);
    width: 100%;
    max-width: 420px;
    padding: 40px;
    text-align: center;
}

/* ============================================
   Typography
   ============================================ */

.login-title {
    font-size: 28px;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: -0.02em;
    margin: 0 0 8px 0;
    line-height: 1.25;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.8));
}

.login-subtitle {
    font-size: 14px;
    font-weight: 400;
    color: #64748b;
    line-height: 1.5;
    margin: 0 0 24px 0;
}

/* ============================================
   Feature Pills
   ============================================ */

.login-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 32px;
}

.feature-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    color: #64748b;
    transition: all 0.2s ease;
}

.feature-pill i {
    font-size: 13px;
    color: #6366f1;
}

.feature-pill:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: #475569;
    transform: translateY(-1px);
}

/* ============================================
   Google Sign-In Button
   ============================================ */

.login-button-wrapper {
    margin: 24px 0;
}

.gsi-material-button {
    -moz-user-select: none;
    -webkit-user-select: none;
    -ms-user-select: none;
    -webkit-appearance: none;
    background-color: #ffffff;
    background-image: none;
    border: 1px solid #d1d5db;
    -webkit-border-radius: 8px;
    border-radius: 8px;
    box-sizing: border-box;
    color: #1f1f1f;
    cursor: pointer;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px;
    font-weight: 500;
    height: 48px;
    letter-spacing: 0.25px;
    outline: none;
    overflow: hidden;
    padding: 0 16px;
    position: relative;
    text-align: center;
    -webkit-transition: all 0.2s ease;
    transition: all 0.2s ease;
    vertical-align: middle;
    white-space: nowrap;
    width: 100%;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.gsi-material-button:hover {
    -webkit-box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #9ca3af;
    background-color: #f9fafb;
    transform: translateY(-1px);
}

.gsi-material-button:active {
    transform: scale(0.98);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.gsi-material-button:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.3), 0 4px 12px rgba(0, 0, 0, 0.1);
}

.gsi-material-button .gsi-material-button-icon {
    height: 20px;
    margin-right: 12px;
    min-width: 20px;
    width: 20px;
    flex-shrink: 0;
}

.gsi-material-button .gsi-material-button-content-wrapper {
    -webkit-align-items: center;
    align-items: center;
    display: flex;
    -webkit-flex-direction: row;
    flex-direction: row;
    -webkit-flex-wrap: nowrap;
    flex-wrap: nowrap;
    height: 100%;
    justify-content: center;
    position: relative;
    width: 100%;
}

.gsi-material-button .gsi-material-button-contents {
    -webkit-flex-grow: 1;
    flex-grow: 1;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: top;
}

.gsi-material-button .gsi-material-button-state {
    -webkit-transition: opacity 0.15s;
    transition: opacity 0.15s;
    bottom: 0;
    left: 0;
    opacity: 0;
    position: absolute;
    right: 0;
    top: 0;
}

.gsi-material-button:disabled {
    cursor: not-allowed;
    background-color: #f3f4f6;
    border-color: #e5e7eb;
    opacity: 0.6;
}

.gsi-material-button:disabled .gsi-material-button-contents {
    opacity: 0.6;
}

.gsi-material-button:disabled .gsi-material-button-icon {
    opacity: 0.6;
}

.gsi-material-button:disabled:hover {
    box-shadow: none;
    transform: none;
}

/* ============================================
   Trust Indicator
   ============================================ */

.login-trust {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 20px;
    font-size: 12px;
    color: #94a3b8;
}

.login-trust i {
    font-size: 14px;
    color: #6366f1;
}

/* ============================================
   Alert Messages
   ============================================ */

.login-alert {
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 24px;
    font-size: 14px;
    line-height: 1.5;
    display: flex;
    align-items: center;
    gap: 10px;
}

.login-alert i {
    font-size: 18px;
    flex-shrink: 0;
}

.login-alert--note {
    border: 1px solid #fcd34d;
    background: #fefce8;
    color: #92400e;
}

.login-alert--note i {
    color: #f59e0b;
}

.login-alert--warning {
    border: 1px solid #fca5a5;
    background: #fef2f2;
    color: #991b1b;
}

.login-alert--warning i {
    color: #ef4444;
}

.login-alert--success {
    border: 1px solid #86efac;
    background: #f0fdf4;
    color: #166534;
}

.login-alert--success i {
    color: #22c55e;
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 768px) {
    .login-card {
        padding: 32px;
        max-width: 380px;
    }

    .login-title {
        font-size: 24px;
    }

    .login-logo {
        max-width: 240px;
    }

    .login-bg__blob {
        opacity: 0.42;
        filter: blur(16px);
    }
}

@media (max-width: 480px) {
    .login-back {
        padding: 16px;
    }

    .login-main {
        gap: 1.5rem;
    }

    .login-card {
        padding: 24px;
        max-width: 100%;
    }

    .login-title {
        font-size: 22px;
    }

    .login-subtitle {
        font-size: 13px;
    }

    .login-logo {
        max-width: 200px;
    }

    .login-features {
        gap: 6px;
    }

    .feature-pill {
        padding: 6px 12px;
        font-size: 11px;
    }

    .gsi-material-button {
        height: 44px;
        font-size: 13px;
    }

    .login-bg {
        display: none;
    }
}

/* ============================================
   Accessibility
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    .login-main,
    .login-card,
    .login-logo,
    .gsi-material-button,
    .login-bg__blob {
        animation: none;
        transition: none;
    }
}

/* Focus visible styles for keyboard navigation */
.login-card:focus-within {
    box-shadow: 
        0 0 0 2px rgba(99, 102, 241, 0.2),
        0 4px 12px -2px rgba(0, 0, 0, 0.06);
}

/* ============================================
   Print Styles
   ============================================ */

@media print {
    .login-back {
        background: white;
    }

    .login-card {
        box-shadow: none;
        border: 1px solid #000;
    }

    .gsi-material-button {
        border: 1px solid #000;
    }
}

/* ============================================
   Snow Effect
   ============================================ */

.snow-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.snowflake {
    position: absolute;
    top: -20px;
    color: #94a3b8;
    font-size: 12px;
    opacity: 0.7;
    animation: fall linear infinite;
    will-change: transform;
}

.snowflake:nth-child(odd) {
    color: #cbd5e1;
    font-size: 10px;
    opacity: 0.5;
}

.snowflake:nth-child(3n) {
    color: #e2e8f0;
    font-size: 14px;
    opacity: 0.8;
}

@keyframes fall {
    0% {
        transform: translateY(-20px) translateX(0) rotate(0deg);
        opacity: 0;
    }
    5% {
        opacity: 1;
    }
    25% {
        transform: translateY(25vh) translateX(var(--sway-1)) rotate(90deg);
    }
    50% {
        transform: translateY(50vh) translateX(var(--sway-2)) rotate(180deg);
    }
    75% {
        transform: translateY(75vh) translateX(var(--sway-3)) rotate(270deg);
    }
    95% {
        opacity: 1;
    }
    100% {
        transform: translateY(110vh) translateX(0) rotate(360deg);
        opacity: 0;
    }
}


