:root {
  color-scheme: light;
  --page: #f5f6f4;
  --paper: #ffffff;
  --ink: #20241f;
  --muted: #858a82;
  --line: #ebede9;
  --green: #53745b;
  --green-deep: #294c34;
  --green-pale: #edf4ed;
  --amber: #a97436;
  --amber-pale: #fbf3e8;
  --blue: #52728b;
  --blue-pale: #edf3f7;
  --shadow: 0 18px 56px rgba(45, 55, 44, 0.055), 0 2px 8px rgba(45, 55, 44, 0.025);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  min-width: 320px;
  background: var(--page);
  color: var(--ink);
  font-family: 'DM Sans', sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }
textarea { font: inherit; }
button { color: inherit; }

.app-shell { min-height: 100vh; }
.main-content { width: min(100% - 48px, 1060px); margin: 0 auto; padding: 57px 0 34px; }
.site-footer { width: min(100% - 48px, 1060px); display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin: 0 auto; padding: 17px 12px 23px; border-top: 1px solid rgba(61, 75, 60, .09); color: #92988f; font-size: 9px; text-align: center; }
.site-footer strong { color: #647460; font-weight: 700; }
.site-footer code { color: #647460; font-family: inherit; font-size: inherit; font-weight: 700; }
.admin-controls { display: flex; align-items: center; margin-left: 8px; }
.admin-button { min-height: 32px; padding: 4px 8px; border: 0; border-radius: 6px; background: transparent; color: #788276; cursor: pointer; font-size: 10px; }
.admin-button:hover { background: #edf4ed; color: #46664b; }
.admin-button:focus-visible { outline: 2px solid #8ba48a; outline-offset: 2px; }
.intro { display: flex; align-items: end; justify-content: space-between; gap: 22px; margin-bottom: 34px; padding: 0 15px; }
h1, h2, p { margin-top: 0; }
h1 { margin: 0 0 9px; font-family: 'Manrope', sans-serif; font-size: clamp(34px, 4vw, 48px); line-height: 1.11; letter-spacing: -2.6px; font-weight: 700; }
h1 span { color: #758a73; }
.mobile-break { display: none; }
.date-controls { display: flex; align-items: center; gap: 8px; }
.date-history { display: flex; align-items: center; gap: 6px; }
.date-history-button { min-width: 75px; display: grid; gap: 4px; padding: 8px 10px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: #969c93; cursor: pointer; text-align: left; transition: background .18s ease, border-color .18s ease, color .18s ease; }
.date-history-button span { font-size: 7px; font-weight: 700; letter-spacing: .11em; }
.date-history-button strong { color: #747c72; font-size: 9px; font-weight: 600; white-space: nowrap; }
.date-history-button:hover { background: rgba(255,255,255,.58); color: #697568; }
.date-history-button:disabled { cursor: not-allowed; opacity: .42; }
.date-history-button.is-active { border-color: #e4e9e1; background: rgba(255,255,255,.76); color: #58715a; }
.date-history-button.is-active strong { color: #465b47; }
.date-history-button:focus-visible, .date-card:focus-visible { outline: 2px solid #8ba48a; outline-offset: 2px; }
.date-card { display: flex; align-items: center; gap: 11px; margin: 0; padding: 12px 15px; border: 1px solid #e8eae5; border-radius: 10px; background: rgba(255,255,255,.52); color: var(--ink); cursor: pointer; text-align: left; transition: background .18s ease, border-color .18s ease; }
.date-card:hover, .date-card.is-active { border-color: #d9e3d7; background: rgba(255,255,255,.9); }
.date-icon { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; background: #eef2ec; color: #6b8068; }
.date-icon svg { width: 16px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.date-card strong, .date-card small { display: block; }
.date-card strong { font-size: 11px; font-weight: 700; }
.date-card small { margin-top: 3px; color: #969b93; font-size: 9px; }

.brief-panel { overflow: hidden; border: 1px solid rgba(43, 55, 43, .07); border-radius: 14px; background: var(--paper); box-shadow: var(--shadow); }
.panel-toolbar { min-height: 73px; display: flex; align-items: center; justify-content: space-between; gap: 17px; padding: 0 25px; border-bottom: 1px solid var(--line); }
.tabs { align-self: stretch; display: flex; align-items: stretch; gap: 20px; }
.tab { position: relative; display: inline-flex; align-items: center; gap: 8px; padding: 2px 1px 0; border: 0; background: transparent; color: #93978f; cursor: pointer; font-size: 11px; font-weight: 600; white-space: nowrap; transition: color .18s ease; }
.tab::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; border-radius: 4px 4px 0 0; background: transparent; content: ''; }
.tab:hover { color: #505a4f; }
.tab.is-active { color: #354c38; }
.tab.is-active::after { background: #6f8b6e; }
.tab:focus-visible, .search-box:focus-within { outline: 2px solid #8ba48a; outline-offset: 3px; }
.tab-icon { display: grid; width: 20px; height: 20px; place-items: center; border-radius: 6px; font-size: 11px; }
.crypto-icon { background: #f8f1e7; color: #b48247; font-weight: 700; }
.crypto-icon svg { width: 15px; height: 15px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.world-icon { background: #edf3f6; color: #628097; }
.france-icon { background: #f3eff6; color: #887294; }
.tab-icon svg { width: 13px; stroke: currentColor; stroke-width: 1.35; stroke-linecap: round; stroke-linejoin: round; }
.toolbar-refresh { display: flex; flex: 0 0 auto; align-items: center; gap: 10px; }
.last-updated { color: #91978e; font-size: 9px; white-space: nowrap; }
.search-box { width: 170px; height: 34px; flex: 0 0 170px; display: flex; align-items: center; gap: 7px; padding: 0 9px; border: 1px solid #eff0ed; border-radius: 7px; background: #fbfcfa; color: #999e96; }
.search-box svg { width: 14px; flex: 0 0 14px; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }
.search-box input { width: 100%; min-width: 0; outline: none; border: 0; background: transparent; color: #3e473e; font-size: 10px; }
.search-box input::placeholder { color: #a5aaa2; }
.search-box kbd { display: grid; width: 17px; height: 18px; flex: 0 0 17px; place-items: center; border: 1px solid #e8eae6; border-radius: 4px; color: #9ea39b; font: 10px 'DM Sans', sans-serif; }

.refresh-button { min-height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 0 11px; border: 1px solid #dce6dc; border-radius: 7px; background: #f5f8f4; color: #46664b; cursor: pointer; font-size: 10px; font-weight: 700; transition: background .18s ease, border-color .18s ease, transform .18s ease; }
.refresh-button:hover:not(:disabled) { transform: translateY(-1px); border-color: #bdcdbd; background: #edf4ec; }
.refresh-button:focus-visible, .dialog-submit:focus-visible, .dialog-cancel:focus-visible { outline: 2px solid #8ba48a; outline-offset: 3px; }
.refresh-button:disabled { cursor: wait; opacity: .6; }
.refresh-button svg { width: 14px; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.news-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 0 30px 28px; }
.news-card { min-height: 151px; display: block; padding: 17px 18px 15px; border: 1px solid #ebede9; border-radius: 9px; background: #fff; color: inherit; text-decoration: none; animation: card-in .28s ease both; transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease; }
.news-card:hover { transform: translateY(-2px); border-color: #dce4da; box-shadow: 0 7px 18px rgba(44, 61, 45, .045); }
.news-card:focus-visible { outline: 2px solid #8ba48a; outline-offset: 3px; }
.card-topline { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.category-badge { display: inline-flex; align-items: center; gap: 5px; width: fit-content; padding: 5px 8px; border-radius: 5px; color: #5d775c; background: #eff4ed; font-size: 8px; font-weight: 700; letter-spacing: .025em; }
.category-badge::before { width: 4px; height: 4px; border-radius: 50%; background: currentColor; content: ''; }
.category-badge.tone-amber { color: var(--amber); background: var(--amber-pale); }
.category-badge.tone-blue { color: var(--blue); background: var(--blue-pale); }
.category-badge.tone-violet { color: #806c91; background: #f3eff6; }
.card-time { color: #a1a59e; font-size: 9px; white-space: nowrap; }
.news-card h3 { margin: 0 0 6px; color: #333932; font-size: 12px; line-height: 1.45; font-weight: 700; letter-spacing: -.1px; }
.news-card p { max-width: 480px; margin: 0; color: #858a82; font-size: 10px; line-height: 1.65; }
.card-bottom { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; padding-top: 10px; border-top: 1px solid #f1f2ef; color: #a1a69e; font-size: 8px; }
.card-source { color: #7c827a; font-weight: 600; }
.card-arrow { color: #a0a79c; font-size: 12px; }
.empty-state { padding: 18px 30px 35px; margin: 0; color: #8b9088; text-align: center; font-size: 12px; }
.refresh-dialog { width: min(100% - 32px, 390px); padding: 26px; border: 1px solid #e6e9e3; border-radius: 14px; background: #fff; color: var(--ink); box-shadow: 0 24px 80px rgba(24, 32, 24, .2); }
.refresh-dialog::backdrop { background: rgba(29, 37, 29, .38); backdrop-filter: blur(3px); }
.refresh-dialog form { margin: 0; }
.dialog-mark { width: 34px; height: 34px; display: grid; place-items: center; margin-bottom: 16px; border-radius: 9px; background: #edf4ed; color: #547457; font-size: 20px; }
.refresh-dialog h2 { margin: 0 0 7px; font-family: 'Manrope', sans-serif; font-size: 19px; letter-spacing: -.5px; }
.dialog-copy { margin: 0 0 20px; color: #858a82; font-size: 11px; line-height: 1.6; }
.password-label { display: block; margin-bottom: 7px; color: #555d54; font-size: 10px; font-weight: 700; }
.refresh-dialog input { width: 100%; height: 40px; padding: 0 11px; border: 1px solid #e2e7df; border-radius: 7px; outline: none; background: #fcfdfb; color: #333a32; font-size: 13px; }
.refresh-dialog input:focus { border-color: #8ba48a; box-shadow: 0 0 0 3px rgba(139, 164, 138, .15); }
.refresh-status { min-height: 16px; margin: 8px 0 0; color: #858a82; font-size: 10px; line-height: 1.5; }
.refresh-status.is-error { color: #a5483f; }
.refresh-status:empty { display: none; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }
.dialog-cancel, .dialog-submit { min-height: 36px; padding: 0 13px; border: 1px solid #e4e8e1; border-radius: 7px; cursor: pointer; font-size: 10px; font-weight: 700; }
.dialog-cancel { background: #fff; color: #73796f; }
.dialog-submit { border-color: #4f7154; background: #4f7154; color: #fff; }
.dialog-submit:hover:not(:disabled) { background: #3e6243; }
.dialog-cancel:disabled, .dialog-submit:disabled { cursor: wait; opacity: .55; }
.toast { position: fixed; top: 18px; right: 20px; z-index: 5; width: min(370px, calc(100vw - 32px)); display: flex; align-items: center; gap: 12px; padding: 14px 16px; transform: translateY(-8px) scale(.985); border: 1px solid rgba(225, 231, 223, .9); border-radius: 13px; background: rgba(255, 255, 255, .94); box-shadow: 0 14px 42px rgba(31, 42, 31, .14), 0 2px 8px rgba(31, 42, 31, .05); backdrop-filter: blur(18px); color: #485448; opacity: 0; pointer-events: none; transition: opacity .22s ease, transform .22s ease; }
.toast[hidden] { display: none; }
.toast.is-visible { transform: translateY(0) scale(1); opacity: 1; }
.toast-indicator { width: 22px; height: 22px; flex: 0 0 22px; display: grid; place-items: center; border: 2px solid #e7eee5; border-radius: 50%; color: #4f7653; }
.toast-progress .toast-indicator { border-color: #e5ede3; border-top-color: #608262; animation: toast-spin .8s linear infinite; }
.toast-success .toast-indicator { border: 0; background: #edf5eb; }
.toast-success .toast-indicator::after { content: '✓'; font-size: 13px; font-weight: 700; }
.toast-error .toast-indicator { border: 0; background: #fbefed; color: #a5483f; }
.toast-error .toast-indicator::after { content: '!'; font-size: 13px; font-weight: 700; }
.toast-copy { min-width: 0; display: grid; gap: 3px; }
.toast-title { color: #344235; font-size: 12px; font-weight: 700; }
.toast-message { color: #7c837a; font-size: 10px; line-height: 1.5; }

.detail-content { width: min(100% - 48px, 800px); margin: 0 auto; padding: 34px 0 48px; }
.back-link { display: inline-flex; align-items: center; gap: 9px; margin: 0 0 20px 2px; color: #687568; font-size: 11px; font-weight: 600; text-decoration: none; }
.back-link span { font-size: 16px; transition: transform .18s ease; }
.back-link:hover span { transform: translateX(-3px); }
.back-link:focus-visible, .detail-source a:focus-visible { outline: 2px solid #8ba48a; outline-offset: 3px; border-radius: 3px; }
.detail-loading { padding: 24px; color: #858a82; text-align: center; font-size: 12px; }
.detail-story, .question-panel { border: 1px solid rgba(43, 55, 43, .07); border-radius: 14px; background: var(--paper); box-shadow: var(--shadow); }
.detail-story { padding: 32px 36px 25px; }
.detail-meta { display: flex; align-items: center; gap: 11px; margin-bottom: 18px; }
.detail-meta time { color: #969b93; font-size: 10px; }
.detail-story h1 { margin: 0; color: #30372f; font-size: clamp(25px, 4vw, 35px); line-height: 1.25; letter-spacing: -1.2px; }
.detail-lead { margin: 15px 0 23px; color: #6f766d; font-size: 15px; line-height: 1.75; }
.detail-explanation { padding: 19px 21px; border: 1px solid #eef0ec; border-radius: 10px; background: #fafbf9; }
.detail-section-label { margin: 0 0 7px !important; color: #526a53 !important; font-size: 10px !important; font-weight: 700; letter-spacing: .04em; }
.detail-explanation p:last-child { margin: 0; color: #777e75; font-size: 12px; line-height: 1.75; }
.detail-source { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-top: 19px; color: #92988f; font-size: 10px; }
.detail-source strong { color: #566353; font-weight: 700; }
.detail-source a { color: #527257; font-weight: 700; text-decoration: none; }
.detail-source a:hover { text-decoration: underline; }
.detail-source a span { padding-left: 3px; }
.question-panel { margin-top: 15px; padding: 23px 25px 20px; }
.question-heading { display: flex; align-items: center; gap: 11px; margin-bottom: 18px; }
.question-mark { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; border-radius: 10px; background: #edf4ed; color: #5a7a5c; font-size: 17px; }
.question-heading h2 { margin: 0 0 4px; font-family: 'Manrope', sans-serif; font-size: 14px; letter-spacing: -.25px; }
.question-heading p { margin: 0; color: #788276; font-size: 12px; line-height: 1.5; }
.question-form textarea, .prompt-fallback textarea { box-sizing: border-box; width: 100%; min-height: 70px; resize: vertical; padding: 12px; border: 1px solid #e7ebe4; border-radius: 10px; background: #fcfdfb; color: #3f473d; font: 16px/1.55 'DM Sans', sans-serif; }
.question-form textarea:focus, .prompt-fallback textarea:focus { outline: 2px solid #8ba48a; outline-offset: 2px; }
.question-form textarea::placeholder { color: #92978f; }
.question-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 10px; }
.question-button { min-height: 44px; padding: 10px 14px; border: 1px solid #4f7154; border-radius: 7px; background: #4f7154; color: #fff; cursor: pointer; font: 600 13px 'DM Sans', sans-serif; }
.question-button:hover { background: #3e6243; }
.question-button:focus-visible { outline: 2px solid #8ba48a; outline-offset: 3px; }
.question-button.secondary { background: #fff; color: #4f7154; }
.question-button.secondary:hover { background: #edf4ed; }
.question-help, .question-status { margin: 10px 0 0; color: #788276; font-size: 12px; line-height: 1.6; }
.question-status:empty { display: none; }
.prompt-fallback { margin-top: 12px; }
.prompt-fallback label { display: block; margin-bottom: 6px; font-size: 12px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; clip-path: inset(50%); }

.recap-icon { color: var(--green); background: var(--green-pale); }
.recap-panel { padding: 18px 30px 24px; }
.recap-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-bottom: 12px; }
.recap-admin-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.recap-cryptos { display: flex; flex: 1 1 auto; min-width: 0; flex-wrap: wrap; gap: 7px; }
.recap-crypto { min-width: 52px; padding: 9px 13px; border: 1px solid var(--line); border-radius: 8px; background: #fafbf9; color: #7c8678; font-size: 11px; font-weight: 700; cursor: pointer; }
.recap-crypto.is-active { border-color: #c7d8c5; background: var(--green-pale); color: var(--green-deep); }
.recap-crypto:focus-visible, .recap-panel summary:focus-visible { outline: 2px solid #8ba48a; outline-offset: 3px; }
.recap-status { margin: 10px 0; color: #7e877b; font-size: 11px; line-height: 1.65; }
.recap-status:empty { display: none; }
.recap-status.is-error { color: #a5483f; }
.recap-summary-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-bottom: 16px; color: #8a9385; font-size: 10px; }
.recap-situation { padding: 20px; border: 1px solid #e2e9df; border-radius: 10px; background: #f6f9f4; }
.recap-situation h3, .recap-card h3, .recap-history h3, .recap-sources h3, .recap-job h3 { margin: 0 0 11px; font-family: 'Manrope', sans-serif; font-size: 13px; color: #40553e; }
.recap-situation p, .recap-card p, .recap-entry p, .recap-coverage p, .recap-latest p { margin: 0 0 9px; color: #737d6d; font-size: 12px; line-height: 1.7; white-space: pre-line; overflow-wrap: anywhere; }
.recap-situation p:last-child, .recap-card p:last-child, .recap-entry p:last-child { margin-bottom: 0; }
.recap-latest { margin-top: 14px; padding-top: 13px; border-top: 1px solid #e2e9df; }
.recap-latest h4 { margin: 0 0 7px; color: #556d51; font-size: 11px; }
.recap-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.recap-card { padding: 18px; border: 1px solid var(--line); border-radius: 10px; }
.recap-bearish h3 { color: #9b654c; }
.recap-entry { padding: 13px 0; border-top: 1px solid var(--line); }
.recap-entry:first-of-type { padding-top: 0; border-top: 0; }
.recap-entry-heading { margin-bottom: 9px; color: #6f7c67; font-size: 10px; font-weight: 700; }
.recap-badge { display: inline-block; margin-left: 6px; padding: 3px 6px; border-radius: 5px; background: #f3f4f0; color: #7d8478; font-size: 9px; font-weight: 500; }
.recap-fields { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 12px; margin: 9px 0; font-size: 11px; line-height: 1.6; }
.recap-fields dt { color: #909989; }
.recap-fields dd { margin: 0; color: #5c6854; overflow-wrap: anywhere; white-space: pre-line; }
.recap-source-link { color: #587651; font-size: 10px; font-weight: 600; text-decoration: none; }
.recap-source-link:hover { text-decoration: underline; }
.recap-evidence { margin-top: 10px; }
.recap-panel summary { cursor: pointer; color: #607358; font-size: 11px; font-weight: 600; line-height: 1.65; }
.recap-evidence blockquote { margin: 8px 0 0; padding-left: 10px; border-left: 2px solid #dde6d8; color: #7b8474; font-size: 11px; line-height: 1.65; white-space: pre-line; }
.recap-history, .recap-sources, .recap-levels { margin-top: 20px; }
.recap-timeline { list-style: none; margin: 12px 0 0 3px; padding: 0 0 0 17px; border-left: 1px solid #dfe6da; }
.recap-timeline > li { position: relative; padding: 0 0 19px; }
.recap-timeline > li::before { position: absolute; top: 5px; left: -21px; width: 7px; height: 7px; border-radius: 50%; background: #90a384; content: ''; }
.recap-timeline .recap-entry { border: 0; padding: 0; }
.recap-table-wrap { overflow-x: auto; }
.recap-table { width: 100%; border-collapse: collapse; font-size: 11px; }
.recap-table th { color: #87917e; font-weight: 600; text-align: left; }
.recap-table td { color: #627158; }
.recap-table th, .recap-table td { padding: 9px 10px 9px 0; border-bottom: 1px solid var(--line); line-height: 1.6; }
.recap-coverage { margin-top: 16px; padding: 13px 15px; border-radius: 8px; background: #f8f9f6; }
.recap-coverage.is-incomplete { border: 1px solid #efdfc7; background: #fdf9f1; }
.recap-coverage p { font-size: 11px; }
.recap-source-list, .recap-plain-list { padding-left: 18px; margin: 8px 0 0; }
.recap-source-list li, .recap-plain-list li { margin: 6px 0; color: #7c8575; font-size: 11px; line-height: 1.7; overflow-wrap: anywhere; }
.recap-admin { margin-top: 25px; padding-top: 17px; border-top: 1px solid var(--line); }
.recap-admin > summary { font-size: 12px; }
.recap-login-form, .recap-instruction-form { margin-top: 17px; }
.recap-login-form label, .recap-instruction-form label { display: block; margin-bottom: 7px; color: #6e7a66; font-size: 11px; font-weight: 600; }
.recap-form-row { display: flex; gap: 8px; }
.recap-login-form input, .recap-instruction-form textarea { width: 100%; min-width: 0; padding: 11px; border: 1px solid #e2e7df; border-radius: 7px; background: #fcfdfb; color: #3f4c39; font-size: 12px; }
.recap-form-row .dialog-submit { flex-shrink: 0; }
.recap-instruction-form textarea { display: block; margin-bottom: 9px; resize: vertical; line-height: 1.7; }
.recap-login-form input:focus, .recap-instruction-form textarea:focus { outline: 2px solid #a4b89c; outline-offset: 1px; }
.recap-admin-heading { margin-top: 15px; align-items: flex-start; }
.recap-admin-heading p { max-width: 550px; margin: 0; color: #858e7d; font-size: 11px; line-height: 1.7; }
.recap-preferences, .recap-job-history { margin-top: 15px; }
.recap-job { margin-top: 15px; padding: 16px; border: 1px solid #e2e9df; border-radius: 8px; background: #fafcf8; }
.recap-job progress { width: 100%; accent-color: #63845a; height: 8px; }
.recap-job pre { max-height: 280px; overflow: auto; margin: 10px 0 0; padding: 11px; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: #6f7c66; font: 11px/1.65 ui-monospace, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.recap-job-item { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); color: #7a8670; font-size: 10px; }
.recap-job-item button { padding: 5px 8px; border: 1px solid #e2e7df; border-radius: 5px; background: #fff; color: #59714e; font-size: 10px; cursor: pointer; }
.recap-result { margin-top: 19px; padding-top: 16px; border-top: 1px solid var(--line); }
.recap-result-summary, .recap-comparison { margin-top: 18px; }
.recap-result-summary h4, .recap-comparison > h4 { margin: 0 0 10px; color: #526b4a; font-size: 12px; }
.recap-comparison-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.recap-comparison-grid .recap-grid { grid-template-columns: 1fr; }
.recap-raw-result { margin-top: 17px; }

@media (max-width: 900px) and (min-width: 701px) {
  .panel-toolbar { flex-wrap: wrap; gap: 10px 15px; padding-bottom: 13px; }
  .tabs { height: 60px; }
  .search-box { margin-left: auto; }
}

@media (max-width: 700px) {
  .recap-panel { padding: 16px 16px 20px; }
  .recap-grid { grid-template-columns: 1fr; }
  .recap-comparison-grid { grid-template-columns: 1fr; }
  .recap-situation, .recap-card { padding: 16px; }
  .recap-fields { grid-template-columns: 1fr; gap: 2px; }
  .recap-fields dd { margin-bottom: 6px; }
  .recap-admin-heading { flex-wrap: wrap; }
}

@keyframes toast-spin { to { transform: rotate(360deg); } }

@keyframes card-in { from { transform: translateY(5px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

@media (max-width: 700px) {
  .toast { top: 12px; right: 12px; }
  .main-content { width: min(100% - 30px, 520px); padding-top: 38px; }
  .site-footer { width: min(100% - 30px, 520px); padding-bottom: 20px; font-size: 8px; }
  .intro { display: block; padding: 0 3px; margin-bottom: 25px; }
  h1 { font-size: 37px; letter-spacing: -2px; }
  .mobile-break { display: initial; }
  .date-controls { justify-content: flex-end; margin-top: 16px; }
  .date-card { gap: 8px; padding: 8px 10px; }
  .date-icon { width: 27px; height: 27px; }
  .date-card strong { font-size: 9px; }
  .date-card small { max-width: 90px; font-size: 8px; }
  .panel-toolbar { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 12px; padding: 0 17px 13px; }
  .tabs { grid-column: 1 / -1; grid-row: 1; height: 59px; justify-content: space-between; gap: 12px; }
  .tab { gap: 6px; font-size: 10px; }
  .tab-icon { width: 18px; height: 18px; }
  .toolbar-refresh { grid-column: 1; grid-row: 2; gap: 7px; }
  .last-updated { font-size: 8px; }
  .refresh-button { min-height: 32px; gap: 5px; padding: 0 8px; font-size: 9px; }
  .refresh-button svg { width: 12px; }
  .search-box { grid-column: 2; grid-row: 2; width: 100%; min-width: 0; height: 35px; flex-basis: auto; }
  .search-box input { font-size: 11px; }
  .news-grid { grid-template-columns: 1fr; gap: 9px; padding: 0 14px 20px; }
  .news-card { min-height: 0; padding: 14px 14px 12px; }
  .card-topline { margin-bottom: 10px; }
  .news-card h3 { font-size: 12px; }
  .news-card p { font-size: 10px; }
  .detail-content { width: min(100% - 30px, 560px); padding: 23px 0 32px; }
  .detail-story { padding: 23px 20px 20px; }
  .detail-meta { margin-bottom: 14px; }
  .detail-lead { margin: 12px 0 18px; font-size: 13px; }
  .detail-explanation { padding: 15px 16px; }
  .question-panel { padding: 18px 16px 15px; }
  .question-heading { align-items: flex-start; }
}

@media (max-width: 390px) {
  .main-content { width: calc(100% - 22px); }
  .site-footer { width: calc(100% - 22px); }
  h1 { font-size: 32px; }
  .date-controls { justify-content: flex-start; gap: 4px; }
  .date-history { flex: 1; gap: 3px; }
  .date-history-button { min-width: 0; flex: 1; padding: 7px 5px; }
  .date-history-button span { font-size: 6px; }
  .date-history-button strong { font-size: 8px; }
  .date-card { min-width: 132px; flex: 1.2; gap: 6px; padding: 7px; }
  .date-card strong { font-size: 8px; }
  .date-card small { font-size: 7px; }
  .date-icon { width: 24px; height: 24px; }
  .panel-toolbar { display: block; padding: 0 12px 12px; }
  .tabs { height: 57px; gap: 7px; }
  .tab { font-size: 9px; }
  .tab-icon { display: none; }
  .toolbar-refresh { justify-content: space-between; margin-bottom: 10px; }
  .last-updated { font-size: 8px; }
  .search-box { width: 100%; }
  .detail-content { width: calc(100% - 22px); }
  .detail-story { padding: 20px 16px 17px; }
  .question-actions { flex-direction: column; }
  .question-button { width: 100%; }
}

/* Une police d’au moins 16 px évite le zoom au focus sur iOS, sans bloquer le zoom manuel. */
@media (any-pointer: coarse) {
  .search-box input, .refresh-dialog input, .recap-login-form input,
  .recap-instruction-form textarea, .question-form textarea, .prompt-fallback textarea { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Trading Lab: private, read-only collector explorer. */
.lab-panel { padding: 28px; min-width: 0; }
.lab-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.lab-heading h2 { margin: 0; font-family: Manrope, sans-serif; font-size: 26px; }
.lab-heading p, .lab-note { color: #69736e; font-size: 13px; line-height: 1.65; }
.lab-tabs { display: flex; gap: 6px; padding: 5px; margin: 20px 0; border-radius: 14px; background: #eff2ef; width: fit-content; max-width: 100%; }
.lab-tab { padding: 10px 16px; min-height: 44px; border: 0; border-radius: 10px; background: transparent; color: #58645c; font: inherit; font-size: 14px; cursor: pointer; }
.lab-tab.is-active { background: white; color: #223b2b; box-shadow: 0 2px 8px #20352710; font-weight: 700; }
.lab-message { font-size: 14px; line-height: 1.6; overflow-wrap: anywhere; }
.lab-message.is-error { color: #a33131; }
.lab-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 20px 0; }
.lab-kpi, .lab-card { background: #fff; border: 1px solid #e3e8e1; border-radius: 18px; padding: 20px; min-width: 0; }
.lab-kpi span { display: block; color: #69736e; font-size: 12px; line-height: 1.5; }
.lab-kpi strong { display: block; font-size: 22px; margin-top: 10px; overflow-wrap: anywhere; }
.lab-kpi:last-child strong { font-size: 15px; }
.lab-card { margin: 16px 0; }
.lab-card h3 { margin: 0 0 16px; font-family: Manrope, sans-serif; font-size: 17px; }
.lab-card h3:not(:first-child) { margin-top: 28px; }
.lab-table-scroll { overflow-x: auto; max-width: 100%; overscroll-behavior-x: contain; border-radius: 8px; }
.lab-table-scroll table { width: 100%; border-collapse: collapse; font-size: 13px; text-align: left; }
.lab-table-scroll th { font-size: 11px; color: #6b766c; background: #f5f7f3; font-weight: 700; white-space: nowrap; }
.lab-table-scroll th, .lab-table-scroll td { padding: 12px; border-bottom: 1px solid #edf0ea; vertical-align: top; min-width: 115px; max-width: 340px; overflow-wrap: anywhere; }
.lab-table-scroll tr:last-child td { border-bottom: 0; }
.lab-filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; margin: 20px 0; }
.lab-filters label, .lab-series-label { display: flex; flex-direction: column; gap: 7px; font-size: 12px; font-weight: 600; flex: 1 1 160px; min-width: 0; }
.lab-filters .lab-wide { flex-basis: 100%; }
.lab-filters input, .lab-filters select, .lab-series-label select { width: 100%; min-width: 0; min-height: 44px; padding: 10px 12px; border: 1px solid #dae1d7; border-radius: 10px; background: #fff; color: #24382a; font: inherit; font-size: 16px; box-sizing: border-box; }
.lab-panel button { min-height: 44px; }
.lab-panel .refresh-button { font-size: 13px; padding: 0 12px; }
.lab-token-button { font: inherit; font-weight: 700; color: #355d40; background: #edf3e9; border: 0; border-radius: 8px; padding: 8px 12px; cursor: pointer; }
.lab-mint { display: block; font-size: 10px; line-height: 1.5; color: #778176; margin-top: 6px; overflow-wrap: anywhere; }
.lab-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
.lab-chart { margin: 0; padding: 16px; border: 1px solid #e3e8e1; border-radius: 12px; min-width: 0; }
.lab-chart figcaption { font-size: 13px; font-weight: 700; }
.lab-chart svg { width: 100%; height: auto; margin-top: 10px; background: linear-gradient(#f4f7f1, #fff); }
.lab-chart polyline { fill: none; stroke: #597946; stroke-width: 2; }
.lab-chart circle { fill: #597946; }
.lab-charts > .lab-note { grid-column: 1 / -1; }
.lab-panel details { padding: 14px 0; }
.lab-panel summary { cursor: pointer; min-height: 44px; font-size: 13px; }
.lab-placeholder { text-align: center; padding: 50px 22px; color: #69736e; }
.lab-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #597946; }
@media (max-width: 900px) { .lab-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) {
  .lab-panel { padding: 18px 12px; }
  .lab-card { padding: 16px 12px; border-radius: 14px; }
  .lab-heading h2 { font-size: 23px; }
  .lab-tabs { width: 100%; box-sizing: border-box; }
  .lab-tab { flex: 1; padding: 10px 6px; font-size: 12px; }
  .lab-kpis { gap: 8px; }
  .lab-kpi { padding: 14px 12px; }
  .lab-kpi strong { font-size: 20px; }
  .lab-charts { grid-template-columns: minmax(0, 1fr); }
  .lab-filters label { flex-basis: 100%; }
  .lab-filters button { width: 100%; }
}
@media (max-width: 430px) {
  .tabs { gap: 8px; }
  .tab-icon { display: none; }
}
