/* HnH Training — shared styles. No external fonts or scripts; works offline. */
:root {
  --ink: #1d2733;
  --muted: #55606c;
  --paper: #fbf8f3;
  --card: #ffffff;
  --line: #e4ddd1;
  --brand: #1f4e5f;        /* main site: deep teal */
  --brand-dark: #153744;
  --accent: #b9852f;       /* warm brass */
  --tint: #eef4f5;
  --radius: 14px;
}
/* Page themes: set <body class="theme-vi"> or "theme-akiyama" */
body.theme-vi {
  --brand: #14274e; --brand-dark: #0c1a38; --accent: #c9a227; --tint: #eef1f8;
}
body.theme-akiyama {
  --brand: #2f5d3a; --brand-dark: #1f4128; --accent: #b8532f; --tint: #f4efe9;
}

* { box-sizing: border-box; }
html { font-size: 112.5%; scroll-behavior: smooth; }  /* 18px base: easy reading */
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: -apple-system, "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
  line-height: 1.65;
}
h1, h2, h3 { font-family: "New York", Georgia, "Times New Roman", serif; line-height: 1.2; color: var(--brand-dark); }
h1 { font-size: 2.3rem; margin: 0 0 .6rem; }
h2 { font-size: 1.6rem; margin: 2.4rem 0 .6rem; }
h3 { font-size: 1.15rem; margin: 0 0 .3rem; }
p { margin: 0 0 1rem; }
a { color: var(--brand); text-underline-offset: 3px; }
a:hover { color: var(--brand-dark); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 22px; }
.narrow { max-width: 760px; }

/* Header */
.site-header { background: var(--card); border-bottom: 4px solid var(--accent); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 24px; padding-top: 14px; padding-bottom: 14px; }
.brand { text-decoration: none; color: var(--brand-dark); }
.brand strong { display: block; font-family: "New York", Georgia, serif; font-size: 1.5rem; letter-spacing: .01em; }
.brand span { display: block; font-size: .82rem; color: var(--muted); }
nav ul { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 6px; margin: 0; padding: 0; }
nav a { display: block; padding: 8px 14px; border-radius: 999px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .95rem; }
nav a:hover { background: var(--tint); }
nav a[aria-current="page"] { background: var(--brand); color: #fff; }

/* Hero */
.hero { background: linear-gradient(160deg, var(--brand-dark), var(--brand)); color: #fff; padding: 64px 0 56px; }
.hero h1 { color: #fff; font-size: 2.7rem; max-width: 18ch; }
.hero p { font-size: 1.15rem; max-width: 58ch; color: #eef3f5; }
.hero .eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .78rem; color: var(--accent); font-weight: 700; margin-bottom: .8rem; }
.page-head { background: var(--tint); border-bottom: 1px solid var(--line); padding: 44px 0 32px; }
.page-head p { color: var(--muted); font-size: 1.1rem; max-width: 62ch; margin-bottom: 0; }

/* Buttons */
.btn { display: inline-block; padding: 13px 24px; border-radius: 999px; font-weight: 700; text-decoration: none; background: var(--accent); color: #1b1608; border: 2px solid var(--accent); }
.btn:hover { background: #fff; color: var(--brand-dark); }
.btn.ghost { background: transparent; color: #fff; border-color: #fff; }
.btn.ghost:hover { background: #fff; color: var(--brand-dark); }
.btn.solid { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.solid:hover { background: #fff; color: var(--brand); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.4rem; }

/* Cards and grids */
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); margin: 1.2rem 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.card p:last-child { margin-bottom: 0; }
.card.accent { border-top: 5px solid var(--accent); }
.callout { background: var(--tint); border-left: 6px solid var(--accent); border-radius: 8px; padding: 20px 24px; margin: 1.6rem 0; }
.callout h3 { margin-bottom: .4rem; }
.callout p:last-child { margin-bottom: 0; }
.kicker { color: var(--muted); font-size: .92rem; }
ul.clean { padding-left: 1.2rem; margin: 0 0 1rem; }
ul.clean li { margin-bottom: .35rem; }

/* Lists of resources (public and private) */
.res-list { list-style: none; margin: 0; padding: 0; }
.res-list li { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; margin-bottom: 10px; display: flex; flex-wrap: wrap; gap: 4px 16px; justify-content: space-between; align-items: baseline; }
.res-list a { font-weight: 700; }
.res-list .note { color: var(--muted); font-size: .92rem; flex-basis: 100%; }

/* Password gate */
.gate { max-width: 460px; margin: 28px auto; }
.gate label { font-weight: 700; display: block; margin-bottom: 6px; }
.gate input[type=password], .gate input[type=text] { width: 100%; font-size: 1.1rem; padding: 12px 14px; border: 2px solid var(--line); border-radius: 10px; margin-bottom: 14px; }
.gate input:focus { border-color: var(--brand); outline: none; }
.error { color: #a02020; font-weight: 600; min-height: 1.5em; }
.hidden { display: none !important; }

/* Footer */
.site-footer { background: var(--brand-dark); color: #dfe8eb; margin-top: 64px; padding: 36px 0; font-size: .95rem; }
.site-footer a { color: #fff; }
.site-footer .cols { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.site-footer h3 { color: #fff; font-size: 1.05rem; }
.site-footer small { display: block; margin-top: 22px; color: #a9bcc2; }

table.simple { width: 100%; border-collapse: collapse; background: var(--card); border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
table.simple th, table.simple td { text-align: left; padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.simple th { background: var(--tint); font-size: .9rem; }

@media (max-width: 640px) {
  html { font-size: 106%; }
  h1, .hero h1 { font-size: 2rem; }
}
@media print {
  .site-header, .site-footer .btn, .btn-row, .gate { display: none !important; }
  body { background: #fff; font-size: 12pt; }
  .hero, .page-head { background: none; color: #000; padding: 10px 0; }
  .hero h1, .hero p { color: #000; }
  .card, .res-list li { break-inside: avoid; }
  a { color: #000; }
}

/* Client tabs */
.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 26px 0 8px; border-bottom: 2px solid var(--line); }
.tabs a { padding: 10px 20px; border-radius: 10px 10px 0 0; text-decoration: none; font-weight: 700; color: var(--muted); background: var(--tint); border: 1px solid var(--line); border-bottom: none; margin-bottom: -2px; }
.tabs a:hover { color: var(--brand-dark); }
.tabs a[aria-current="page"] { background: var(--card); color: var(--brand-dark); border-top: 4px solid var(--accent); padding-top: 7px; border-bottom: 2px solid var(--card); }
@media print { .tabs { display: none; } }
