:root {
    --ink: #173c36;
    --green: #276f5e;
    --mint: #dcebe4;
    --cream: #f7f4ec;
    --paper: #fffefa;
    --orange: #e47b4b;
    --line: #d9e0d9;
    --muted: #687772;
}
* {
    box-sizing: border-box;
}
body {
    margin: 0;
    background: var(--cream);
    color: var(--ink);
    font-family: "DM Sans", sans-serif;
    overflow-x: hidden;
}
a {
    color: inherit;
    text-decoration: none;
}
button,
input,
select {
    font: inherit;
}
button,
input,
select,
summary,
a {
    -webkit-tap-highlight-color: transparent;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible {
    outline: 3px solid #e47b4b;
    outline-offset: 3px;
}
.topbar {
    height: 78px;
    padding: 0 max(5vw, 24px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(247, 244, 236, 0.95);
    border-bottom: 1px solid #e5e2d9;
    position: sticky;
    top: 0;
    z-index: 10;
}
.brand {
    font: 600 26px "Newsreader";
    display: flex;
    gap: 10px;
    align-items: center;
}
.brand span {
    display: grid;
    place-items: center;
    background: var(--ink);
    color: white;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    font: 600 22px "Newsreader";
}
.topbar nav {
    display: flex;
    align-items: center;
    gap: 26px;
    font-size: 14px;
}
.topbar .desktop-nav > a {
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    line-height: 1.2;
}
.topbar > .mobile-nav {
    display: none !important;
}
@media (min-width: 801px) {
    .topbar > .desktop-nav {
        display: flex !important;
    }
    .topbar > .mobile-nav {
        display: none !important;
    }
}
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 8px;
    background: var(--ink);
    color: white;
    padding: 15px 22px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 0 #0d2723;
    min-height: 46px;
    line-height: 1.2;
    text-align: center;
    transition: background-color .2s ease, color .2s ease, transform .2s ease;
}
.button:hover {
    transform: translateY(-1px);
}
.button.small {
    min-height: 42px;
    padding: 0 16px;
    box-shadow: none;
}
.button.full {
    width: 100%;
}
.hello {
    color: var(--muted);
}
main {
    min-height: 75vh;
}
.flash {
    max-width: 1100px;
    margin: 16px auto;
    padding: 13px 18px;
    border-radius: 8px;
    background: #dcebe4;
}
.flash.error {
    background: #f9ddd4;
    color: #8a311c;
}
.hero {
    padding: 72px max(6vw, 30px) 96px;
    max-width: 1400px;
    margin: auto;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 8vw;
    align-items: center;
}
.eyebrow {
    color: var(--green);
    font-size: 12px;
    letter-spacing: 2px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 18px;
}
.hero h1,
.page-head h1,
.detail h1,
.import-page h1,
.auth h1 {
    font: 600 clamp(44px, 5.5vw, 78px) / 0.98 "Newsreader";
    margin: 0 0 25px;
}
.hero h1 em,
.page-head h1 em {
    color: var(--green);
    font-style: italic;
}
.lead {
    font-size: 19px;
    line-height: 1.65;
    color: #536761;
    max-width: 600px;
}
.actions {
    display: flex;
    gap: 22px;
    align-items: center;
    margin-top: 32px;
}
.trust {
    font-size: 13px;
    font-weight: 700;
}
.trust small {
    font-weight: 400;
    color: var(--muted);
}
.hero-card {
    background: var(--mint);
    padding: 38px;
    border-radius: 50% 50% 45% 55%/40% 45% 55% 60%;
    position: relative;
}
.paper {
    background: var(--paper);
    padding: 26px;
    border-radius: 10px;
    box-shadow: 0 20px 60px #173c3630;
    transform: rotate(1.5deg);
}
.paper-head {
    display: flex;
    gap: 12px;
    align-items: center;
    border-bottom: 1px solid var(--line);
    padding-bottom: 18px;
}
.paper-head div {
    display: flex;
    flex-direction: column;
    flex: 1;
}
.paper-head small {
    color: var(--muted);
}
.paper-head i {
    color: var(--green);
}
.doc-icon,
.case-icon {
    display: grid;
    place-items: center;
    background: var(--mint);
    width: 42px;
    height: 42px;
    border-radius: 8px;
}
.result {
    padding: 22px 0;
}
.result small,
.deadline small,
.card-title small {
    display: block;
    color: var(--green);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
}
.result strong {
    font: 600 21px/1.4 "Newsreader";
    display: block;
    margin-top: 6px;
}
.result mark {
    background: #f6dfb5;
    color: inherit;
    padding: 2px;
}
.deadline {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    background: #f7eee1;
    border-radius: 8px;
}
.deadline div {
    display: flex;
    flex-direction: column;
    flex: 1;
}
.deadline label {
    font-size: 10px;
    background: #f4d2bd;
    color: #983e20;
    padding: 5px;
    border-radius: 4px;
}
.choices {
    display: flex;
    flex-direction: column;
    gap: 9px;
    margin-top: 20px;
}
.choices span {
    border: 1px solid var(--line);
    padding: 12px;
    border-radius: 6px;
}
.choices i {
    float: right;
}
.secure {
    text-align: center;
    font-size: 11px;
    margin-top: 30px;
}
.how {
    background: var(--ink);
    color: white;
    padding: 85px max(6vw, 30px);
}
.how > h2 {
    font: 600 46px/1.1 "Newsreader";
    margin: 0;
}
.how .eyebrow {
    color: #9fd3c2;
}
.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 55px;
}
.steps article {
    border-top: 1px solid #ffffff30;
    padding-top: 20px;
    position: relative;
}
.steps article > b {
    color: #82ad9f;
}
.step-icon {
    display: grid;
    place-items: center;
    background: #ffffff12;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    font-size: 22px;
    margin: 30px 0;
}
.steps h3 {
    font: 600 27px "Newsreader";
    margin: 0 0 10px;
}
.steps p {
    color: #b9cbc5;
    line-height: 1.6;
}
footer {
    padding: 45px max(5vw, 24px);
    display: flex;
    align-items: center;
    gap: 30px;
    border-top: 1px solid #dedbd2;
}
footer p {
    flex: 1;
    color: var(--muted);
}
footer small {
    color: var(--muted);
}
.auth {
    min-height: 700px;
    display: grid;
    place-items: center;
    padding: 50px;
}
.form-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 42px;
    width: min(460px, 100%);
    box-shadow: 0 16px 50px #173c3610;
}
.form-card h1 {
    font-size: 46px;
}
.form-card > p,
.form-card > small {
    color: var(--muted);
}
.auth-switch {
    margin: 28px 0 0;
    padding-top: 22px;
    border-top: 1px solid var(--line);
    text-align: center;
    line-height: 1.6;
}
.auth-switch a {
    color: var(--green);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}
form label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    margin: 18px 0 7px;
}
input,
select {
    width: 100%;
    border: 1px solid #cbd5ce;
    border-radius: 7px;
    padding: 13px;
    background: white;
    color: var(--ink);
    min-height: 48px;
}
form .button {
    margin-top: 20px;
}
.check {
    display: flex !important;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.4;
}
.check input {
    width: auto;
    margin-top: 3px;
}
.dashboard,
.detail {
    max-width: 1180px;
    margin: auto;
    padding: 60px 25px 90px;
}
.page-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
}
.page-head h1 {
    font-size: 55px;
}
.metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin: 25px 0 55px;
}
.metric-card {
    display: block;
    position: relative;
    background: var(--paper);
    padding: 22px;
    border: 1px solid var(--line);
    border-radius: 9px;
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.metric-card:hover {
    border-color: #89aa9c;
    transform: translateY(-2px);
}
.metric-card.active {
    border-color: var(--green);
    box-shadow: 0 0 0 2px #276f5e18;
}
.metric-card.active::after {
    content: "Filtre actif";
    position: absolute;
    top: 12px;
    right: 12px;
    color: var(--green);
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
}
.metrics small {
    font-size: 10px;
    letter-spacing: 1px;
    color: var(--green);
    font-weight: 700;
}
.metrics strong {
    display: block;
    font: 600 42px "Newsreader";
    margin: 8px 0;
}
.metrics span {
    font-size: 12px;
    color: var(--muted);
}
.metrics .warm {
    background: #f7eee1;
}
.section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.section-head h2 {
    font: 600 32px "Newsreader";
}
.section-head span {
    color: var(--muted);
    font-size: 13px;
}
.dashboard-breadcrumbs {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 38px;
    color: var(--muted);
    font-size: 12px;
}
.dashboard-breadcrumbs a {
    color: var(--green);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.dashboard-breadcrumbs strong {
    color: var(--ink);
}
.breadcrumb-count {
    margin-left: auto;
}
.reset-all-filters {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 12px;
    border: 1px solid #c6d5ce;
    border-radius: 7px;
    background: var(--paper);
    color: var(--green) !important;
    font-weight: 700;
    text-decoration: none !important;
}
.folder-section {
    margin: 0 0 45px;
}
.folder-section .section-head {
    margin-bottom: 18px;
}
.section-head > div h2 {
    margin: 5px 0 0;
}
.section-kicker {
    color: var(--green) !important;
    font-size: 9px !important;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.reset-filter {
    color: var(--green);
    font-size: 12px;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.folder-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 12px;
}
.folder-card {
    display: grid;
    grid-template-columns: 46px 1fr auto;
    gap: 14px;
    align-items: center;
    min-width: 0;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--paper);
    transition: border-color .2s ease, transform .2s ease;
}
.folder-card:hover,
.folder-card.active {
    border-color: var(--green);
    transform: translateY(-2px);
}
.folder-card.active {
    background: #edf3ed;
}
.folder-icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 9px;
    background: var(--mint);
    color: var(--green);
    font: 600 23px "Newsreader";
}
.folder-card small {
    color: var(--green);
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.folder-card h3 {
    margin: 3px 0;
    overflow-wrap: anywhere;
    font: 600 20px/1.2 "Newsreader";
}
.folder-card p {
    margin: 0;
    color: var(--muted);
    font-size: 10px;
}
.folder-arrow {
    font-size: 18px;
}
.analysis-heading {
    margin-bottom: 18px;
}
.active-filter {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin: 0 0 14px;
    padding: 11px 14px;
    border-radius: 7px;
    background: #edf3ed;
    color: #536761;
    font-size: 11px;
}
.active-filter a {
    color: var(--green);
    font-weight: 700;
    text-decoration: underline;
}
.active-filter > div {
    display: flex;
    gap: 16px;
}
.case-list {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 10px;
}
.case {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 21px;
    border-bottom: 1px solid var(--line);
}
.case:last-child {
    border: 0;
}
.case:hover {
    background: #f9fbf8;
}
.case-main {
    flex: 1;
}
.case-main h3 {
    margin: 7px 0 3px;
}
.case-main p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
}
.analysis-state {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 20px;
    background: var(--mint);
    color: var(--green);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .3px;
}
.analysis-state.needs-review {
    background: #f5dfcf;
    color: #8f351e;
}
.case-arrow {
    flex: 0 0 auto;
    font-size: 20px;
}
.dashboard-trust {
    display: flex;
    gap: 15px;
    align-items: flex-start;
    background: #edf3ed;
    border: 1px solid #cddcd3;
    border-radius: 9px;
    padding: 17px 20px;
    margin: 0 0 45px;
}
.dashboard-trust > span {
    font-size: 24px;
}
.dashboard-trust p {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.6;
}
.pill,
.attention {
    display: inline-block;
    border-radius: 15px;
    padding: 5px 9px;
    background: var(--mint);
    font-size: 10px;
    font-weight: 700;
    margin-right: 6px;
}
.case-date {
    border-left: 1px solid var(--line);
    padding: 0 25px;
}
.case-date small {
    display: block;
    color: var(--muted);
    font-size: 9px;
}
.empty {
    text-align: center;
    background: var(--paper);
    border: 1px dashed #b9c7bf;
    padding: 70px 20px;
    border-radius: 10px;
}
.compact-empty {
    padding-block: 48px;
}
.empty > span {
    font-size: 35px;
}
.import-page {
    max-width: 700px;
    margin: auto;
    padding: 50px 25px 90px;
}
.back {
    display: inline-block;
    margin-bottom: 45px;
    color: var(--muted);
    font-size: 13px;
}
.import-page h1 {
    font-size: 58px;
}
.upload-form {
    margin-top: 30px;
}
.drop {
    height: 280px;
    border: 2px dashed #9cb7ab;
    border-radius: 10px;
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #edf3ed;
    cursor: pointer;
}
.drop input {
    position: absolute;
    opacity: 0;
    width: 1px;
}
.drop span {
    font-size: 30px;
}
.drop p {
    font-weight: 400;
    margin: 7px;
}
.drop small {
    color: var(--muted);
}
.privacy {
    display: flex;
    gap: 12px;
    background: #f7eee1;
    padding: 14px;
    border-radius: 8px;
    margin-top: 16px;
}
.privacy div {
    display: flex;
    flex-direction: column;
    font-size: 12px;
}
.privacy small {
    color: var(--muted);
}
.detail-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    border-bottom: 1px solid var(--line);
    padding-bottom: 25px;
}
.detail-head h1 {
    font-size: 48px;
    margin: 12px 0;
}
.detail-head p {
    color: var(--muted);
    margin: 0;
}
.detail-head select {
    min-width: 130px;
}
.attention {
    background: #f4d2bd;
    color: #8b351d;
}
.detail-grid {
    display: grid;
    grid-template-columns: 1.35fr 0.85fr;
    gap: 20px;
    margin-top: 25px;
}
.detail article {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 9px;
    padding: 25px;
    margin-bottom: 20px;
}
.card-title {
    display: flex;
    gap: 12px;
    align-items: center;
}
.card-title > span {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--mint);
}
.card-title h2 {
    font: 600 24px "Newsreader";
    margin: 3px 0;
}
.summary-card > p {
    font-size: 17px;
    line-height: 1.65;
}
.big-deadline {
    display: flex;
    gap: 13px;
    align-items: center;
    background: #f7eee1;
    padding: 16px;
    border-radius: 8px;
}
.big-deadline div {
    flex: 1;
}
.big-deadline small {
    display: block;
    color: #9b593c;
    font-size: 9px;
    font-weight: 700;
}
.big-deadline label {
    font-size: 10px;
}
.fact {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--line);
    padding: 15px 0;
}
.fact:first-of-type {
    margin-top: 18px;
}
.fact div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.fact small {
    color: var(--muted);
}
.confidence {
    font-size: 10px;
    color: var(--green);
    background: var(--mint);
    border-radius: 12px;
    padding: 4px 8px;
}
.confidence.low {
    background: #f7eee1;
    color: #9b593c;
}
.notice {
    font-size: 11px !important;
    color: var(--muted);
    background: #f3f2ed;
    padding: 10px;
}
.options button {
    width: 100%;
    border: 1px solid var(--line);
    background: white;
    text-align: left;
    padding: 13px;
    margin-top: 9px;
    border-radius: 6px;
    color: var(--ink);
    cursor: pointer;
}
.options button i {
    float: right;
}
.tasks > p {
    font-size: 12px;
    color: var(--muted);
}
.task {
    display: flex;
    align-items: center;
    gap: 10px;
}
.task button {
    width: 22px;
    height: 22px;
    border: 1px solid #9cb7ab;
    border-radius: 50%;
    background: white;
    color: white;
    padding: 0;
}
.task span {
    font-size: 13px;
}
.task small {
    display: block;
    color: var(--muted);
}
.task.done span {
    text-decoration: line-through;
    color: var(--muted);
}
.task.done button {
    background: var(--green);
}
.new-task {
    display: grid;
    grid-template-columns: 1fr 125px 34px;
    gap: 6px;
    margin-top: 15px;
}
.new-task input {
    padding: 9px;
    font-size: 12px;
}
.new-task button {
    border: 0;
    border-radius: 6px;
    background: var(--ink);
    color: white;
}
.document-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--paper);
    border: 1px solid var(--line);
    padding: 18px;
    border-radius: 9px;
}
.document-bar > div {
    display: flex;
    align-items: center;
    gap: 12px;
}
.document-bar > div > div {
    display: flex;
    flex-direction: column;
}
.document-bar small {
    color: var(--muted);
}
.document-bar form {
    display: inline;
}
.link {
    border: 0;
    background: none;
    text-decoration: underline;
    cursor: pointer;
    color: var(--muted);
}
.link.danger {
    color: #a64128;
}
.link:disabled {
    text-decoration: none;
}
.document-bar .link {
    margin: 0;
}
.detail form {
    margin: 0;
}
@media (max-width: 800px) {
    .topbar {
        height: 66px;
        padding-inline: 18px;
    }
    .topbar > .desktop-nav {
        display: none !important;
    }
    .topbar > .mobile-nav {
        display: block !important;
        position: relative;
    }
    .mobile-nav summary {
        display: grid;
        align-content: center;
        gap: 5px;
        width: 46px;
        height: 46px;
        padding: 11px;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: var(--paper);
        cursor: pointer;
        list-style: none;
    }
    .mobile-nav summary::-webkit-details-marker {
        display: none;
    }
    .mobile-nav summary span {
        display: block;
        height: 2px;
        border-radius: 2px;
        background: var(--ink);
    }
    .mobile-nav nav {
        position: absolute;
        top: 54px;
        right: 0;
        display: flex;
        align-items: stretch;
        flex-direction: column;
        gap: 4px;
        width: min(310px, calc(100vw - 36px));
        padding: 12px;
        border: 1px solid var(--line);
        border-radius: 10px;
        background: var(--paper);
        box-shadow: 0 18px 45px #173c3630;
    }
    .mobile-nav nav a,
    .mobile-hello {
        display: block;
        padding: 12px 14px;
        border-radius: 7px;
        line-height: 1.35;
    }
    .mobile-nav nav a:not(.button):hover {
        background: var(--mint);
    }
    .mobile-hello {
        color: var(--muted);
        font-size: 12px;
        border-bottom: 1px solid var(--line);
        border-radius: 0;
    }
    .hero {
        grid-template-columns: 1fr;
        padding-top: 45px;
    }
    .hero-card {
        margin-top: 20px;
        padding: 20px;
    }
    .steps,
    .metrics,
    .detail-grid {
        grid-template-columns: 1fr;
    }
    .how > h2 {
        font-size: 36px;
    }
    .page-head {
        align-items: stretch;
        flex-direction: column;
        gap: 20px;
    }
    .page-head .button {
        width: 100%;
        text-align: center;
    }
    .case-date {
        display: none;
    }
    .case {
        gap: 14px;
        padding-block: 20px;
    }
    .case-main h3 {
        overflow-wrap: anywhere;
    }
    .dashboard-trust {
        margin-top: 0;
    }
    .dashboard-breadcrumbs {
        align-items: flex-start;
        flex-wrap: wrap;
        margin-bottom: 28px;
    }
    .breadcrumb-count {
        width: 100%;
        margin-left: 0;
    }
    .reset-all-filters {
        width: 100%;
        justify-content: center;
    }
    .folder-section .section-head,
    .analysis-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }
    .active-filter {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }
    .active-filter > div {
        align-items: flex-start;
        flex-direction: column;
        gap: 7px;
    }
    .detail-head {
        align-items: start;
        gap: 15px;
    }
    .detail-head h1 {
        font-size: 38px;
    }
    .document-bar {
        align-items: start;
        gap: 15px;
        flex-direction: column;
    }
    footer {
        flex-direction: column;
        text-align: center;
    }
    .actions {
        align-items: start;
        flex-direction: column;
    }
    .hero h1 {
        font-size: 54px;
    }
    .form-card {
        padding: 28px 22px;
    }
    .auth {
        min-height: calc(100svh - 66px);
        padding: 40px 18px;
    }
    .new-task {
        grid-template-columns: 1fr 34px;
    }
    .new-task input[type="date"] {
        display: none;
    }
}
@media (max-width: 480px) {
    .hero,
    .dashboard,
    .detail,
    .import-page {
        padding-inline: 18px;
    }
    .hero h1,
    .page-head h1,
    .detail h1,
    .import-page h1,
    .auth h1 {
        font-size: clamp(38px, 12vw, 48px);
        overflow-wrap: anywhere;
    }
    .form-card {
        border-radius: 10px;
    }
}
