/* Clippings design tools: shared look. Medieval print: a woodcut chapbook crossed with an illuminated manuscript.
   Vellum, iron-gall ink, vermilion rubrication (plus a little ultramarine and gold), blackletter titles,
   old printed type for everything else, double-ruled frames, woodcut hatching, manicules. */
@import url('https://fonts.googleapis.com/css2?family=UnifrakturMaguntia&family=IM+Fell+English:ital@0;1&family=IM+Fell+English+SC&display=swap');

:root {
  --paper: #eee2c6;            /* vellum */
  --card: #f4ead3;             /* a fresh leaf */
  --card-2: #e7d8b6;           /* inputs, inner panels */
  --ink: #1d1813;
  --muted: #6a5d4b;
  --rubric: #b2301d;           /* vermilion */
  --blue: #25428a;             /* ultramarine */
  --gold: #b3862c;
  --verdigris: #3c7a5c;
  --bad: #b2301d;
  --edge: 1.5px solid var(--ink);
  --line: var(--edge);
  --fibers: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.6 0.4' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.35 0 0 0 0 0.27 0 0 0 0 0.15 0 0 0 0.16 -0.02'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E");
  --hatch: repeating-linear-gradient(-45deg, rgba(29, 24, 19, 0.16) 0 1px, transparent 1px 5px);
  --blackletter: 'UnifrakturMaguntia', 'Old English Text MT', serif;
  --type: 'IM Fell English', Georgia, serif;
  --caps: 'IM Fell English SC', 'IM Fell English', Georgia, serif;
  /* kept so older pages don't break */
  --display: var(--blackletter);
  --mono: var(--caps);
  --lime: var(--rubric);
}
* { box-sizing: border-box; }
html {
  /* the halftone-printed sheet (textures/halftone-paper.jpg) washed with warm ochre so it reads golden, not grey */
  background: radial-gradient(ellipse at 50% 40%, transparent 55%, rgba(90, 50, 15, 0.25) 100%) fixed,
    linear-gradient(rgba(232, 196, 130, 0.45), rgba(232, 196, 130, 0.45)) fixed,
    url('textures/halftone-paper.jpg') center / cover fixed, #b9a27a;
}
body {
  margin: 0; color: var(--ink);
  font: 18px/1.5 var(--type);
  min-height: 100vh;
}
a { color: inherit; }
::selection { background: var(--rubric); color: var(--card); }

/* ---- top bar ---- */
.top {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 12px 22px 10px; color: var(--card);
  /* oxblood leather binding: the speckled texture under a deep red, with a gold rule */
  background: linear-gradient(rgba(122, 26, 16, 0.84), rgba(122, 26, 16, 0.84)), url('textures/speckled-grey.jpg') center / 900px;
  border-bottom: 3px solid var(--gold); box-shadow: 0 2px 0 var(--ink), 0 5px 10px rgba(60, 25, 10, 0.25);
  position: sticky; top: 0; z-index: 10;
}
.logo { font: 36px/1 var(--blackletter); text-decoration: none; display: inline-flex; align-items: center; gap: 2px; }
.logo .word::first-letter { color: #f0c463; }
.logo .snip { font-family: var(--type); color: #f0c463; font-size: .62em; margin-right: 8px; transform: rotate(-12deg); display: inline-block; transition: transform .15s; }
.logo:hover .snip { transform: rotate(-35deg); }
.logo .spark { display: none; }
.tabs { display: flex; gap: 18px; flex-wrap: wrap; margin-left: auto; }
.tab { font: 18px var(--caps); letter-spacing: .06em; text-decoration: none; padding: 2px 2px; border-bottom: 2px solid transparent; }
.tab:hover { color: #f0c463; }
.tab[aria-current] { color: var(--card); border-bottom-color: #f0c463; }

/* ---- ticker: a printed banner ---- */
.ticker { overflow: hidden; white-space: nowrap; background: var(--fibers), var(--card); color: var(--ink); border-bottom: 1.5px solid var(--ink); box-shadow: 0 3px 8px rgba(20, 12, 6, 0.25); }
.ticker div { display: inline-block; padding: 5px 0 3px; font: 16px var(--caps); letter-spacing: .1em; animation: tick 60s linear infinite; }
.ticker .sep { color: var(--rubric); }
@keyframes tick { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker div { animation: none; } }

main { max-width: 1020px; margin: 0 auto; padding: 36px 16px 80px; }

/* ---- shared bits ---- */
.display { font-family: var(--blackletter); font-weight: 400; }
/* a big printed title: blackletter, rubricated initial */
.title { font: clamp(56px, 10vw, 104px)/1 var(--blackletter); margin: 0; }
.title::first-letter { color: var(--rubric); }
/* a manuscript leaf: heavy rule outside, hairline inside */
.card { background: var(--fibers), var(--card); border: 2px solid var(--ink); outline: 1px solid var(--ink); outline-offset: -7px; padding: 6px; }
.btn {
  font: 19px/1 var(--caps); letter-spacing: .06em; color: var(--card); text-decoration: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 20px 10px; border: 2px solid var(--ink); border-radius: 0; background: var(--ink);
  transition: background .12s, transform .08s;
}
.btn:hover { background: var(--rubric); border-color: var(--rubric); }
.btn:active { transform: translateY(1px); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { color: var(--rubric); border-color: var(--rubric); background: transparent; }
.btn.pink { background: var(--rubric); border-color: var(--rubric); }
.btn.pink:hover { background: var(--ink); border-color: var(--ink); }
.btn:disabled { opacity: .4; cursor: default; }

@media (max-width: 560px) {
  .logo { font-size: 30px; }
  .tabs { margin-left: 0; }
}

/* phones: the top bar stays one compact strip -- the logo, then the five tools in one row you can swipe sideways --
   rather than wrapping into a tall red block */
@media (max-width: 560px) {
  .top { padding: 8px 14px 6px; gap: 4px 14px; }
  .logo { font-size: 26px; }
  .tabs { width: 100%; flex-wrap: nowrap; gap: 16px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; padding-bottom: 2px; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab { font-size: 15px; white-space: nowrap; flex: none; }
}
