/* Shared by every Fibrae page: the home page and the legal pages.
   Brand colours and typefaces are Fibrae's own (pistachio on warm stone, Fraunces
   and Inter). The one motif is the thread, the curve with two knots that the app
   draws between cards: it is the hero shape, the round end of every button, the
   mask of every picture and the mark that closes the page. */

:root{
  /* Brand ground and ink */
  --bg:#f2ece3; --sand:#e8e0d3; --mint:#dfe9d0; --mint-2:#cfe0bb;
  --ink:#2b2622; --ink-soft:#5a5149;
  --paper:#fdfbf7;
  /* Brand accent: pistachio fills, deep green for text and solid buttons */
  --pist:#93c572; --deep:#54763a;
  --on-pist:#1c2a12; --on-deep:#fdfbf7;
  --accent-text:#456a2d;
  --btn:#54763a; --btn-ink:#ffffff;
  --shape:#93c572; --knot:#54763a;
  --input-bg:#fdfbf7;

  /* The fields the page changes colour through. Fixed in both themes. */
  --f1-bg:#93c572; --f1-ink:#1c2a12;
  --f2-bg:#54763a; --f2-ink:#fdfbf7;
  --f3-bg:#2b2622; --f3-ink:#a8d98a;

  --serif:"Fraunces",Georgia,serif;
  --sans:"Inter",-apple-system,system-ui,"Segoe UI",sans-serif;

  /* Five type steps. Nothing else is used. */
  --s-xl:clamp(2.5rem,10.4vw,6.25rem);
  --s-l:clamp(2.25rem,8vw,4.5rem);
  --s-m:clamp(1.5rem,5vw,2rem);
  --s-body:1.125rem;
  --s-sm:.875rem;

  --m:clamp(20px,2.4vw,32px);           /* the one pair of page margins */
  --g:clamp(8px,1.2vw,16px);            /* the one gap between neighbours */
  --r:28px;                             /* the one corner for pictures and fields */
  --bar:64px;

  --ease-out:cubic-bezier(.22,1,.36,1);
  --ease-expo:cubic-bezier(.16,1,.3,1);
  --ease-in-out:cubic-bezier(.76,0,.24,1);
  --ease-soft:cubic-bezier(.33,1,.68,1);
}
@media (min-width:900px){
  :root{
    --s-xl:clamp(3.5rem,6.2vw,6.25rem);
    --s-l:clamp(2.75rem,5.4vw,4.5rem);
    --s-m:clamp(1.625rem,2.4vw,2.25rem);
  }
}
@media (prefers-color-scheme:dark){
  :root{
    --bg:#14131a; --sand:#1e1d26; --mint:#222b22; --mint-2:#2a382a;
    --ink:#ece7e0; --ink-soft:#b6aea6;
    --paper:#24222d;
    --pist:#a8d98a; --deep:#a8d98a;
    --on-pist:#14200e; --on-deep:#14200e;
    --accent-text:#a8d98a;
    --btn:#a8d98a; --btn-ink:#14200e;
    --shape:#3b5a2b; --knot:#a8d98a;
    --input-bg:#24222d;
  }
}

*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{
  margin:0;background:var(--bg);color:var(--ink);
  font-family:var(--sans);font-size:var(--s-body);line-height:1.6;
  -webkit-font-smoothing:antialiased;overflow-x:clip;
}
h1,h2,h3{font-family:var(--serif);font-weight:600;margin:0;text-wrap:balance}
p{margin:0}
a{color:var(--accent-text)}
img{display:block;max-width:100%;height:auto}
:where(a,button,input,summary):focus-visible{outline:3px solid var(--pist);outline-offset:3px;border-radius:8px}
::selection{background:var(--pist);color:var(--on-pist)}

.wrap{width:min(100% - var(--m) * 2,1600px);margin-inline:auto}
.skip{position:absolute;left:-9999px;top:0}
.skip:focus{left:var(--m);top:12px;z-index:99;min-height:44px;display:inline-flex;align-items:center;background:var(--paper);color:var(--ink);padding:10px 16px;border-radius:999px}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0} /* taste-skill-ignore: a 1px visually hidden box, not a rule */

/* ------------------------------------------------------------------ bar */
.bar{position:sticky;top:0;z-index:30;background:var(--bg)}
.bar-in{display:flex;align-items:center;justify-content:space-between;gap:var(--g);min-height:var(--bar)}
.brand{
  display:inline-flex;align-items:center;gap:.6rem;min-height:44px;
  color:var(--ink);text-decoration:none;
  font-family:var(--serif);font-weight:600;font-size:1.5rem;letter-spacing:-.02em;
}
.mark{width:34px;height:34px;flex:none;overflow:visible}
.mark path{stroke:currentColor}
.mark circle{fill:var(--pist)}
.bar nav{display:flex;align-items:center;gap:clamp(1rem,2.6vw,2.4rem);margin-inline:auto 1.2rem}
.bar nav a{display:inline-flex;align-items:center;min-height:44px;min-width:44px;justify-content:center;color:var(--ink);text-decoration:none;font-weight:500}
.bar nav a:hover,.bar nav a[aria-current]{color:var(--accent-text);text-decoration:underline;text-underline-offset:.35em;text-decoration-thickness:2px}
@media (max-width:759px){.bar nav{display:none}}

/* --------------------------------------------------------------- buttons */
/* One shape: the round end of a thread. */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:.6rem;
  min-height:48px;padding:0 1.5rem;border:0;border-radius:999px;cursor:pointer;
  background:var(--btn);color:var(--btn-ink);
  font:inherit;font-size:1rem;font-weight:600;text-decoration:none;white-space:nowrap;
  transition:transform 140ms var(--ease-out),background-color 180ms ease;
}
.btn:hover{transform:translateY(-2px)}
.btn:active{transform:scale(.97)}
.btn.sm{min-height:44px;padding:0 1.25rem;font-size:var(--s-sm)}

/* ------------------------------------------------------------ waitlist box */
.pill-form{
  display:flex;align-items:center;gap:6px;width:min(100%,34rem);
  padding:6px;border-radius:999px;background:var(--input-bg);
}
.pill-form input[type=email]{
  flex:1 1 auto;min-width:0;min-height:52px;padding:0 1.1rem;border:0;border-radius:999px;
  background:transparent;color:var(--ink);font:inherit;font-size:1.0625rem;
}
.pill-form input::placeholder{color:var(--ink-soft);opacity:1}
.pill-form input:focus-visible{outline:none}
.pill-form:focus-within{outline:3px solid var(--pist);outline-offset:3px}
.pill-form .btn{min-height:52px;flex:none}
.signup-msg{min-height:1.6em;margin-top:.7rem;font-size:1rem}
.signup-msg[data-state=ok]{color:var(--accent-text);font-weight:600}
.signup-msg[data-state=error]{color:#a8321f}
@media (prefers-color-scheme:dark){.signup-msg[data-state=error]{color:#ff9d8a}}
.trap{position:absolute;left:-9999px;top:auto;width:1px;height:1px;overflow:hidden} /* taste-skill-ignore: a hidden bot trap, not a rule */
@media (max-width:420px){.pill-form .btn{padding:0 1.1rem}}

/* ----------------------------------------------------------------- footer */
/* The mark, built large: each letter is cut out of its own block, the blocks
   differ in height and butt together on one line. */
.foot{background:var(--bg);padding-block:clamp(4rem,9vw,8rem) 2.5rem}
.blocks{
  --bh:clamp(190px,34svh,380px);
  display:flex;align-items:flex-end;gap:4px;height:var(--bh);
}
.blocks span{
  flex:1 1 0;height:calc(var(--bh) * var(--h));
  display:flex;align-items:flex-end;justify-content:center;overflow:hidden;
  border-radius:var(--r) var(--r) 0 0;
  background:var(--c);color:var(--bg);
  font-family:var(--serif);font-weight:600;line-height:.74;
  font-size:calc(var(--bh) * .74);padding-bottom:calc(var(--bh) * .015);
  transform-origin:50% 100%;
}
.blocks span:nth-child(1){--h:.94;--c:var(--pist);color:var(--on-pist)}
.blocks span:nth-child(2){--h:.62;--c:var(--ink);color:var(--bg)}
.blocks span:nth-child(3){--h:1;--c:var(--shape-solid,#54763a);color:#fdfbf7}
.blocks span:nth-child(4){--h:.7;--c:var(--sand);color:var(--ink)}
.blocks span:nth-child(5){--h:.86;--c:var(--pist);color:var(--on-pist)}
.blocks span:nth-child(6){--h:.78;--c:var(--ink);color:var(--bg)}
@media (prefers-color-scheme:dark){
  .blocks span:nth-child(3){--c:#3b5a2b;color:#ece7e0}
}
@media (max-width:640px){
  .blocks{flex-wrap:wrap;height:auto;gap:4px;--bh:clamp(120px,22svh,200px)}
  .blocks span{flex:1 1 calc(33.3% - 4px);height:calc(var(--bh) * var(--h));border-radius:var(--r)}
  .blocks span{font-size:calc(var(--bh) * .74)}
}
.foot-grid{
  display:grid;grid-template-columns:repeat(12,1fr);gap:2.4rem var(--g);
  margin-top:3.5rem;
}
.foot-links{grid-column:1 / span 8;display:grid;grid-template-columns:repeat(4,1fr);gap:1.6rem var(--g)}
.foot-contact{grid-column:9 / span 4}
.foot h3{font-family:var(--sans);font-size:1rem;font-weight:700;margin-bottom:.7rem;text-wrap:wrap}
.foot ul{list-style:none;margin:0;padding:0;display:grid;gap:.1rem}
.foot li a,.foot-contact a{display:inline-flex;align-items:center;min-height:44px;color:var(--ink);text-decoration:none;font-size:1rem}
.foot li a:hover,.foot-contact a:hover{color:var(--accent-text);text-decoration:underline;text-underline-offset:.3em}
.foot-contact p{font-size:1rem;color:var(--ink);margin-bottom:.4rem}
.foot-last{
  margin-top:3rem;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:1rem var(--g);
}
.foot-last p{font-size:1rem;color:var(--ink-soft)}
@media (max-width:899px){
  .foot-links{grid-column:1 / -1;grid-template-columns:repeat(2,1fr)}
  .foot-contact{grid-column:1 / -1}
}

/* ----------------------------------------------------------- reduced motion */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important;scroll-behavior:auto!important}
}
