:root {

    --bg: #05070a;

    --surface: #0c1117;

    --surface-2: #111821;

    --surface-3: #151e28;

    --border: #202b37;

    --text: #edf2f7;

    --muted: #8996a5;

    --gold: #d8ad55;

    --green: #55d695;

    --red: #ef6b73;

    --blue: #65a9ff;

    --radius: 12px;

}


/* ================= RESET ================= */

* {

    box-sizing: border-box;

    margin: 0;

    padding: 0;

}


html {

    min-height: 100%;

    background: #000;

}


body {

    min-height: 100vh;

    background: #000;

    color: var(--text);

    font-family:
        Arial,
        Helvetica,
        sans-serif;

}


button,
input {

    font: inherit;

}


/* ================= MOBILE ================= */

.phone {

    width: 390px;

    max-width: 100%;

    min-height: 100vh;

    margin: 0 auto;

    background: var(--bg);

    position: relative;

    padding-bottom: 78px;

}


/* ================= HEADER ================= */

.topbar {

    height: 70px;

    padding: 13px 15px;

    display: flex;

    align-items: center;

    justify-content: space-between;

    background:
        rgba(5,7,10,.97);

    border-bottom:
        1px solid var(--border);

    position: sticky;

    top: 0;

    z-index: 20;

}


.brand {

    display: flex;

    align-items: center;

    gap: 10px;

}


.brand-logo {

    width: 39px;

    height: 39px;

    display: grid;

    place-items: center;

    border:
        1px solid var(--gold);

    border-radius: 9px;

    color: var(--gold);

    font-size: 11px;

    font-weight: bold;

}


.brand strong {

    display: block;

    font-size: 12px;

}


.brand span {

    display: block;

    color: var(--muted);

    font-size: 8px;

    margin-top: 3px;

}


.icon-button {

    width: 36px;

    height: 36px;

    border:
        1px solid var(--border);

    background: var(--surface);

    color: var(--text);

    border-radius: 8px;

    cursor: pointer;

    font-size: 19px;

}


/* ================= SCREENS ================= */

.screen {

    display: none;

    padding:
        18px 13px 25px;

}


.screen.active {

    display: block;

}


/* ================= HERO ================= */

.hero {

    padding:
        25px 19px;

    background:

        radial-gradient(
            circle at 85% 20%,
            rgba(216,173,85,.09),
            transparent 40%
        ),

        var(--surface);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius);

}


.eyebrow {

    color: var(--gold);

    font-size: 8px;

    font-weight: bold;

    letter-spacing: 1.7px;

}


.hero h1 {

    font-size: 27px;

    line-height: 1.15;

    margin-top: 9px;

}


.hero p {

    color: var(--muted);

    font-size: 10px;

    line-height: 1.7;

    margin-top: 13px;

}


/* ================= PROGRESSION ================= */

.progress-card {

    margin-top: 10px;

    padding: 15px;

    background: var(--surface);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius);

}


.progress-header {

    display: flex;

    justify-content: space-between;

    font-size: 10px;

}


.progress-header strong {

    color: var(--gold);

}


.progress-bar {

    height: 5px;

    margin-top: 11px;

    background: var(--surface-3);

    border-radius: 10px;

    overflow: hidden;

}


#progressBar {

    width: 0%;

    height: 100%;

    background: var(--gold);

    transition:
        width .3s ease;

}


.progress-card small {

    display: block;

    color: var(--muted);

    font-size: 8px;

    margin-top: 8px;

}


/* ================= TITRES ================= */

.section-title {

    margin:
        25px 3px 12px;

}


.section-title h2 {

    font-size: 21px;

    margin-top: 4px;

}


/* ================= CHAPITRES ================= */

.chapter-list {

    display: flex;

    flex-direction: column;

    gap: 8px;

}


.chapter-card {

    width: 100%;

    padding: 15px;

    background: var(--surface);

    border:
        1px solid var(--border);

    border-radius: 10px;

    cursor: pointer;

    transition:
        transform .15s,
        border-color .15s;

}


.chapter-card:active {

    transform: scale(.985);

}


.chapter-card:hover {

    border-color:
        #364452;

}


.chapter-top {

    display: flex;

    align-items: center;

    gap: 12px;

}


.chapter-number {

    width: 34px;

    height: 34px;

    display: grid;

    place-items: center;

    flex-shrink: 0;

    border:
        1px solid var(--border);

    border-radius: 7px;

    color: var(--gold);

    font-size: 9px;

}


.chapter-card h3 {

    font-size: 12px;

}


.chapter-card p {

    color: var(--muted);

    font-size: 9px;

    line-height: 1.5;

    margin-top: 4px;

}


.chapter-count {

    color: var(--muted);

    font-size: 8px;

    margin-top: 11px;

}


/* ================= RETOUR ================= */

.back-button {

    border: 0;

    background: transparent;

    color: var(--gold);

    cursor: pointer;

    font-size: 10px;

    padding: 4px 0;

    margin-bottom: 17px;

}


/* ================= CHAPITRE ================= */

.chapter-header {

    padding-bottom: 18px;

    border-bottom:
        1px solid var(--border);

    margin-bottom: 14px;

}


.chapter-header h1 {

    font-size: 24px;

    margin-top: 7px;

}


.chapter-header p {

    color: var(--muted);

    font-size: 10px;

    line-height: 1.6;

    margin-top: 8px;

}


/* ================= LEÇONS ================= */

.lesson-list {

    display: flex;

    flex-direction: column;

    gap: 7px;

}


.lesson-item {

    display: flex;

    align-items: center;

    gap: 11px;

    padding: 13px;

    background: var(--surface);

    border:
        1px solid var(--border);

    border-radius: 9px;

    cursor: pointer;

}


.lesson-number {

    color: var(--gold);

    font-size: 8px;

    width: 25px;

}


.lesson-info {

    flex: 1;

}


.lesson-info strong {

    display: block;

    font-size: 10px;

}


.lesson-info span {

    display: block;

    color: var(--muted);

    font-size: 8px;

    margin-top: 4px;

}


.lesson-check {

    color: var(--green);

    font-size: 8px;

}


/* ================= LEÇON ================= */

.lesson-content {

    padding-bottom: 18px;

}


.lesson-content .lesson-category {

    color: var(--gold);

    font-size: 8px;

    letter-spacing: 1.5px;

}


.lesson-content h1 {

    font-size: 25px;

    line-height: 1.2;

    margin-top: 8px;

}


.lesson-content h2 {

    font-size: 16px;

    margin:
        24px 0 9px;

}


.lesson-content h3 {

    font-size: 12px;

    margin:
        18px 0 7px;

}


.lesson-content p {

    color: #bac5cf;

    font-size: 10px;

    line-height: 1.75;

    margin-top: 9px;

}


.lesson-content ul {

    padding-left: 17px;

    margin-top: 9px;

}


.lesson-content li {

    color: #bac5cf;

    font-size: 10px;

    line-height: 1.7;

    margin-bottom: 5px;

}


/* ================= BLOCS ================= */

.info-box {

    padding: 13px;

    margin-top: 12px;

    background: var(--surface);

    border:
        1px solid var(--border);

    border-left:
        3px solid var(--gold);

    border-radius: 7px;

}


.info-box.green {

    border-left-color:
        var(--green);

}


.info-box.red {

    border-left-color:
        var(--red);

}


.info-box.blue {

    border-left-color:
        var(--blue);

}


.info-box strong {

    display: block;

    font-size: 9px;

    color: var(--gold);

    margin-bottom: 5px;

}


.info-box.green strong {

    color: var(--green);

}


.info-box.red strong {

    color: var(--red);

}


.info-box.blue strong {

    color: var(--blue);

}


/* ================= CODE ================= */

.code-block {

    margin-top: 11px;

    padding: 13px;

    background: #030507;

    border:
        1px solid var(--border);

    border-radius: 8px;

    overflow-x: auto;

}


.code-block pre {

    color: #c6d1dc;

    font-family:
        Consolas,
        monospace;

    font-size: 8px;

    line-height: 1.7;

    white-space: pre-wrap;

    word-break: break-word;

}


/* ================= EXERCICE ================= */

.exercise {

    margin-top: 18px;

    padding: 15px;

    background:
        rgba(101,169,255,.05);

    border:
        1px solid rgba(101,169,255,.2);

    border-radius: 9px;

}


.exercise strong {

    color: var(--blue);

    font-size: 9px;

}


.exercise p {

    margin-top: 7px;

}


/* ================= À RETENIR ================= */

.takeaway {

    margin-top: 22px;

    padding: 16px;

    background:
        rgba(216,173,85,.06);

    border:
        1px solid rgba(216,173,85,.25);

    border-radius: 9px;

}


.takeaway strong {

    color: var(--gold);

    font-size: 9px;

}


.takeaway p {

    margin-top: 7px;

}


/* ================= TERMINER ================= */

.complete-button {

    width: 100%;

    border:
        1px solid var(--gold);

    background: var(--gold);

    color: #111;

    padding: 13px;

    border-radius: 8px;

    font-size: 10px;

    font-weight: bold;

    cursor: pointer;

}


.complete-button.completed {

    background:
        rgba(85,214,149,.12);

    color: var(--green);

    border-color:
        var(--green);

}


/* ================= RECHERCHE ================= */

.search-header {

    display: flex;

    flex-direction: column;

    gap: 8px;

}


#searchInput {

    width: 100%;

    padding: 13px;

    background: var(--surface);

    border:
        1px solid var(--border);

    border-radius: 8px;

    color: var(--text);

    outline: none;

    font-size: 11px;

}


#searchInput:focus {

    border-color:
        var(--gold);

}


.search-result {

    margin-top: 8px;

    padding: 13px;

    background: var(--surface);

    border:
        1px solid var(--border);

    border-radius: 8px;

    cursor: pointer;

}


.search-result strong {

    display: block;

    font-size: 10px;

}


.search-result span {

    display: block;

    color: var(--muted);

    font-size: 8px;

    margin-top: 4px;

}


/* ================= NAVIGATION ================= */

.bottom-nav {

    position: fixed;

    width: 390px;

    max-width: 100%;

    height: 70px;

    left: 50%;

    transform:
        translateX(-50%);

    bottom: 0;

    z-index: 50;

    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 4px;

    padding: 5px;

    background:
        rgba(9,13,18,.98);

    border-top:
        1px solid var(--border);

}


.bottom-button {

    border:
        1px solid transparent;

    background:
        transparent;

    color: var(--muted);

    border-radius: 8px;

    font-size: 8px;

    cursor: pointer;

}


.bottom-button span {

    display: block;

    color: #53606d;

    font-size: 7px;

    margin-bottom: 4px;

}


.bottom-button.active {

    color: var(--gold);

    background:
        var(--surface-2);

    border-color:
        var(--border);

}


/* ================= MOBILE STRICT ================= */

@media (max-width: 390px) {

    .phone {

        width: 100%;

    }

    .bottom-nav {

        width: 100%;

    }

}


@media (min-width: 391px) {

    body {

        display: flex;

        justify-content: center;

        align-items: flex-start;

        background:
            radial-gradient(
                circle at center,
                #11161d,
                #000 70%
            );

    }

}