/* 
============================================================
   PHRI PORTAL - UNIFIED AUTHENTICATION STYLES (v2.0)
   Clean, Professional, Premium & Responsive
============================================================ 
*/

/* 1. BASE & THEME */
:root {
    --primary: #F2A93B;
    --primary-light: #FFD27D;
    --bg-dark: #08040C;
    --card-bg: rgba(28, 18, 40, 0.6);
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-main: #fff;
    --text-muted: #B9AFC8;
    --error: #ff4d4d;
    --success: #22C55E;
}

.auth-page-modern {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    background: var(--bg-dark);
    overflow-x: hidden;
    color: var(--text-main);
}

/* 2. LAYOUT: SPLIT SCREEN */
.login-split-container {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    min-height: 100vh;
}

/* LEFT PANEL: VISUAL CONTENT */
.login-visual-panel {
    position: relative;
    background: url('/images/login-bg.png') center/cover no-repeat fixed;
    display: flex;
    align-items: center;
    padding: 60px;
    overflow: hidden;
}

.visual-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(20, 12, 31, 0.9) 0%, rgba(20, 12, 31, 0.4) 100%);
    z-index: 1;
}

/* LUXURY DECOR V3 */
.luxury-decor { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 2; pointer-events: none; overflow: hidden; }
.decor-glow { position: absolute; border-radius: 50%; filter: blur(120px); opacity: 0.15; animation: slowRotate 15s infinite linear; }
.dg-1 { width: 500px; height: 500px; background: var(--primary); top: -100px; right: -100px; }
.dg-2 { width: 400px; height: 400px; background: #7C3AED; bottom: -50px; left: -50px; }

.visual-content {
    position: relative;
    z-index: 10;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
}

.branding-top { display: flex; align-items: center; gap: 20px; animation: fadeInDown 0.8s ease-out; }
.brand-logo { width: 64px; height: 64px; filter: drop-shadow(0 0 15px rgba(242, 169, 59, 0.2)); }
.brand-text { display: flex; flex-direction: column; }
.brand-name { font-family: 'Outfit', sans-serif; font-weight: 900; font-size: 28px; letter-spacing: 2px; line-height: 1; }
.brand-city { font-weight: 700; font-size: 12px; color: var(--primary); letter-spacing: 4px; margin-top: 4px; }

/* REFINED GLASS PLATFORM CARD */
.hero-platform-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 40px;
    padding: 50px;
    margin: 40px 0;
    max-width: 620px;
    animation: float 8s ease-in-out infinite, fadeInRight 1s ease-out both;
    position: relative;
}

.hero-platform-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 40px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(242, 169, 59, 0.4), transparent 50%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.badge-platform {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(242, 169, 59, 0.1);
    border-radius: 50px;
    color: var(--primary);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 24px;
}

.hero-platform-card h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 38px;
    font-weight: 800;
    margin-bottom: 16px;
    color: #fff;
    line-height: 1.1;
}

.hero-platform-card p {
    color: var(--text-muted);
    font-size: 17px;
    line-height: 1.6;
    margin-bottom: 35px;
}

.hero-stats-row {
    display: flex;
    gap: 25px;
    padding-top: 35px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.stat-pill {
    display: flex;
    align-items: center;
    gap: 12px;
    transition: 0.3s;
}

.stat-pill i {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 18px;
}

.stat-data { display: flex; flex-direction: column; }
.stat-data strong { color: #fff; font-size: 18px; line-height: 1; margin-bottom: 2px; }
.stat-data span { color: var(--text-muted); font-size: 10px; text-transform: uppercase; letter-spacing: 1px; }

.visual-footer h1 { font-family: 'Outfit', sans-serif; font-weight: 800; font-size: 44px; margin-bottom: 15px; animation: fadeInUp 0.8s ease-out 0.4s both; }
.visual-footer p { font-size: 16px; color: var(--text-muted); max-width: 480px; margin-bottom: 30px; animation: fadeInUp 0.8s ease-out 0.6s both; }

.feature-badges { display: flex; gap: 15px; flex-wrap: wrap; animation: fadeInUp 0.8s ease-out 0.8s both; }
.f-badge { padding: 12px 20px; background: rgba(255, 255, 255, 0.04); backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, 0.08); border-radius: 50px; font-size: 12px; font-weight: 700; display: flex; align-items: center; gap: 8px; transition: 0.3s; }
.f-badge i { color: var(--primary); }
.f-badge:hover { transform: translateY(-3px); background: rgba(242, 169, 59, 0.1); border-color: rgba(242, 169, 59, 0.3); }

/* INLINE ERROR MESSAGES */
.error-msg {
    color: #ff4d4d;
    font-size: 11px;
    font-weight: 600;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 5px;
    animation: errorSlideDown 0.3s ease-out;
    pointer-events: none; /* Prevents blocking clicks to inputs below/near it */
    user-select: none;
}

@keyframes errorSlideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slowRotate {
    0% { transform: translate(0,0) rotate(0deg); }
    50% { transform: translate(30px, 30px) rotate(180deg); }
    100% { transform: translate(0,0) rotate(360deg); }
}

/* RIGHT PANEL: FORM AREA */
.login-form-panel {
    background: var(--bg-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px;
    position: relative;
    overflow-y: auto;
}

.register-panel { align-items: flex-start; padding: 40px 60px; } /* Specific for register scroll */

.form-wrapper {
    width: 100%;
    max-width: 420px;
    animation: fadeInRight 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.register-wrapper-wide { max-width: 720px; margin: auto; }

.mobile-logo-wrap { display: none; margin-bottom: 25px; text-align: center; }
.mobile-logo-wrap img { width: 80px; filter: drop-shadow(0 0 15px rgba(242, 169, 59, 0.2)); }

.form-header { margin-bottom: 35px; }
.form-header h2 { font-family: 'Outfit', sans-serif; font-size: 32px; font-weight: 800; margin-bottom: 8px; color: #fff; }
.form-header p { color: var(--text-muted); font-size: 15px; }

/* 3. INPUT COMPONENTS (STANDARDIZED) */
.input-group-modern { display: flex; flex-direction: column; gap: 8px; margin-bottom: 15px; }
.input-group-modern label { font-size: 13px; font-weight: 700; color: #E6E1EE; letter-spacing: 0.5px; }

.input-with-icon { position: relative; width: 100%; }
.input-with-icon i:not(.toggle-password) {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 20px;
    transition: 0.3s;
    z-index: 2;
}

.input-with-icon input, 
.input-with-icon textarea {
    width: 100%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 16px 16px 16px 52px;
    color: #fff;
    font-size: 15px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.input-with-icon textarea { padding-top: 20px; resize: vertical; min-height: 100px; }

.input-with-icon input:focus, 
.input-with-icon textarea:focus {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(242, 169, 59, 0.1);
    outline: none;
}

.input-with-icon input:focus + i { color: var(--primary); }

/* CUSTOM DROPDOWN (PREMIUM SELECT) */
.custom-select-wrapper { position: relative; user-select: none; width: 100%; }
.custom-select-trigger {
    cursor: pointer;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 16px 45px 16px 52px;
    color: #fff;
    font-size: 15px;
    display: flex;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    min-height: 55px;
    box-sizing: border-box;
}

.custom-select-trigger:hover { 
    background: rgba(255, 255, 255, 0.05); 
    border-color: rgba(255, 255, 255, 0.2); 
}

.custom-select-wrapper.open .custom-select-trigger { 
    border-color: var(--primary); 
    background: rgba(242, 169, 59, 0.03);
    box-shadow: 0 0 0 4px rgba(242, 169, 59, 0.1); 
}

.trigger-icon-left { 
    position: absolute; left: 18px; top: 50%; transform: translateY(-50%); 
    color: var(--text-muted); font-size: 20px; transition: 0.3s; 
}

.custom-select-wrapper.open .trigger-icon-left { color: var(--primary); }

.toggle-icon-right { 
    position: absolute; right: 18px; top: 50%; transform: translateY(-50%); 
    color: rgba(185, 175, 200, 0.3); transition: all 0.3s ease; 
}

.custom-select-wrapper.open .toggle-icon-right { 
    transform: translateY(-50%) rotate(180deg); color: var(--primary); 
}

.custom-options {
    position: absolute;
    top: calc(100% + 10px);
    left: 0; width: 100%;
    background: #140C1F;
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 10px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 25px 50px rgba(0,0,0,0.8);
}

.custom-select-wrapper.open .custom-options { opacity: 1; visibility: visible; transform: translateY(0); }

.custom-option {
    padding: 14px 18px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 15px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    margin-bottom: 2px;
}

.custom-option:last-child { margin-bottom: 0; }
.custom-option i { color: var(--primary); opacity: 0.6; font-size: 18px; }
.custom-option:hover { background: rgba(255, 255, 255, 0.05); color: #fff; }

.custom-option.selected { 
    background: var(--primary); 
    color: #08040C; 
    font-weight: 700; 
}

.custom-option.selected i { color: #08040C; opacity: 1; }

.custom-option.selected { background: var(--primary); color: #1C1228; font-weight: 700; }
.custom-option.selected i { color: #1C1228; }

/* PASSWORD TOGGLE EYE */
.toggle-password {
    position: absolute !important;
    right: 18px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: rgba(185, 175, 200, 0.4) !important;
    cursor: pointer;
    transition: 0.3s;
    font-size: 18px !important;
    z-index: 5;
    left: auto !important;
}
.toggle-password:hover { color: #fff; }

/* 4. GRID & SECTIONS */
.modern-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 15px 40px; }
.modern-grid-full { grid-column: span 2; }

.modern-form-section {
    grid-column: span 2;
    margin: 30px 0 10px;
    font-size: 13px;
    font-weight: 800;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
    gap: 15px;
}
.modern-form-section::after { content: ""; flex: 1; height: 1px; background: rgba(255, 255, 255, 0.08); }

/* 5. UPLOAD COMPONENT */
.file-upload-wrapper { display: grid; grid-template-columns: 1fr 1fr; gap: 25px; }
.file-upload-modern {
    border: 2px dashed var(--glass-border);
    border-radius: 24px;
    padding: 30px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.02);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.preview-img {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    z-index: 1;
    display: none;
    border-radius: 22px;
}

.preview-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2;
    display: none;
}

.file-upload-modern.has-preview { border-style: solid; border-color: var(--primary); }
.file-upload-modern.has-preview .preview-img,
.file-upload-modern.has-preview .preview-overlay { display: block; }
.file-upload-modern.has-preview i,
.file-upload-modern.has-preview strong,
.file-upload-modern.has-preview span { position: relative; z-index: 10; }

.file-upload-modern:hover { border-color: var(--primary); background: rgba(242, 169, 59, 0.05); }
.file-upload-modern i { font-size: 28px; color: var(--primary); margin-bottom: 10px; transition: 0.3s; }
.file-upload-modern span { font-size: 13px; color: var(--text-muted); transition: 0.3s; }
.file-upload-modern strong { color: #fff; font-size: 14px; display: block; margin-bottom: 4px; transition: 0.3s; }

/* 6. BUTTONS & FOOTER */
.btn-login-modern {
    margin-top: 25px;
    width: 100%;
    background: var(--primary);
    color: #08040C;
    border: none;
    padding: 20px;
    border-radius: 20px;
    font-size: 16px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.btn-login-modern:hover { 
    background: var(--primary-light); 
    transform: translateY(-4px); 
    box-shadow: 0 15px 35px rgba(242, 169, 59, 0.25); 
}

.btn-login-modern i { font-size: 24px; }

.form-footer-modern { 
    margin-top: 50px; 
    padding-top: 35px; 
    border-top: 1px solid rgba(255, 255, 255, 0.05); 
    text-align: center; 
}

.form-footer-modern p { 
    font-size: 15px; 
    color: var(--text-muted); 
    margin-bottom: 20px; 
}

.btn-secondary-modern { 
    display: inline-block; 
    padding: 14px 28px; 
    background: rgba(255, 255, 255, 0.03); 
    border: 1px solid var(--glass-border); 
    border-radius: 14px; 
    color: #fff; 
    text-decoration: none; 
    font-size: 14px; 
    font-weight: 700; 
    transition: all 0.3s ease; 
}

.btn-secondary-modern:hover { 
    background: rgba(255, 255, 255, 0.08); 
    border-color: rgba(255, 255, 255, 0.2); 
    color: var(--primary); 
}

.copyright-text { 
    margin-top: 50px; 
    font-size: 12px; 
    color: rgba(185, 175, 200, 0.3); 
    text-align: center; 
    letter-spacing: 0.5px;
}

/* 7. ALERTS */
.modern-alert { padding: 16px 20px; border-radius: 16px; display: flex; align-items: center; gap: 15px; margin-bottom: 25px; font-size: 14px; font-weight: 600; animation: shake 0.5s; }
.modern-alert.error { background: rgba(236, 33, 33, 0.1); color: var(--error); border: 1px solid rgba(236, 33, 33, 0.2); }
.modern-alert.success { background: rgba(34, 197, 94, 0.1); color: var(--success); border: 1px solid rgba(34, 197, 94, 0.2); }

/* 8. ANIMATIONS */
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInRight { from { opacity: 0; transform: translateX(30px); } to { opacity: 1; transform: translateX(0); } }
@keyframes shake { 0%, 100% { transform: translateX(0); } 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }
@keyframes spin { 100% { transform: rotate(360deg); } }

/* 9. RESPONSIVE */
@media (max-width: 1100px) {
    .login-split-container { grid-template-columns: 1fr 1fr; }
    .visual-footer h1 { font-size: 42px; }
}

@media (max-width: 991px) {
    .login-split-container { grid-template-columns: 1fr; }
    .login-visual-panel { display: none; }
    .login-form-panel { padding: 40px 20px; }
    .register-panel { padding: 40px 25px; }
    .mobile-logo-wrap { display: block; text-align: center; margin-bottom: 30px; }
    .mobile-logo-wrap img { width: 70px; }
}

@media (max-width: 768px) {
    .modern-grid-2 { grid-template-columns: 1fr; }
    .modern-grid-full { grid-column: span 1; }
    .modern-form-section { grid-column: span 1; }
    .file-upload-wrapper { grid-template-columns: 1fr; }
}
/* 10. SWEETALERT PREMIUM STYLING */
/* 10. SWEETALERT PREMIUM STYLING */
.swal2-premium-popup {
    border-radius: 24px !important;
    background: rgba(20, 12, 31, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 25px 50px rgba(0,0,0,0.6) !important;
    padding: 20px !important;
}

.swal2-title {
    font-family: 'Outfit', sans-serif !important;
    font-weight: 800 !important;
    letter-spacing: 0.5px !important;
}

.swal2-html-container {
    color: var(--text-muted) !important;
    font-size: 15px !important;
}

.swal2-styled.swal2-confirm {
    border-radius: 14px !important;
    padding: 12px 30px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    font-size: 13px !important;
}

/* 11. CENTERED AUTH CARD (FORGOT PASSWORD) */
.auth-centered-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    position: relative;
    overflow: hidden;
    background: var(--bg-dark);
}

.modern-auth-card {
    width: 100%;
    max-width: 480px;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 32px;
    padding: 50px;
    position: relative;
    z-index: 10;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.4);
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.auth-card-logo { text-align: center; margin-bottom: 30px; }
.auth-card-logo img { width: 80px; filter: drop-shadow(0 0 20px rgba(242, 169, 59, 0.3)); }

.auth-card-header { text-align: center; margin-bottom: 35px; }
.auth-card-header h2 { font-family: 'Outfit', sans-serif; font-size: 32px; font-weight: 800; margin-bottom: 12px; color: #fff; }
.auth-card-header p { color: var(--text-muted); font-size: 15px; line-height: 1.6; }

.small-link {
    font-size: 13px;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    transition: 0.3s;
    opacity: 0.8;
}
.small-link:hover { opacity: 1; text-decoration: underline; }

.back-to-login {
    margin-top: 35px;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    text-align: center;
}
.back-to-login a {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: 0.3s;
}
.back-to-login a:hover { color: #fff; transform: translateX(-5px); }
.back-to-login i { font-size: 18px; }

.d-flex-between { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 8px; }

