:root {
  color-scheme: light;
  --ink: #13241e;
  --muted: #6a7771;
  --line: #d8e1da;
  --canvas: #f4f7f4;
  --panel: #ffffff;
  --teal: #006c65;
  --teal-dark: #00534e;
  --lime: #c9f05c;
  --warning: #b74e09;
  --danger: #bd3147;
  --shadow: 0 16px 45px rgba(32, 64, 52, .08);
  font-family: Manrope, ui-sans-serif, system-ui, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--canvas); color: var(--ink); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.login-page { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr); background: #edf2ef; }
.login-visual { background: linear-gradient(145deg, rgba(0, 64, 60, .90), rgba(8, 42, 34, .77)), url('/assets/gestion-llm-locaux.jpg') center/cover; color: white; padding: clamp(32px, 6vw, 96px); display: flex; flex-direction: column; min-height: 100vh; }
.login-visual img { width: 130px; height: auto; background: white; padding: 7px 11px; border-radius: 8px; }
.login-visual h1 { margin: auto 0 16px; max-width: 620px; font-size: clamp(36px, 4.3vw, 65px); line-height: 1.03; letter-spacing: -.05em; }
.login-visual p { max-width: 540px; color: #e3f0eb; font-size: 17px; line-height: 1.7; }
.login-powered { display: flex; align-items: center; gap: 12px; font-size: 13px; color: #e3f0eb; margin-top: auto; }
.login-powered img { width: 122px; background: white; padding: 4px 8px; }
.login-panel { background: white; padding: 48px clamp(30px, 7vw, 86px); display: flex; align-items: center; }
.login-form { width: 100%; max-width: 390px; margin: auto; }
.login-form .eyebrow { color: var(--teal); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; font-weight: 800; }
h2 { letter-spacing: -.035em; margin: 8px 0; font-size: 31px; }
.login-form > p { color: var(--muted); line-height: 1.6; margin: 0 0 28px; }
.field { display: grid; gap: 7px; margin: 14px 0; }
.field label { font-size: 13px; color: #365046; font-weight: 700; }
.field input, .field select, .field textarea { border: 1px solid var(--line); border-radius: 9px; padding: 12px 13px; background: #fff; color: var(--ink); outline: none; width: 100%; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(0,108,101,.12); }
.field textarea { min-height: 120px; resize: vertical; }
.login-note { font: 12px/1.5 'DM Mono', monospace; color: var(--muted); padding: 12px; background: #f3f7f3; border-radius: 8px; margin-top: 20px; }
.app-shell { min-height: 100vh; }
.dashboard { min-height: 100vh; display: grid; grid-template-columns: 254px 1fr; }
.sidebar { background: #092e2a; color: #d9ebe4; display: flex; flex-direction: column; padding: 22px 14px; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; gap: 11px; align-items: center; padding: 7px 12px 29px; }
.brand-mark { width: 34px; height: 34px; display: grid; place-items: center; background: var(--lime); color: #153026; border-radius: 10px; font: 800 13px 'DM Mono', monospace; }
.brand-title { font-weight: 800; color: white; letter-spacing: -.03em; }
.brand-subtitle { font-size: 11px; color: #94b9ad; margin-top: 2px; }
.nav { display: grid; gap: 3px; }
.nav button { border: 0; text-align: left; color: #c3dbd2; background: transparent; border-radius: 8px; padding: 11px 12px; font-size: 14px; transition: background .16s ease, color .16s ease; }
.nav button:hover, .nav button.active { background: rgba(207,244,102,.13); color: white; }
.nav button.active::before { content: '•'; color: var(--lime); margin-right: 8px; }
.sidebar-footer { margin-top: auto; border-top: 1px solid rgba(210,237,226,.16); padding: 16px 12px 5px; }
.user-name { color: white; font-size: 13px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.user-role { color: #97baaf; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; margin: 4px 0 12px; }
.link-button { background: none; border: 0; color: #a9d5c6; padding: 0; font-size: 12px; text-decoration: underline; }
.main { padding: 32px clamp(24px, 4vw, 62px); max-width: 1600px; min-width: 0; }
.page-top { display: flex; justify-content: space-between; gap: 18px; align-items: flex-start; margin-bottom: 28px; }
.page-top h1 { margin: 0; font-size: clamp(29px, 3.5vw, 45px); letter-spacing: -.055em; }
.page-top p { color: var(--muted); margin: 7px 0 0; max-width: 720px; font-size: 14px; line-height: 1.6; }
.status-key { display: flex; gap: 12px; font-size: 12px; color: var(--muted); padding-top: 12px; white-space: nowrap; }
.dot { width: 8px; height: 8px; display: inline-block; border-radius: 50%; margin-right: 6px; background: #94a59c; }
.dot.ok { background: #36a56f; box-shadow: 0 0 0 3px rgba(54,165,111,.13); }.dot.warn { background: #dd9e3e; }.dot.down { background: #d55464; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 25px; }
.metric { background: var(--panel); box-shadow: 0 1px 0 var(--line); border-radius: 13px; padding: 17px; border: 1px solid #e7ede8; }
.metric-label { color: var(--muted); font-size: 12px; }.metric-value { font-size: 27px; letter-spacing: -.05em; font-weight: 800; margin-top: 5px; }.metric-caption { color: var(--muted); font-size: 11px; margin-top: 2px; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 335px; gap: 18px; align-items: start; }
.panel { background: var(--panel); border: 1px solid #e4ece6; border-radius: 13px; box-shadow: 0 1px 1px rgba(18,43,34,.02); overflow: hidden; }
.panel-header { padding: 19px 20px 15px; display: flex; justify-content: space-between; gap: 10px; align-items: center; border-bottom: 1px solid #edf1ee; }.panel-header h3 { margin: 0; font-size: 15px; letter-spacing: -.02em; }.panel-header span { color: var(--muted); font-size: 12px; }
.engine-list { display: grid; gap: 11px; }
.engine-card { padding: 19px 20px; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 16px; border-bottom: 1px solid #edf1ee; }.engine-card:last-child { border: 0; }
.engine-name { font-size: 16px; font-weight: 800; letter-spacing: -.02em; }.engine-meta { font: 11px 'DM Mono', monospace; color: var(--muted); margin-top: 7px; }.engine-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 13px; }
.tag { font: 11px 'DM Mono', monospace; color: #245c53; background: #eaf4ed; border-radius: 5px; padding: 4px 6px; }.tag.default { background: #dbef9d; color: #344d00; }
.card-actions { display: flex; align-self: center; gap: 7px; flex-wrap: wrap; justify-content: flex-end; }.btn { padding: 9px 11px; border: 1px solid var(--line); background: white; color: #243b32; border-radius: 8px; font-weight: 700; font-size: 12px; transition: transform .14s ease, background .14s ease; }.btn:active { transform: scale(.97); }.btn:hover { background: #f1f7f3; }.btn.primary { background: var(--teal); color: white; border-color: var(--teal); }.btn.primary:hover { background: var(--teal-dark); }.btn.lime { background: var(--lime); color: #263d1e; border-color: var(--lime); }.btn.danger { color: var(--danger); border-color: #f0c7ce; }.btn:disabled { opacity: .45; cursor: not-allowed; }
.info-list { padding: 6px 20px 15px; }.info-row { padding: 13px 0; border-bottom: 1px solid #edf1ee; }.info-row:last-child { border:0; }.info-label { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }.info-value { margin-top: 4px; font-size: 13px; font-weight: 700; }.info-code { font: 11px/1.5 'DM Mono', monospace; color: #365a50; overflow-wrap: anywhere; }
.data-table-wrap { overflow-x: auto; }.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }.data-table th { text-align: left; color: var(--muted); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; padding: 11px 14px; background: #f7f9f7; }.data-table td { padding: 13px 14px; border-top: 1px solid #edf1ee; vertical-align: middle; }.empty { color: var(--muted); padding: 27px 20px; text-align: center; font-size: 13px; }
.page-section { display: grid; gap: 18px; }.section-actions { display: flex; gap: 8px; flex-wrap: wrap; }.details-panel { padding: 0; }.details-intro { padding: 20px; border-bottom: 1px solid #edf1ee; color: var(--muted); font-size: 13px; line-height: 1.55; }.model-row { padding: 14px 20px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-bottom: 1px solid #edf1ee; }.model-row:last-child { border: 0; }.model-name { font: 12px 'DM Mono', monospace; font-weight: 700; }.model-details { font-size: 11px; color: var(--muted); margin-top: 5px; }.model-actions { display: flex; gap: 6px; }
.modal-layer { position: fixed; inset: 0; background: rgba(11,30,24,.56); display: grid; place-items: center; padding: 22px; z-index: 10; }.modal { width: min(620px, 100%); max-height: calc(100vh - 44px); overflow: auto; background: white; border-radius: 14px; box-shadow: var(--shadow); }.modal-header { padding: 20px 21px 13px; display: flex; justify-content: space-between; align-items: center; }.modal-header h3 { margin: 0; font-size: 20px; letter-spacing: -.04em; }.modal-body { padding: 0 21px 21px; }.modal-footer { display: flex; gap: 9px; justify-content: flex-end; padding: 14px 21px 20px; }.icon-close { border: 0; background: none; color: var(--muted); font-size: 23px; }.check-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; padding: 10px; background: #f5f8f5; border-radius: 8px; }.check-list label { font-size: 12px; display: flex; gap: 7px; align-items: center; }.test-result { white-space: pre-wrap; font: 12px/1.65 'DM Mono', monospace; color: #24473d; background: #eff6f1; border-radius: 9px; padding: 13px; max-height: 300px; overflow: auto; }.form-error { color: var(--danger); font-size: 12px; margin-top: 8px; }.toast-region { position: fixed; right: 20px; bottom: 20px; z-index: 20; display: grid; gap: 9px; }.toast { padding: 12px 14px; background: #163b32; color: white; box-shadow: var(--shadow); border-radius: 8px; font-size: 13px; max-width: 380px; }.toast.error { background: #902a3d; }
@media (max-width: 1050px) { .metrics { grid-template-columns: repeat(2, 1fr); }.content-grid { grid-template-columns: 1fr; }.sidebar { width: 218px; }.dashboard { grid-template-columns: 218px 1fr; } }
@media (max-width: 720px) { .login-page { grid-template-columns: 1fr; }.login-visual { min-height: 285px; }.login-visual h1 { margin-top: 55px; }.dashboard { display: block; }.sidebar { position: relative; height: auto; }.nav { grid-template-columns: repeat(2, 1fr); }.main { padding: 24px 16px; }.page-top, .engine-card { display: block; }.status-key { padding-top: 0; margin-top: 10px; }.card-actions { justify-content: flex-start; margin-top: 14px; }.metrics { grid-template-columns: 1fr 1fr; }.model-row { align-items: flex-start; flex-direction: column; }.data-table { min-width: 620px; } }
