/* Vialchemy web Library (App Store Phase 6): the app's Alchemist look on top of site.css. Black and gold, Cormorant
   headings, Hanken body, thin gold hairlines instead of boxes. Self-hosted fonts only. */
@font-face { font-family: "Cormorant Garamond"; src: url(/fonts/CormorantGaramond-SemiBold.ttf) format("truetype"); font-weight: 600; font-display: swap; }
:root { --win: #8FBF7A; --amber: #F5B452; --bad: #FB7185; }
.lib-top { border-bottom: 1px solid var(--line); }
.lib-top .wrap { display: flex; align-items: center; justify-content: space-between; padding-top: 18px; padding-bottom: 18px; }
.lib-top nav a { color: var(--ink); text-decoration: none; margin-left: 22px; font-size: 15px; }
.lib-top nav a:hover { color: var(--gold); }
.lib-main { max-width: 860px; padding-top: 40px; padding-bottom: 72px; }
.page-head h1, .profile-head h1 { font-size: clamp(40px, 6vw, 58px); line-height: 1.04; margin: 0 0 12px; }
.lede { color: var(--muted); }
.medical { font-size: 14px; color: var(--gold-soft); border-left: 2px solid var(--gold); padding-left: 12px; margin: 18px 0 0; }
.fine { font-size: 14px; color: var(--muted); }
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 16px; }
.pill { font-size: 12px; font-weight: 600; letter-spacing: .4px; padding: 3px 10px; border-radius: 999px; background: rgba(236,230,214,.08); color: var(--ink); }
.pill.outline { background: none; border: 1px solid var(--gold); color: var(--gold); }
.pill.tone-win { color: var(--win); background: rgba(143,191,122,.14); }
.pill.tone-amber { color: var(--amber); background: rgba(245,180,82,.14); }
.pill.tone-bad { color: var(--bad); background: rgba(251,113,133,.14); }
.pill.muted, .pill.tone-muted { color: var(--muted); }
.regions { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 8px 24px; margin: 18px 0 0; }
.regions dt, .facts dt { font-size: 12px; font-weight: 600; letter-spacing: 2px; text-transform: uppercase; color: var(--muted); }
.regions dd, .facts dd { margin: 2px 0 10px; }
.download { margin: 26px 0 0; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.card { border-top: 1px solid var(--line); padding: 28px 0; }
.card h2 { font-size: 30px; margin: 0 0 12px; }
.card ul { padding-left: 20px; margin: 0; }
.card li { margin: 0 0 8px; }
.card-note { font-size: 14px; color: var(--muted); }
.card.tone-amber h2 { color: var(--amber); }
.card.tone-bad h2 { color: var(--bad); }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 9px 12px 9px 0; border-bottom: 1px solid var(--line); }
th { font-size: 12px; font-weight: 600; letter-spacing: 1.6px; text-transform: uppercase; color: var(--muted); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 0 28px; margin: 0; }
.verdicts { list-style: none; padding: 0 !important; }
.verdicts li { display: flex; gap: 12px; margin: 0 0 16px; }
.verdicts .dot { flex: none; width: 10px; height: 10px; border-radius: 50%; margin-top: 8px; background: var(--muted); }
.verdicts .tone-win .dot { background: var(--win); }
.verdicts .tone-bad .dot { background: var(--bad); }
.verdicts .tone-amber .dot { background: var(--amber); }
.verdicts .q { font-weight: 600; margin: 0; }
.verdicts .d { color: var(--muted); margin: 2px 0 0; }
.sources { padding-left: 20px; font-size: 15px; }
.sources a { color: var(--ink); text-decoration-color: var(--gold); }
.lib-group { border-top: 1px solid var(--line); padding: 28px 0 8px; }
.lib-group h2 { font-size: 30px; margin: 0 0 4px; }
.lib-list { list-style: none; padding: 0; margin: 12px 0 0; }
.lib-row { display: flex; flex-direction: column; gap: 2px; padding: 14px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.lib-row:hover .name { color: var(--gold); }
.lib-row .name { font-size: 24px; }
.lib-row .meta { font-size: 14px; color: var(--muted); }
/* Calculator */
.calc-note { font-size: 14px; color: var(--gold-soft); }
.calc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; margin: 14px 0; }
.calc label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; letter-spacing: .3px; color: var(--muted); }
.calc input, .calc select { font: inherit; font-size: 16px; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 11px 13px; min-width: 0; }
.calc input:focus, .calc select:focus { outline: 2px solid var(--gold); outline-offset: 1px; }
.calc .pair { display: flex; gap: 8px; }
.calc .pair input { flex: 1; }
.calc details { border-top: 1px solid var(--line); padding: 14px 0 0; margin-top: 14px; }
.calc summary { cursor: pointer; font-weight: 600; color: var(--ink); }
.calc-strength { color: var(--muted); margin: 6px 0; }
.calc-result { font-size: 20px; margin: 8px 0; }
.calc-result strong { font-family: "Cormorant Garamond", Georgia, serif; font-size: 30px; font-weight: 600; color: var(--gold); }
.calc-hint { color: var(--muted); font-size: 15px; }
.calc-warn { color: var(--amber); font-size: 15px; margin: 6px 0; }
.calc-warn.red { color: var(--bad); }
.calc-bar { height: 12px; border-radius: 6px; background: var(--surface); border: 1px solid var(--line); overflow: hidden; margin: 8px 0 12px;
  background-image: repeating-linear-gradient(90deg, transparent 0 calc(10% - 1px), var(--line) calc(10% - 1px) 10%); }
.calc-bar span { display: block; height: 100%; background: var(--gold); }
@media (max-width: 760px) {
  .lib-top nav a:not(.keep) { display: none; }
  .calc-grid { grid-template-columns: 1fr; }
  .lib-main { padding-top: 28px; }
}
