:root{color-scheme:light;font-family:Arial,Helvetica,sans-serif}
body{margin:0;background:#f5f7fb;color:#1f2937}.wrap{max-width:1900px;margin:auto;padding:20px}
h1{margin-bottom:4px;color:#111827}.sub,.hint{color:#6b7280}.card{background:#ffffff;border:1px solid #d1d5db;border-radius:10px;padding:16px;margin:14px 0;box-shadow:0 1px 3px rgba(0,0,0,.05)}
.crossedCard{border-color:#16a34a}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:10px}
label{color:#4b5563;font-size:13px}input{display:block;width:100%;box-sizing:border-box;margin-top:6px;padding:9px;background:#ffffff;border:1px solid #cbd5e1;border-radius:6px;color:#111827}
.status{margin-top:6px;padding:9px;background:#f8fafc;border:1px solid #cbd5e1;border-radius:6px;font-weight:bold;color:#111827}
.actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}button{padding:10px 14px;border:0;border-radius:6px;background:#16a34a;color:white;font-weight:bold;cursor:pointer}.secondary{background:#2563eb}.danger{background:#dc2626}
.cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:9px}.metric{background:#ffffff;border:1px solid #d1d5db;border-radius:8px;padding:12px;box-shadow:0 1px 2px rgba(0,0,0,.04)}.metric span{display:block;color:#6b7280;font-size:12px}.metric b{font-size:20px;color:#111827}
.tablewrap{overflow:auto;max-height:55vh;background:#ffffff}table{width:100%;border-collapse:collapse;font-size:12px;white-space:nowrap;background:#ffffff}th,td{padding:8px;border-bottom:1px solid #e5e7eb;text-align:right}th:first-child,td:first-child{text-align:left}th{position:sticky;top:0;background:#f3f4f6;color:#4b5563;z-index:1}tbody tr:nth-child(even){background:#fafafa}tbody tr:hover{background:#eef6ff}
.good{color:#15803d;font-weight:bold}.bad{color:#b91c1c;font-weight:bold}.info{color:#1d4ed8}.warn{color:#b45309;font-weight:bold}

.chartbtn{
  display:inline-block;
  padding:5px 8px;
  border-radius:5px;
  background:#1f6feb;
  color:#fff;
  text-decoration:none;
  font-weight:700;
  font-size:11px;
  white-space:nowrap;
}
.chartbtn:hover{background:#1558b0}
.stocklink{color:#0969da;text-decoration:none}
.stocklink:hover{text-decoration:underline}

.modal{position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:9999;display:flex;align-items:center;justify-content:center;padding:20px}
.modal.hidden{display:none}
.modalbox{width:min(1450px,96vw);height:min(850px,94vh);background:#fff;border-radius:12px;box-shadow:0 18px 60px rgba(0,0,0,.25);padding:16px;overflow:hidden}
.modalhead{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;border-bottom:1px solid #e5e7eb;padding-bottom:8px}
.modalhead h2{margin:0 0 4px}.closebtn{background:#e5e7eb;color:#111827;border:0;border-radius:7px;font-size:28px;line-height:1;padding:5px 11px;cursor:pointer}
.closebtn:hover{background:#d1d5db}

.sidebar{position:fixed;left:0;top:0;bottom:0;width:190px;background:#ffffff;border-right:1px solid #d0d7de;padding:18px 12px;box-sizing:border-box;z-index:1000}
.brand{font-weight:800;font-size:20px;color:#1f2937;margin:5px 8px 22px}
.navitem{display:block;padding:11px 12px;margin:5px 0;border-radius:7px;color:#344054;text-decoration:none;font-weight:700}
.navitem:hover{background:#eef5ff;color:#0969da}.navitem.active{background:#0969da;color:#fff}
.withsidebar{margin-left:190px;max-width:none}
@media(max-width:800px){.sidebar{position:static;width:100%;display:flex;gap:5px;align-items:center}.brand{margin:0 10px 0 0}.navitem{display:inline-block}.withsidebar{margin-left:0}}

/* Excel-linked final journal, preserving the existing clean light theme */
.fj-head{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap}.fj-head h1,.fj-head h2{margin:5px 0}.fj-eyebrow{color:#2563eb;letter-spacing:1.4px;font-size:11px;font-weight:800}.fj-link{color:#2563eb;font-size:13px;text-decoration:none;font-weight:700;border:1px solid #bfdbfe;background:#eff6ff;padding:11px 14px;border-radius:7px;display:inline-block}.fj-link:hover{background:#dbeafe}.fj-actions{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.fj-kpis{margin:18px 0}.fj-kpis .metric{padding:20px 16px;border-top:3px solid #2563eb}.fj-kpis .metric b{display:block;font-size:clamp(18px,2vw,27px);margin-top:8px}.fj-charts{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.fj-plot{height:245px;display:flex;align-items:center}.fj-plot svg{width:100%;height:100%}.fj-search-label{font-size:12px}.fj-search-label input{margin-top:3px;min-width:210px}.fj-actions select{padding:10px;border:1px solid #cbd5e1;border-radius:6px;background:#fff;color:#111827}.fj-table{max-height:62vh}.fj-table th,.fj-table td{padding:12px 11px}.fj-table th:last-child,.fj-table td:last-child{text-align:left}.fj-market{font-size:11px;background:#eff6ff;border:1px solid #dbeafe;color:#1d4ed8;border-radius:4px;padding:4px 6px}.fj-remark{color:#6b7280}.journal-preview{border-left:4px solid #2563eb}@media(max-width:1100px){.fj-charts{grid-template-columns:1fr}}@media(max-width:800px){.fj-head{align-items:flex-start}.fj-actions{width:100%}}
