/* style.css - Shared styles for all pages */
:root {
    --primary: #2c5aa0;
    --primary-light: #4a7bc8;
    --secondary: #e63946;
    --accent: #ffb703;
    --success: #2a9d8f;
    --light: #f8f9fa;
    --dark: #212529;
    --gray: #6c757d;
    --light-gray: #e9ecef;
    --border-radius: 10px;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f7fb;
    color: var(--dark);
    line-height: 1.6;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header & Navigation */
header {
    background-color: white;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    gap: 24px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--primary);
    text-decoration: none;
}

.logo i {
    color: var(--accent);
}

.nav-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex: 1;
    gap: 24px;
}

.nav-links {
    display: flex;
    gap: 25px;
    justify-content: center;
    flex: 1;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary);
}

.auth-buttons {
    display: flex;
    gap: 10px;
    margin-left: auto;
}

.btn {
    padding: 10px 20px;
    border-radius: var(--border-radius);
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-light);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background-color: rgba(44, 90, 160, 0.1);
}

.btn-success {
    background-color: var(--success);
    color: white;
}

.btn-success:hover {
    background-color: #21867a;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* Guest Warning */
.guest-warning {
    background-color: #fff3cd;
    border-left: 5px solid #ffc107;
    padding: 15px;
    margin: 20px 0;
    border-radius: 5px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.guest-warning i {
    color: #856404;
    font-size: 1.5rem;
}

.guest-warning p {
    color: #856404;
    margin: 0;
}

/* Hero Section */
.hero {
    padding: 80px 0;
    background: linear-gradient(135deg, #f5f7fb 0%, #e3e9f8 100%);
}

.hero-content {
    display: flex;
    align-items: center;
    gap: 50px;
}

.hero-text {
    flex: 1;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.hero-image img {
    max-width: 100%;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

h1 {
    font-size: 2.8rem;
    margin-bottom: 20px;
    color: var(--primary);
    line-height: 1.2;
}

.highlight {
    color: var(--secondary);
}

.hero p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    color: var(--gray);
}

.features {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 30px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: white;
    padding: 10px 15px;
    border-radius: 50px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.feature i {
    color: var(--success);
}

/* Main Dashboard */
.dashboard {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    color: var(--primary);
}

.section-title h2 {
    font-size: 2.2rem;
    margin-bottom: 10px;
}

/* Process Flow */
.process-flow {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-bottom: 60px;
}

.process-step {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 25px;
    width: 180px;
    text-align: center;
    box-shadow: var(--shadow);
    position: relative;
}

.process-step:not(:last-child)::after {
    content: "↓";
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.5rem;
    color: var(--gray);
}

.step-number {
    background-color: var(--primary);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    font-weight: bold;
}

.step-title {
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--primary);
}

/* Modules */
.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 60px;
}

.module-card {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 25px;
    box-shadow: var(--shadow);
    border-top: 5px solid var(--primary);
    transition: var(--transition);
}

.module-card:hover {
    transform: translateY(-5px);
}

.module-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.module-icon {
    width: 50px;
    height: 50px;
    background-color: rgba(44, 90, 160, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.2rem;
}

.module-title {
    font-size: 1.3rem;
    color: var(--primary);
}

.process-list {
    list-style-type: none;
}

.process-list li {
    padding: 8px 0;
    border-bottom: 1px solid var(--light-gray);
    display: flex;
    align-items: center;
    gap: 10px;
}

.process-list li:last-child {
    border-bottom: none;
}

.process-list i {
    color: var(--success);
}

/* OCR Upload Section */
.upload-section {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow);
    margin-bottom: 60px;
}

.upload-area {
    border: 3px dashed var(--light-gray);
    border-radius: var(--border-radius);
    padding: 50px 20px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    margin-bottom: 30px;
}

.upload-area:hover {
    border-color: var(--primary);
    background-color: rgba(44, 90, 160, 0.02);
}

.upload-area i {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 15px;
}

.upload-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

/* DSS Results */
.results-section {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow);
    margin-bottom: 60px;
}

.scholarship-card {
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    padding: 25px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.scholarship-card:hover {
    border-color: var(--primary);
}

.scholarship-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.scholarship-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary);
}

.probability-badge {
    background-color: var(--success);
    color: white;
    padding: 5px 15px;
    border-radius: 50px;
    font-weight: 600;
}

.probability-70 {
    background-color: #2a9d8f;
}

.probability-50 {
    background-color: #e9c46a;
}

.probability-30 {
    background-color: #f4a261;
}

.scholarship-details {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.detail-item {
    display: flex;
    gap: 8px;
}

.detail-label {
    font-weight: 600;
    color: var(--gray);
}

/* Application Wizard */
.wizard-container {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow);
    margin-bottom: 60px;
}

.wizard-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin-bottom: 40px;
}

.wizard-steps::before {
    content: "";
    position: absolute;
    top: 20px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--light-gray);
    z-index: 1;
}

.wizard-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
}

.step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--light-gray);
    color: var(--gray);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    margin-bottom: 10px;
    transition: var(--transition);
}

.wizard-step.active .step-circle {
    background-color: var(--primary);
    color: white;
}

.wizard-step.completed .step-circle {
    background-color: var(--success);
    color: white;
}

.step-label {
    font-weight: 500;
    color: var(--gray);
}

.wizard-step.active .step-label {
    color: var(--primary);
    font-weight: 600;
}

.wizard-content {
    padding: 20px;
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    min-height: 300px;
}

.wizard-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
}

/* Login Page Styles */
.login-page {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 0;
}

.login-container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.login-card {
    background-color: white;
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h1 {
    color: var(--primary);
    margin-bottom: 10px;
}

.login-tabs {
    display: flex;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--light-gray);
}

.login-tab {
    flex: 1;
    padding: 15px;
    text-align: center;
    background: none;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray);
    cursor: pointer;
    transition: var(--transition);
    border-bottom: 3px solid transparent;
}

.login-tab.active {
    color: var(--primary);
    border-bottom: 3px solid var(--primary);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(44, 90, 160, 0.1);
}

.form-footer {
    text-align: center;
    margin-top: 20px;
    color: var(--gray);
}

/* Footer */
footer {
    background-color: var(--dark);
    color: white;
    padding: 60px 0 30px;
    margin-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: white;
}

.footer-about p {
    color: #adb5bd;
    margin-bottom: 20px;
}

.footer-links h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: white;
}

.footer-links ul {
    list-style-type: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #adb5bd;
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #495057;
    color: #adb5bd;
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .hero-content {
        flex-direction: column;
    }
    
    .hero-text, .hero-image {
        width: 100%;
    }
    
    h1 {
        font-size: 2.2rem;
    }
    
    .process-step:not(:last-child)::after {
        display: none;
    }
    
    .process-flow {
        gap: 15px;
    }
    
    .process-step {
        width: 45%;
    }
}

@media (max-width: 768px) {
    .navbar {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .process-step {
        width: 100%;
    }
    
    .wizard-steps {
        flex-direction: column;
        gap: 30px;
    }
    
    .wizard-steps::before {
        display: none;
    }
    
    .upload-info {
        flex-direction: column;
        gap: 20px;
    }
}

@media (max-width: 576px) {
    .login-card {
        padding: 30px 20px;
    }
    
    .auth-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .auth-buttons .btn {
        width: 100%;
    }

    .available-scholarships {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.no-scholarships {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.no-scholarships h3 {
    color: #4b5563;
    margin-bottom: 10px;
}

.no-scholarships p {
    color: #6b7280;
    max-width: 400px;
    margin: 0 auto;
}
}

.probability-badge {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: bold;
    display: inline-block;
    color: white;
}

.probability-70 { background: linear-gradient(135deg, #4CAF50, #2E7D32); }
.probability-50 { background: linear-gradient(135deg, #FF9800, #EF6C00); }
.probability-30 { background: linear-gradient(135deg, #F44336, #C62828); }

.scholarship-card.not-eligible {
    opacity: 0.7;
    filter: grayscale(0.3);
}

.deadline-warning {
    color: #f44336;
    font-weight: bold;
    font-size: 0.9em;
}

.eligibility-warning {
    background: #ffebee;
    padding: 8px 12px;
    border-radius: 5px;
    margin-top: 10px;
    border-left: 3px solid #f44336;
    font-size: 0.9em;
}

.eligibility-warning i {
    color: #f44336;
    margin-right: 5px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
/* Responsive system shell upgrades */
body {
    overflow-x: hidden;
}

img,
picture,
video,
canvas,
svg {
    max-width: 100%;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
}

.nav-toggle {
    display: none;
    align-items: center;
    gap: 8px;
    min-height: 42px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid #dbe4f3;
    background: #f8fbff;
    color: var(--primary);
    font-weight: 700;
    cursor: pointer;
}

.nav-toggle-label {
    font-size: 0.82rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.nav-panel {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 24px;
    flex: 1;
    margin-left: auto;
}

.nav-links a.active {
    color: var(--primary);
    font-weight: 700;
}

#guestButtons,
#userButtons {
    display: flex;
    align-items: center;
}

#guestButtons {
    gap: 10px;
}

#userName {
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 1100px) {
    .container {
        padding: 0 18px;
    }

    .hero-content {
        gap: 32px;
    }

    .nav-panel {
        gap: 18px;
    }
}

@media (max-width: 900px) {
    body.nav-open {
        overflow: hidden;
    }

    .navbar {
        position: relative;
        gap: 16px;
        padding: 14px 0;
        flex-wrap: wrap;
    }

    .logo {
        font-size: 1.2rem;
    }

    .nav-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .nav-panel {
        display: none;
        position: absolute;
        top: calc(100% + 10px);
        left: 0;
        right: 0;
        margin-left: 0;
        padding: 18px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid #dce6f5;
        box-shadow: 0 22px 46px rgba(15, 23, 42, 0.12);
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }

    .navbar.is-open .nav-panel {
        display: flex;
    }

    .nav-links {
        flex-direction: column;
        gap: 8px;
    }

    .nav-links a {
        display: block;
        padding: 11px 12px;
        border-radius: 12px;
        background: #f8fbff;
    }

    .nav-links a.active {
        background: rgba(44, 90, 160, 0.1);
    }

    .auth-buttons,
    #guestButtons,
    #userButtons,
    .user-profile {
        width: 100%;
    }

    #guestButtons,
    .user-profile {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .user-profile {
        padding-top: 8px;
        border-top: 1px solid #edf2f8;
    }

    #userName {
        max-width: none;
        white-space: normal;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .hero {
        padding: 52px 0;
    }

    .hero-content {
        flex-direction: column;
        gap: 24px;
    }

    h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .features {
        gap: 10px;
    }

    .feature {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .dashboard,
    .login-page {
        padding: 36px 0;
    }

    .section-title {
        margin-bottom: 28px;
    }

    .section-title h2 {
        font-size: 1.8rem;
    }

    .modules-grid,
    .scholarship-details,
    .footer-content {
        grid-template-columns: 1fr;
    }

    .process-step,
    .module-card,
    .upload-section,
    .results-section,
    .wizard-container,
    .login-card {
        width: 100%;
        padding: 22px;
    }

    .upload-area {
        padding: 34px 16px;
    }

    .upload-info,
    .wizard-actions,
    .scholarship-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .wizard-steps {
        gap: 14px;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 10px;
        margin-bottom: 28px;
        scrollbar-width: thin;
    }

    .wizard-steps::before {
        top: 18px;
    }

    .wizard-step {
        min-width: 88px;
    }

    .step-label {
        font-size: 0.78rem;
        text-align: center;
    }

    .wizard-content {
        min-height: auto;
        padding: 16px;
    }

    footer {
        padding: 42px 0 24px;
        margin-top: 42px;
    }
}

@media (max-width: 576px) {
    .container {
        padding: 0 14px;
    }

    .guest-warning {
        align-items: flex-start;
        padding: 14px;
    }

    h1 {
        font-size: 1.75rem;
    }

    .logo {
        font-size: 1.05rem;
    }

    .logo span {
        max-width: 170px;
    }

    .btn,
    .btn-outline,
    .btn-primary,
    .btn-success {
        width: 100%;
    }

    .process-step,
    .module-card,
    .upload-section,
    .results-section,
    .wizard-container,
    .login-card {
        padding: 18px;
    }

    .footer-logo {
        font-size: 1.4rem;
    }

    .copyright {
        padding-top: 20px;
    }
}
/* Mobile menu alignment polish */
@media (max-width: 900px) {
    .navbar {
        justify-content: space-between;
        align-items: center;
        flex-wrap: nowrap;
    }

    .logo {
        min-width: 0;
        gap: 8px;
        line-height: 1.1;
    }

    .logo span {
        display: inline-block;
        font-size: 1.08rem;
        line-height: 1.15;
    }

    .logo i {
        font-size: 0.95rem;
        flex-shrink: 0;
    }

    .nav-toggle {
        flex-shrink: 0;
        margin-left: 12px;
    }

    .nav-panel {
        left: 50%;
        right: auto;
        width: min(340px, calc(100vw - 28px));
        transform: translateX(-50%);
        padding: 16px;
        align-items: center;
        text-align: center;
    }

    .nav-links {
        width: 100%;
        align-items: center;
    }

    .nav-links a {
        width: 100%;
        max-width: 100%;
        text-align: center;
        padding: 12px 14px;
    }

    .auth-buttons,
    #guestButtons,
    #userButtons {
        justify-content: center;
        align-items: center;
    }

    #guestButtons,
    .user-profile {
        max-width: 100%;
    }

    .user-profile {
        align-items: center;
        text-align: center;
        padding-top: 12px;
    }

    .user-avatar {
        margin: 0 auto;
    }

    #logoutButton,
    #guestButtons .btn {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .logo span {
        font-size: 0.98rem;
        max-width: 180px;
    }

    .nav-toggle {
        min-height: 40px;
        padding: 0 12px;
    }

    .nav-toggle-label {
        font-size: 0.75rem;
    }

    .nav-panel {
        width: calc(100vw - 22px);
        top: calc(100% + 8px);
        border-radius: 16px;
    }
}
/* Mobile drawer navigation */
.nav-backdrop {
    display: none;
}

.nav-drawer-heading {
    display: none;
}

@media (max-width: 900px) {
    .navbar {
        justify-content: space-between;
        align-items: center;
        flex-wrap: nowrap;
    }

    .logo {
        min-width: 0;
        flex: 1;
        gap: 10px;
    }

    .logo span {
        font-size: 1.05rem;
        line-height: 1.15;
    }

    .nav-toggle {
        width: 44px;
        min-width: 44px;
        height: 44px;
        min-height: 44px;
        padding: 0;
        margin-left: 12px;
        border-radius: 14px;
        border: 1px solid #dce6f5;
        background: #ffffff;
        box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
    }

    .nav-toggle-label {
        display: none;
    }

    .nav-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        border: 0;
        background: rgba(15, 23, 42, 0.28);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.25s ease;
        z-index: 1190;
    }

    .navbar.is-open .nav-backdrop {
        opacity: 1;
        pointer-events: auto;
    }

    .nav-panel {
        display: flex;
        position: fixed;
        top: 0;
        right: 0;
        left: auto;
        width: min(320px, calc(100vw - 24px));
        height: 100dvh;
        margin-left: 0;
        padding: 22px 18px 18px;
        border-radius: 24px 0 0 24px;
        background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
        border-left: 1px solid #dce6f5;
        box-shadow: -22px 0 48px rgba(15, 23, 42, 0.16);
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
        transform: translateX(108%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.28s ease, opacity 0.24s ease;
        z-index: 1200;
        overflow-y: auto;
        text-align: left;
    }

    .navbar.is-open .nav-panel {
        transform: translateX(0);
        opacity: 1;
        pointer-events: auto;
    }

    .nav-drawer-heading {
        display: flex;
        flex-direction: column;
        gap: 4px;
        padding: 0 4px 10px;
        border-bottom: 1px solid #e8eef7;
    }

    .nav-drawer-kicker {
        color: #2c5aa0;
        font-size: 0.72rem;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-transform: uppercase;
    }

    .nav-drawer-heading strong {
        color: #102544;
        font-size: 1rem;
        line-height: 1.25;
    }

    .nav-links {
        width: 100%;
        flex-direction: column;
        gap: 8px;
        align-items: stretch;
    }

    .nav-links a {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        width: 100%;
        padding: 13px 14px;
        border-radius: 14px;
        background: #ffffff;
        border: 1px solid #e3ebf8;
        text-align: left;
        font-weight: 600;
        box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
    }

    .nav-links a.active {
        background: #edf4ff;
        border-color: #cfe0fb;
    }

    .auth-buttons,
    #guestButtons,
    #userButtons,
    .user-profile {
        width: 100%;
    }

    .auth-buttons {
        margin-top: auto;
        padding-top: 14px;
        border-top: 1px solid #e8eef7;
    }

    #guestButtons,
    .user-profile {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .user-profile {
        text-align: left;
        padding-top: 0;
        border-top: 0;
    }

    .user-avatar {
        margin: 0;
    }

    #userName {
        max-width: none;
        color: #102544;
        font-weight: 600;
    }

    #logoutButton,
    #guestButtons .btn {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .logo span {
        font-size: 0.96rem;
    }

    .nav-panel {
        width: min(300px, calc(100vw - 16px));
        padding: 20px 16px 16px;
        border-radius: 20px 0 0 20px;
    }
}
/* Left drawer alignment refinements */
@media (max-width: 900px) {
    .navbar {
        flex-direction: row !important;
        justify-content: flex-start;
        align-items: center;
        gap: 10px;
        flex-wrap: nowrap;
    }

    .nav-toggle {
        display: inline-flex !important;
        order: -1;
        margin: 0;
        justify-content: center;
        align-items: center;
        width: 42px;
        min-width: 42px;
        height: 42px;
        min-height: 42px;
        border-radius: 12px;
        border: 1px solid #dce6f5;
        background: #ffffff;
        box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
    }

    .nav-toggle i {
        display: block;
        font-size: 1.05rem;
        line-height: 1;
    }

    .logo {
        flex: 0 1 auto;
        min-width: 0;
        max-width: calc(100% - 54px);
        gap: 8px;
        margin-right: 0;
    }

    .logo span {
        font-size: 1rem;
        line-height: 1.15;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .nav-panel {
        left: 0;
        right: auto;
        width: min(320px, calc(100vw - 18px));
        border-radius: 0 24px 24px 0;
        border-left: 0;
        border-right: 1px solid #dce6f5;
        box-shadow: 22px 0 48px rgba(15, 23, 42, 0.16);
        transform: translateX(-108%);
    }

    .navbar.is-open .nav-panel {
        transform: translateX(0);
    }
}

@media (max-width: 576px) {
    .logo {
        max-width: calc(100% - 50px);
    }

    .logo span {
        font-size: 0.94rem;
    }

    .nav-panel {
        width: min(296px, calc(100vw - 12px));
        border-radius: 0 20px 20px 0;
    }
}
/* Final mobile drawer polish */
.user-profile-meta {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-profile-copy {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.user-profile-label {
    display: none;
}

.nav-drawer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #102544;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.nav-drawer-brand i {
    color: var(--accent);
    font-size: 1rem;
}

@media (max-width: 900px) {
    .navbar {
        flex-direction: row !important;
        justify-content: flex-start;
        align-items: center;
        gap: 10px;
        flex-wrap: nowrap;
    }

    .nav-toggle {
        display: inline-flex !important;
        order: -1;
        margin: 0;
        justify-content: center;
        align-items: center;
        width: 42px;
        min-width: 42px;
        height: 42px;
        min-height: 42px;
        border-radius: 12px;
        border: 1px solid #dce6f5;
        background: #ffffff;
        box-shadow: 0 8px 22px rgba(15, 23, 42, 0.08);
    }

    .nav-toggle i {
        display: block;
        font-size: 1.05rem;
        line-height: 1;
    }

    .logo {
        flex: 0 1 auto;
        min-width: 0;
        max-width: calc(100% - 54px);
        gap: 8px;
        margin-right: 0;
    }

    .logo span {
        font-size: 1rem;
        line-height: 1.15;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .nav-panel {
        left: 0;
        right: auto;
        width: min(320px, calc(100vw - 18px));
        border-radius: 0 24px 24px 0;
        border-left: 0;
        border-right: 1px solid #dce6f5;
        box-shadow: 22px 0 48px rgba(15, 23, 42, 0.16);
        transform: translateX(-108%);
        padding: 22px 18px 18px;
    }

    .navbar.is-open .nav-panel {
        transform: translateX(0);
    }

    .nav-drawer-heading {
        display: flex;
        align-items: center;
        padding: 0 2px 12px;
        border-bottom: 1px solid #e8eef7;
    }

    .nav-links {
        width: 100%;
        flex-direction: column;
        gap: 8px;
        align-items: stretch;
    }

    .nav-links a {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        width: 100%;
        padding: 13px 14px;
        border-radius: 14px;
        background: #ffffff;
        border: 1px solid #e3ebf8;
        text-align: left;
        font-weight: 600;
        box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
    }

    .nav-links a.active {
        background: #edf4ff;
        border-color: #cfe0fb;
    }

    .auth-buttons,
    #guestButtons,
    #userButtons,
    .user-profile {
        width: 100%;
    }

    .auth-buttons {
        margin-top: auto;
        padding-top: 14px;
        border-top: 1px solid #e8eef7;
    }

    #guestButtons,
    .user-profile {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .user-profile {
        padding: 14px;
        border-radius: 18px;
        background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
        border: 1px solid #e3ebf8;
        box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
        text-align: left;
    }

    .user-profile-meta {
        gap: 12px;
        align-items: center;
    }

    .user-avatar {
        width: 48px;
        height: 48px;
        margin: 0;
        border: 2px solid #dbe7fb;
        box-shadow: 0 8px 18px rgba(44, 90, 160, 0.14);
        flex-shrink: 0;
    }

    .user-profile-label {
        display: block;
        color: #6a82a4;
        font-size: 0.64rem;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-transform: uppercase;
    }

    #userName {
        max-width: none;
        color: #102544;
        font-weight: 700;
        font-size: 0.98rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    #logoutButton,
    #guestButtons .btn {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .logo {
        max-width: calc(100% - 50px);
    }

    .logo span {
        font-size: 0.94rem;
    }

    .nav-panel {
        width: min(296px, calc(100vw - 12px));
        border-radius: 0 20px 20px 0;
        padding: 20px 16px 16px;
    }

    .nav-drawer-brand {
        font-size: 0.98rem;
    }
}
