/* =====================================================================
   Neuro Different · Companion Toolkit design system v2 · "MCM"
   Matches the book cover: cream ground, charcoal ink, mustard / teal /
   terracotta accents. Jost (the ordered, geometric world) with a brush
   script (the mind that won't sit in the box) breaking through it.
   Single source of truth. Every tool links this, then adds its own CSS.
   (Dogger is intentionally NOT used here — license pending, not public-hosted.)
   ===================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Caveat:wght@400;700&family=Permanent+Marker&family=EB+Garamond:ital@0;1&display=swap');

:root{
  /* ---- palette (the cover) ---- */
  --paper:#f1e7ce;        /* cream ground */
  --paper-2:#ece0c0;      /* deeper cream: bands, fills */
  --ink:#262320;          /* charcoal, never pure black */
  --ink-soft:#5f574b;     /* muted ink for secondary text */
  --muted:#e7dcc0;        /* old paper */
  --red:#c75b39;          /* terracotta — primary accent */
  --blue:#2d5da1;         /* cover blue */
  --teal:#2e7d78;         /* teal */
  --green:#2e7d78;        /* legacy alias (teal) */
  --yellow:#e0a52b;       /* mustard */
  --postit:#fbe8bd;       /* mustard tint */
  --white:#fffdf8;        /* warm card white */
  /* ---- shape: clean MCM, a hint of hand ---- */
  --wobbly:12px;
  --wobbly-md:10px;
  --wobbly-sm:7px;
  --wobbly-pill:999px;
  /* ---- shadows: editorial print offset, used with intent ---- */
  --shadow:4px 4px 0 0 var(--ink);
  --shadow-lg:7px 7px 0 0 var(--ink);
  --shadow-soft:0 3px 12px rgba(38,35,32,0.10);
  /* ---- type ---- */
  --disp:'Jost',system-ui,sans-serif;   /* geometric display (bold) = order */
  --head:'Jost',system-ui,sans-serif;   /* headings, labels */
  --body:'Jost',system-ui,sans-serif;   /* UI + body */
  --script:'Caveat',cursive;            /* handwriting = margin notes */
  --marker:'Permanent Marker',cursive;  /* dry-brush marker = the cover's headline energy */
  --serif:'EB Garamond',Georgia,serif;  /* long reading passages */
}

*{box-sizing:border-box; margin:0; padding:0}
html{-webkit-text-size-adjust:100%}
body{
  font-family:var(--body); color:var(--ink); background:var(--paper);
  line-height:1.55; font-size:1.12rem; padding:0 0 80px;
  -webkit-font-smoothing:antialiased;
}
/* quiet cover-echo motif (sun + wave + escaping scribble), one corner */
body::after{content:""; position:fixed; right:-30px; bottom:-30px; width:190px; height:190px; z-index:-1; opacity:0.5; pointer-events:none;
  background-repeat:no-repeat; background-size:contain;
  background-image:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'><circle cx='150' cy='52' r='30' fill='%23E0A52B'/><path d='M12 150 q 30 -22 60 0 t 60 0 t 60 0' fill='none' stroke='%232E7D78' stroke-width='6' stroke-linecap='round'/><path d='M18 96 C 58 60 92 130 130 100 S 192 70 184 122' fill='none' stroke='%23C75B39' stroke-width='6' stroke-linecap='round' stroke-linejoin='round'/></svg>");}
@media(max-width:900px){ body::after{display:none} }

/* ---- type helpers ---- */
.t-disp{font-family:var(--disp); font-weight:700; letter-spacing:-0.015em; line-height:0.95}
.t-head{font-family:var(--head); font-weight:600; line-height:1.15}
.t-label{font-family:var(--head); font-weight:600; text-transform:uppercase; letter-spacing:0.16em; font-size:0.82rem}
.t-script{font-family:var(--script); font-weight:700; line-height:1}
.t-serif{font-family:var(--serif)}

/* ---- buttons: ONE strong primary (filled charcoal), secondary is subordinate ---- */
.btn{font-family:var(--head); font-weight:500; font-size:1.05rem; background:var(--ink); color:var(--paper);
  border:2px solid var(--ink); border-radius:var(--wobbly-pill); box-shadow:var(--shadow);
  padding:12px 26px; min-height:48px; cursor:pointer; display:inline-flex; align-items:center; gap:8px;
  text-decoration:none; transition:transform .1s ease, box-shadow .1s ease, background .1s ease, color .1s ease}
.btn:hover{background:var(--red); border-color:var(--red); color:#fff; box-shadow:2px 2px 0 0 var(--ink); transform:translate(2px,2px)}
.btn:active{box-shadow:0 0 0 0 var(--ink); transform:translate(4px,4px)}
.btn:focus-visible{outline:3px solid var(--blue); outline-offset:3px}
.btn.secondary{background:transparent; color:var(--ink); box-shadow:none; border-color:var(--ink)}
.btn.secondary:hover{background:var(--ink); color:var(--paper); transform:none}

/* ---- cards ---- */
.card{background:var(--white); border:1.5px solid var(--ink); border-radius:var(--wobbly-md);
  box-shadow:var(--shadow-soft); padding:24px 26px; position:relative}
.card.pop{box-shadow:var(--shadow)}
.card.postit{background:var(--postit); border-color:var(--ink)}
/* tape strip + thumbtack: the scrapbook/pinned-photo motif (used with intent, sparingly) */
.tape::before{content:""; position:absolute; top:-11px; left:50%; transform:translateX(-50%) rotate(-3deg);
  width:98px; height:24px; background:rgba(224,165,43,0.26); border:1px dashed rgba(38,35,32,0.28); pointer-events:none}
.tack::before{content:""; position:absolute; top:-9px; left:50%; transform:translateX(-50%);
  width:16px; height:16px; border-radius:50%; background:var(--red);
  box-shadow:inset -3px -3px 0 rgba(0,0,0,0.22); pointer-events:none}

/* ---- inputs ---- */
.field{font-family:var(--body); font-size:1.1rem; background:var(--white); color:var(--ink);
  border:1.5px solid var(--ink); border-radius:var(--wobbly-sm); padding:12px 15px; width:100%; min-height:48px}
.field::placeholder{color:rgba(38,35,32,0.42)}
.field:focus{outline:none; border-color:var(--teal); box-shadow:0 0 0 3px rgba(46,125,120,0.22)}

/* ---- accent link underline ---- */
.wavy{text-decoration:none; color:var(--red);
  background-image:linear-gradient(var(--red),var(--red)); background-position:0 100%;
  background-size:100% 2px; background-repeat:no-repeat; padding-bottom:2px}
.wavy:hover{background-size:100% 3px}

/* ---- dashed divider ---- */
.dash{border:none; border-top:1.5px dashed rgba(38,35,32,0.38); margin:26px 0}

/* ---- subtle grid-break rotations (the mind nudging the box) ---- */
.rot-1{transform:rotate(-0.6deg)} .rot1{transform:rotate(0.6deg)}
.rot-2{transform:rotate(-1deg)}   .rot2{transform:rotate(1deg)}
.jiggle{transition:transform .12s ease}
.jiggle:hover{transform:rotate(-0.8deg) translateY(-2px)}

/* ---- staggered reveal ---- */
.rise{opacity:0; transform:translateY(12px); animation:t-rise .55s cubic-bezier(.2,.8,.2,1) forwards}
@keyframes t-rise{to{opacity:1; transform:none}}
.d1{animation-delay:.05s}.d2{animation-delay:.12s}.d3{animation-delay:.19s}.d4{animation-delay:.26s}.d5{animation-delay:.33s}

/* ---- cover-faithful tool header (shared with the hub) ----
   Oversized dry-brush marker title + a hand-torn terracotta underscribble,
   so every tool page opens with the same energy as the cover and the hub.
   A class, so it overrides each tool's local element-level h1 rule. */
.tk-h1{font-family:var(--marker); font-weight:400; color:var(--ink);
  font-size:clamp(2.5rem,7.6vw,4.7rem); line-height:0.96; letter-spacing:0.005em;
  margin-bottom:10px; text-shadow:3px 3px 0 rgba(199,91,57,0.20)}
.tk-scribble{display:block; height:15px; width:280px; max-width:70%; margin:2px 0 20px 2px; color:var(--red)}
@media(max-width:560px){ .tk-scribble{max-width:84%} }

/* ---- motion sensitivity (this audience especially) ---- */
@media (prefers-reduced-motion: reduce){
  *{transition:none !important; animation:none !important}
  .rise{opacity:1; transform:none}
  .btn:hover,.btn:active,.jiggle:hover{transform:none}
}
