/* =========================================================================
   SlizeLink — base stylesheet
   Loaded on every page: design tokens, resets, the .band layout system,
   buttons, navbar and footer. Anything a specific page needs on top of
   this (hero, waitlist form, feature grid, etc.) lives in that page's own
   stylesheet, e.g. home.css, loaded after this one via {% block extra_css %}.
   Main colour: blueviolet. Main colour dark: --ink. Accent: #cbb8ee.
   ========================================================================= */

/* -------------------------------------------------------------------------
   1. TOKENS
   ------------------------------------------------------------------------- */
:root {
  /* Ink is the dark end of the brand */
  --ink: #241046;
  --ink-soft: #5b5170;
  --body-on-dark: #cfc2e8;

  /* Brand */
  --main-color: blueviolet;
  --main-color-dark: var(--ink);

  --violet: blueviolet;
  --violet-deep: #6a11b8;
  --violet-darker: #4b0f83;

  /* Triadic partners of blueviolet, straight off the harmony wheel. */
  --accent: #cbb8ee;
  --mint: #2be28a;
  --magenta: #e22bdf;
  --indigo: #3b27e0;

  --white: #ffffff;
  --line: #e7e2f2;
  --line-strong: #cbb8ee;
  /* Neutral light fill for tiny surfaces — no violet tint, so ink reads cleanly */
  --surface-2: #f4f3f8;

  --success: #0e7a4b;
  --success-bg: #e8faf1;
  --danger: #b42318;
  --danger-bg: #fdeceb;

  /* Aliases the hero rules consume */
  --text-primary: var(--ink);
  --text-secondary: var(--ink-soft);
  --success-color: var(--success);
  --purple-light: rgba(138, 43, 226, 0.1);
  --shadow-md: 0 4px 12px -2px rgba(36, 16, 70, 0.12);

  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;
  --s-9: 6rem;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-pill: 999px;

  --lift: 0 18px 36px -18px rgba(36, 16, 70, 0.35);
  --lift-dark: 0 22px 44px -22px rgba(0, 0, 0, 0.6);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  /* easeOutQuint: long tail, so the crossfade settles instead of stopping dead */
  --ease-soft: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 250ms;
  --transition: all var(--dur) var(--ease);

  /* Use-case rotation interval */
  --rotate: 6200ms;
}


/* -------------------------------------------------------------------------
   2. BASE
   ------------------------------------------------------------------------- */
* { margin: 0; padding: 0; box-sizing: border-box; }

/* Element selectors, so these beat Bootstrap's own p/h/ul margins */
p, h1, h2, h3, h4, h5, h6, ul, ol, figure, blockquote { margin: 0; }

a {
  text-decoration: none;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 5rem;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Prompt', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

:focus-visible {
  outline: 3px solid var(--violet);
  outline-offset: 2px;
  border-radius: var(--r-sm);
}
:focus:not(:focus-visible) { outline: none; }

[hidden] { display: none !important; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

@media (min-width: 1200px) {
  .container, .container-lg, .container-md, .container-sm, .container-xl { max-width: 1180px; }
}


/* -------------------------------------------------------------------------
   3. BANDS
   ------------------------------------------------------------------------- */
.band { padding-block: var(--s-8); }
.band--white  { background: var(--white); color: var(--ink); }
.band--ink    { background: var(--ink);   color: var(--white); }
.band--violet { background: var(--violet-deep); color: var(--white); }

@media (min-width: 768px) { .band { padding-block: var(--s-9); } }

.band-head { max-width: 36rem; margin-bottom: var(--s-7); }

.kicker {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-bottom: var(--s-3);
  color: var(--violet-deep);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.kicker::before { content: ""; width: 28px; height: 2px; background: currentColor; flex-shrink: 0; }
.kicker--accent { color: var(--accent); }

.band-title {
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.025em;
  text-wrap: balance;
  margin-bottom: var(--s-3);
}

.band-sub { font-size: 1.0625rem; color: var(--ink-soft); text-wrap: pretty; }
.band--ink .band-sub { color: var(--body-on-dark); }
.band--violet .band-sub { color: rgba(255, 255, 255, 0.88); }

/* Reveal is applied to CONTAINERS only, never to an element that has its own
   hover transform — otherwise .is-visible{transform:none} beats :hover. */
.js .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 450ms var(--ease), transform 450ms var(--ease);
  /* Safety net, independent of JS: if base.js never runs for any reason
     (wrong static path, network hiccup, blocked script), .is-visible
     never gets added and this would stay invisible forever. This
     unconditional animation forces full visibility after a few seconds
     regardless, so a script failure degrades to "revealed a bit late"
     instead of "permanently blank". Harmless when JS does run normally:
     .is-visible already sets the same end state well before this fires. */
  animation: revealFallback 1ms 2.5s forwards;
}
.js .reveal.is-visible { opacity: 1; transform: none; }

@keyframes revealFallback { to { opacity: 1; transform: none; } }


/* -------------------------------------------------------------------------
   3b. TONES — a small palette any page can hang off [data-tone] to mark
   distinct, parallel things (personas, themes, categories) with their own
   colour. Shared because both home (use-case rail, bio themes) and features
   (preview cards, theme swatches, secondary grid) need the same palette.
   ------------------------------------------------------------------------- */
[data-tone="violet"]  { --tone: var(--violet);  --tone-deep: #6a11b8; --tone-on: #ffffff; }
[data-tone="indigo"]  { --tone: var(--indigo);  --tone-deep: #2a1bb0; --tone-on: #ffffff; }
[data-tone="magenta"] { --tone: #b31eb0;        --tone-deep: #8a1489; --tone-on: #ffffff; }
[data-tone="mint"]    { --tone: var(--mint);    --tone-deep: #0e7a4b; --tone-on: var(--ink); }
[data-tone="pink"]    { --tone: #c01a6b;        --tone-deep: #92104f; --tone-on: #ffffff; }

/* -------------------------------------------------------------------------
   4. BUTTONS
   ------------------------------------------------------------------------- */
.btn {
  --bs-btn-focus-box-shadow: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: 48px;
  padding: 0.75rem 1.5rem;
  border: 2px solid transparent;
  border-radius: var(--r-md);
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: var(--transition);
}

/* Shared light hero action for solid brand-colour sections. */
.btn-hero {
  padding-inline: 1.75rem;
  color: var(--violet-deep);
  background: #fff;
  border-color: #fff;
}
.btn-hero:hover,
.btn-hero:focus-visible {
  color: var(--violet-darker);
  background: #f7f4fc;
  border-color: #f7f4fc;
  box-shadow: 0 18px 34px -16px rgba(0, 0, 0, 0.4);
  transform: translateY(-3px);
}

.btn-primary {
  background: var(--violet);
  border-color: var(--violet);
  color: #fff;
}
.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--violet-deep);
  border-color: var(--violet-deep);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--lift);
}
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; box-shadow: none; }

/* White button on the violet CTA band — stays light on hover, just lifts */
.btn-on-brand {
  background: #fff;
  border-color: #fff;
  color: var(--violet-deep);
  padding-inline: 2rem;
}
.btn-on-brand:hover,
.btn-on-brand:focus-visible {
  background: #f7f4fc;
  border-color: #f7f4fc;
  color: var(--violet-darker);
  transform: translateY(-4px);
  box-shadow: 0 22px 44px -18px rgba(0, 0, 0, 0.4);
}
.btn-on-brand:active { transform: translateY(-1px); }


/* -------------------------------------------------------------------------
   5. NAVBAR
   ------------------------------------------------------------------------- */
.navbar {
  padding: 0.75rem 0;
  background: var(--white) !important;
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease);
}
.navbar.is-scrolled { border-bottom-color: var(--line); }

.logo { height: 26px; width: auto; }

.nav-link {
  color: var(--ink-soft);
  font-weight: 500;
  padding: 0.5rem 0.9rem !important;
  border-radius: var(--r-sm);
  transition: var(--transition);
}
.nav-link:hover, .nav-link:focus-visible { color: var(--violet-deep); background: var(--surface-2); }

/* The Features trigger is a <button>, so it needs the same reset a link gets
   for free plus a caret and font inherited from Bootstrap's dropdown-toggle. */
button.nav-link {
  background: none;
  border: 0;
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
}

.navbar .dropdown-menu {
  --bs-dropdown-min-width: 14rem;
  --bs-dropdown-padding-x: 0.4rem;
  --bs-dropdown-padding-y: 0.5rem;
  --bs-dropdown-spacer: 0.5rem;
  --bs-dropdown-font-size: 0.9375rem;
  --bs-dropdown-border-color: var(--line);
  --bs-dropdown-border-radius: var(--r-md);
  --bs-dropdown-inner-border-radius: calc(var(--r-md) - 1px);
  --bs-dropdown-link-color: var(--ink);
  --bs-dropdown-link-hover-color: var(--violet-deep);
  --bs-dropdown-link-hover-bg: var(--surface-2);
  --bs-dropdown-link-active-color: #fff;
  --bs-dropdown-link-active-bg: var(--violet-deep);
  --bs-dropdown-item-padding-x: 0.85rem;
  --bs-dropdown-item-padding-y: 0.55rem;
  box-shadow: 0 20px 40px -20px rgba(36, 16, 70, 0.35);
}
.navbar .dropdown-item { border-radius: var(--r-sm); font-weight: 500; }
/* Below lg the menu sits inside the collapsed nav's normal flow instead of
   floating (Bootstrap's default position:absolute clips awkwardly there). */
@media (max-width: 991.98px) {
  .navbar .dropdown-menu {
    position: static;
    margin-top: 0.25rem;
    box-shadow: none;
    border-color: var(--line);
  }
}

.navbar .join-waitlist { min-height: 44px; padding: 0.5rem 1.1rem; }
.navbar .join-waitlist:hover { color: #fff !important; }

.nav-cta { margin-top: var(--s-3); }
.nav-cta .btn { width: 100%; }

@media (min-width: 992px) {
  .nav-cta { margin-top: 0; }
  .nav-cta .btn { width: auto; }
}


/* -------------------------------------------------------------------------
   6. PHONE MOCK — one component, shared by every page that needs a phone-
   framed preview (home's use-case rail and bio section, features' bio
   deep-dive, and any future page). Same physical frame as the hero: 280x560, 12px bezel, 40px radius.
   Colours come from --pm-brand so the bio phone can theme itself.
   ------------------------------------------------------------------------- */
.app-mock {
  --pm-brand: var(--violet);
  --pm-cover: var(--violet-deep);
  --pm-on-brand: #ffffff;

  position: relative;
  width: 280px;
  max-width: 100%;
  height: 560px;
  padding: 12px;
  background: #1a1a1a;
  border-radius: 40px;
  box-shadow: 0 30px 60px -28px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.09);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.app-mock:hover { box-shadow: 0 40px 78px -30px rgba(0, 0, 0, 0.75); }

.app-notch {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 108px;
  height: 22px;
  background: #1a1a1a;
  border-radius: 0 0 14px 14px;
  z-index: 4;
}

.pm-screen {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  background: var(--white);
  border-radius: 30px;
  overflow: hidden;
}

/* --- status bar --- */
.pm-status {
  position: relative;
  z-index: 3;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 1.1rem 0.15rem;
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.pm-time { font-variant-numeric: tabular-nums; }
.pm-sys { display: inline-flex; align-items: center; gap: 5px; }
.pm-sig { width: 15px; height: 10px; }
.pm-wifi { width: 14px; height: 10px; }
.pm-bat { width: 22px; height: 10px; }

/* --- cover artwork, drawn in CSS so there is no image to load --- */
.pm-cover {
  position: absolute;
  inset: 0 0 auto;
  height: 112px;
  background: var(--pm-cover);
  overflow: hidden;
  transition: background-color 700ms var(--ease-soft);
}
.pm-cover span { position: absolute; display: block; border-radius: 50%; }

.pm-cover[data-art="waves"] span {
  border: 2px solid rgba(255, 255, 255, 0.22);
  border-radius: 50%;
}
.pm-cover[data-art="waves"] span:nth-child(1) { width: 150px; height: 150px; top: 12px;  right: -40px; }
.pm-cover[data-art="waves"] span:nth-child(2) { width: 104px; height: 104px; top: 36px;  right: -18px; }
.pm-cover[data-art="waves"] span:nth-child(3) { width: 60px;  height: 60px;  top: 58px;  right: 4px;  background: rgba(255, 255, 255, 0.14); border: 0; }

.pm-cover[data-art="grid"] span {
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.16);
}
.pm-cover[data-art="grid"] span:nth-child(1) { width: 54px; height: 54px; top: 18px; right: 16px; }
.pm-cover[data-art="grid"] span:nth-child(2) { width: 54px; height: 54px; top: 18px; right: 80px; opacity: 0.6; }
.pm-cover[data-art="grid"] span:nth-child(3) { width: 118px; height: 26px; top: 82px; right: 16px; opacity: 0.4; }

.pm-cover[data-art="poster"] span { border-radius: 3px; background: rgba(255, 255, 255, 0.18); }
.pm-cover[data-art="poster"] span:nth-child(1) { width: 88px; height: 10px; top: 30px; left: 16px; }
.pm-cover[data-art="poster"] span:nth-child(2) { width: 132px; height: 10px; top: 48px; left: 16px; opacity: 0.65; }
.pm-cover[data-art="poster"] span:nth-child(3) { width: 62px;  height: 10px; top: 66px; left: 16px; opacity: 0.4; }

/* --- profile --- */
.pm-head { position: relative; z-index: 2; flex-shrink: 0; padding: 54px 1rem 0; text-align: center; }

.pm-avatar {
  position: relative;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 0.4rem;
  border: 3px solid var(--white);
  border-radius: 50%;
  background: var(--pm-brand);
  color: var(--pm-on-brand);
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: background-color 700ms var(--ease-soft), color 700ms var(--ease-soft);
}
.pm-check {
  position: absolute;
  right: -3px;
  bottom: -1px;
  display: grid;
  place-items: center;
  width: 19px;
  height: 19px;
  border: 2px solid var(--white);
  border-radius: 50%;
  background: var(--mint);
  color: var(--ink);
}
.pm-check svg { width: 9px; height: 9px; }

.pm-name { font-size: 0.9375rem; font-weight: 700; line-height: 1.2; }
.pm-handle { font-size: 0.625rem; font-weight: 600; color: var(--violet-deep); letter-spacing: 0.01em; }
.pm-bio { margin-top: 0.25rem; font-size: 0.6875rem; line-height: 1.35; color: var(--ink-soft); }

.pm-stats {
  display: flex;
  justify-content: center;
  gap: 0.9rem;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--line);
}
.pm-stat { display: flex; flex-direction: column; font-size: 0.5625rem; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.06em; }
.pm-stat strong { font-size: 0.8125rem; font-weight: 700; color: var(--ink); letter-spacing: 0; text-transform: none; }

/* --- link rows --- */
.pm-links {
  list-style: none;
  margin: 0.6rem 0 0;
  padding: 0 0.8rem;
  display: grid;
  gap: 0.35rem;
  align-content: start;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

.pm-link {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.4rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.pm-link:hover { border-color: var(--pm-brand); transform: translateX(3px); }

.pm-link__icon {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  border-radius: 7px;
  background: var(--surface-2);
  color: var(--violet-deep);
  transition: background-color 700ms var(--ease-soft), color 700ms var(--ease-soft);
}
.pm-link__icon svg { width: 14px; height: 14px; }

.pm-link__body { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; text-align: left; }
.pm-link__title { font-size: 0.6875rem; font-weight: 700; line-height: 1.25; color: var(--ink); }
.pm-link__sub {
  font-size: 0.5625rem;
  color: var(--ink-soft);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.pm-link__count {
  flex-shrink: 0;
  font-size: 0.5625rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--ink-soft);
}

.pm-link--lead {
  background: var(--pm-brand);
  border-color: var(--pm-brand);
  transition: background-color 700ms var(--ease-soft), border-color 700ms var(--ease-soft), transform var(--dur) var(--ease);
}
.pm-link--lead .pm-link__title,
.pm-link--lead .pm-link__count { color: var(--pm-on-brand); }
.pm-link--lead .pm-link__sub { color: var(--pm-on-brand); opacity: 0.78; }
.pm-link--lead .pm-link__icon { background: rgba(255, 255, 255, 0.22); color: var(--pm-on-brand); }
.app-mock[data-theme="mint"] .pm-link--lead .pm-link__icon { background: rgba(36, 16, 70, 0.14); }

/* --- dock --- */
.pm-dock {
  flex-shrink: 0;
  margin-top: auto;
  padding: 0.55rem 0.85rem 0.7rem;
  text-align: center;
  background: var(--white);
  border-top: 1px solid var(--line);
}
.pm-socials { display: inline-flex; gap: 0.55rem; }
.pm-social {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--pm-brand);
  color: var(--pm-on-brand);
  opacity: 0.9;
  transition: background-color 700ms var(--ease-soft), color 700ms var(--ease-soft);
}
.pm-social svg { width: 12px; height: 12px; }
.pm-brand {
  display: block;
  margin-top: 0.35rem;
  line-height: 1;
  font-size: 0.5rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* -------------------------------------------------------------------------
   7. FINAL CTA — shared band pattern (home's waitlist push, features'
   closing CTA, and any future page that wants the same "big violet band,
   one line, one button" close).
   ------------------------------------------------------------------------- */
.final-cta { text-align: center; }

.final-cta__title {
  font-size: clamp(1.875rem, 6vw, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  text-wrap: balance;
  margin-bottom: var(--s-3);
}

.final-cta__sub {
  max-width: 32rem;
  margin: 0 auto var(--s-6);
  font-size: 1.0625rem;
  color: rgba(255, 255, 255, 0.88);
}

.final-cta__note { margin-top: var(--s-5); font-size: 0.875rem; color: rgba(255, 255, 255, 0.8); }

.final-cta :focus-visible { outline-color: #fff; }

/* -------------------------------------------------------------------------
   8. RECENT LINKS DIALOG
   Shared by the navbar on every public page and the URL shortener result.
   ------------------------------------------------------------------------- */
.recent-links {
  position: fixed;
  top: 50%;
  left: 50%;
  width: min(42rem, calc(100% - 2rem));
  max-height: min(80vh, 44rem);
  max-height: min(80dvh, 44rem);
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 1.25rem;
  background: var(--white);
  color: var(--ink);
  opacity: 0;
  transform: translate(-50%, -46%) scale(0.97);
  visibility: hidden;
  box-shadow: 0 2rem 6rem -2rem rgba(36, 16, 70, 0.72);
  transition: opacity 220ms var(--ease), transform 260ms var(--ease-soft), visibility 0s linear 260ms;
}

.recent-links[open] { visibility: visible; }

.recent-links[open].is-open {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  transition-delay: 0s;
}

.recent-links[open].is-closing {
  opacity: 0;
  transform: translate(-50%, -46%) scale(0.97);
  visibility: visible;
  transition-delay: 0s;
}

.recent-links::backdrop {
  background: rgba(30, 9, 54, 0);
  transition: background 220ms var(--ease);
}

.recent-links[open].is-open::backdrop { background: rgba(30, 9, 54, 0.72); }

.recent-links__frame {
  display: grid;
  max-height: inherit;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.recent-links__header,
.recent-links__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  padding: 1.2rem 1.35rem;
}

.recent-links__header { border-bottom: 1px solid var(--line); }

.recent-links__header p,
.recent-links__footer p {
  color: var(--ink-soft);
  font-size: 0.75rem;
}

.recent-links__header h2 {
  margin-top: 0.15rem;
  color: var(--ink);
  font-size: 1.45rem;
  font-weight: 700;
}

.recent-links__header button {
  display: grid;
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  color: var(--ink);
  cursor: pointer;
  transition: var(--transition);
}

.recent-links__header button:hover { border-color: var(--violet); color: var(--violet-deep); }

.recent-links__header svg {
  width: 1.15rem;
  height: 1.15rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.8;
}

.recent-links__body {
  min-height: 12rem;
  padding: 1.2rem 1.35rem;
  overflow: auto;
  overscroll-behavior: contain;
}

#recentLinksStatus {
  color: var(--ink-soft);
  font-size: 0.85rem;
  text-align: center;
}

.recent-links__list { display: grid; gap: 0.7rem; }

.recent-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.8rem;
  padding: 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
}

.recent-link__original,
.recent-link__short { overflow-wrap: anywhere; }

.recent-link__original {
  display: -webkit-box;
  overflow: hidden;
  color: var(--ink-soft);
  font-size: 0.72rem;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  text-overflow: ellipsis;
}

.recent-link__short {
  display: block;
  margin-top: 0.25rem;
  color: var(--violet-deep);
  font-size: 0.92rem;
  font-weight: 650;
}

.recent-link__meta {
  margin-top: 0.35rem;
  color: var(--ink-soft);
  font-size: 0.7rem;
}

.recent-link__actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.recent-link__actions button,
.recent-link__actions a {
  display: inline-grid;
  min-width: 2.75rem;
  min-height: 2.75rem;
  place-items: center;
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 0.55rem;
  background: var(--white);
  color: var(--violet-deep);
  font: inherit;
  font-size: 0.7rem;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
}

.recent-link__actions button:hover,
.recent-link__actions a:hover { border-color: var(--violet); background: var(--surface-2); }

.recent-link__actions button:disabled { cursor: not-allowed; opacity: 0.5; }

.recent-links__footer { border-top: 1px solid var(--line); }

.recent-links__footer a {
  color: var(--violet-deep);
  font-size: 0.78rem;
  font-weight: 650;
  text-decoration: none;
}

.recent-links button:focus-visible,
.recent-links a:focus-visible {
  outline: 3px solid var(--violet-deep);
  outline-offset: 3px;
}

@media (max-width: 575.98px) {
  .recent-links__footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .recent-link { grid-template-columns: 1fr; }
  .recent-link__actions { justify-content: flex-start; }
}

/* -------------------------------------------------------------------------
   13. FOOTER
   ------------------------------------------------------------------------- */
.footer { padding-block: var(--s-7); background: var(--ink); color: var(--body-on-dark); }

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-7);
}
@media (min-width: 992px) {
  .footer-grid { grid-template-columns: 1.3fr repeat(3, 1fr); gap: var(--s-6); }
}

.footer-brand { display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-4); }
.footer-logo { display: inline-flex; }
.footer-blurb { max-width: 26rem; font-size: 0.9375rem; line-height: 1.6; color: var(--body-on-dark); }

/* Was a grid nested inside .footer-grid's own grid-column span — two grid
   contexts with two different gap values, and a long unbroken phrase like
   "QR code generator" could push its column wider than its fair share,
   leaving the row uneven. Flex with an explicit basis sidesteps both:
   three columns always split the row exactly evenly. */
.footer-links {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
}
@media (min-width: 576px) {
  .footer-links { flex-direction: row; gap: var(--s-5); }
}
@media (min-width: 992px) {
  .footer-links { grid-column: 2 / -1; }
}

.footer-col { flex: 1 1 0; min-width: 0; }

.footer-col__title {
  margin-bottom: var(--s-3);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.footer-col__list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s-2); }

.footer-link {
  color: var(--body-on-dark);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9375rem;
  transition: var(--transition);
}
.footer-link:hover, .footer-link:focus-visible { color: #fff; }

.footer-social { display: flex; gap: var(--s-2); list-style: none; padding: 0; margin: 0; }

.social-link {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--r-md);
  color: var(--body-on-dark);
  text-decoration: none;
  transition: var(--transition);
}
.social-link:hover, .social-link:focus-visible {
  background: var(--violet);
  border-color: var(--violet);
  color: #fff;
  transform: translateY(-2px);
}

.footer-divider {
  margin: var(--s-5) 0 var(--s-4);
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  opacity: 1;
}

.footer-copyright { text-align: center; font-size: 0.875rem; color: rgba(255, 255, 255, 0.7); }


/* -------------------------------------------------------------------------
   14. REDUCED MOTION (shared)
   ------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .js .reveal { opacity: 1; transform: none; }
  .recent-links { transition: none; }
  .recent-links[open],
  .recent-links[open].is-open { transform: translate(-50%, -50%) scale(1); }
}

/* -------------------------------------------------------------------------
   15. PRINT (shared)
   ------------------------------------------------------------------------- */
@media print {
  .navbar { display: none !important; }
  .recent-links { display: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .band--ink, .band--violet { background: #fff !important; color: #000 !important; }
  .footer { background: #fff !important; color: #000 !important; }
  body { color: #000; }
}

.text-balance { text-wrap: balance; }
.text-pretty { text-wrap: pretty; }
