/* optin: list growth. Four signup sources feed lanes into one list card. Not pinned. */
.opt {
  /* dusk: a sky glow behind the stage and a faint warm bloom low on the right, fading out before both edges */
  background:
    radial-gradient(56% 46% at 50% 62%, rgba(54, 173, 224, .11), transparent 72%),
    radial-gradient(34% 28% at 86% 74%, rgba(201, 120, 196, .10), transparent 70%),
    radial-gradient(30% 24% at 8% 72%, rgba(252, 115, 77, .06), transparent 70%);
}
.opt .bay-head { margin-bottom: clamp(28px, 4vw, 48px); }

.opt-stage {
  position: relative; isolation: isolate;
  display: grid; grid-template-columns: minmax(230px, 290px) minmax(120px, 1fr) minmax(300px, 370px); align-items: center;
  padding: clamp(18px, 2.6vw, 32px); border-radius: var(--r-xl);
  background:
    radial-gradient(circle at 1px 1px, rgba(124, 203, 236, .10) 1px, transparent 1.6px) 0 0 / 22px 22px,
    radial-gradient(600px 300px at 55% 40%, rgba(54, 173, 224, .13), transparent 70%),
    radial-gradient(520px 260px at 80% 110%, rgba(201, 120, 196, .10), transparent 70%),
    var(--surface);
  -webkit-backdrop-filter: var(--glass); backdrop-filter: var(--glass);
  border: 1px solid var(--line); box-shadow: var(--shadow-1); overflow: clip;
}
.opt-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

/* sources */
.opt-srcs { grid-column: 1; list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; position: relative; z-index: 1; }
.opt-src {
  --c: var(--brand);
  display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 16px; background: var(--surface-solid); border: 1px solid var(--line); box-shadow: var(--shadow-1);
  color: var(--ink); text-decoration: none; position: relative;
  transition: transform .35s var(--e-out), border-color .3s, box-shadow .3s;
}
.opt-src:hover, .opt-src:focus-visible { transform: translateX(4px); border-color: color-mix(in srgb, var(--c) 45%, var(--line)); box-shadow: 0 10px 30px color-mix(in srgb, var(--c) 18%, transparent); }
.opt-ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; color: var(--c); background: color-mix(in srgb, var(--c) 15%, transparent); box-shadow: 0 0 0 1px color-mix(in srgb, var(--c) 22%, transparent) inset; }
.opt-ico svg { width: 22px; height: 22px; }
.opt-src-t { display: flex; flex-direction: column; min-width: 0; }
.opt-src-t b { font-weight: 600; font-size: .98rem; line-height: 1.25; }
.opt-src-t small { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .02em; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.opt-src-n { font-family: var(--f-mono); font-size: .72rem; font-weight: 600; color: var(--c); font-variant-numeric: tabular-nums; min-width: 2.4em; text-align: right; }
.opt-src.pa .opt-ico { animation: opt-ping-a .6s var(--e-out); }
.opt-src.pb .opt-ico { animation: opt-ping-b .6s var(--e-out); }
@keyframes opt-ping-a { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--c) 45%, transparent); } 100% { box-shadow: 0 0 0 12px transparent; } }
@keyframes opt-ping-b { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--c) 45%, transparent); } 100% { box-shadow: 0 0 0 12px transparent; } }

/* the list */
.opt-list {
  grid-column: 3; position: relative; z-index: 1;
  padding: 20px 20px 14px; border-radius: 22px; background: var(--surface-solid); border: 1px solid var(--line-2); box-shadow: var(--shadow-2);
}
.opt-list-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.opt-chip { padding: 5px 10px; font-size: .62rem; gap: 5px; }
.opt-count { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; margin-bottom: 14px; }
.opt-num { font-size: clamp(2.3rem, 3.6vw, 3rem); font-weight: 600; letter-spacing: -.03em; line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; display: inline-block; transform-origin: 0 80%; }
.opt-num.pa { animation: opt-pop-a .45s var(--e-spring); }
.opt-num.pb { animation: opt-pop-b .45s var(--e-spring); }
@keyframes opt-pop-a { 40% { transform: scale(1.045); color: var(--brand-light); } }
@keyframes opt-pop-b { 40% { transform: scale(1.045); color: var(--brand-light); } }
.opt-today { font-size: .84rem; color: var(--ink-3); }
.opt-today b { color: var(--mint); font-weight: 600; font-variant-numeric: tabular-nums; }

.opt-bar { display: flex; gap: 3px; height: 8px; margin-bottom: 8px; }
.opt-bar i { flex: 1 1 0; border-radius: 4px; background: var(--c, var(--brand)); transition: flex-grow .6s var(--e-out); }
.opt-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: .6rem; margin-bottom: 12px; }
.opt-legend span { display: inline-flex; align-items: center; gap: 5px; }
.opt-legend i { width: 7px; height: 7px; border-radius: 2px; background: var(--c, var(--brand)); }

.opt-feed { list-style: none; margin: 0; padding: 0; border-top: 1px dashed var(--line); }
.opt-row { --c: var(--brand); display: grid; grid-template-columns: 30px 1fr auto 52px; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.opt-row:last-child { border-bottom: 0; }
.opt-row.is-new { animation: opt-row-in .55s var(--e-out); }
@keyframes opt-row-in { from { opacity: 0; transform: translateY(-10px); background: color-mix(in srgb, var(--c) 10%, transparent); } }
.opt-av { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: .78rem; font-weight: 600; color: var(--c); background: color-mix(in srgb, var(--c) 16%, transparent); }
.opt-row-t { display: flex; flex-direction: column; min-width: 0; }
.opt-row-t b { font-family: var(--f-mono); font-size: .8rem; font-weight: 500; color: var(--ink); letter-spacing: .02em; }
.opt-row-t small { font-size: .74rem; color: var(--ink-3); }
.opt-ok { width: 16px; height: 16px; color: var(--mint); }
.opt-time { text-align: right; font-size: .6rem; }

.opt-note { grid-column: 1 / -1; margin: 18px 0 0; position: relative; z-index: 1; text-align: center; font-size: .6rem; }

.opt-cta { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 12px 18px; margin-top: clamp(24px, 3.5vw, 40px); text-align: center; }

/* tablet */
@media (max-width: 1000px) {
  .opt-stage { grid-template-columns: minmax(200px, 240px) minmax(70px, 1fr) minmax(270px, 320px); }
  .opt-src { grid-template-columns: 36px 1fr auto; gap: 10px; padding: 10px 12px; }
  .opt-ico { width: 36px; height: 36px; }
}

/* phones: the sources sit in a row on top and the lanes run down into the list */
@media (max-width: 760px) {
  .opt-stage { grid-template-columns: 1fr; padding: 14px; }
  .opt-srcs { grid-column: 1; flex-direction: row; gap: 8px; margin-bottom: 64px; }
  .opt-srcs li { flex: 1 1 0; min-width: 0; }
  .opt-src { grid-template-columns: 1fr; justify-items: center; gap: 6px; padding: 10px 4px 9px; border-radius: 14px; text-align: center; }
  .opt-src:hover, .opt-src:focus-visible { transform: translateY(-2px); }
  .opt-ico { width: 34px; height: 34px; border-radius: 10px; }
  .opt-ico svg { width: 19px; height: 19px; }
  .opt-src-t b { font-size: .74rem; }
  .opt-src-t small { display: none; }
  .opt-src-n { position: absolute; top: 4px; right: 6px; font-size: .58rem; min-width: 0; }
  .opt-list { grid-column: 1; padding: 16px 14px 10px; border-radius: 18px; }
  .opt-row { grid-template-columns: 28px 1fr auto 44px; gap: 8px; padding: 8px 0; }
  .opt-av { width: 28px; height: 28px; }
  .opt-note { margin-top: 12px; }
}
@media (max-width: 370px) {
  .opt-src-t b { font-size: .68rem; white-space: nowrap; }
  .opt-chip { display: none; }
  .opt-row { grid-template-columns: 26px 1fr 40px; }
  .opt-ok { display: none; }
}

/* reduced motion: a still picture, so drop the live "joined while you watched" line */
@media (prefers-reduced-motion: reduce) {
  .opt-today { display: none; }
}
