/* Deck library — shared by the internal shelf (/decks) and the per-client
   libraries under /library. Cards redraw each deck's own cover in CSS rather
   than using screenshots, so a card can never fall out of step with its deck. */

:root{
  --bg:#07080f; --card:#10122a; --card2:#0c0e20;
  --line:#23264e; --line2:#2f3366;
  --purple:#7b7ef2; --pdark:#5a5dc7; --plight:#a1a3ff; --cyan:#4fd1f2; --green:#7ed957;
  --text:#e8e9f7; --mute:#8c92bd; --dim:#b9bed8;
  --grad:linear-gradient(115deg,var(--cyan),var(--purple) 45%,var(--plight) 75%,#8a68e8);
  --ease:cubic-bezier(.22,1,.36,1);
}

*{box-sizing:border-box}
body{margin:0;background:var(--bg);color:var(--text);line-height:1.5;
  font-family:"Google Sans",-apple-system,sans-serif;-webkit-font-smoothing:antialiased}
a{color:var(--plight);text-decoration:none}
a:hover{color:#fff}
/* bottom padding, not a margin on the last child: a trailing margin
   collapses out through main and gives no space at all at the page end */
.wrap{max-width:1280px;margin:0 auto;padding:0 28px 64px}

/* ---------- header ----------
   The logo sits on the same line as the page title, right-hand side, rather
   than in a band of its own above. */
header.dk{padding:34px 0 6px}
header.dk .brand{height:52px;display:block}

.hero{padding:64px 0 6px}
.hero-line{display:flex;align-items:center;justify-content:space-between;gap:48px}
/* symmetric margins, so centring the flex row centres the text on the logo
   rather than on an off-centre margin box */
.hero .hero-line h1{margin:15px 0}
.hero-brand{flex:0 0 auto;display:block;line-height:0}
.hero-brand img{height:58px;width:auto;display:block;transition:opacity .2s}
.hero-brand:hover img{opacity:.82}
.hero .eyebrow{display:inline-block;font-size:11px;font-weight:700;letter-spacing:.22em;
  text-transform:uppercase;color:var(--plight);border:1px solid rgba(123,126,242,.35);
  background:rgba(123,126,242,.08);padding:5px 12px;border-radius:20px}
.hero h1{font-size:2.6rem;margin:18px 0 12px;letter-spacing:-.015em;font-weight:500}
.hero p{color:var(--mute);max-width:66ch;margin:0}

/* ---------- controls ---------- */
/* solid, not a fade — cards scrolling under a translucent bar read as a bug */
.controls{display:flex;align-items:center;gap:14px;flex-wrap:wrap;margin:30px 0 6px;
  position:sticky;top:0;z-index:20;background:var(--bg);padding:16px 0;
  box-shadow:0 1px 0 var(--line),0 14px 22px -18px rgba(0,0,0,.9)}
.search{flex:1 1 260px;max-width:360px;position:relative}
.search input{width:100%;background:var(--card2);border:1px solid var(--line);color:var(--text);
  border-radius:999px;padding:11px 18px 11px 42px;font:inherit;font-size:.88rem;outline:none;
  transition:border-color .2s}
.search input:focus{border-color:var(--purple)}
.search svg{position:absolute;left:15px;top:50%;transform:translateY(-50%);width:17px;height:17px;
  stroke:var(--mute);fill:none;stroke-width:2}
.count{margin-left:auto;font-size:.74rem;letter-spacing:.08em;color:var(--mute);white-space:nowrap}

/* ---------- stage sections ---------- */
.stage{padding:26px 0 0;scroll-margin-top:90px}
.stage > h2{font-size:.78rem;font-weight:700;letter-spacing:.2em;text-transform:uppercase;
  margin:0 0 4px;display:flex;align-items:center;gap:11px;color:var(--acc,var(--purple))}
.stage > h2 .dot{width:8px;height:8px;border-radius:50%;background:var(--acc,var(--purple));
  box-shadow:0 0 10px var(--acc,var(--purple))}
.stage > .sub{color:var(--mute);font-size:.86rem;margin:0 0 18px;padding-left:19px}

/* ---------- grid ---------- */
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(290px,1fr));gap:20px}
.grid.feat{grid-template-columns:repeat(auto-fill,minmax(360px,1fr))}

/* The grid item stays put and .dc-inner does the moving. Lifting the hovered
   element itself slid it out from under the cursor along the bottom edge, so
   it un-hovered, dropped back, and re-hovered — visible as a stutter. */
.dcard{position:relative;display:flex}
.dc-inner{display:flex;flex-direction:column;width:100%;
  background:linear-gradient(170deg,var(--card),var(--card2));
  border:1px solid var(--line);border-radius:16px;overflow:hidden;color:inherit;
  transition:border-color .25s,transform .25s var(--ease),box-shadow .25s}
.dcard:hover .dc-inner,.dcard:focus-within .dc-inner{
  border-color:var(--acc,var(--purple));transform:translateY(-4px);
  box-shadow:0 22px 50px rgba(0,0,0,.45)}

/* The hero card runs the full width of the grid, cover beside the copy rather
   than above it, so the way in to the set is obvious. */
.dcard.wide{grid-column:1/-1}
.dcard.wide .dc-inner{flex-direction:row;align-items:stretch}
.dcard.wide .dc-cover{flex:0 0 44%;aspect-ratio:auto;min-height:250px;
  border-bottom:0;border-right:1px solid var(--line)}
.dcard.wide .dc-panel{top:14%;bottom:18%;width:54%;padding:20px 24px;border-radius:0 14px 14px 0}
.dcard.wide .dc-t{font-size:1.5rem;-webkit-line-clamp:4}
.dcard.wide .dc-rule{margin:14px 0 10px}
.dcard.wide .dc-k{font-size:.66rem}
.dcard.wide .dc-motif{width:26%}
.dcard.wide .dc-meta{padding:34px 40px;justify-content:center}
.dcard.wide .dc-meta h3{font-size:1.7rem;font-weight:500;letter-spacing:-.015em;margin-bottom:12px}
.dcard.wide .dc-meta p{font-size:.98rem;-webkit-line-clamp:4;max-width:64ch}
.dcard.wide .dc-foot{margin-top:22px;padding-top:16px;font-size:.76rem}

/* ---------- built by saasyn ---------- */
/* last thing on the page now, so it takes its top gap from the closing
   block's own bottom margin and carries its own space underneath */
/* ---------- the saasyn credit ----------
   Wears saasyn's palette rather than Optronix's, and carries their actual
   hero background: js/syn-flow.js runs the same shader that paints
   saasyn.com, in a canvas clipped to this strip. The gradients below are
   what shows before WebGL is up, and all that shows if it never is. */
.builtby{position:relative;overflow:hidden;isolation:isolate;
  display:flex;align-items:center;gap:20px;flex-wrap:wrap;margin:0;
  padding:20px 26px;border:1px solid rgba(34,211,238,.26);border-radius:16px;
  background-color:#070a16;text-decoration:none;
  transition:border-color .25s,box-shadow .25s}
.builtby::before{content:"";position:absolute;inset:-30%;z-index:0;pointer-events:none;
  background:
    radial-gradient(ellipse 42% 185% at  9% 38%, rgba(14,165,233,.42), transparent 70%),
    radial-gradient(ellipse 36% 175% at 45% 62%, rgba(34,211,238,.28), transparent 70%),
    radial-gradient(ellipse 44% 190% at 88% 44%, rgba(124,92,255,.40), transparent 70%);
  filter:blur(26px)}
.bb-flow{position:absolute;inset:0;z-index:1;display:block;
  width:100%;height:100%;border-radius:inherit;pointer-events:none}
/* the hero has a veil over it for the same reason: the flow runs bright in
   places and there is white text sitting on this */
.builtby::after{content:"";position:absolute;inset:0;z-index:2;pointer-events:none;
  border-radius:inherit;
  background:linear-gradient(90deg,rgba(5,6,14,.50),rgba(5,6,14,.38) 46%,rgba(5,6,14,.46))}
.builtby > span{position:relative;z-index:3}

a.builtby:hover{border-color:rgba(34,211,238,.55);
  box-shadow:0 0 0 1px rgba(34,211,238,.14),0 18px 44px rgba(14,165,233,.13)}
.builtby .bb-lab{font-size:.82rem;font-weight:700;color:var(--text);white-space:nowrap}
/* The wordmark sits inside the label rather than beside it as a flex item,
   so "Built in-house by saasyn" is one phrase on one baseline. As a flex
   item it was centred against a box whose height moves when the note wraps,
   which is why a fixed nudge never held.

   Two numbers, both off the tight file's viewBox (708 units tall, of which
   the 508-unit x-band is the visible lowercase and the rest is the y's
   descender):
   - height 15px puts the x-height at 10.8px against the label's 7px, so the
     wordmark reads as larger than its caption without towering over it. At
     19px it was twice the label's x-height and nothing would make it sit on
     a line with it.
   - margin-bottom -4.24px is that descender (15 x 200/708). vertical-align
     baseline drops the image's bottom margin edge on the text baseline, so
     without this the y's tail sits on the line and the word floats above it. */
.builtby .bb-logo{height:15px;width:auto;vertical-align:baseline;
  margin:0 0 -4.24px 9px;filter:invert(1);opacity:.95}
.builtby .bb-note{font-size:.82rem;color:#d7e0f0;flex:1 1 260px}
.builtby .bb-go{font-size:.78rem;font-weight:700;color:#5fe3f7;white-space:nowrap;
  opacity:0;transform:translateX(-6px);transition:opacity .2s,transform .2s var(--ease)}
a.builtby:hover .bb-go{opacity:1;transform:none}
/* nothing hovers on a phone, so the link would sit there invisible and
   leave a blank row under the stacked text */
@media (hover:none){.builtby .bb-go{opacity:1;transform:none}}

/* the deck's cover, redrawn */
.dc-cover{position:relative;aspect-ratio:16/9;background:#07080f;overflow:hidden;flex:0 0 auto;
  border-bottom:1px solid var(--line)}
.dc-cover::after{content:"";position:absolute;inset:0;
  background:radial-gradient(circle at 78% 42%,rgba(123,126,242,.20),transparent 58%)}
.dc-panel{position:absolute;left:0;top:11%;bottom:16%;width:57%;border-radius:0 10px 10px 0;
  padding:14px 16px;display:flex;flex-direction:column;
  background:linear-gradient(160deg,#5a5dc7,#4a4db4 55%,#3f4299);
  box-shadow:0 10px 30px rgba(0,0,0,.45);z-index:2}
.dc-t{font-size:.94rem;font-weight:500;line-height:1.15;color:#fff;letter-spacing:-.01em;
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.dc-rule{display:block;height:1px;background:rgba(255,255,255,.35);margin:9px 0 7px}
.dc-k{font-size:.56rem;font-weight:400;letter-spacing:.1em;text-transform:uppercase;
  color:rgba(255,255,255,.66);margin-top:auto}
/* ---------- card motifs ----------
   Line art in the card's stage colour, sitting where the mark used to. Static
   at rest; the moving parts only run on hover, because twenty-five animated
   SVGs in one grid is both noisy and a real cost. */
.dc-motif{position:absolute;right:6%;top:50%;transform:translateY(-50%);
  width:31%;height:auto;z-index:1;color:var(--acc,var(--purple));overflow:visible}
.dc-motif [class^="m-"],.dc-motif [class*=" m-"]{
  stroke:currentColor;fill:none;stroke-width:3;stroke-linecap:round;stroke-linejoin:round;
  vector-effect:non-scaling-stroke}
.dc-motif .m-u,.dc-motif .m-port,.dc-motif .m-grid{opacity:.4;stroke-width:2.4}
.dc-motif .m-grid{opacity:.22}
.dc-motif .m-track{opacity:.3;stroke-dasharray:4 5}
.dc-motif .m-dot,.dc-motif .m-node,.dc-motif .m-pin,.dc-motif .m-fill,
.dc-motif .m-dev,.dc-motif .m-run,.dc-motif .m-wheel{fill:currentColor;stroke:none}
.dc-motif .m-fill,.dc-motif .m-dev{opacity:.55}
.dc-motif .m-run{opacity:0}
.dc-motif .m-ring{opacity:.22}
/* the dot that runs the lifecycle ring, and the tail behind it. Three arcs at
   falling opacity rather than a gradient — a gradient cannot follow a curved
   stroke. */
.dc-motif .m-head{fill:var(--green);stroke:none;
  filter:drop-shadow(0 0 5px rgba(126,217,87,.85))}
.dc-motif .m-tail{stroke:var(--green);fill:none;stroke-width:4;stroke-linecap:round}
.dc-motif .t1{opacity:.7} .dc-motif .t2{opacity:.4} .dc-motif .t3{opacity:.18}
/* runs all the time rather than on hover: one card, and the point of it is
   that the lifecycle does not stop */
.dc-motif .m-orbit{transform-box:view-box;transform-origin:60px 60px;
  animation:mOrbit 11s linear infinite}
@keyframes mOrbit{to{transform:rotate(360deg)}}
.dc-motif .m-hub{opacity:.5}
.dc-motif .m-node{opacity:.7}
.dc-motif .m-tick{stroke-width:4}
.dc-motif .m-out,.dc-motif .m-site{opacity:.5}
.dc-motif .m-road{opacity:.3}
.dc-motif .m-wave{opacity:.5}
.dc-motif .m-stamp,.dc-motif .m-lens{opacity:.65}
.dc-motif .m-plot{opacity:.45}
.dc-motif .m-ask{stroke-width:3.4}
.dc-motif .m-bar{fill:currentColor;stroke:none;opacity:.5}
.dc-motif .m-row{opacity:.55}
.dc-motif .m-flow{opacity:.5;stroke-dasharray:5 6}
.dc-motif .m-tool,.dc-motif .m-hand{stroke-width:3.4}

/* At rest the card shows the drawing; pointing at it sets it going. On touch
   there is no hover, so the page adds .play as a card scrolls into view — the
   same rules, a different trigger. */
:is(.dcard:hover,.dcard.play) .dc-motif .m-run{opacity:1}
:is(.dcard:hover,.dcard.play) .dc-motif .m-sweep{animation:mSweep 2.6s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-spin{animation:mSpin 4s linear infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-fill{animation:mFill 1.8s ease-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .f2{animation-delay:.15s}
:is(.dcard:hover,.dcard.play) .dc-motif .f3{animation-delay:.3s}
:is(.dcard:hover,.dcard.play) .dc-motif .f4{animation-delay:.45s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-wave{animation:mWave 2s ease-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .w2{animation-delay:.25s}
:is(.dcard:hover,.dcard.play) .dc-motif .w3{animation-delay:.5s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-pin{animation:mPin 2.1s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .p2{animation-delay:.35s}
:is(.dcard:hover,.dcard.play) .dc-motif .p3{animation-delay:.7s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-site{animation:mSite 2.4s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .s2{animation-delay:.3s}
:is(.dcard:hover,.dcard.play) .dc-motif .s3{animation-delay:.6s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-draw{animation:mDraw 2.6s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .b{animation-delay:.3s}
:is(.dcard:hover,.dcard.play) .dc-motif .c{animation-delay:.6s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-cable{animation:mCable 2.4s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-bolt{animation:mBolt 1.4s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .pulse{animation:mPulse 1.6s ease-out infinite;opacity:1}
:is(.dcard:hover,.dcard.play) .dc-motif .m-wheel{animation:mRoll 1.2s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-tick{animation:mTick 2.2s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-dev{animation:mDev 2.2s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .d2{animation-delay:.4s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-bar{animation:mBar 2.2s ease-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .b2{animation-delay:.2s}
:is(.dcard:hover,.dcard.play) .dc-motif .b3{animation-delay:.4s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-row{animation:mFill 2s ease-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .r2{animation-delay:.2s}
:is(.dcard:hover,.dcard.play) .dc-motif .r3{animation-delay:.4s}
:is(.dcard:hover,.dcard.play) .dc-motif .m-flow{animation:mFlow 1.6s linear infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-turn{animation:mTurn 2.4s ease-in-out infinite}
:is(.dcard:hover,.dcard.play) .dc-motif .m-ask{animation:mTick 2s ease-in-out infinite}

@keyframes mSweep{0%,100%{transform:translate(0,0)}50%{transform:translate(-30px,14px)}}
@keyframes mSpin{to{transform:rotate(360deg)}}
@keyframes mFill{0%{opacity:.12}40%{opacity:.85}100%{opacity:.12}}
@keyframes mWave{0%{opacity:0;transform:translateY(6px)}30%{opacity:.7}100%{opacity:0;transform:translateY(-4px)}}
@keyframes mPin{0%,100%{transform:translateY(0)}50%{transform:translateY(-5px)}}
@keyframes mSite{0%,100%{opacity:.35}50%{opacity:.95}}
@keyframes mDraw{0%{opacity:.15}45%{opacity:1}100%{opacity:.15}}
@keyframes mCable{0%,100%{opacity:.35}50%{opacity:1}}
@keyframes mBolt{0%,100%{opacity:.3}50%{opacity:1}}
@keyframes mPulse{0%{r:4;opacity:.9}100%{r:16;opacity:0}}
@keyframes mRoll{0%,100%{transform:translateY(0)}50%{transform:translateY(-2px)}}
@keyframes mTick{0%,100%{opacity:.35}50%{opacity:1}}
@keyframes mBar{0%{transform:scaleX(.25);opacity:.2}60%{transform:scaleX(1);opacity:.75}100%{transform:scaleX(1);opacity:.3}}
@keyframes mFlow{to{stroke-dashoffset:-22}}
@keyframes mTurn{0%,100%{transform:rotate(0)}50%{transform:rotate(-16deg)}}
@keyframes mDev{0%,100%{transform:translateX(0);opacity:.55}50%{transform:translateX(6px);opacity:1}}

/* transform-based motion needs an origin inside the icon's own box */
.dc-motif .m-spin,.dc-motif .m-sweep,.dc-motif .m-pin,.dc-motif .m-wheel,
.dc-motif .m-site,.dc-motif .m-dev,.dc-motif .m-wave,.dc-motif .m-row{transform-origin:60px 60px;transform-box:fill-box}
.dc-motif .m-bar{transform-origin:left center;transform-box:fill-box}
.dc-motif .m-turn{transform-origin:96px 50px;transform-box:view-box}
.dc-motif .m-spin{transform-origin:center}

@media (prefers-reduced-motion:reduce){
  .dc-motif .m-orbit{animation:none}
  :is(.dcard:hover,.dcard.play) .dc-motif *{animation:none!important}
  :is(.dcard:hover,.dcard.play) .dc-motif .m-run{opacity:1}
}
.dc-badge{position:absolute;right:9px;top:9px;z-index:3;font-size:.55rem;font-weight:700;
  letter-spacing:.12em;text-transform:uppercase;padding:4px 9px;border-radius:999px;
  background:rgba(7,8,15,.72);border:1px solid var(--line2);color:var(--mute);backdrop-filter:blur(4px)}
.dc-badge.tool{color:var(--cyan);border-color:rgba(79,209,242,.4)}
.dc-badge.internal{color:#e8b34a;border-color:rgba(232,179,74,.45)}
.dc-badge.retired{color:var(--mute)}

.dc-meta{padding:17px 19px 19px;display:flex;flex-direction:column;flex:1 1 auto}
.dc-meta h3{margin:0 0 8px;font-size:1rem;font-weight:700;letter-spacing:-.005em}
.dc-meta p{margin:0;font-size:.84rem;color:var(--dim);line-height:1.5;
  display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.dc-foot{display:flex;align-items:center;gap:14px;margin-top:15px;padding-top:13px;
  border-top:1px solid var(--line);font-size:.7rem;letter-spacing:.07em;color:var(--mute)}
.dc-foot .sep{width:3px;height:3px;border-radius:50%;background:var(--line2)}

/* ---------- card actions ----------
   Open stretches over the whole card, so anywhere on it opens the deck; Share
   sits above that layer so it stays clickable in its own right. */
.dc-actions{display:flex;align-items:center;gap:10px;margin-top:16px}
.dc-open,.dc-share{display:inline-flex;align-items:center;justify-content:center;gap:8px;
  font-family:inherit;font-size:.78rem;font-weight:700;letter-spacing:.01em;
  border-radius:999px;padding:10px 18px;cursor:pointer;text-decoration:none;
  transition:background .2s,border-color .2s,color .2s,filter .2s}
.dc-open{background:var(--acc,var(--purple));color:#fff;border:1px solid transparent}
.dc-open:hover{filter:brightness(1.14);color:#fff}
.dc-open svg{width:13px;height:13px;stroke:currentColor;fill:none;stroke-width:2.4;
  stroke-linecap:round;stroke-linejoin:round}

.dc-share{background:transparent;color:var(--dim);border:1px solid var(--line2)}
.dc-share:hover{border-color:var(--acc,var(--purple));color:#fff}
.dc-share svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:2;
  stroke-linecap:round;stroke-linejoin:round;transition:transform .3s var(--ease)}
.dc-share.done{border-color:var(--green);color:var(--green)}
.dc-share.done svg{transform:scale(1.15)}
.dcard.wide .dc-actions{margin-top:22px}

.empty{color:var(--mute);font-size:.9rem;padding:40px 0}

#toast{position:fixed;bottom:30px;left:50%;z-index:60;display:flex;align-items:center;gap:10px;
  background:#14173a;border:1px solid var(--purple);color:#fff;font-weight:600;font-size:.85rem;
  padding:12px 22px;border-radius:999px;box-shadow:0 18px 44px rgba(0,0,0,.6);
  pointer-events:none;opacity:0;transform:translate(-50%,14px) scale(.96);
  transition:opacity .28s var(--ease),transform .28s var(--ease)}
#toast.on{opacity:1;transform:translate(-50%,0) scale(1)}
#toast.bad{border-color:#ff8a8a}
#toast svg{width:17px;height:17px;stroke:var(--green);fill:none;stroke-width:2.8;
  stroke-linecap:round;stroke-linejoin:round;
  stroke-dasharray:26;stroke-dashoffset:26}
#toast.on svg{animation:toastTick .45s var(--ease) .1s forwards}
@keyframes toastTick{to{stroke-dashoffset:0}}
@media (prefers-reduced-motion:reduce){
  #toast{transition:opacity .2s}
  #toast.on svg{animation:none;stroke-dashoffset:0}
}

.note{color:var(--mute);font-size:.8rem;margin:46px 0 60px;padding-top:20px;
  border-top:1px solid var(--line)}
.note code{background:#151833;border:1px solid var(--line);border-radius:5px;padding:1px 6px;
  font-size:.94em}

@media (max-width:820px){
  .dcard.wide .dc-inner{flex-direction:column}
  .dcard.wide .dc-cover{flex:0 0 auto;aspect-ratio:16/9;min-height:0;
    border-right:0;border-bottom:1px solid var(--line)}
  .dcard.wide .dc-panel{width:57%;padding:14px 16px}
  .dcard.wide .dc-t{font-size:1rem}
  .dcard.wide .dc-motif{width:31%}
  .dcard.wide .dc-meta{padding:17px 19px 19px}
  .dcard.wide .dc-meta h3{font-size:1.15rem}
  .dcard.wide .dc-meta p{font-size:.86rem}
}
@media (max-width:760px){
  /* the title needs the full width on a narrow screen, so the logo goes above it */
  .hero{padding-top:32px}
  .hero-line{flex-direction:column-reverse;align-items:flex-start;gap:0}
  .hero-brand{margin:14px 0 4px}
  .hero-brand img{height:46px}
}
@media (max-width:640px){
  .hero h1{font-size:2rem}
  .grid,.grid.feat{grid-template-columns:1fr}
  .controls{position:static}
  .count{margin-left:0;width:100%}
}

/* ---------- public page closing ---------- */
.closing{margin:64px 0 80px;padding-top:34px;border-top:1px solid var(--line)}
.closing h2{margin:0 0 8px;font-size:1.5rem;font-weight:500;letter-spacing:-.01em}
.closing p{margin:0 0 22px;color:var(--mute)}
.closing .cta{display:inline-flex;align-items:center;gap:9px;background:var(--purple);color:#fff;
  font-size:.86rem;font-weight:700;border-radius:999px;padding:12px 26px;transition:filter .2s}
.closing .cta:hover{filter:brightness(1.12);color:#fff}

/* ---------- admin ---------- */
.arow{display:flex;align-items:center;gap:16px;background:linear-gradient(170deg,var(--card),var(--card2));
  border:1px solid var(--line);border-radius:12px;padding:12px 16px;margin-bottom:8px;
  transition:border-color .2s,opacity .2s,background .2s}
.arow.off{opacity:.42}
.arow.drag{border-color:var(--purple);background:#161a3a}
.arow.over{border-top:2px solid var(--purple)}
.a-grip{cursor:grab;color:var(--mute);flex:0 0 auto;display:grid;place-items:center;width:22px}
.a-grip svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2.6;stroke-linecap:round}
.a-grip:active{cursor:grabbing}
.a-num{flex:0 0 30px;font-size:.72rem;font-weight:700;color:var(--mute);letter-spacing:.06em}
.a-swatch{flex:0 0 auto;width:8px;height:8px;border-radius:50%;background:var(--acc,var(--purple))}
.a-name{font-size:.94rem;font-weight:500}
.a-name small{display:block;font-size:.7rem;color:var(--mute);font-weight:400;letter-spacing:.04em;margin-top:2px}
.a-tag{font-size:.58rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:#e8b34a;
  border:1px solid rgba(232,179,74,.45);border-radius:999px;padding:3px 9px}
.a-right{margin-left:auto;display:flex;align-items:center;gap:10px}
.a-move{display:flex;flex-direction:column;gap:2px}
.a-move button{background:transparent;border:1px solid var(--line);color:var(--mute);border-radius:6px;
  width:24px;height:17px;display:grid;place-items:center;cursor:pointer;padding:0}
.a-move button:hover{border-color:var(--purple);color:#fff}
.a-move svg{width:11px;height:11px;stroke:currentColor;fill:none;stroke-width:2.4}
.a-view{font-size:.72rem;color:var(--mute);border:1px solid var(--line);border-radius:999px;padding:6px 13px}
.a-view:hover{border-color:var(--purple);color:#fff}
.sw{position:relative;width:46px;height:26px;flex:0 0 auto;cursor:pointer}
.sw input{position:absolute;opacity:0;width:100%;height:100%;margin:0;cursor:pointer}
.sw i{position:absolute;inset:0;border-radius:999px;background:#22254a;border:1px solid var(--line2);
  transition:background .2s,border-color .2s}
.sw i::after{content:"";position:absolute;left:3px;top:3px;width:18px;height:18px;border-radius:50%;
  background:var(--mute);transition:transform .2s var(--ease),background .2s}
.sw input:checked + i{background:rgba(123,126,242,.3);border-color:var(--purple)}
.sw input:checked + i::after{transform:translateX(20px);background:var(--purple)}

.abar{position:sticky;bottom:0;z-index:30;display:flex;align-items:center;gap:16px;flex-wrap:wrap;
  background:var(--bg);border-top:1px solid var(--line);padding:16px 0;margin-top:26px}
.abar .stat{font-size:.78rem;color:var(--mute)}
.abar .stat b{color:var(--text);font-weight:700}
.abar .btn{font-family:inherit;font-size:.82rem;font-weight:700;border-radius:999px;padding:11px 24px;
  cursor:pointer;border:1px solid var(--line2);background:transparent;color:var(--text);transition:all .2s}
.abar .btn:hover{border-color:var(--purple);color:#fff}
.abar .btn.primary{background:var(--purple);border-color:var(--purple);color:#fff}
.abar .btn.primary:hover{filter:brightness(1.12)}
.abar .btn[disabled]{opacity:.4;pointer-events:none}
.abar .msg{font-size:.78rem;color:var(--green)}
.abar .msg.bad{color:#ff8a8a}
.ahint{color:var(--mute);font-size:.8rem;margin:6px 0 20px}

/* ---------- saasyn edge bar ----------
   Rests closed against the right edge showing only the wordmark, and slides
   open on hover. It is a link, so keyboard focus opens it too; on touch there
   is no hover, so a tap opens it and a second tap follows it. */
.synbar{position:fixed;right:0;top:50%;z-index:40;display:flex;align-items:stretch;
  text-decoration:none;color:inherit;
  background:rgba(14,16,38,.94);border:1px solid var(--line2);border-right:0;
  border-radius:16px 0 0 16px;backdrop-filter:blur(10px);
  box-shadow:0 22px 60px rgba(0,0,0,.55);
  transform:translate(calc(100% - 46px),-50%);
  transition:transform .4s var(--ease),border-color .3s}
.synbar:hover,.synbar:focus-visible,.synbar.open{transform:translate(0,-50%);border-color:var(--purple)}
.synbar:focus-visible{outline:2px solid var(--purple);outline-offset:2px}

.sb-tab{flex:0 0 46px;position:relative;display:block;border-right:1px solid var(--line)}
/* a chevron rather than a plain rule: it has to read as "pull this open" */
.sb-chev{position:absolute;left:50%;bottom:11px;transform:translateX(-50%);
  width:15px;height:15px;stroke:var(--mute);fill:none;stroke-width:2.4;
  stroke-linecap:round;stroke-linejoin:round;
  transition:transform .4s var(--ease),stroke .3s}
.synbar:hover .sb-chev,.synbar.open .sb-chev{transform:translateX(-50%) rotate(180deg);stroke:var(--plight)}
.sb-tab img{position:absolute;top:50%;left:50%;width:78px;height:auto;
  transform:translate(-50%,-50%) rotate(-90deg);filter:invert(1);opacity:.82;
  transition:opacity .3s}
.synbar:hover .sb-tab img,.synbar.open .sb-tab img{opacity:1}

.sb-body{width:252px;padding:18px 20px;display:flex;flex-direction:column;gap:7px}
.sb-body b{font-size:.84rem;font-weight:700;color:var(--text)}
.sb-note{font-size:.78rem;color:var(--mute);line-height:1.45}
.sb-go{font-size:.76rem;font-weight:700;color:var(--plight);margin-top:2px}

@media (prefers-reduced-motion:reduce){.synbar{transition:none}}
/* the strip under the grid already carries this on a narrow screen, and a
   fixed tab there would sit over the cards */
@media (max-width:820px){.synbar{display:none}}

/* ---------- boot screen ----------
   Shown while /api/decks-list is in flight. It is in the markup rather than
   built by script, so it is there on the first paint and the page never shows
   an empty grid. */
#boot{position:fixed;inset:0;z-index:80;display:grid;place-items:center;
  background:var(--bg);opacity:1;transition:opacity .45s var(--ease)}
#boot::before{content:"";position:absolute;inset:0;
  background:radial-gradient(60% 50% at 50% 42%,rgba(123,126,242,.20),transparent 70%)}
#boot::after{content:"";position:absolute;inset:0;opacity:.05;mix-blend-mode:overlay;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E")}
#boot.done{opacity:0;pointer-events:none}

.boot-in{position:relative;z-index:2;display:flex;flex-direction:column;align-items:center;
  gap:34px;padding:0 24px;text-align:center}
.boot-mark{height:132px;width:auto;display:block;
  animation:bootIn .7s var(--ease) both}
.boot-bar{width:min(340px,68vw);height:3px;border-radius:2px;overflow:hidden;
  background:rgba(255,255,255,.09);animation:bootIn .7s var(--ease) .08s both}
.boot-bar i{display:block;height:100%;width:0;border-radius:2px;background:var(--grad);
  background-size:200% auto;box-shadow:0 0 14px rgba(123,126,242,.55);
  transition:width .45s var(--ease);animation:bootShim 2.4s linear infinite}
/* saasyn-word-tight.svg is the wordmark cropped to its own glyphs. The stock
   file carries 41% empty space above the letters inside its viewBox, so
   centring the boxes still left the wordmark sitting low against the label,
   and the height property was sizing mostly air. */
.boot-note{display:flex;align-items:center;gap:16px;
  animation:bootIn .7s var(--ease) .16s both}
.boot-note span{font-size:.72rem;font-weight:600;letter-spacing:.2em;text-transform:uppercase;
  color:var(--mute);line-height:1}
.boot-syn{height:24px;width:auto;display:block;filter:invert(1);opacity:.92;
  position:relative;top:1px}

@keyframes bootIn{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
@keyframes bootShim{to{background-position:200% center}}

@media (prefers-reduced-motion:reduce){
  #boot{transition:none}
  .boot-mark,.boot-bar,.boot-note{animation:none}
  .boot-bar i{animation:none;transition:none}
}
@media (max-width:640px){ .boot-mark{height:92px} .boot-in{gap:26px} .boot-syn{height:19px} }

/* ---------- who to call ---------- */
.people{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));
  gap:22px;max-width:760px;margin-top:26px}
.person{display:flex;flex-direction:column;gap:4px;
  background:linear-gradient(170deg,var(--card),var(--card2));
  border:1px solid var(--line);border-radius:14px;padding:20px 22px;
  transition:border-color .2s}
.person:hover{border-color:var(--line2)}
.person b{font-size:1rem;font-weight:700;color:var(--text)}
.person .role{font-size:.78rem;color:var(--mute);margin-bottom:8px}
.person a{font-size:.86rem;color:var(--dim);text-decoration:none;width:fit-content;
  transition:color .2s}
.person a:hover{color:var(--plight)}
@media (max-width:640px){ .people{grid-template-columns:1fr} }
