/* vlickd — design tokens and layout.
 *
 * Hand-written CSS, no framework and no build step, matching the house style in
 * futtoday and dapcollections.
 *
 * THEMING. Three states, and all three must work:
 *   :root                      light, the default
 *   prefers-color-scheme:dark  the system default when nothing is chosen
 *   [data-theme]               an explicit choice, which must beat the system
 * Every colour is defined once on :root and only REDEFINED in the other two
 * blocks. A colour whose only definition lives inside a media query is a colour
 * that disappears in the other theme.
 *
 * ⚠ THE VIDEO STAGE STAYS DARK IN BOTH THEMES. Every serious editor does this,
 * and the reason is not fashion: a light surround shifts your perception of
 * what you are looking at, and the footage is the thing being judged.
 *
 * ⚠ BRAND COLOURS ARE NOT THEMED. --brand-blue and --brand-teal are the two
 * colours sampled out of the logo mark; they are constants, so a gradient built
 * from them is the same object in light and dark. --accent is the *themed*
 * interactive colour derived from them: on white, raw #2dd4c8 is a 1.7:1 link
 * and unreadable, so light mode darkens it until it passes. Do not "simplify"
 * this by pointing --accent at --brand-teal.
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  /* Brand — identical in both themes. Sampled from the logo mark. */
  --brand-blue: #2b6ef0;
  --brand-teal: #2dd4c8;
  --brand-grad: linear-gradient(135deg, var(--brand-blue), var(--brand-teal));

  --bg: #ffffff;
  --surface: #f7f8fb;
  --surface-2: #edeff5;
  --border: #dfe3ec;
  --text: #12141a;
  --muted: #5c6270;

  /* Teal, darkened until it clears 4.5:1 on --bg. See the header note. */
  --accent: #0c8279;
  --accent-hover: #0a6a63;
  --accent-fg: #ffffff;

  /* The maximum-contrast button: dark ink on light, white on dark. */
  --solid-bg: #12141a;
  --solid-fg: #ffffff;

  --danger: #d1394b;
  --success: #1a8a5a;
  --warn: #a86b00;

  /* Hero / CTA wash. Far weaker on white than on the dark ground: the same
   * alpha that reads as atmosphere on #10121c reads as a smear on #fff. */
  --glow-teal: color-mix(in srgb, var(--brand-teal) 16%, transparent);
  --glow-blue: color-mix(in srgb, var(--brand-blue) 15%, transparent);

  /* The editor stage: identical in both themes, on purpose — including the
   * accent painted ON it, which is why this is not just var(--accent). */
  --stage: #0b0c0f;
  --stage-2: #1a1c22;
  --stage-text: #e9ebf0;
  --stage-muted: #9aa0ad;
  --stage-border: #2a2e38;
  --stage-accent: var(--brand-teal);

  --radius: 10px;
  --radius-lg: 16px;
  --radius-pill: 999px;
  --shadow: 0 1px 2px rgba(16, 18, 24, .06), 0 4px 16px rgba(16, 18, 24, .06);
  --font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #10121c;
    --surface: #171a27;
    --surface-2: #1f2331;
    --border: #2a2f42;
    --text: #e9eaf2;
    --muted: #9aa1b8;
    --accent: #2dd4c8;
    --accent-hover: #5ce3d9;
    --accent-fg: #06201e;
    --solid-bg: #ffffff;
    --solid-fg: #0c0d14;
    --danger: #f0788a;
    --success: #4cc38a;
    --warn: #e0a33a;
    --glow-teal: color-mix(in srgb, var(--brand-teal) 30%, transparent);
    --glow-blue: color-mix(in srgb, var(--brand-blue) 36%, transparent);
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 4px 16px rgba(0, 0, 0, .3);
  }
}

:root[data-theme="dark"] {
  --bg: #10121c;
  --surface: #171a27;
  --surface-2: #1f2331;
  --border: #2a2f42;
  --text: #e9eaf2;
  --muted: #9aa1b8;
  --accent: #2dd4c8;
  --accent-hover: #5ce3d9;
  --accent-fg: #06201e;
  --solid-bg: #ffffff;
  --solid-fg: #0c0d14;
  --danger: #f0788a;
  --success: #4cc38a;
  --warn: #e0a33a;
  --glow-teal: color-mix(in srgb, var(--brand-teal) 30%, transparent);
  --glow-blue: color-mix(in srgb, var(--brand-blue) 36%, transparent);
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 4px 16px rgba(0, 0, 0, .3);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font);
  /* Explicit, never inherited: a transparent body borrows the host's colour. */
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); }

/* ---------------------------------------------------------------- chrome */

/* The pill nav. Floats over whatever it sits on rather than sitting in a bar
 * with a bottom border, which is what lets the hero gradient run to the top of
 * the page. It is sticky, so `backdrop-filter` is doing real work: the content
 * scrolls under it. */
.pill-nav {
  position: sticky; top: 14px; z-index: 20;
  display: flex; align-items: center; gap: 24px;
  max-width: 1040px; margin: 14px auto 0;
  padding: 8px 8px 8px 20px; min-height: 54px;
  border: 1px solid var(--border); border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.brand {
  display: flex; align-items: center; gap: 9px;
  font-weight: 600; font-size: 18px; letter-spacing: -.02em;
  color: var(--text); text-decoration: none;
}
.brand .mark { width: 26px; height: 26px; display: block; }
.nav-links { display: flex; align-items: center; gap: 26px; margin-right: auto; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 14px; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-actions .time { max-width: 22ch; overflow: hidden; text-overflow: ellipsis; }

/* Under ~760px the middle links collapse; the actions stay, because "Try it
 * free" on a phone is the entire point of the page. */
@media (max-width: 760px) {
  .nav-links { display: none; }
  .pill-nav { gap: 12px; padding-left: 16px; }
  .brand span { display: none; }
}

.plan {
  font-size: 12px; font-weight: 600; padding: 4px 10px;
  border-radius: var(--radius-pill); background: var(--surface-2); color: var(--muted);
}
.plan.paid { background: var(--brand-grad); color: #fff; }
.spacer { flex: 1; }

main { max-width: 1180px; margin: 0 auto; padding: 40px 24px 72px; }
h1 { font-size: 32px; letter-spacing: -.03em; margin: 0 0 6px; font-weight: 600; }
h2 { font-size: 15px; margin: 0 0 12px; font-weight: 600; }
.sub { color: var(--muted); margin: 0 0 26px; font-size: 15px; }

/* ---------------------------------------------------------------- controls */

/* One rule for <button> and for links dressed as buttons, so an <a href> and a
 * <button> sitting next to each other in the nav line up exactly. */
button, .btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-size: 14px; font-weight: 600; line-height: 1.2;
  cursor: pointer; text-decoration: none; white-space: nowrap;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  padding: 9px 18px; border-radius: var(--radius-pill);
  transition: background .15s, border-color .15s, color .15s;
}
button:hover:not(:disabled), .btn:hover { background: var(--surface-2); }
button:disabled { opacity: .5; cursor: not-allowed; }

button.primary, .btn.primary {
  background: var(--accent); border-color: var(--accent); color: var(--accent-fg);
}
button.primary:hover:not(:disabled), .btn.primary:hover {
  background: var(--accent-hover); border-color: var(--accent-hover);
}
.btn.solid { background: var(--solid-bg); border-color: var(--solid-bg); color: var(--solid-fg); }
.btn.solid:hover { background: var(--solid-bg); border-color: var(--solid-bg); opacity: .88; }
.btn.ghost { background: transparent; }
.btn.ghost:hover { border-color: var(--accent); color: var(--accent); background: transparent; }
.btn.big { padding: 15px 30px; font-size: 16px; }
.btn.block, button.block { width: 100%; }

/* Square, and the same height as a .btn, so a nav with only an icon button in
 * it is not 3px shorter than one with a text button beside it. */
button.icon {
  width: 36px; height: 36px; padding: 0; font-size: 14px; flex: none;
}

/* Visible focus. Removing it to "clean up" the design makes the app
 * unusable by keyboard, which is not a tradeoff worth making. */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------------------------------------------------------------- dropzone */

.drop {
  border: 2px dashed var(--border); border-radius: var(--radius-lg);
  padding: 56px 24px; text-align: center; background: var(--surface);
  transition: border-color .15s, background .15s;
}
.drop.over { border-color: var(--accent); background: var(--surface-2); }
.drop p { color: var(--muted); margin: 10px 0 18px; }
.limits { font-size: 13px; color: var(--muted); margin-top: 18px; }

.bar {
  height: 6px; background: var(--surface-2); border-radius: var(--radius-pill);
  overflow: hidden; margin: 16px 0 8px;
}
.bar > i { display: block; height: 100%; width: 0; background: var(--brand-grad); }
.status { font-size: 13px; color: var(--muted); }
.status.err { color: var(--danger); }
.status.ok { color: var(--success); }

.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow);
}
.hidden { display: none !important; }

/* ---------------------------------------------------------------- editor */

.editor { display: grid; grid-template-columns: 1fr 320px; gap: 20px; }
@media (max-width: 900px) { .editor { grid-template-columns: 1fr; } }

.stage {
  background: var(--stage); border-radius: var(--radius-lg);
  padding: 14px; color: var(--stage-text);
}
.stage video {
  width: 100%; max-height: 58vh; display: block;
  background: #000; border-radius: var(--radius);
}

.transport {
  display: flex; align-items: center; gap: 10px; margin-top: 12px;
  color: var(--stage-text);
}
.transport button {
  background: var(--stage-2); border-color: var(--stage-border);
  color: var(--stage-text);
}
.transport button:hover:not(:disabled) { background: #262a33; }
.transport button.icon { width: auto; min-width: 36px; padding: 0 12px; }
.time { font-family: var(--mono); font-size: 13px; color: var(--stage-muted); }

/* --- timeline ---
 * Hand-built rather than a library: it is ~80 lines and a dependency here
 * would be the only one in the project.
 * Everything painted here uses --stage-accent, not --accent: the stage is dark
 * in both themes, so a light-theme accent chosen for contrast on white would be
 * the one thing on this surface you cannot see. */
.timeline {
  position: relative; height: 56px; margin-top: 12px;
  background: var(--stage-2); border-radius: var(--radius);
  border: 1px solid var(--stage-border);
  cursor: pointer; user-select: none; touch-action: none;
}
.tl-sel {
  position: absolute; top: 0; bottom: 0;
  background: color-mix(in srgb, var(--stage-accent) 30%, transparent);
  border-left: 2px solid var(--stage-accent); border-right: 2px solid var(--stage-accent);
}
.tl-handle {
  position: absolute; top: 0; bottom: 0; width: 14px;
  margin-left: -7px; cursor: ew-resize;
  display: flex; align-items: center; justify-content: center;
}
.tl-handle::after {
  content: ""; width: 4px; height: 26px; border-radius: 2px;
  background: var(--stage-accent);
}
.tl-playhead {
  position: absolute; top: -3px; bottom: -3px; width: 2px;
  background: var(--stage-text); pointer-events: none;
}
.tl-playhead::before {
  content: ""; position: absolute; top: -4px; left: -4px;
  border: 5px solid transparent; border-top-color: var(--stage-text);
}

.seg-row {
  display: flex; align-items: center; gap: 8px; padding: 9px 0;
  border-bottom: 1px solid var(--border); font-size: 14px;
}
.seg-row:last-child { border-bottom: 0; }
.seg-row .mono { font-family: var(--mono); font-size: 13px; color: var(--text); }
.seg-row .grow { flex: 1; }

.field { display: flex; align-items: center; gap: 8px; margin: 10px 0; }
.field label { font-size: 13px; color: var(--muted); min-width: 42px; }
input[type="text"] {
  font: inherit; font-family: var(--mono); font-size: 13px;
  padding: 7px 9px; width: 84px;
  border: 1px solid var(--border); border-radius: 8px;
  background: var(--bg); color: var(--text);
}

.note {
  font-size: 13px; color: var(--muted); line-height: 1.5;
  padding: 10px 12px; background: var(--surface-2);
  border-radius: var(--radius); margin-top: 14px;
}
.note b { color: var(--text); }

.dl {
  display: inline-flex; align-items: center; justify-content: center;
  text-decoration: none; text-align: center;
  background: var(--success); color: #fff; font-weight: 600; font-size: 14px;
  padding: 11px 20px; border-radius: var(--radius-pill); margin-top: 12px;
}

/* --- reel segments -------------------------------------------------------
 * Committed segments are drawn on the timeline itself rather than only in the
 * list, so the reel is legible in the same place it is cut from. */
.tl-seg {
  position: absolute; top: 0; bottom: 0;
  background: color-mix(in srgb, var(--success) 30%, transparent);
  border-left: 1px solid var(--success);
  border-right: 1px solid var(--success);
}
.tl-seg span {
  position: absolute; top: 3px; left: 4px;
  font-family: var(--mono); font-size: 10px; color: var(--stage-text);
  opacity: .85;
}
.seg-row .idx {
  font-family: var(--mono); font-size: 11px; color: var(--muted);
  min-width: 16px;
}
.seg-row button { padding: 4px 10px; font-size: 12px; line-height: 1.2; }
.seg-row button.del { color: var(--danger); }

/* --- landing -------------------------------------------------------------
 * Only the front door uses these. The app pages keep the plain <main>. */

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

.hero { position: relative; overflow: hidden; padding: 104px 0 120px; text-align: center; }
/* The wash sits in a ::before rather than on the section so it paints *under*
 * the content without needing a z-index on every child. */
.hero::before {
  content: ""; position: absolute; inset: -20% 0 0; z-index: 0;
  background:
    radial-gradient(760px 540px at 84% 6%, var(--glow-teal), transparent 62%),
    radial-gradient(900px 660px at 16% 92%, var(--glow-blue), transparent 60%);
}
.hero > * { position: relative; z-index: 1; }
.hero h1 {
  font-size: clamp(38px, 6.2vw, 68px); line-height: 1.04; letter-spacing: -.035em;
  font-weight: 600; margin: 0 auto; max-width: 15ch;
}
.hero .lede {
  margin: 26px auto 0; max-width: 54ch;
  font-size: 18px; line-height: 1.6; color: var(--muted);
}
.hero-cta {
  display: flex; gap: 16px; justify-content: center; align-items: center;
  flex-wrap: wrap; margin-top: 36px;
}
.hero-cta .quiet { font-size: 15px; font-weight: 600; text-decoration: none; }

.section { padding: 88px 0; }
.section.tint { background: var(--surface); border-block: 1px solid var(--border); }
.kicker {
  font-size: 12px; letter-spacing: .09em; text-transform: uppercase;
  color: var(--accent); text-align: center; margin: 0 0 12px; font-weight: 600;
}
/* The section's own heading only — a direct child of .wrap. A descendant
 * selector here also caught the <h2 class="plan-name"> inside the pricing
 * cards and rendered "FREE" at 38px. */
.section > .wrap > h2 {
  font-size: clamp(26px, 3.4vw, 38px); letter-spacing: -.025em; font-weight: 600;
  text-align: center; margin: 0 auto 56px; max-width: 20ch;
}

.cards3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 820px) { .cards3 { grid-template-columns: 1fr; } }
.feature {
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 28px; background: var(--bg);
}
.icon-tile {
  width: 48px; height: 48px; border-radius: 14px; margin-bottom: 20px;
  display: flex; align-items: center; justify-content: center;
  background: var(--brand-grad); color: #fff;
}
.icon-tile svg { width: 22px; height: 22px; display: block; }
.feature h3 { font-size: 18px; font-weight: 600; margin: 0 0 8px; letter-spacing: -.015em; }
.feature p { font-size: 14.5px; line-height: 1.65; color: var(--muted); margin: 0; }

.close-cta { text-align: center; padding: 96px 0; }
.close-cta h2 {
  font-size: clamp(26px, 3.6vw, 42px); letter-spacing: -.025em; font-weight: 600;
  margin: 0 auto 32px; max-width: 18ch;
}

.site-foot {
  border-top: 1px solid var(--border); padding: 28px 0;
  font-size: 13px; color: var(--muted);
}
.site-foot .wrap {
  display: flex; flex-wrap: wrap; gap: 8px 18px;
  align-items: center; justify-content: center;
}
.site-foot a { color: var(--muted); text-decoration: none; }
.site-foot a:hover { color: var(--text); }

/* --- marketing / legal pages ------------------------------------------- */
.prose { max-width: 72ch; }
.prose h1 { margin-bottom: 6px; }
.prose h2 { font-size: 19px; margin: 30px 0 8px; }
.prose p, .prose li { line-height: 1.68; color: var(--text); }
.prose ul { padding-left: 20px; }
.prose li { margin-bottom: 8px; }
.updated { color: var(--muted); font-size: 14px; margin: 0 0 26px; }

.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.plan-card { display: flex; flex-direction: column; }
/* The paid card is the recommendation, and says so with the brand colour
 * rather than with a "MOST POPULAR" ribbon we have no data to support. */
.plan-card.featured {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--brand-teal) 7%, var(--surface));
}
.plan-name { font-size: 13px; text-transform: uppercase; letter-spacing: .09em; color: var(--muted); font-weight: 600; }
.price { margin: 0 0 4px; }
.price .amt { font-size: 42px; font-weight: 600; letter-spacing: -.035em; }
.price .per { color: var(--muted); font-size: 15px; }
.plan-sub { color: var(--muted); font-size: 14px; margin: 0 0 18px; }
.feat { list-style: none; padding: 0; margin: 0 0 20px; flex: 1; }
/* The tick is positioned, not a flex item. Flex here made every inline <b>
 * inside the item a flex item too, so "kept for <b>30 days</b> so you can
 * re-edit" broke into three gapped columns. */
.feat li {
  position: relative; padding: 7px 0 7px 26px;
  font-size: 15px; line-height: 1.5;
}
.feat li svg {
  position: absolute; left: 0; top: 12px;
  width: 16px; height: 16px; color: var(--accent);
}
.trust {
  display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center;
  color: var(--muted); font-size: 13px; margin-top: 22px;
}

/* --- account / auth ------------------------------------------------------ */
.tabs { display: flex; gap: 4px; margin-bottom: 18px; }
.tab {
  flex: 1; border: 0; background: none; color: var(--muted);
  padding: 8px 0; border-bottom: 2px solid var(--border); border-radius: 0;
}
.tab:hover:not(:disabled) { background: none; color: var(--text); }
.tab.on { color: var(--text); border-bottom-color: var(--accent); }
.fl { display: block; font-size: 13px; color: var(--muted); margin: 12px 0 5px; }
input.wide {
  width: 100%; font-family: var(--font); font-size: 15px;
  padding: 10px 12px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--bg); color: var(--text);
}
.or { text-align: center; margin: 4px 0 2px; position: relative; color: var(--muted); font-size: 13px; }
.or::before {
  content: ""; position: absolute; left: 0; right: 0; top: 50%;
  border-top: 1px solid var(--border);
}
.or span { background: var(--surface); padding: 0 10px; position: relative; }
.danger-card { border-color: color-mix(in srgb, var(--danger) 40%, var(--border)); }
.danger-card h2 { color: var(--danger); }
.danger-btn { border-color: var(--danger); color: var(--danger); }
.danger-btn:not(:disabled):hover { background: var(--danger); color: #fff; }

/* Prose lists that are NOT feature lists — refund terms, restrictions. Same
 * rhythm as .feat, but a neutral dot: a green tick beside "no partial refunds"
 * reads as a benefit. */
.bullets { list-style: none; padding: 0; margin: 0 0 4px; }
.bullets li {
  position: relative; padding: 7px 0 7px 22px;
  font-size: 15px; line-height: 1.55;
}
.bullets li::before {
  content: ""; position: absolute; left: 5px; top: 15px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--muted);
}
