/* ============================================================
   LOGIN PAGE — Splash + Scroll-Reveal Layout
   ============================================================ */

/* ---- RESET & BASE ---- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
    overflow: hidden; /* Lock scroll awal */
    background: #eef2fb;
    font-family: 'Outfit', sans-serif;
}

/* ---- BACKGROUND BLOBS ---- */
body::before,
body::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    z-index: 0;
    filter: blur(90px);
    opacity: 0.55;
    pointer-events: none;
}

body::before {
    width: 480px;
    height: 480px;
    background: #3b82f6;
    top: -120px;
    left: -120px;
    animation: blobDrift1 8s ease-in-out infinite alternate;
}

body::after {
    width: 360px;
    height: 360px;
    background: #8b5cf6;
    bottom: -80px;
    right: -80px;
    animation: blobDrift2 10s ease-in-out infinite alternate;
}

@keyframes blobDrift1 {
    from { transform: translate(0, 0) scale(1); }
    to   { transform: translate(40px, 30px) scale(1.08); }
}
@keyframes blobDrift2 {
    from { transform: translate(0, 0) scale(1); }
    to   { transform: translate(-30px, -20px) scale(1.05); }
}

/* ============================================================
   SPLASH SCREEN — Hanya logo, full viewport
   ============================================================ */
.splash-screen {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    /* Transisi keluar saat revealed */
    transition: transform 0.75s cubic-bezier(0.4, 0, 0.2, 1),
                opacity  0.6s ease;
}

/* State saat login card naik: splash mundur ke atas */
body.revealed .splash-screen {
    transform: translateY(-18%);
    opacity: 0.25;
    pointer-events: none;
}

.splash-logo {
    width: 120px;
    height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 16px 32px rgba(59, 130, 246, 0.3));
    animation: logoFloat 4s ease-in-out infinite;
    transition: transform 0.4s ease, filter 0.4s ease;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-10px); }
}

.splash-title {
    font-size: 42px;
    font-weight: 800;
    letter-spacing: 6px;
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-top: 6px;
    line-height: 1;
}

.splash-subtitle {
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 6px;
}

/* ---- HINT geser ke atas ---- */
.scroll-hint {
    position: absolute;
    bottom: 52px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 1;
    transition: opacity 0.4s ease;
}

body.revealed .scroll-hint {
    opacity: 0;
    pointer-events: none;
}

.scroll-hint-text {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    letter-spacing: 0.5px;
}

.scroll-hint-arrow {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
}

.scroll-hint-arrow span {
    display: block;
    width: 10px;
    height: 10px;
    border-right: 2.5px solid #94a3b8;
    border-bottom: 2.5px solid #94a3b8;
    transform: rotate(45deg);
    border-radius: 1px;
    animation: arrowBounce 1.4s ease-in-out infinite;
}

.scroll-hint-arrow span:nth-child(2) { animation-delay: 0.15s; opacity: 0.65; }
.scroll-hint-arrow span:nth-child(3) { animation-delay: 0.30s; opacity: 0.35; }

@keyframes arrowBounce {
    0%, 100% { transform: rotate(45deg) translateY(0);   opacity: 1; }
    50%       { transform: rotate(45deg) translateY(4px); opacity: 0.5; }
}

/* ============================================================
   LOGIN PANEL — Naik dari bawah
   ============================================================ */
.login-panel {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 30;
    display: flex;
    justify-content: center;
    padding: 0 16px 32px;
    /* Posisi awal: tersembunyi di bawah viewport */
    transform: translateY(110%);
    opacity: 0;
    transition: transform 0.72s cubic-bezier(0.34, 1.3, 0.64, 1),
                opacity  0.5s ease;
    pointer-events: none;
}

body.revealed .login-panel {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

/* ---- LOGIN CARD ---- */
.login-card {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 28px 28px 28px 28px;
    padding: 40px 32px 32px;
    width: 100%;
    max-width: 400px;
    box-shadow:
        0 32px 64px -16px rgba(0, 0, 0, 0.14),
        0 0 0 1px rgba(255, 255, 255, 0.3) inset;
    position: relative;
}

/* Pill handle di atas card (seperti bottom sheet) */
.login-card::before {
    content: '';
    display: block;
    width: 44px;
    height: 5px;
    background: #cbd5e1;
    border-radius: 99px;
    margin: 0 auto 28px;
}

.login-card h2 {
    text-align: center;
    color: #0f172a;
    margin-bottom: 6px;
    font-size: 24px;
    font-weight: 700;
}

.login-card p.subtitle {
    text-align: center;
    color: #64748b;
    margin-bottom: 28px;
    font-size: 14px;
    font-weight: 500;
}

/* ---- FORM ELEMENTS ---- */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #334155;
    font-weight: 700;
    font-size: 13px;
    padding-left: 4px;
}

.form-group input {
    width: 100%;
    padding: 14px 18px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 14px;
    font-size: 15px;
    color: #0f172a;
    font-family: 'Outfit', sans-serif;
    font-weight: 500;
    outline: none;
    transition: all 0.3s ease;
}

.form-group input::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.form-group input:focus {
    background: #ffffff;
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

/* ---- ROLE SELECTOR ---- */
.role-selector {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    background: #f1f5f9;
    padding: 5px;
    border-radius: 14px;
}

.role-btn {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: #64748b;
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.role-btn.active {
    background: #ffffff;
    color: #3b82f6;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

/* ---- BTN LOGIN ---- */
.btn-login {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: #ffffff;
    border: none;
    border-radius: 16px;
    font-size: 17px;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    box-shadow: 0 10px 25px -5px rgba(59, 130, 246, 0.4);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(59, 130, 246, 0.5);
}

.btn-login:active {
    transform: translateY(1px);
}

/* ---- ERROR MSG ---- */
.error-msg {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #ef4444;
    padding: 13px 16px;
    border-radius: 13px;
    margin-bottom: 20px;
    font-size: 13px;
    text-align: center;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* ---- LUPA PASSWORD ---- */
.forgot-password-wrapper {
    text-align: center;
    margin-top: 16px;
}

.forgot-password-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #64748b;
    font-size: 13px;
    font-weight: 500;
    font-family: 'Outfit', sans-serif;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 8px;
    transition: all 0.25s ease;
}

.forgot-password-link:hover {
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.08);
    text-decoration: underline;
}

/* ---- content-wrapper (fp-card compatibility) ---- */
.content-wrapper {
    z-index: 10;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* ---- HEADER SECTION (lupa password page) ---- */
.header-section {
    text-align: center;
    margin-bottom: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.header-logo {
    width: 100px;
    height: 100px;
    object-fit: contain;
    margin-bottom: -4px;
    filter: drop-shadow(0 12px 24px rgba(59, 130, 246, 0.25));
}

.header-title {
    font-size: 36px;
    font-weight: 800;
    letter-spacing: 5px;
    margin-bottom: 2px;
    line-height: 1.1;
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-subtitle {
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 480px) {
    .splash-title { font-size: 34px; letter-spacing: 4px; }
    .login-card { padding: 32px 22px 24px; }
}