/* YTPocket: bold "sticker" style. Yellow ground, thick ink outlines with an
   offset shadow, pink for selected things and progress, mint for download.
   Icons: /icons.svg (Phosphor + Simple Icons), filled with currentColor.

   Sections: tokens, base, header & menus, page & hero, tool (result, sheet,
   options), content sections, step pictures, tool cards, footer, legal
   pages, toasts, responsive. */

@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/fonts/bricolage-latin.woff2') format('woff2');
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC,
    U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/fonts/bricolage-latin-ext.woff2') format('woff2');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F,
    U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ------------------------------------------------------------- tokens --- */
/* Yellow is the default everywhere. Dark is opt-in via the moon button
   (data-theme="dark" on <html>, set by /theme.js before first paint). */
:root {
  color-scheme: light;
  --bg: #ffd43b;
  --card: #fffdf5;
  --soft: #fff4c2; /* paste zone, hover, step stages */
  --field: #ffffff;
  --ink: #161616;
  --muted: #55524a;
  --outline: #161616;
  --shadow: #161616;
  --pop: #ff5d8f; /* selected, progress */
  --pop-soft: #ffc2d5;
  --pop-softer: #ffdfe9;
  --mint: #3ddc97; /* download */
  --sun: #ffd43b;
  --on-color: #161616; /* text on pop / mint / sun */
  --danger: #c4202f;
  --cta-bg: #161616;
  --cta-ink: #ffffff;
  --foot-bg: #161616;
  --foot-ink: #fff8e1;
  --foot-muted: #d8d1bb;

  --font:
    'Bricolage Grotesque', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, 'Noto Sans', 'Noto Sans Arabic',
    sans-serif;
  --line: 3px;
  --r-lg: 24px;
  --r-md: 16px;
  --r-sm: 12px;
  --pad: clamp(14px, 4vw, 28px);
  --max: 1120px;
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --bg: #1c1b18;
  --card: #2a2823;
  --soft: #34312a;
  --field: #1c1b18;
  --ink: #fff8e1;
  --muted: #c9c2ab;
  --outline: #fff8e1;
  --shadow: #ffd43b;
  --pop-soft: #6b2c41;
  --pop-softer: #4a2532;
  --danger: #ff8a95;
  --cta-bg: #ffd43b;
  --cta-ink: #161616;
  --foot-bg: #11100e;
}

/* --------------------------------------------------------------- base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  overflow-x: clip; /* offset shadows must never cause sideways scrolling */
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font: 500 1rem/1.45 var(--font);
  -webkit-font-smoothing: antialiased;
}
body.no-scroll {
  overflow: hidden;
}
h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}
ul,
ol {
  padding: 0;
  list-style: none;
}
a {
  color: inherit;
}
button,
input {
  font: inherit;
  color: inherit;
}
button,
summary {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
}
img,
svg {
  display: block;
}
[hidden] {
  display: none !important;
}
:focus-visible {
  outline: 3px solid var(--pop);
  outline-offset: 3px;
}
.ic {
  width: 20px;
  height: 20px;
  flex: none;
  fill: currentColor;
}
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip {
  position: absolute;
  left: 8px;
  top: -80px;
  z-index: 40;
  padding: 10px 14px;
  border: var(--line) solid var(--outline);
  border-radius: var(--r-sm);
  background: var(--card);
  color: var(--ink);
  font-weight: 700;
}
.skip:focus {
  top: 8px;
}

/* The signature: card with a thick outline and a hard offset shadow. */
.box {
  background: var(--card);
  border: var(--line) solid var(--outline);
  box-shadow: 4px 4px 0 var(--shadow);
}

/* ----------------------------------------------------- header & menus --- */
.topbar,
.page,
.foot-inner {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding-inline: var(--pad);
}
.topbar {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 14px;
  padding-top: max(16px, env(safe-area-inset-top));
  padding-bottom: 12px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: inherit;
  text-decoration: none;
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.logo {
  width: 36px;
  height: 36px;
  border: var(--line) solid var(--outline);
  border-radius: 11px;
  background: var(--pop);
  color: #161616;
  display: grid;
  place-items: center;
}
.logo .ic {
  width: 20px;
  height: 20px;
}
/* Mini-site menu: the group's tools as flat links. */
.menu {
  display: flex;
  gap: 2px;
  margin-left: 8px;
}
.menu > a {
  padding: 7px 11px;
  border-radius: 12px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}
.menu > a:hover {
  background: var(--soft);
}
.menu > a[aria-current='page'] {
  background: var(--card);
  box-shadow: inset 0 0 0 var(--line) var(--outline);
}
.dd {
  position: relative;
}
.dd > summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  border-radius: 12px;
  font-weight: 800;
}
.dd > summary::-webkit-details-marker {
  display: none;
}
.dd > summary .caret {
  width: 14px;
  height: 14px;
  transition: transform 0.15s;
}
.dd > summary:hover,
.dd.active > summary {
  background: var(--soft);
}
.dd[open] > summary {
  background: var(--card);
  box-shadow: inset 0 0 0 var(--line) var(--outline);
}
.dd[open] > summary .caret {
  transform: rotate(180deg);
}
.dd-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 290px;
  padding: 8px;
  background: var(--card);
  border: var(--line) solid var(--outline);
  border-radius: var(--r-md);
  box-shadow: 4px 4px 0 var(--shadow);
}
/* Menu item: platform sticker + label + one-line description. */
.dd-panel a,
.drawer nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 12px;
  text-decoration: none;
}
.dd-panel a:hover,
.drawer nav a:hover {
  background: var(--soft);
}
.dd-panel a[aria-current='page'],
.drawer nav a[aria-current='page'] {
  background: var(--soft);
  box-shadow: inset 4px 0 0 var(--pop);
}
.dd-panel b,
.drawer nav b {
  display: block;
  font-weight: 800;
}
.dd-panel small,
.drawer nav small {
  display: block;
  color: var(--muted);
  font-size: 0.8125rem;
}
.topbar-end {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.icon-btn {
  width: 44px;
  height: 44px;
  border: var(--line) solid var(--outline);
  border-radius: 12px;
  background: var(--card);
  color: var(--ink);
  display: grid;
  place-items: center;
  box-shadow: 3px 3px 0 var(--shadow);
}
.icon-btn:active {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0 var(--shadow);
}
.menu-btn {
  display: none;
}
.status {
  padding: 4px 12px;
  border: 2px solid var(--outline);
  border-radius: 99px;
  background: var(--card);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--danger);
}

/* Slide-in menu (phones). */
.drawer {
  position: fixed;
  inset: 0;
  z-index: 30;
}
.drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgb(22 22 22 / 0.5);
}
.drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(360px, 88vw);
  overflow-y: auto;
  padding: max(14px, env(safe-area-inset-top)) 14px 24px;
  background: var(--card);
  border-left: var(--line) solid var(--outline);
  animation: slide-in 0.2s ease-out;
}
@keyframes slide-in {
  from {
    transform: translateX(30px);
    opacity: 0;
  }
}
.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}
.drawer-label {
  margin: 16px 10px 4px;
  font-size: 0.8125rem;
  font-weight: 800;
  color: var(--muted);
}

/* Brand colours (Simple Icons), as classes: the strict CSP blocks inline
   style attributes. */
.brand-youtube {
  --brand: #ff0000;
}
.brand-tiktok {
  --brand: #000000;
}
.brand-facebook {
  --brand: #0866ff;
}
.brand-pinterest {
  --brand: #bd081c;
}
.brand-dailymotion {
  --brand: #0a0a0a;
}
.brand-twitch {
  --brand: #9146ff;
}
.brand-more {
  --brand: #ff5d8f;
}

/* Platform logo "sticker": brand colour, ink frame, slightly tilted. */
.sticker {
  position: relative;
  width: 48px;
  height: 48px;
  flex: none;
  border: var(--line) solid #161616;
  border-radius: 14px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  transform: rotate(-5deg);
  box-shadow: 2px 2px 0 #161616;
}
.sticker .ic {
  width: 24px;
  height: 24px;
}
.sticker.sm {
  width: 34px;
  height: 34px;
  border-width: 2px;
  border-radius: 10px;
  box-shadow: none;
}
.sticker.sm .ic {
  width: 18px;
  height: 18px;
}
.sticker .fmt {
  position: absolute;
  right: -10px;
  bottom: -8px;
  transform: rotate(5deg);
  padding: 0 5px;
  border: 2px solid #161616;
  border-radius: 7px;
  background: var(--mint);
  color: #161616;
  font-size: 0.625rem;
  font-weight: 800;
}

/* ------------------------------------------------------- page & hero --- */
.page {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr); /* let the column shrink below the input's default width */
  gap: 18px;
  align-content: start;
  padding-bottom: 36px;
}
.crumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--muted);
}
.crumbs li {
  display: flex;
  align-items: center;
  gap: 4px;
}
.crumbs a {
  text-decoration: none;
}
.crumbs a:hover {
  text-decoration: underline;
}
.crumbs .sep {
  width: 12px;
  height: 12px;
}
.crumbs [aria-current] {
  color: var(--ink);
}

/* Hero: headline on the yellow ground, the tool in a card, and (on pages
   that have one) an example card beside it. */
.hero-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  align-items: center;
}
.hero {
  display: grid;
  gap: 14px;
  min-width: 0;
}
.hero h1 {
  font-size: clamp(2rem, 6.5vw, 3.4rem);
  line-height: 0.98;
  font-weight: 800;
  letter-spacing: -0.03em;
  max-width: 16ch;
}
.lead {
  color: var(--ink);
  opacity: 0.85;
  font-size: 1.125rem;
  margin-top: -4px;
  max-width: 52ch;
}
.tool-card {
  border-radius: var(--r-lg);
  padding: clamp(14px, 2.5vw, 20px);
  display: grid;
  gap: 12px;
}
.proof {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-weight: 700;
  font-size: 0.9375rem;
}
.proof li {
  display: flex;
  align-items: center;
  gap: 7px;
}
.proof .ic {
  width: 22px;
  height: 22px;
  padding: 3px;
  border: 2px solid var(--outline);
  border-radius: 50%;
  background: var(--mint);
  color: #161616;
}
@media (min-width: 900px) {
  .hero-row.has-example {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    gap: 32px;
  }
  .hero-row.ex-is-tall,
  .hero-row.ex-is-pin {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  }
}

/* Example card: a real, free-to-share video, shaped like what the page saves. */
.ex {
  position: relative;
  width: 100%;
  max-width: 440px;
  justify-self: end;
  margin-top: 14px;
  padding: 12px;
  border-radius: 22px;
  transform: rotate(1.2deg);
}
.ex-tag {
  position: absolute;
  z-index: 2;
  top: -15px;
  left: 16px;
  transform: rotate(-3deg);
  padding: 1px 10px;
  border: var(--line) solid #161616;
  border-radius: 12px;
  background: var(--pop);
  color: #161616;
  font-weight: 800;
  font-size: 0.8125rem;
}
.ex-media {
  position: relative;
  overflow: hidden;
  border: var(--line) solid #161616;
  border-radius: 14px;
  background: #161616;
}
.ex-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ex-media.wide {
  aspect-ratio: 16 / 9;
}
.ex-media.tall {
  aspect-ratio: 9 / 16;
}
.ex-media.square {
  aspect-ratio: 1;
}
.ex-media.pin {
  aspect-ratio: 2 / 3;
  border-radius: 18px;
}
.ex-pin {
  grid-template-columns: 170px minmax(0, 1fr);
}
.ex-chip {
  position: absolute;
  padding: 1px 7px;
  border-radius: 7px;
  background: rgb(22 22 22 / 0.85);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
}
.ex-chip.br {
  right: 8px;
  bottom: 8px;
}
.ex-chip.tl {
  left: 8px;
  top: 8px;
}
.ex-mark {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 30px;
  height: 30px;
  border: 2px solid #161616;
  border-radius: 9px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
}
.ex-mark .ic {
  width: 16px;
  height: 16px;
}
.ex-title {
  margin: 10px 2px 0;
  font-weight: 800;
  font-size: 1.0625rem;
  line-height: 1.2;
}
.ex-by {
  margin: 2px 2px 8px;
  font-size: 0.8125rem;
  color: var(--muted);
}
.ex-rows {
  display: grid;
  gap: 6px;
}
.ex-rows li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px 5px 11px;
  border: var(--line) solid var(--outline);
  border-radius: 12px;
  background: var(--field);
  font-size: 0.9375rem;
}
.ex-rows b {
  flex: 1;
}
.ex-rows span {
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--muted);
  white-space: nowrap;
}
.ex-rows .ex-dl {
  width: 28px;
  height: 28px;
  border: 2px solid #161616;
  border-radius: 50%;
  background: var(--mint);
  color: #161616;
  display: grid;
  place-items: center;
}
.ex-dl .ic {
  width: 14px;
  height: 14px;
}
.ex-try {
  margin-top: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.875rem;
  font-weight: 800;
  text-underline-offset: 3px;
}
.ex-try .ic {
  width: 15px;
  height: 15px;
}
/* Tall (Shorts): phone-shaped video left, details right. */
.ex-tall {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}
.ex-tall .ex-title {
  margin-top: 2px;
}
/* Narrow details column: format names only. */
.ex-tall .ex-rows b {
  white-space: nowrap;
}
.ex-tall .ex-rows span:not(.ex-dl) {
  display: none;
}
.ex-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 30px 9px 9px;
  background: linear-gradient(transparent, rgb(0 0 0 / 0.7));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.25;
}
/* Music (MP3): square cover, tags, a little player. */
.ex-head {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}
.ex-head .ex-title {
  margin-top: 0;
}
.ex-head .ex-mark {
  width: 26px;
  height: 26px;
  top: 6px;
  right: 6px;
}
.ex-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.ex-tags span {
  padding: 0 7px;
  border: 2px solid var(--outline);
  border-radius: 99px;
  background: var(--soft);
  font-size: 0.6875rem;
  font-weight: 800;
}
.ex-player {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  padding: 8px 10px;
  border: var(--line) solid var(--outline);
  border-radius: 12px;
  background: var(--field);
}
.ex-play {
  width: 28px;
  height: 28px;
  flex: none;
  border-radius: 50%;
  background: var(--ink);
  color: var(--card);
  display: grid;
  place-items: center;
}
.ex-play .ic {
  width: 13px;
  height: 13px;
}
.ex-wave {
  flex: 1;
  min-width: 0;
  height: 26px;
  fill: color-mix(in srgb, var(--ink) 25%, transparent);
}
.ex-wave .played {
  fill: var(--pop);
}
.ex-player small {
  font-weight: 800;
  font-size: 0.75rem;
  color: var(--muted);
}
/* Thumbnail: just the image, its title and size. */
.ex-thumb-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
}
.ex-thumb-meta .ex-title {
  flex: 1;
  margin: 0;
}
.ex-size {
  padding: 1px 9px;
  border: 2px solid var(--outline);
  border-radius: 99px;
  background: var(--soft);
  font-size: 0.75rem;
  font-weight: 800;
  white-space: nowrap;
}
@media (max-width: 899px) {
  .ex {
    max-width: none;
    justify-self: stretch;
    transform: rotate(0.6deg);
  }
}
@media (max-width: 420px) {
  .ex-tall {
    grid-template-columns: 120px minmax(0, 1fr);
  }
}
.intake {
  display: flex;
  gap: 10px;
}
.field-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
}
.intake input {
  width: 100%;
  min-width: 0;
  height: 56px;
  padding: 0 44px 0 16px;
  border: var(--line) solid var(--outline);
  border-radius: var(--r-md);
  background: var(--field);
  font-size: 1rem; /* 16px: no iOS zoom on focus */
  outline: none;
}
.intake input::placeholder {
  color: var(--muted);
  opacity: 0.9;
}
.intake input:focus-visible {
  box-shadow: 0 0 0 3px var(--pop);
}
.intake.dragging input {
  border-style: dashed;
  background: var(--soft);
}
/* Paste button inside the field, right side (shown while the field is empty). */
.field-paste {
  position: absolute;
  top: 9px;
  right: 9px;
  height: 38px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  border: 2px solid var(--outline);
  border-radius: 10px;
  background: var(--soft);
  font-weight: 800;
  font-size: 0.9375rem;
}
.field-paste:hover {
  background: var(--mint);
  color: #161616;
}
.field-paste .ic {
  width: 18px;
  height: 18px;
}
.intake input:placeholder-shown {
  padding-right: 112px; /* room for the Paste button */
}
/* Phones: link box full width (with its Paste button), the action button
   full width under it. */
@media (max-width: 559px) {
  .intake {
    flex-direction: column;
  }
  .intake input {
    height: 58px;
  }
  .field-paste {
    top: 10px;
    height: 38px;
  }
  .cta {
    width: 100%;
    height: 54px;
  }
}
.clear {
  position: absolute;
  top: 8px;
  right: 6px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 10px;
  background: none;
  display: grid;
  place-items: center;
}
.clear:hover {
  background: var(--soft);
}
.clear .ic {
  width: 18px;
  height: 18px;
}
.cta {
  flex: none;
  min-width: 128px;
  padding: 0 20px;
  white-space: nowrap;
  height: 56px;
  border: var(--line) solid var(--outline);
  border-radius: var(--r-md);
  background: var(--cta-bg);
  color: var(--cta-ink);
  font-weight: 800;
  font-size: 1.1rem;
  transition: transform 0.08s;
}
.cta:active:not(:disabled) {
  transform: translate(2px, 2px);
}
.cta:disabled {
  opacity: 0.7;
}
.alert {
  border: var(--line) solid var(--danger);
  border-radius: var(--r-sm);
  padding: 10px 14px;
  background: var(--card);
}
.alert strong {
  display: block;
  font-weight: 800;
  color: var(--danger);
}
.alert span {
  color: var(--muted);
  font-size: 0.9375rem;
}
.terms {
  margin-top: -4px;
  font-size: 0.8125rem;
  color: var(--muted);
}
.terms a {
  color: var(--ink);
  font-weight: 700;
}

/* Sister pages of the same platform (Video / To MP3 / To MP4 ...). */
.sisters ul {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 4px 6px 2px;
  scrollbar-width: none;
}
.sisters ul::-webkit-scrollbar {
  display: none;
}
.sisters a {
  display: block;
  white-space: nowrap;
  padding: 7px 16px;
  border: var(--line) solid var(--outline);
  border-radius: 99px;
  background: var(--card);
  font-weight: 800;
  text-decoration: none;
  box-shadow: 3px 3px 0 var(--shadow);
}
.sisters a:hover {
  background: var(--soft);
}
.sisters a[aria-current='page'] {
  background: var(--pop);
  color: var(--on-color);
}

/* Once a video is loaded the page keeps its shape: the pasted video takes
   the example card's place, and the guides stay below. */
.has-video .ex {
  display: none;
}
@media (min-width: 900px) {
  .has-video .hero-row {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: 32px;
    align-items: start;
  }
  .has-video .hero {
    padding-top: 36px;
  }
  .hero-row > .result {
    grid-column: 2;
    grid-row: 1;
  }
}

/* ------------------------------------------------------------- result --- */
/* "Your video": one card with the picture, details and formats. */
.result {
  position: relative;
  width: 100%;
  max-width: 480px;
  justify-self: end;
  margin-top: 14px;
  padding: 12px;
  border-radius: 22px;
}
.ex-tag.yours {
  background: var(--mint);
}
@media (max-width: 899px) {
  .result {
    max-width: none;
    justify-self: stretch;
    scroll-margin-top: 12px;
  }
}
.screen {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border: var(--line) solid #161616;
  border-radius: 14px;
  background: #000;
}
.screen img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Card layouts, like the example cards. Tall (Shorts, TikTok, Reels): the
   phone-shaped picture on the left, everything else beside it. Music (MP3
   pages): a square cover next to the title, formats below. */
.result.is-tall,
.result.is-music {
  display: grid;
  column-gap: 12px;
  align-items: start;
}
.result.is-tall {
  grid-template-columns: 150px minmax(0, 1fr);
}
.result.is-music {
  grid-template-columns: 112px minmax(0, 1fr);
}
.result.is-tall #videoCard,
.result.is-tall #videoBody,
.result.is-music #videoCard,
.result.is-music #videoBody {
  display: contents;
}
.result.is-tall .screen {
  grid-column: 1;
  grid-row: 1 / span 2;
  aspect-ratio: 9 / 16;
}
.result.is-tall .video-text,
.result.is-tall .sheet {
  grid-column: 2;
  min-width: 0;
}
.result.is-music .video-text,
.result.is-music .sheet {
  min-width: 0;
}
/* Narrow column: size goes under the name. */
.result.is-tall .opt-text {
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
}
.result.is-tall .opt-name,
.result.is-tall .opt-sub {
  max-width: 100%;
}
.result.is-tall .opt-name {
  flex: none;
}
.result.is-tall .video-text {
  padding-top: 0;
}
.result.is-music .screen {
  aspect-ratio: 1;
}
.result.is-music .video-text {
  align-self: center;
  padding: 0;
}
.result.is-music .sheet {
  grid-column: 1 / -1;
}
.result.is-tall .video-actions {
  flex-wrap: wrap;
  row-gap: 6px;
}
.result.is-tall .tabs {
  flex-basis: 100%;
  width: fit-content;
}
@media (max-width: 420px) {
  .result.is-tall {
    grid-template-columns: 116px minmax(0, 1fr);
  }
}
/* No thumbnail available: striped panel with the site name. */
.screen.empty {
  background: repeating-linear-gradient(45deg, var(--pop) 0 14px, var(--pop-soft) 14px 28px);
  display: grid;
  place-items: center;
}
.screen.empty::after {
  content: attr(data-site);
  padding: 6px 16px;
  border: var(--line) solid #161616;
  border-radius: 99px;
  background: #fffdf5;
  color: #161616;
  font-weight: 800;
  font-size: 1.25rem;
}
.live {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 2px 10px;
  border: 2px solid #161616;
  border-radius: 99px;
  background: var(--pop);
  color: #161616;
  font-weight: 800;
  font-size: 0.875rem;
}
.video-text {
  padding: 10px 2px 4px;
}
.video-text h2 {
  font-size: 1.0625rem;
  line-height: 1.25;
  font-weight: 800;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.meta {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.9375rem;
}
.meta span:empty {
  display: none;
}
.meta #site {
  font-weight: 800;
  color: var(--ink);
}
.video-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin-top: 8px;
}
/* "Clear": a small tag on the card's top-right edge, opposite "Your video". */
.result .card-clear {
  position: absolute;
  z-index: 2;
  top: -15px;
  right: 16px;
  height: auto;
  padding: 1px 10px;
  border: var(--line) solid var(--outline);
  border-radius: 12px;
  background: var(--card);
  color: var(--ink);
  font-weight: 800;
  font-size: 0.8125rem;
  text-decoration: none;
}
.result .card-clear:hover {
  background: var(--soft);
}
@media (max-width: 420px) {
  .video-actions {
    column-gap: 8px;
  }
  .video-actions .pill:not(.big) .ic {
    display: none;
  }
  .tabs button {
    padding: 4px 10px;
  }
}
.video-actions .pill:not(.big) {
  white-space: nowrap;
  padding: 0;
  border: 0;
  background: none;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 2px solid var(--outline);
  border-radius: 99px;
  background: var(--card);
  color: var(--ink);
  font-weight: 800;
  font-size: 0.875rem;
}
.pill:hover {
  background: var(--soft);
}
.pill:disabled {
  opacity: 0.7;
  cursor: progress;
}
.pill .ic {
  width: 16px;
  height: 16px;
}
/* Thumbnail pages: saving the image is the main action. */
.pill.big {
  flex: 1;
  justify-content: center;
  padding: 14px;
  border-width: var(--line);
  border-radius: var(--r-md);
  background: var(--mint);
  color: #161616;
  font-size: 1.1rem;
  box-shadow: 3px 3px 0 var(--shadow);
}
.pill.big .ic {
  width: 22px;
  height: 22px;
}
:root[data-theme='dark'] .pill.big {
  border-color: #161616;
}

/* "Cut a part" (switched off in app.js until it gets a timeline UI). */
.cut-toggle {
  margin-top: 10px;
  border: 0;
  background: none;
  font-weight: 800;
  text-decoration: underline;
}
.cut {
  margin-top: 6px;
  padding: 12px;
  border: var(--line) dashed var(--outline);
  border-radius: var(--r-md);
  background: var(--soft);
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 10px 12px;
}
.cut label {
  display: grid;
  gap: 2px;
  font-weight: 800;
  font-size: 0.875rem;
}
.cut input {
  width: 96px;
  height: 44px;
  padding: 0 10px;
  border: var(--line) solid var(--outline);
  border-radius: var(--r-sm);
  background: var(--field);
  font-size: 1rem;
}
.cut-msg {
  flex-basis: 100%;
  font-size: 0.875rem;
  font-weight: 700;
}
.cut-msg.bad {
  color: var(--danger);
}
.link-btn {
  height: 44px;
  border: 0;
  background: none;
  font-weight: 700;
  text-decoration: underline;
  color: var(--muted);
}

.skeleton {
  display: grid;
  gap: 10px;
}
.sk {
  background: var(--soft);
  animation: breathe 1.3s ease-in-out infinite;
}
.sk-media {
  aspect-ratio: 16 / 9;
  border-radius: 14px;
}
.sk-line {
  height: 16px;
  margin: 0 2px;
  border-radius: 6px;
}
.sk-row {
  height: 48px;
  border-radius: 14px;
}
.sk-note {
  text-align: center;
  font-weight: 800;
  font-size: 0.875rem;
  color: var(--muted);
}
.sk-line.short {
  width: 40%;
}
@keyframes breathe {
  50% {
    opacity: 0.45;
  }
}

/* ---------------------------------------------------------- the sheet --- */
.sheet {
  margin-top: 10px;
}
/* MP4 | MP3: a small switch in the card's action row. */
.tabs {
  display: inline-flex;
  flex: none;
  overflow: hidden;
  border: 2px solid var(--outline);
  border-radius: 99px;
}
.tabs button {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border: 0;
  background: var(--card);
  font-weight: 800;
  font-size: 0.875rem;
}
.tabs button + button {
  border-left: 2px solid var(--outline);
}
.tabs .ic {
  width: 15px;
  height: 15px;
}
.tabs button[aria-pressed='true'] {
  background: var(--pop);
  color: var(--on-color);
}
.tabs button:disabled {
  opacity: 0.4;
}
.sheet-note {
  margin-bottom: 8px;
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--danger);
}
/* The formats: rows like the example card. More than four scroll inside
   the card (styled scrollbar, fade at the bottom) so the page never grows. */
.options {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}
.options.scrolls {
  max-height: 196px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0 6px 18px 0;
  margin-right: -4px;
  scrollbar-width: thin;
  scrollbar-color: var(--outline) var(--soft);
  -webkit-mask-image: linear-gradient(#000 calc(100% - 26px), transparent);
  mask-image: linear-gradient(#000 calc(100% - 26px), transparent);
}
.options.scrolls::-webkit-scrollbar {
  width: 8px;
}
.options.scrolls::-webkit-scrollbar-track {
  background: var(--soft);
  border-radius: 99px;
}
.options.scrolls::-webkit-scrollbar-thumb {
  background: var(--outline);
  border-radius: 99px;
}
.options-more {
  margin-top: 4px;
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--muted);
}
.sheet-switch {
  display: block;
  margin-top: 10px;
  text-align: center;
  font-weight: 800;
  font-size: 0.9375rem;
  text-underline-offset: 3px;
}

/* One format = one row button. Its background doubles as the progress bar. */
.opt {
  --p: 0;
  position: relative;
  overflow: hidden;
  width: 100%;
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px 5px 11px;
  border: var(--line) solid var(--outline);
  border-radius: 12px;
  background: var(--field);
  text-align: left;
}
.opt.best {
  background: color-mix(in srgb, var(--mint) 18%, var(--field));
}
.opt:hover:not(:disabled) {
  background: var(--soft);
}
.opt::before {
  content: '';
  position: absolute;
  inset: 0;
  width: calc(var(--p) * 1%);
  background: repeating-linear-gradient(45deg, var(--pop-soft) 0 8px, var(--pop-softer) 8px 16px);
  transition: width 0.5s ease-out;
}
.opt-text {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.opt-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.9375rem;
  font-weight: 800;
  white-space: nowrap;
}
.opt-tag {
  margin-left: 6px;
  padding: 0 6px;
  border: 1.5px solid var(--outline);
  border-radius: 99px;
  background: var(--soft);
  font-style: normal;
  font-size: 0.6875rem;
  vertical-align: 2px;
}
.opt-sub {
  flex: none;
  max-width: 62%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--muted);
}
.opt-icon {
  position: relative;
  flex: none;
  width: 30px;
  height: 30px;
  border: 2px solid var(--outline);
  border-radius: 50%;
  background: var(--mint);
  color: #161616;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.5625rem;
  font-variant-numeric: tabular-nums;
}
.opt-icon .ic {
  width: 15px;
  height: 15px;
}
.opt.busy {
  background: var(--card);
}
.opt.busy .opt-icon {
  background: var(--card);
  color: var(--ink);
}
/* Unknown progress (waiting, converting): stripes slide across. */
.opt.busy.indeterminate::before {
  width: 100%;
  opacity: 0.6;
  background-size: 200% 100%;
  animation: slide 1.2s linear infinite;
}
@keyframes slide {
  to {
    background-position: -45px 0;
  }
}
.opt.done .opt-icon {
  background: var(--ink);
  color: var(--mint);
}
.opt.failed .opt-sub {
  color: var(--danger);
}
.opt.failed .opt-icon {
  background: var(--card);
  color: var(--ink);
}
.opt:disabled .opt-name,
.opt:disabled .opt-sub {
  color: var(--muted);
}
.opt:disabled .opt-icon {
  background: var(--soft);
  color: var(--muted);
  border-color: var(--muted);
}

/* ---------------------------------------------------- content sections --- */
.content {
  display: grid;
  grid-template-columns: minmax(0, 1fr); /* wide chip rows scroll instead of stretching the page */
  gap: 18px;
}
.sec {
  border-radius: var(--r-lg);
  padding: clamp(18px, 3vw, 26px);
}
.sec h2,
.related h2 {
  margin-bottom: 14px;
  font-size: clamp(1.3rem, 3vw, 1.6rem);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.prose p {
  max-width: 72ch;
  color: var(--muted);
  font-size: 1.0625rem;
  line-height: 1.6;
}
.prose p + p {
  margin-top: 10px;
}
.prose a,
.faq a,
.doc a {
  color: var(--ink);
  font-weight: 800;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

/* "What you get": one strip split into equal columns by thin lines (the
   grid gap shows the strip's background as the divider), not cards in a
   card. Desktop: 5 across. Phones: 2 across, the last one full width. */
.feats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 2px;
  overflow: hidden;
  border: var(--line) solid var(--outline);
  border-radius: 18px;
  background: color-mix(in srgb, var(--outline) 16%, var(--field));
}
.feat {
  padding: 18px 16px 20px;
  background: var(--field);
}
.tile {
  width: 52px;
  height: 52px;
  margin-bottom: 12px;
  border: var(--line) solid #161616;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #161616;
  --duo: #fff;
  --duo-opacity: 1;
}
.tile .ic {
  width: 30px;
  height: 30px;
}
.tone-pop {
  background: var(--pop);
}
.tone-mint {
  background: var(--mint);
}
.tone-sun {
  background: var(--sun);
}
:root[data-theme='dark'] .tile {
  border-color: var(--outline);
}
.feat b {
  display: block;
  font-size: 1.0625rem;
  line-height: 1.25;
}
.feat-desc {
  display: block;
  margin-top: 3px;
  font-size: 0.875rem;
  line-height: 1.4;
  color: var(--muted);
}
@media (max-width: 859px) {
  .feats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  /* Odd one out spans the row and lays out sideways. */
  .feat:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 14px;
  }
  .feat:last-child:nth-child(odd) .tile {
    margin-bottom: 0;
  }
}

/* FAQ: native disclosure widgets, plus/minus icons. */
.faq details {
  border-top: 2px solid var(--soft);
}
.faq details:first-of-type {
  border-top: 0;
}
.faq summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 0;
  font-weight: 800;
  font-size: 1.0625rem;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq-icon {
  width: 32px;
  height: 32px;
  flex: none;
  border: 2px solid var(--outline);
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.faq-icon .ic {
  width: 16px;
  height: 16px;
}
.faq-icon .minus,
.faq details[open] .faq-icon .plus {
  display: none;
}
.faq details[open] .faq-icon .minus {
  display: block;
}
.faq details[open] .faq-icon {
  background: var(--pop);
  color: #161616;
}
.faq details p {
  max-width: 72ch;
  padding: 0 0 16px;
  color: var(--muted);
  line-height: 1.6;
}
/* SEO pages: two columns of questions on wide screens. */
.faq-cols {
  display: grid;
  gap: 0 32px;
}
.faq-cols > div > details:first-child {
  border-top: 0;
}
@media (min-width: 860px) {
  .faq-cols {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}
@media (max-width: 859px) {
  .faq-cols > div + div > details:first-child {
    border-top: 2px solid var(--soft);
  }
}

/* ------------------------------------------------------ SEO sections --- */
/* Calm by design: thin dividers and one accent per section; the boxes,
   shadows and colour stay with the tool itself. */
.sec-lead {
  max-width: 70ch;
  color: var(--muted);
  font-size: 1.0625rem;
  line-height: 1.6;
}
.sec-lead + .sec-lead {
  margin-top: 10px;
}
.sec-lead b,
.choice b,
.fixes p b,
.allowed b {
  color: var(--ink);
}
.prose code,
.link-lists code {
  font-family: inherit;
  font-weight: 800;
}
.foot-note {
  margin-top: 14px;
  max-width: 70ch;
  font-size: 0.875rem;
  color: var(--muted);
}

.sec[id] {
  scroll-margin-top: 16px;
}

/* Devices: four columns split by thin lines (no boxes inside the box). */
.devices {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 2px solid var(--soft);
}
.dev {
  padding: 14px 16px 4px;
  border-left: 2px solid var(--soft);
}
.dev:first-child {
  padding-left: 0;
  border-left: 0;
}
.dev h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 1.0625rem;
  font-weight: 800;
}
.dev h3 .ic {
  width: 20px;
  height: 20px;
}
.dev ol {
  padding-left: 18px;
  list-style: decimal;
  color: var(--muted);
  font-size: 0.9375rem;
  line-height: 1.5;
}
.dev b {
  color: var(--ink);
}
.dev .dev-where {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 9px;
  font-size: 0.8125rem;
  font-weight: 700;
}
.dev-where .ic {
  width: 16px;
  height: 16px;
  color: var(--muted);
}

/* File-size calculator */
.len {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 16px 0 10px;
  padding: 12px 16px;
  border: 2px solid var(--outline);
  border-radius: 14px;
  background: var(--soft);
}
.len label {
  font-weight: 800;
  white-space: nowrap;
}
.len input {
  --fill: 5%;
  flex: 1;
  min-width: 0;
  height: 28px;
  margin: 0;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}
.len input::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 99px;
  background:
    linear-gradient(var(--ink), var(--ink)) 0 / var(--fill) 100% no-repeat,
    color-mix(in srgb, var(--ink) 15%, transparent);
}
.len input::-moz-range-track {
  height: 8px;
  border-radius: 99px;
  background: color-mix(in srgb, var(--ink) 15%, transparent);
}
.len input::-moz-range-progress {
  height: 8px;
  border-radius: 99px;
  background: var(--ink);
}
.len input::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  margin-top: -8px;
  border: var(--line) solid var(--outline);
  border-radius: 50%;
  background: var(--field);
}
.len input::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: var(--line) solid var(--outline);
  border-radius: 50%;
  background: var(--field);
}
.len-val {
  min-width: 72px;
  text-align: right;
  font-weight: 800;
  font-size: 1.125rem;
  font-variant-numeric: tabular-nums;
}
.bar {
  display: grid;
  grid-template-columns: minmax(0, 240px) minmax(0, 1fr) 86px;
  gap: 14px;
  align-items: center;
  padding: 8px 0;
  border-top: 2px solid var(--soft);
}
.bar:first-child {
  border-top: 0;
}
.bar-name b {
  font-weight: 800;
}
.bar-name small {
  margin-left: 7px;
  font-size: 0.875rem;
  color: var(--muted);
}
.bar.best .bar-name small {
  color: var(--ink);
  font-weight: 700;
}
.track {
  height: 10px;
  border-radius: 99px;
  background: color-mix(in srgb, var(--ink) 10%, transparent);
}
.fill {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: var(--ink);
}
.bar.best .fill {
  background: var(--mint);
  box-shadow: 0 0 0 2px var(--outline);
}
.mb {
  text-align: right;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.w-5 {
  width: 5%;
}
.w-10 {
  width: 10%;
}
.w-15 {
  width: 15%;
}
.w-20 {
  width: 20%;
}
.w-25 {
  width: 25%;
}
.w-30 {
  width: 30%;
}
.w-35 {
  width: 35%;
}
.w-40 {
  width: 40%;
}
.w-45 {
  width: 45%;
}
.w-50 {
  width: 50%;
}
.w-55 {
  width: 55%;
}
.w-60 {
  width: 60%;
}
.w-65 {
  width: 65%;
}
.w-70 {
  width: 70%;
}
.w-75 {
  width: 75%;
}
.w-80 {
  width: 80%;
}
.w-85 {
  width: 85%;
}
.w-90 {
  width: 90%;
}
.w-95 {
  width: 95%;
}
.w-100 {
  width: 100%;
}

/* Explainers (MP3 bitrate, MP4 formats) */
.two {
  display: grid;
  gap: 22px;
  align-items: start;
}
@media (min-width: 860px) {
  .two {
    grid-template-columns: 1fr 1fr;
  }
}
.choices {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.choices.wide {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}
.choice {
  padding: 9px 12px;
  border: var(--line) solid var(--outline);
  border-radius: 14px;
  background: var(--field);
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.35;
}
.choice b {
  display: block;
  font-size: 1rem;
}
.choice.best {
  background: color-mix(in srgb, var(--mint) 22%, var(--field));
}
.wave {
  margin: 0;
  padding: 14px;
  border: var(--line) solid var(--outline);
  border-radius: 18px;
  background: var(--field);
}
.lane {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}
.lane b {
  display: block;
  font-size: 0.9375rem;
}
.lane small {
  display: block;
  font-size: 0.8125rem;
  color: var(--muted);
}
.wave-svg {
  width: 100%;
  height: 40px;
}
.wave-bg {
  fill: var(--soft);
}
.wave-svg path {
  fill: none;
  stroke-width: 2;
}
.wave-ink {
  stroke: var(--ink);
}
.wave-mint {
  stroke: #1a9e66;
}
.wave-pop {
  stroke: #d6336c;
}
.wave-cut {
  stroke: var(--ink);
  stroke-width: 2;
  stroke-dasharray: 3 3;
}
.wave figcaption {
  padding: 8px 10px;
  border: 2px dashed var(--outline);
  border-radius: 12px;
  background: var(--soft);
  font-size: 0.875rem;
}

/* Thumbnail sizes table */
.tbl-wrap {
  margin-top: 14px;
  overflow-x: auto;
  border: var(--line) solid var(--outline);
  border-radius: 16px;
  background: var(--field);
}
.tbl {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}
.tbl th,
.tbl td {
  padding: 10px 14px;
  text-align: left;
  border-top: 2px solid var(--soft);
}
.tbl thead th {
  border-top: 0;
  background: var(--ink);
  color: var(--bg);
  font-weight: 800;
}
.tbl tbody th {
  font-weight: 800;
  white-space: nowrap;
}
.tbl td {
  color: var(--muted);
}
.tbl tr.best > * {
  background: color-mix(in srgb, var(--mint) 18%, var(--field));
}

/* Links that work */
.addr {
  margin-top: 14px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  padding: 9px 14px;
  border: var(--line) solid var(--outline);
  border-radius: 14px;
  background: var(--field);
  overflow-wrap: anywhere;
}
.addr > .ic {
  width: 16px;
  height: 16px;
  color: var(--muted);
}
@media (max-width: 559px) {
  .addr > span {
    flex: 1;
    min-width: 0;
  }
  .addr small {
    flex-basis: 100%;
  }
}
.addr mark {
  white-space: nowrap;
  padding: 0 5px;
  border: 2px solid var(--outline);
  border-radius: 7px;
  background: var(--sun);
  color: #161616;
  font-weight: 800;
}
.addr small {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  font-size: 0.875rem;
}
.addr small .up {
  width: 14px;
  height: 14px;
}
.link-lists {
  margin-top: 16px;
  display: grid;
  gap: 18px;
}
@media (min-width: 760px) {
  .link-lists {
    grid-template-columns: 1fr 1fr;
  }
}
.link-lists h3 {
  margin-bottom: 8px;
  font-size: 1.0625rem;
  font-weight: 800;
}
.link-lists ul {
  display: grid;
  gap: 7px;
}
.link-lists li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 0.9375rem;
  color: var(--muted);
}
.link-lists li .ic {
  width: 22px;
  height: 22px;
  padding: 3px;
  border: 2px solid var(--outline);
  border-radius: 50%;
  color: #161616;
}
.link-lists .ok .ic {
  background: var(--mint);
}
.link-lists .no .ic {
  background: var(--pop);
}

/* Fixes: a quiet two-column list */
.fixes {
  margin-top: 6px;
  display: grid;
  gap: 0 32px;
}
@media (min-width: 760px) {
  .fixes {
    grid-template-columns: 1fr 1fr;
  }
  .fixes li:nth-child(2) {
    border-top: 0;
  }
}
.fixes li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 3px 10px;
  padding: 12px 0;
  border-top: 2px solid var(--soft);
}
.fixes li:first-child {
  border-top: 0;
}
.fix-ic {
  grid-row: span 2;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  border: 2px solid var(--outline);
  border-radius: 50%;
  background: var(--pop);
  color: #161616;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  font-weight: 800;
}
.fixes b {
  font-weight: 800;
}
.fixes p {
  font-size: 0.9375rem;
  color: var(--muted);
  line-height: 1.45;
}

/* Safe and legal */
.nots {
  margin: 14px 0 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.nots li {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px 5px 6px;
  border: var(--line) solid var(--outline);
  border-radius: 14px;
  background: var(--field);
  font-weight: 800;
}
.nots .ic {
  width: 22px;
  height: 22px;
  padding: 2px;
  border-radius: 50%;
  background: var(--pop);
  color: #161616;
}
.allowed {
  max-width: 80ch;
  padding: 12px 14px;
  border: 2px dashed var(--outline);
  border-radius: 14px;
  background: var(--soft);
  line-height: 1.55;
}
.allowed a {
  color: var(--ink);
  font-weight: 800;
}

/* Phones: a "Paste a link" button follows you down the page. */
.sticky-paste {
  position: fixed;
  z-index: 15;
  left: 14px;
  right: 14px;
  bottom: max(14px, env(safe-area-inset-bottom));
  height: 54px;
  border: var(--line) solid var(--outline);
  border-radius: var(--r-md);
  background: var(--cta-bg);
  color: var(--cta-ink);
  font-weight: 800;
  font-size: 1.0625rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 4px 4px 0 var(--pop);
  animation: drop 0.2s ease-out;
}
@media (min-width: 760px) {
  .sticky-paste {
    display: none !important;
  }
}

/* ------------------------------------------------------ step pictures --- */
/* Small copies of the real interface. Decorative (aria-hidden). */
.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.step {
  border: var(--line) solid var(--outline);
  border-radius: 20px;
  background: var(--field);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.stage {
  height: 190px;
  position: relative;
  border-bottom: var(--line) solid var(--outline);
  background-color: var(--soft);
  background-image: radial-gradient(rgb(22 22 22 / 0.12) 1.2px, transparent 1.2px);
  background-size: 14px 14px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: #161616;
  font-size: 13px;
}
:root[data-theme='dark'] .stage {
  background-image: radial-gradient(rgb(255 248 225 / 0.12) 1.2px, transparent 1.2px);
}
.step-text {
  padding: 14px 16px 16px;
}
.step-text h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.125rem;
  font-weight: 800;
}
.step-text p {
  margin-top: 6px;
  color: var(--muted);
}
.num {
  width: 32px;
  height: 32px;
  flex: none;
  border: var(--line) solid var(--outline);
  border-radius: 50%;
  background: var(--mint);
  color: #161616;
  display: grid;
  place-items: center;
  font-size: 0.875rem;
}
.hand {
  position: absolute;
  width: 30px;
  height: 30px;
  color: #161616;
  filter: drop-shadow(2px 2px 0 #fff);
}
/* 1: phone with share sheet */
.m-phone {
  position: absolute;
  top: 16px;
  width: 132px;
  height: 230px;
  padding: 8px;
  border: 3px solid #161616;
  border-radius: 22px;
  background: #fff;
  box-shadow: 4px 4px 0 #161616;
}
.m-video {
  height: 62px;
  border: 2px solid #161616;
  border-radius: 10px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
}
.m-video .ic {
  width: 30px;
  height: 30px;
}
.m-share {
  position: absolute;
  left: -30px;
  right: -30px;
  top: 70px;
  padding: 8px;
  border: 3px solid #161616;
  border-radius: 16px;
  background: #fffdf5;
  box-shadow: 3px 3px 0 #161616;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.m-share > div {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 700;
}
.m-share i {
  width: 34px;
  height: 34px;
  border: 2px solid #161616;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
}
.m-share i .ic {
  width: 18px;
  height: 18px;
}
.m-share .hit i {
  background: var(--pop);
}
.m-share .hand {
  left: 30px;
  top: 6px;
  width: 24px;
  height: 24px;
}
/* 2: our link box */
.m-pasted {
  position: absolute;
  top: 30px;
  left: 22px;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border: 2px solid #161616;
  border-radius: 99px;
  background: var(--mint);
  font-size: 12px;
  font-weight: 800;
}
.m-pasted .ic {
  width: 14px;
  height: 14px;
}
.m-intake {
  width: 88%;
  display: flex;
  gap: 6px;
  padding: 8px;
  border: 3px solid #161616;
  border-radius: 16px;
  background: #fffdf5;
  box-shadow: 4px 4px 0 #161616;
}
.m-field {
  flex: 1;
  min-width: 0;
  height: 40px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 9px;
  border: 3px solid #161616;
  border-radius: 11px;
  background: #fff;
}
.m-field span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.m-field .ic {
  width: 16px;
  height: 16px;
  color: #55524a;
}
.m-cta {
  height: 40px;
  padding: 0 12px;
  border-radius: 11px;
  background: #161616;
  color: #fff;
  font-weight: 800;
  font-size: 14px;
  white-space: nowrap;
  display: grid;
  place-items: center;
}
.hand-cta {
  right: 30px;
  bottom: 32px;
}
/* 3: our format rows / thumbnail card */
.m-sheet {
  width: 88%;
  padding: 10px;
  border: 3px solid #161616;
  border-radius: 18px;
  background: #fffdf5;
  box-shadow: 4px 4px 0 #161616;
  display: grid;
  gap: 6px;
}
.m-tabs {
  display: flex;
  gap: 6px;
}
.m-tabs span {
  flex: 1;
  padding: 4px;
  border: 2px solid #161616;
  border-radius: 10px;
  text-align: center;
  font-size: 11px;
  font-weight: 800;
}
.m-tabs .on {
  background: var(--pop);
}
.m-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
  border: 2px solid transparent;
  border-radius: 11px;
  overflow: hidden;
}
.m-row .t {
  position: relative;
  flex: 1;
  font-size: 14.5px;
  font-weight: 800;
  line-height: 1.15;
}
.m-row .t small {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: #55524a;
}
.m-row .c {
  position: relative;
  width: 32px;
  height: 32px;
  border: 2px solid #161616;
  border-radius: 50%;
  background: var(--mint);
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 800;
}
.m-row .c .ic {
  width: 16px;
  height: 16px;
}
.m-row .c.done {
  background: #161616;
  color: var(--mint);
}
.m-row.busy {
  border-color: #161616;
  background: #fff;
}
.m-row.busy::before {
  content: '';
  position: absolute;
  inset: 0 36% 0 0;
  background: repeating-linear-gradient(45deg, #ffc2d5 0 7px, #ffdfe9 7px 14px);
}
.m-row.busy .c {
  background: #fff;
}
.m-thumb {
  width: 78%;
  padding: 8px;
  border: 3px solid #161616;
  border-radius: 16px;
  background: #fffdf5;
  box-shadow: 4px 4px 0 #161616;
  display: grid;
  gap: 8px;
  justify-items: center;
}
.m-thumb-img {
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 86px;
  border: 2px solid #161616;
  border-radius: 10px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  position: relative;
}
.m-thumb-img .ic {
  width: 32px;
  height: 32px;
}
.m-thumb-img span {
  position: absolute;
  right: 6px;
  bottom: 4px;
  padding: 0 5px;
  border-radius: 6px;
  background: #161616;
  font-size: 10px;
  font-weight: 800;
}
.m-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border: 2px solid #161616;
  border-radius: 99px;
  background: var(--mint);
  font-size: 12px;
  font-weight: 800;
}
.m-pill .ic {
  width: 14px;
  height: 14px;
}
.hand-pill {
  left: 58%;
  bottom: 14px;
}

/* --------------------------------------------------------- tool cards --- */
.tools {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}
.tool {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 100%;
  padding: 14px;
  border: var(--line) solid var(--outline);
  border-radius: 18px;
  background: var(--card);
  box-shadow: 4px 4px 0 var(--shadow);
  text-decoration: none;
  transition:
    transform 0.12s,
    box-shadow 0.12s,
    background-color 0.12s;
}
.tool:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--shadow);
  background: var(--soft);
}
.tool:active {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 var(--shadow);
}
.tool-text {
  flex: 1;
  min-width: 0;
}
.tool-text b {
  display: block;
  font-size: 1.0625rem;
  line-height: 1.2;
}
.tool-text span {
  font-size: 0.875rem;
  color: var(--muted);
}
.go {
  width: 36px;
  height: 36px;
  flex: none;
  border: 2px solid var(--outline);
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.go .ic {
  width: 16px;
  height: 16px;
}
.tool:hover .go {
  background: var(--ink);
  color: var(--bg);
}

/* ------------------------------------------------------------- footer --- */
.site-foot {
  margin-top: 18px;
  background: var(--foot-bg);
  color: var(--foot-ink);
  padding: 32px 0 max(28px, env(safe-area-inset-bottom));
}
.fcols {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: 24px;
}
.fcol .brand {
  font-size: 1.25rem;
}
.fcol.about p {
  margin-top: 10px;
  color: var(--foot-muted);
  font-size: 0.9375rem;
  max-width: 28ch;
}
.fhead {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: var(--sun);
  font-weight: 800;
}
.fhead .ic {
  width: 18px;
  height: 18px;
}
.fcol li a {
  display: inline-block;
  padding: 4px 0;
  color: var(--foot-muted);
  text-decoration: none;
  font-size: 0.9375rem;
}
.fcol li a:hover {
  color: var(--foot-ink);
  text-decoration: underline;
}
.fine {
  margin-top: 26px;
  padding-top: 16px;
  border-top: 1px solid rgb(255 248 225 / 0.15);
  color: var(--foot-muted);
  font-size: 0.8125rem;
}

/* --------------------------------------------------------- legal pages --- */
.doc {
  max-width: 820px;
}
.doc h1 {
  margin-bottom: 12px;
  font-size: clamp(1.9rem, 5vw, 2.6rem);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.doc h2 {
  margin: 24px 0 8px;
  font-size: 1.25rem;
  font-weight: 800;
}
.doc p {
  max-width: 72ch;
  line-height: 1.65;
  color: var(--muted);
}
.doc p + p {
  margin-top: 8px;
}

/* ------------------------------------------------------------- toasts --- */
.toasts {
  position: fixed;
  z-index: 20;
  top: max(12px, env(safe-area-inset-top));
  left: 50%;
  transform: translateX(-50%);
  width: min(440px, calc(100vw - 24px));
  display: grid;
  gap: 8px;
}
.toast {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 0 8px;
  padding: 10px 6px 10px 14px;
  border: var(--line) solid #161616;
  border-radius: var(--r-md);
  background: var(--mint);
  color: #161616;
  box-shadow: 4px 4px 0 #161616;
  animation: drop 0.2s ease-out;
}
.toast.error {
  background: var(--pop);
}
.toast.info {
  background: #fffdf5;
}
.toast b {
  font-weight: 800;
}
.toast p {
  grid-column: 1;
  font-size: 0.9375rem;
  overflow-wrap: anywhere;
}
.toast button {
  grid-column: 2;
  grid-row: 1 / span 2;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: inherit;
  display: grid;
  place-items: center;
}
.toast button:hover {
  background: rgb(0 0 0 / 0.08);
}
.toast .ic {
  width: 16px;
  height: 16px;
}
@keyframes drop {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
}

/* --------------------------------------------------------- responsive --- */
@media (max-width: 1000px) {
  .fcols {
    grid-template-columns: repeat(3, 1fr);
  }
  .fcol.about {
    grid-column: 1 / -1;
  }
}
/* Below laptop width the flat menu moves into the slide-in panel; the
   sister tabs under the tool take over. */
@media (max-width: 1079px) {
  .menu {
    display: none;
  }
  .menu-btn {
    display: grid;
  }
  .devices {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .dev:nth-child(odd) {
    padding-left: 0;
    border-left: 0;
  }
  .dev:nth-child(n + 3) {
    border-top: 2px solid var(--soft);
  }
}
@media (min-width: 1080px) {
  .sisters {
    display: none;
  }
}
@media (max-width: 859px) {
  .steps {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 559px) {
  .devices {
    grid-template-columns: 1fr;
  }
  .dev {
    padding: 12px 0 6px;
    border-left: 0;
  }
  .dev + .dev {
    border-top: 2px solid var(--soft);
  }
  .bar {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px 10px;
  }
  .track {
    grid-column: 1 / -1;
    grid-row: 2;
  }
  .len {
    flex-wrap: wrap;
    gap: 6px 12px;
  }
  .len input {
    order: 3;
    flex-basis: 100%;
  }
  .len-val {
    margin-left: auto;
  }
  .lane {
    grid-template-columns: 96px minmax(0, 1fr);
  }
  .hero h1 {
    font-size: 2.15rem;
  }
}
@media (max-width: 759px) {
  .cta {
    min-width: 0;
    padding: 0 16px;
  }
  .fcols {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
}
@media (max-width: 380px) {
  .cta {
    padding: 0 12px;
    font-size: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
@media (forced-colors: active) {
  .opt::before {
    background: Highlight;
    forced-color-adjust: none;
  }
  .sticker,
  .tile {
    forced-color-adjust: none;
  }
}
