:root {
    /* Sciences Po Bordeaux — charte graphique (Septembre 2024) */
    --spb-red: #dd1019;
    --spb-red-dark: #b40d16;
    --spb-navy: #0f315e;
    --spb-navy-deep: #0a2444;
    --spb-anthracite: #2f3235;
    --spb-turquoise: #00999a;
    --spb-turquoise-dark: #00787a;
    --spb-orange: #f7941e;
    --spb-orange-dark: #d97c0c;
    --spb-green: #00854a;

    --color-bg: #f2f3f5;
    --color-surface: #ffffff;
    --color-text: var(--spb-anthracite);
    --color-text-muted: #6b7076;
    --color-border: #e2e4e8;
    --color-accent: var(--spb-red);
    --color-accent-hover: var(--spb-red-dark);

    --font-display: "Rokkitt", Georgia, "Times New Roman", serif;
    --font-body: "Open Sans", "Segoe UI", system-ui, -apple-system, sans-serif;

    --radius: 14px;
    --radius-sm: 8px;
    --shadow: 0 1px 2px rgba(15, 30, 55, 0.04), 0 20px 40px -16px rgba(10, 30, 60, 0.18);
    color-scheme: light;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-body);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

h1, h2 {
    font-family: var(--font-display);
    font-weight: 600;
}

/* ---------- Page shell ---------- */

.page {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 0 20px 64px;
    background: linear-gradient(160deg, var(--spb-navy-deep) 0%, var(--spb-navy) 65%, #1a4886 100%);
    background-repeat: no-repeat;
    background-size: 100% 264px;
}

.page__inner {
    width: 100%;
    max-width: 680px;
}

/* ---------- Hero / brand band ---------- */

.hero {
    position: relative;
    padding: 40px 4px 0;
    display: flex;
    justify-content: center;
    overflow: hidden;
}

.hero__rings {
    position: absolute;
    top: -40px;
    right: -40px;
    width: 220px;
    height: 220px;
    opacity: 0.16;
    pointer-events: none;
}

.hero__badge {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--color-surface);
    border-radius: var(--radius-sm);
    padding: 14px 22px;
    box-shadow: 0 18px 32px -14px rgba(5, 15, 35, 0.55);
}

.hero__logo {
    height: 42px;
    width: auto;
    display: block;
}

/* ---------- Panel ---------- */

.panel {
    position: relative;
    background: var(--color-surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 40px 40px 36px;
    margin-top: 28px;
}

.panel__intro {
    text-align: center;
    margin-bottom: 28px;
}

.panel__intro h1 {
    position: relative;
    margin: 0 0 18px;
    padding-bottom: 14px;
    font-size: 1.6rem;
    letter-spacing: -0.01em;
    color: var(--spb-navy);
}

.panel__intro h1::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    background: var(--spb-red);
    border-radius: 2px;
}

.panel__intro p {
    margin: 0;
    color: var(--color-text-muted);
    font-size: 0.98rem;
}

/* ---------- Method choice cards ---------- */

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

.method {
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 26px 22px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.method:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 28px -18px rgba(15, 30, 55, 0.35);
}

.method__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    margin-bottom: 14px;
}

.method__icon svg {
    width: 20px;
    height: 20px;
}

.method--know .method__icon {
    background: color-mix(in srgb, var(--spb-turquoise) 14%, white);
    color: var(--spb-turquoise-dark);
}

.method--know:hover {
    border-color: color-mix(in srgb, var(--spb-turquoise) 45%, white);
}

.method--forgot .method__icon {
    background: color-mix(in srgb, var(--spb-orange) 16%, white);
    color: var(--spb-orange-dark);
}

.method--forgot:hover {
    border-color: color-mix(in srgb, var(--spb-orange) 45%, white);
}

.method h2 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--spb-navy);
}

.method p {
    margin: 4px 0 18px;
    color: var(--color-text-muted);
    font-size: 0.875rem;
    flex-grow: 1;
}

.method--know .btn {
    background: var(--spb-turquoise);
    border-color: var(--spb-turquoise);
    color: #fff;
}

.method--know .btn:hover {
    background: var(--spb-turquoise-dark);
    border-color: var(--spb-turquoise-dark);
}

.method--forgot .btn {
    background: var(--spb-orange);
    border-color: var(--spb-orange);
    color: #fff;
}

.method--forgot .btn:hover {
    background: var(--spb-orange-dark);
    border-color: var(--spb-orange-dark);
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-block;
    width: 100%;
    text-align: center;
    padding: 11px 16px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--spb-navy);
    text-decoration: none;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
    background: color-mix(in srgb, var(--spb-navy) 8%, white);
    border-color: var(--spb-navy);
}

.btn--primary {
    background: var(--spb-red);
    border-color: var(--spb-red);
    color: #fff;
}

.btn--primary:hover {
    background: var(--color-accent-hover);
    border-color: var(--color-accent-hover);
    color: #fff;
}

.btn--ghost {
    margin-top: 1rem;
    background: transparent;
    border-color: var(--color-border);
    color: var(--color-text-muted);
    width: auto;
    padding: 9px 16px;
    font-size: 0.85rem;
}

.btn--ghost:hover {
    background: var(--color-bg);
    border-color: var(--color-text-muted);
    color: var(--color-text);
}

button.btn {
    cursor: pointer;
    font: inherit;
}

/* ---------- Notices ---------- */

.notices {
    margin-top: 22px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.notice {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: 18px 20px;
    color: var(--color-text-muted);
    font-size: 0.85rem;
}

.notice p {
    margin: 0 0 8px;
}

.notice ol {
    margin: 0 0 12px;
    padding-left: 20px;
}

.notice ol li {
    margin-bottom: 6px;
}

.notice a {
    color: var(--color-accent);
    font-weight: 600;
    text-decoration: none;
}

.notice a:hover {
    text-decoration: underline;
}

/* ---------- Documents ---------- */

.document {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--color-text);
    text-decoration: none;
    font-size: 0.85rem;
}

.document svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: var(--color-text-muted);
}

.document__name {
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--color-border);
    text-underline-offset: 2px;
}

.document:hover .document__name {
    text-decoration-color: currentColor;
}

.document__date {
    color: var(--color-text-muted);
}

.document__date::before {
    content: "\00b7";
    margin-right: 8px;
}

.document--unavailable {
    font-style: italic;
    margin: 0;
}

/* ---------- Forms ---------- */

.field {
    margin-bottom: 18px;
}

.field label {
    display: block;
    margin-bottom: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--spb-navy);
}

.field input[type="password"],
.field input[type="text"],
.field input[type="date"] {
    width: 100%;
    padding: 11px 13px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--color-text);
    background: #fbfbfc;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.field input:focus {
    outline: none;
    border-color: var(--spb-red);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(221, 16, 25, 0.14);
}

.field__hint {
    margin: 6px 0 20px;
    color: var(--color-text-muted);
    font-size: 0.8rem;
}

.criteria-list {
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 0.8rem;
}

.criteria {
    color: var(--color-text-muted);
}

.criteria::before {
    content: "○ ";
}

.criteria--met {
    color: var(--spb-green);
}

.criteria--met::before {
    content: "✓ ";
}

.field ul {
    margin: 6px 0 0;
    padding: 0 0 0 18px;
    color: var(--color-accent);
    font-size: 0.8rem;
}

.field--checkbox {
    margin-top: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.field--checkbox label {
    margin: 0;
    font-weight: 400;
    color: var(--color-text);
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-top: 14px;
}

/* ---------- Flash messages ---------- */

.flash {
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    margin-bottom: 20px;
}

.flash--success {
    background: #e6f4ea;
    color: #1e7b34;
    border: 1px solid #b7e1c1;
}

.flash--danger {
    background: #fbe9eb;
    color: var(--color-accent-hover);
    border: 1px solid #f3c1c8;
}

@media (max-width: 480px) {
    .panel {
        padding: 28px 22px;
    }

    .page {
        background-size: 100% 210px;
    }
}
