/* ============================================
   BRAINHEALTH PORTAL - SHARED STYLES
   ============================================ */

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

body {
    font-family: 'Inter', sans-serif;
    background: #F4F6FA;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    color: #071A31;
}

h1, h2, h3, h4, h5 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
}

.hidden {
    display: none !important;
}

/* ============================================
   LOADING SCREEN
   ============================================ */
.loading-screen {
    text-align: center;
    color: #071A31;
}

.loading-screen h2 {
    font-size: 32px;
    margin-bottom: 20px;
}

/* ============================================
   LOGIN SCREEN
   ============================================ */
.login-container {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 20px rgba(19, 64, 120, 0.1);
    max-width: 450px;
    width: 100%;
}

.login-logo {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo h1 {
    color: #071A31;
    font-size: 28px;
    margin-bottom: 8px;
    font-weight: 700;
}

.login-logo p {
    color: #071A31;
    font-size: 14px;
}

.login-form {
    display: block;
    margin-top: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #071A31;
    font-weight: 600;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #E4EFEF;
    border-radius: 6px;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #071A31;
}

.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper input {
    padding-right: 45px;
}

.password-toggle {
    position: absolute;
    right: 10px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: #071A31;
}

.password-toggle svg {
    width: 20px;
    height: 20px;
}

.login-btn {
    width: 100%;
    background: #134078;
    color: white;
    border: none;
    padding: 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: background 0.3s;
}

.login-btn:hover {
    background: #0f3461;
}

.login-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.login-btn.secondary {
    background: #3A3A3A;
    margin-top: 10px;
}

.login-btn.secondary:hover {
    background: #2a2a2a;
}

.login-info {
    background: #E4EFEF;
    border-left: 4px solid #289696;
    padding: 15px;
    margin-top: 20px;
    border-radius: 4px;
}

.login-info p {
    font-size: 12px;
    color: #071A31;
    margin: 5px 0;
}

.login-info a {
    color: #071A31;
    text-decoration: none;
    font-weight: 700;
}

.login-info a:hover {
    text-decoration: underline;
}

.error-message {
    background: #fee;
    border: 1px solid #fcc;
    color: #c33;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
    font-size: 14px;
}

.caps-lock-warning {
    background: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
    padding: 8px 12px;
    border-radius: 4px;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 600;
}

/* ============================================
   DASHBOARD SCREEN
   ============================================ */
.dashboard-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(19, 64, 120, 0.1);
    width: 100%;
    max-width: 900px;
    min-height: 500px;
    display: flex;
    flex-direction: column;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    border-bottom: 2px solid #E4EFEF;
}

.header-left h1 {
    color: #071A31;
    font-size: 24px;
    margin-bottom: 4px;
}

.account-name {
    color: #666;
    font-size: 14px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-greeting {
    color: #071A31;
    font-size: 14px;
    font-weight: 600;
}

.sign-out-btn {
    background: #289696;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: background 0.3s;
}

.sign-out-btn:hover {
    background: #1f7a7a;
}

.dashboard-main {
    flex: 1;
    padding: 40px 32px;
}

.dashboard-main h2 {
    color: #071A31;
    font-size: 20px;
    margin-bottom: 32px;
    text-align: center;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
    max-width: 700px;
    margin: 0 auto;
}

.service-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 24px;
    background: #F4F6FA;
    border: 2px solid #E4EFEF;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Inter', sans-serif;
}

.service-btn:hover {
    background: #E4EFEF;
    border-color: #134078;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(19, 64, 120, 0.15);
}

.service-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 16px;
    color: #134078;
}

.service-icon svg {
    width: 100%;
    height: 100%;
}

.service-name {
    font-size: 16px;
    font-weight: 600;
    color: #071A31;
    text-align: center;
}

.no-services {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.no-services p {
    margin-bottom: 10px;
}

.dashboard-footer {
    padding: 16px 32px;
    border-top: 1px solid #E4EFEF;
    text-align: center;
}

.dashboard-footer p {
    color: #999;
    font-size: 12px;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }

    .login-container {
        padding: 30px 20px;
    }

    .login-logo h1 {
        font-size: 24px;
    }

    .dashboard-header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
        padding: 20px;
    }

    .header-right {
        flex-direction: column;
        gap: 12px;
    }

    .dashboard-main {
        padding: 30px 20px;
    }

    .service-grid {
        grid-template-columns: 1fr;
    }

    .service-btn {
        padding: 24px 20px;
    }
}
