/* Charte campus : papier clair, vert profond et accent abricot. */
:root {
    --bg-page: #f5f4ef;
    --bg-surface: #fff;
    --bg-surface-alt: #f0f3ef;
    --text-primary: #183c38;
    --text-secondary: #425954;
    --text-muted: #526760;
    --text-light: #526760;
    --primary: #17594d;
    --primary-hover: #103f37;
    --primary-light: #e5f1e9;
    --primary-gradient: linear-gradient(120deg, #17594d, #226759);
    --indigo-50: #e9f2ec;
    --indigo-100: #d4e7d9;
    --indigo-200: #c7ded0;
    --indigo-300: #6e9d8c;
    --indigo-400: #40836c;
    --border-subtle: #d7dfd7;
    --border-strong: #b2c4b8;
    --border-focus: #17594d;
    --radius-md: 18px;
    --shadow-md: 0 6px 24px rgba(33, 64, 52, .06);
    --shadow-lg: 0 12px 28px rgba(33, 64, 52, .1);
}
body { background: var(--bg-page); background-image: none; font-family: 'Instrument Sans', 'Segoe UI', Arial, sans-serif; }
.container { max-width: 1360px; }
main.main-content { padding-top: 28px; }
.navbar { background: #143f36; border: 0; }
.navbar-brand .logo-icon { background: #f6ce9e; color: #143f36; border: 0; border-radius: 12px; }
.nav-link { color: #edf4ee; }
.nav-link.active { background: #2a5a4e; box-shadow: inset 3px 0 #f6ce9e; }
.page-header { background: #e8eee6; border: 0; padding: 24px 28px; margin-bottom: 24px; }
.page-title { letter-spacing: -.035em; }
.page-header .badge { box-shadow: none; }
.card { border: 1px solid var(--border-subtle); box-shadow: var(--shadow-xs); }
.card-title { font-size: 1.15rem; }
.btn { border-radius: 10px; min-height: 42px; }
.btn-primary { background: var(--primary); border-color: var(--primary); box-shadow: none; }
.btn-primary:hover { background: var(--primary-hover); }
.btn-outline-primary { background: #fff; border-color: var(--primary); color: var(--primary); }
.tabs-header { background: #e9ece5; border: 0; border-radius: 12px; padding: 6px; }
.tab-btn.active { background: #fff; color: var(--primary); box-shadow: 0 2px 5px #183c3812; }
.form-control, .form-select { border-radius: 9px; background: #fff; }
.live-search-input { width: 100%; padding: 12px 18px; border: 1px solid #8aa394; border-radius: 10px; font: inherit; color: var(--text-primary); background: #fff; }
.live-filter-wrapper .live-search-input { padding-left: 42px; }
.form-control:focus, .form-select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px #17594d1a; }
.badge-primary { background: #e2f0e5; color: #154b3f; border-color: #bdd7c5; }
.auth-wrapper { max-width: 540px; padding-block: 30px; }
.auth-card { border-radius: 22px; box-shadow: var(--shadow-md); border: 1px solid var(--border-subtle); }
.auth-card::before { background: #e3b181; }
.auth-logo { background: #e9f2ec; color: var(--primary); box-shadow: none; }
.auth-header h1 { color: var(--text-primary); }
.password-request-link { display: block; padding: 14px 16px; margin-top: 20px; background: #fff3e4; border: 1px solid #c39665; border-radius: 10px; color: #613c18; font-weight: 650; text-align: center; text-decoration: underline; text-underline-offset: 3px; }
.password-request-link:hover { background: #ffe8cc; color: #4d2e11; }
.recovery-card { max-width: 680px; margin: 20px auto; }
.recovery-card h1 { font-size: clamp(1.5rem, 3vw, 2rem); }
.feature-symbol { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 13px; background: #e5efe6; color: #17594d; font: 700 1.6rem system-ui; flex-shrink: 0; }
.teacher-alerts, .student-overview { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-bottom: 24px; }
.student-overview { grid-template-columns: 1.25fr 1fr 1fr; }
.teacher-alerts .card, .student-overview .card { margin-bottom: 0; }
.action-tile { display: flex; gap: 16px; align-items: center; padding: 22px; color: var(--text-primary); }
.action-tile:hover { border-color: var(--primary); background: #fbfdf9; }
.action-tile strong, .action-tile small { display: block; }
.action-tile small { color: var(--text-muted); margin-top: 6px; line-height: 1.4; }
.progress-overview { display: flex; align-items: center; gap: 20px; padding: 22px; }
.progress-overview h2 { font-size: 1.2rem; }
.progress-overview p { font-size: .9rem; margin-block: 5px; }
.progress-ring { --completion: 0%; border-radius: 50%; width: 92px; height: 92px; flex-shrink: 0; display: grid; place-items: center; background: conic-gradient(#2b7861 var(--completion), #e3e9dd 0); }
.progress-ring > strong { width: 72px; height: 72px; border-radius: 50%; display: grid; align-content: center; justify-items: center; background: #fff; font-size: 1.3rem; }
.progress-ring small { font-size: .8rem; font-weight: 500; }

.campus-hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 7%; align-items: center; padding: 42px 0 52px; }
.eyebrow { color: #496358; text-transform: uppercase; letter-spacing: .12em; font-weight: 650; font-size: .8rem; margin-bottom: 20px; }
.campus-intro h1 { font-size: clamp(2.4rem, 4.3vw, 4.3rem); letter-spacing: -.055em; line-height: 1.08; margin-bottom: 24px; }
.campus-intro h1 span { color: #527b5b; }
.campus-intro > p:not(.eyebrow) { font-size: 1.08rem; line-height: 1.7; max-width: 490px; margin-bottom: 24px; }
.campus-intro .password-request-link { max-width: 430px; font-size: .9rem; }
.learning-map { background: #e6ece0; border: 1px solid #cedbc9; border-radius: 28px; padding: 28px; transform: rotate(-1deg); }
.learning-map-heading { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.learning-map-heading strong { font-size: 1.25rem; }
.learning-map-heading .feature-symbol { background: #143f36; color: #fff; }
.map-stage { display: flex; gap: 14px; align-items: center; background: #fff; padding: 16px; border-radius: 13px; border: 1px solid #cbdac8; }
.map-stage > div { flex: 1; }
.map-stage strong, .map-stage small { display: block; }
.map-stage small { color: var(--text-muted); margin-top: 4px; }
.map-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 9px; background: #eef3e9; color: #17594d; font: 700 1.3rem system-ui; }
.map-connector { margin-left: 34px; height: 17px; width: 2px; background: #95b19b; }
.map-exam { background: #fff3e5; border-color: #d9b78e; }
.map-duration { color: #624318; font-weight: 700; white-space: nowrap; }
.campus-features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.campus-features h2 { font-size: 1.15rem; margin-block: 18px 10px; }
.campus-features p { line-height: 1.6; font-size: .95rem; }
.exam-home-panel { display: flex; align-items: center; flex-wrap: wrap; gap: 22px; background: #e4eade; border-radius: 18px; padding: 28px; margin-top: 12px; }
.exam-home-panel > div { flex: 1; min-width: min(280px, 100%); }
.exam-home-panel h2 { font-size: 1.2rem; margin-bottom: 6px; }
.notice-fallback { max-width: 650px; margin-inline: auto; }
.notice-fallback > .feature-symbol { margin-bottom: 16px; }
.notice-fallback h1 { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 18px; }
.notice-fallback p { line-height: 1.7; margin-bottom: 14px; }
.notice-fallback .exam-option { margin-block: 22px; }
#exam-notice { padding: 0; width: min(680px, calc(100% - 32px)); max-height: calc(100dvh - 40px); border: 0; border-radius: 20px; margin: auto; box-shadow: 0 25px 100px #052c3655; }
#exam-notice::backdrop { background: #122c2ad9; backdrop-filter: blur(4px); }
#exam-notice .card { margin: 0; max-width: none; border: 0; padding: 32px; }
footer { background: #e9ece4; color: var(--text-secondary); border-top: 1px solid var(--border-subtle); }
footer strong { color: var(--text-primary); }

@media (min-width: 1200px) {
    .workspace-layout:not(.exam-layout) { padding-left: 228px; }
    .workspace-layout:not(.exam-layout) > .navbar { position: fixed; inset: 0 auto 0 0; width: 228px; overflow-y: auto; }
    .workspace-layout:not(.exam-layout) > .navbar .container { display: flex; flex-direction: column; align-items: stretch; padding: 25px 14px; }
    .workspace-layout:not(.exam-layout) .navbar-brand { margin: 0 4px 26px; font-size: 1.05rem; }
    .workspace-layout:not(.exam-layout) .navbar-nav { display: grid; justify-content: stretch; gap: 6px; }
    .workspace-layout:not(.exam-layout) .nav-link { width: 100%; justify-content: flex-start; border-radius: 9px; padding: 12px; font-size: .9rem; }
    .workspace-layout:not(.exam-layout) .navbar-nav li:last-child { margin-top: 20px; border-top: 1px solid #53766b; padding-top: 16px; }
}
@media (max-width: 1100px) {
    .student-overview { grid-template-columns: repeat(2, 1fr); }
    .progress-overview { grid-column: 1 / -1; }
}
@media (max-width: 768px) {
    .campus-hero { grid-template-columns: 1fr; gap: 32px; padding-block: 20px 32px; }
    .learning-map { transform: none; padding: 18px; }
    .campus-features, .teacher-alerts, .student-overview { grid-template-columns: 1fr; gap: 12px; }
    .campus-features .card { margin-bottom: 0; }
    .exam-home-panel { margin-top: 20px; padding: 20px; }
    .page-header { padding: 20px; }
    .progress-overview { grid-column: auto; }
    #exam-notice .card { padding: 24px; }
    .notice-fallback .btn { width: 100%; }
    .recovery-card { margin-block: 0; }
}
