/* =============================================
   Y4GH2 Alumni Portal — Main Stylesheet
   ============================================= */

:root {
    --bg-primary:    #0d1b2a;
    --bg-secondary:  #112236;
    --bg-card:       #152a3e;
    --bg-input:      #0d1b2a;
    --accent-green:  #3dd68c;
    --accent-green2: #2fb87a;
    --accent-blue:   #1e90ff;
    --text-primary:  #e8f0fe;
    --text-muted:    #8fa8c8;
    --border:        #1e3a55;
    --error:         #ff6b6b;
    --success:       #3dd68c;
    --warning:       #ffc107;
    --radius:        10px;
    --radius-lg:     16px;
    --shadow:        0 8px 32px rgba(0,0,0,0.4);
    --font:          'Segoe UI', system-ui, -apple-system, sans-serif;
}

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

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

a { color: var(--accent-green); text-decoration: none; }
a:hover { color: var(--accent-green2); text-decoration: underline; }

/* ── Auth Layout ── */
.auth-wrapper {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.auth-left {
    background: linear-gradient(160deg, #0d1b2a 0%, #112236 60%, #0d1b2a 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 60px 56px;
    position: relative;
    overflow: hidden;
}

.auth-left::before {
    content: '';
    position: absolute;
    width: 420px; height: 420px;
    background: radial-gradient(circle, rgba(61,214,140,0.07) 0%, transparent 70%);
    top: -60px; left: -60px;
    border-radius: 50%;
    pointer-events: none;
}

.auth-left::after {
    content: '';
    position: absolute;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(30,144,255,0.05) 0%, transparent 70%);
    bottom: 40px; right: -40px;
    border-radius: 50%;
    pointer-events: none;
}

.brand-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--accent-green);
    margin-bottom: 18px;
}

.auth-left h1 {
    font-size: 2.6rem;
    font-weight: 800;
    line-height: 1.15;
    color: #ffffff;
    margin-bottom: 18px;
}

.auth-left p.subtitle {
    color: var(--text-muted);
    font-size: 0.97rem;
    max-width: 380px;
    margin-bottom: 44px;
}

.feature-list { list-style: none; display: flex; flex-direction: column; gap: 14px; }

.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 18px;
}

.feature-list li .feat-icon {
    width: 36px; height: 36px;
    border-radius: 8px;
    background: rgba(61,214,140,0.12);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    font-size: 1rem;
}

.feature-list li .feat-text strong {
    display: block;
    font-size: 0.88rem;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.feature-list li .feat-text span {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ── Auth Right Panel ── */
.auth-right {
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 32px;
    border-left: 1px solid var(--border);
}

.auth-card {
    width: 100%;
    max-width: 460px;
}

.auth-card h2 {
    font-size: 1.7rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 6px;
}

.auth-card .card-sub {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 32px;
}

/* ── Form Controls ── */
.form-group { margin-bottom: 20px; }

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 7px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.input-wrap {
    position: relative;
}

.input-wrap .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1rem;
    pointer-events: none;
}

.input-wrap input,
.input-wrap select {
    width: 100%;
    padding: 12px 14px 12px 42px;
    background: var(--bg-input);
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: var(--font);
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
    appearance: none;
}

.input-wrap input::placeholder { color: #4a6380; }

.input-wrap input:focus,
.input-wrap select:focus {
    border-color: var(--accent-green);
    box-shadow: 0 0 0 3px rgba(61,214,140,0.12);
}

.input-wrap input.is-invalid,
.input-wrap select.is-invalid {
    border-color: var(--error);
}

.toggle-password {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    padding: 0;
    transition: color 0.2s;
}

.toggle-password:hover { color: var(--accent-green); }

.field-error {
    font-size: 0.78rem;
    color: var(--error);
    margin-top: 5px;
    display: block;
}

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 24px;
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-weight: 600;
    font-family: var(--font);
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    letter-spacing: 0.02em;
}

.btn-primary {
    background: var(--accent-green);
    color: #0d1b2a;
    width: 100%;
}

.btn-primary:hover {
    background: var(--accent-green2);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(61,214,140,0.3);
}

.btn-primary:active { transform: translateY(0); }

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* ── Alerts ── */
.alert {
    padding: 12px 16px;
    border-radius: var(--radius);
    font-size: 0.88rem;
    margin-bottom: 22px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.alert-error {
    background: rgba(255,107,107,0.12);
    border: 1px solid rgba(255,107,107,0.3);
    color: #ff9999;
}

.alert-success {
    background: rgba(61,214,140,0.12);
    border: 1px solid rgba(61,214,140,0.3);
    color: var(--accent-green);
}

.alert-warning {
    background: rgba(255,193,7,0.1);
    border: 1px solid rgba(255,193,7,0.3);
    color: var(--warning);
}

/* ── Divider ── */
.divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 24px 0;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* ── Password Strength ── */
.strength-bar {
    display: flex;
    gap: 4px;
    margin-top: 8px;
}

.strength-bar span {
    flex: 1;
    height: 4px;
    border-radius: 2px;
    background: var(--border);
    transition: background 0.3s;
}

.strength-label {
    font-size: 0.75rem;
    margin-top: 5px;
    color: var(--text-muted);
}

/* ── Sidebar Layout ── */
.app-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 260px;
    min-height: 100vh;
    background: #080f1d;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0; top: 0; bottom: 0;
    z-index: 100;
    overflow-y: auto;
    overflow-x: hidden;
}

.sidebar-logo {
    padding: 22px 20px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.sidebar-logo .logo-mark {
    width: 34px; height: 34px;
    background: var(--accent-green);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: #0d1b2a;
    font-weight: 900;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.sidebar-logo span {
    font-size: 0.92rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}

.sidebar-logo small {
    display: block;
    font-size: 0.68rem;
    font-weight: 400;
    color: var(--text-muted);
    letter-spacing: 0.05em;
}

/* Sidebar User Block */
.sidebar-user {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.sidebar-user-inner {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-avatar {
    width: 44px; height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(61,214,140,0.3);
    flex-shrink: 0;
}

.sidebar-avatar-initials {
    width: 44px; height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-green), #1e90ff);
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem; font-weight: 800;
    color: #0d1b2a;
    border: 2px solid rgba(61,214,140,0.3);
    flex-shrink: 0;
}

.sidebar-user-info {
    overflow: hidden;
    flex: 1;
}

.sidebar-user-name {
    font-size: 0.88rem;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-role-badge {
    display: inline-block;
    margin-top: 3px;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.sidebar-role-badge.alumni {
    background: rgba(61,214,140,0.12);
    color: var(--accent-green);
    border: 1px solid rgba(61,214,140,0.2);
}

.sidebar-role-badge.employer {
    background: rgba(30,144,255,0.12);
    color: #60aaff;
    border: 1px solid rgba(30,144,255,0.2);
}

.sidebar-role-badge.admin {
    background: rgba(184,128,255,0.12);
    color: #b880ff;
    border: 1px solid rgba(184,128,255,0.2);
}

/* Sidebar Nav */
.sidebar-nav {
    flex: 1;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow-y: auto;
}

.sidebar-section-label {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 10px 10px 4px;
    opacity: 0.6;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px 12px;
    border-radius: 9px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.15s;
    white-space: nowrap;
}

.sidebar-link i {
    width: 18px;
    text-align: center;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.sidebar-link:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text-primary);
    text-decoration: none;
}

.sidebar-link.active {
    background: rgba(61,214,140,0.12);
    color: var(--accent-green);
    font-weight: 600;
    text-decoration: none;
}

.sidebar-link.active i { color: var(--accent-green); }

.sidebar-divider {
    height: 1px;
    background: var(--border);
    margin: 6px 12px;
}

/* Sidebar Footer */
.sidebar-footer {
    padding: 12px 12px 16px;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
}

.btn-logout {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    background: rgba(255,107,107,0.07);
    border: 1px solid rgba(255,107,107,0.15);
    border-radius: 9px;
    color: #ff9999;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    font-family: var(--font);
    transition: all 0.2s;
    text-decoration: none;
}

.btn-logout:hover {
    background: rgba(255,107,107,0.14);
    color: #ff9999;
    text-decoration: none;
}

/* App Main */
.app-main {
    margin-left: 260px;
    flex: 1;
    min-height: 100vh;
}

/* ── Dashboard ── */
.main-content {
    padding: 36px 40px;
    width: 100%;
}

.page-header { margin-bottom: 36px; }

.page-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
}

.page-header p { color: var(--text-muted); font-size: 0.92rem; margin-top: 4px; }

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 36px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.stat-icon.green  { background: rgba(61,214,140,0.15); }
.stat-icon.blue   { background: rgba(30,144,255,0.15); }
.stat-icon.orange { background: rgba(255,165,0,0.15);  }
.stat-icon.purple { background: rgba(150,80,255,0.15); }

.stat-info strong {
    display: block;
    font-size: 1.6rem;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    margin-bottom: 4px;
}

.stat-info span { font-size: 0.8rem; color: var(--text-muted); }

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: border-color 0.2s, transform 0.2s;
    cursor: pointer;
}

.feature-card:hover {
    border-color: rgba(61,214,140,0.35);
    transform: translateY(-2px);
}

.feature-card .card-icon {
    width: 44px; height: 44px;
    background: rgba(61,214,140,0.12);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 16px;
}

.feature-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}

.feature-card p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    margin-top: 14px;
    letter-spacing: 0.04em;
}

.badge-green  { background: rgba(61,214,140,0.15); color: var(--accent-green); }
.badge-blue   { background: rgba(30,144,255,0.15);  color: #60aaff; }
.badge-orange { background: rgba(255,165,0,0.15);   color: #ffaa44; }

/* ── Terms checkbox ── */
.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 4px;
}

.checkbox-group input[type="checkbox"] {
    width: 16px; height: 16px;
    margin-top: 2px;
    accent-color: var(--accent-green);
    flex-shrink: 0;
    cursor: pointer;
}

.checkbox-group label {
    font-size: 0.83rem;
    color: var(--text-muted);
    text-transform: none;
    letter-spacing: 0;
    font-weight: 400;
    cursor: pointer;
    margin-bottom: 0;
}

/* ── Role Selector ── */
.hidden-field { display: none !important; }

.role-selector {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 4px;
}

.role-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
    padding: 18px 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s;
    background: var(--bg-input);
}

.role-card:hover {
    border-color: rgba(61,214,140,0.4);
    background: rgba(61,214,140,0.04);
}

.role-card.active {
    border-color: var(--accent-green);
    background: rgba(61,214,140,0.07);
    box-shadow: 0 0 0 3px rgba(61,214,140,0.12);
}

.role-card .role-icon {
    width: 42px; height: 42px;
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.role-card strong {
    display: block;
    font-size: 0.88rem;
    color: var(--text-primary);
    font-weight: 700;
}

.role-card span {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* ── Footer ── */
.auth-footer {
    text-align: center;
    margin-top: 28px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.auth-footer a { color: var(--accent-green); }

/* ── Welcome Banner ── */
.welcome-banner {
    background: linear-gradient(135deg, rgba(61,214,140,0.06) 0%, rgba(13,27,42,0) 100%);
    border: 1px solid rgba(61,214,140,0.2);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 32px;
    flex-wrap: wrap;
}

.welcome-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.welcome-avatar {
    width: 64px; height: 64px;
    background: linear-gradient(135deg, var(--accent-green), var(--accent-blue));
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.4rem;
    font-weight: 800;
    color: #0d1b2a;
    flex-shrink: 0;
}

.access-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: rgba(61,214,140,0.1);
    border: 1px solid rgba(61,214,140,0.2);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent-green);
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.welcome-banner h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
}

.welcome-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    font-size: 0.82rem;
    color: var(--text-muted);
}

.welcome-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.btn-outline-green {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: 1.5px solid rgba(61,214,140,0.4);
    border-radius: var(--radius);
    color: var(--accent-green);
    font-size: 0.88rem;
    font-weight: 600;
    font-family: var(--font);
    cursor: pointer;
    background: transparent;
    text-decoration: none;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-outline-green:hover {
    background: rgba(61,214,140,0.1);
    border-color: var(--accent-green);
    text-decoration: none;
    color: var(--accent-green);
}

/* ── Section Title ── */
.section-title {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.section-line {
    flex: 1;
    height: 1px;
    background: var(--border);
}

/* ── Access Level Grid ── */
.access-level-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-bottom: 40px;
}

.access-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 24px;
    text-align: center;
    transition: border-color 0.2s;
}

.access-card--active {
    border-color: rgba(61,214,140,0.4);
    background: rgba(61,214,140,0.03);
}

.access-card-icon {
    width: 64px; height: 64px;
    border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.6rem;
    margin: 0 auto 16px;
}

.access-card h4 {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.access-card p {
    font-size: 0.84rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.you-badge {
    display: inline-block;
    padding: 2px 9px;
    background: var(--accent-green);
    color: #0d1b2a;
    border-radius: 20px;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    vertical-align: middle;
}

/* ── Profile Page ── */
.profile-header {
    display: flex;
    align-items: flex-end;
    gap: 28px;
    padding: 32px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.profile-photo-wrap {
    position: relative;
    flex-shrink: 0;
}

.profile-photo {
    width: 100px; height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(61,214,140,0.4);
    display: block;
}

.profile-photo-initials {
    width: 100px; height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-green), #1e90ff);
    display: flex; align-items: center; justify-content: center;
    font-size: 2rem; font-weight: 800;
    color: #0d1b2a;
    border: 3px solid rgba(61,214,140,0.4);
}

.photo-upload-btn {
    position: absolute;
    bottom: 2px; right: 2px;
    width: 30px; height: 30px;
    background: var(--accent-green);
    border: 2px solid #080f1d;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    color: #0d1b2a;
    font-size: 0.75rem;
}

.photo-upload-btn:hover { background: var(--accent-green2); }

.profile-info-block { flex: 1; }

.profile-info-block h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
}

.profile-info-block .meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.82rem;
    color: var(--text-muted);
}

.profile-info-block .meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.profile-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 28px;
}

.profile-tab {
    padding: 10px 20px;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    text-decoration: none;
    transition: all 0.15s;
}

.profile-tab:hover { color: var(--text-primary); text-decoration: none; }

.profile-tab.active {
    color: var(--accent-green);
    border-bottom-color: var(--accent-green);
}

.profile-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    margin-bottom: 20px;
}

.profile-section h3 {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

/* ── Directory Page ── */
.search-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.search-bar .input-wrap { flex: 1; min-width: 200px; }

.member-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 18px;
}

.member-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    text-align: center;
    transition: all 0.2s;
}

.member-card:hover {
    border-color: rgba(61,214,140,0.3);
    transform: translateY(-2px);
}

.member-card-avatar {
    width: 64px; height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-green), #1e90ff);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem; font-weight: 800;
    color: #0d1b2a;
    margin: 0 auto 14px;
}

.member-card img {
    width: 64px; height: 64px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 14px;
    display: block;
}

.member-card h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.member-card p {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 2px;
}

/* ── Empty State ── */
.empty-state {
    text-align: center;
    padding: 80px 40px;
    color: var(--text-muted);
}

.empty-state .empty-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
    opacity: 0.35;
}

.empty-state h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 0.88rem;
    max-width: 340px;
    margin: 0 auto 24px;
    line-height: 1.6;
}

/* ── Page Header ── */
.page-top-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.page-top-bar h1 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
}

.page-top-bar p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ── Responsive ── */
@media (max-width: 900px) {
    .auth-wrapper { grid-template-columns: 1fr; }
    .auth-left { display: none; }
    .auth-right { border-left: none; }
    .form-row { grid-template-columns: 1fr; }
    .sidebar { transform: translateX(-100%); transition: transform 0.25s; }
    .sidebar.open { transform: translateX(0); }
    .app-main { margin-left: 0; }
    .main-content { padding: 24px 18px; }
    .access-level-grid { grid-template-columns: 1fr; }
    .welcome-banner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 640px) {
    .role-selector { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .welcome-left { flex-direction: column; align-items: flex-start; }
    .welcome-banner { padding: 20px; }
    .member-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
    .auth-card h2 { font-size: 1.4rem; }
    .member-grid { grid-template-columns: 1fr; }
}
