/* Rolla prototype styles. Light theme built on ink and mint. Standouts are ink with a mint star. */
:root {
  --bg: #F4F5F2;
  --surface: #FFFFFF;
  --line: #E4E6E1;
  --chip: #EDEEEA;
  --ink: #0E0E0E;
  --ink-2: #2E2F2C;
  --muted: #5C5E59;
  --mint: #7EE8C3;
  --mint-mark: #1FAE80;
  --mint-text: #0E7052;
  --mint-deep: #0A513C;
  --mint-tint: #E8F8F1;
  --so: #0E0E0E;
  --so-star: #7EE8C3;
  --error: #D63B40;
  --shadow-sm: 0 1px 2px rgba(14, 14, 14, 0.05), 0 2px 8px rgba(14, 14, 14, 0.05);
  --shadow-md: 0 1px 2px rgba(14, 14, 14, 0.04), 0 10px 30px rgba(14, 14, 14, 0.09);
  --shadow-lg: 0 2px 6px rgba(14, 14, 14, 0.06), 0 22px 50px rgba(14, 14, 14, 0.14);
  --display: 'Figtree', 'Helvetica Neue', Arial, sans-serif;
  --body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --spring: cubic-bezier(0.34, 1.4, 0.5, 1);
  --apple: cubic-bezier(0.32, 0.72, 0, 1);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #DFE1DC;
  font-family: var(--body);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:active:not(:disabled) { transform: scale(0.97); }
:focus-visible { outline: 2px solid var(--mint-text); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
svg { display: block; }

/* ---------- Phone frame ---------- */
.phone {
  position: relative;
  width: 390px;
  height: min(844px, 100dvh);
  background: var(--bg);
  border-radius: 44px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 0 11px #0E0E0E, 0 0 0 12px #2A2A2A, 0 40px 80px rgba(0, 0, 0, 0.25);
}
@media (max-width: 480px), (max-height: 720px) {
  body { align-items: stretch; }
  .phone { width: 100%; height: 100dvh; border-radius: 0; box-shadow: none; }
}

.view { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; }
.view.enter-push { animation: pushIn 0.5s var(--apple); box-shadow: -20px 0 40px rgba(14,14,14,0.08); }
.view.enter-pop { animation: popIn 0.45s var(--apple); }
.view.enter-fade { animation: fadeIn 0.25s ease; }
.scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
.scroll::-webkit-scrollbar { display: none; }
.pad { padding-left: 20px; padding-right: 20px; }
.top-space { padding-top: max(18px, env(safe-area-inset-top)); }
.tab-space { padding-bottom: 104px; }

/* ---------- Type ---------- */
.display { font-family: var(--display); font-weight: 800; font-size: 32px; line-height: 36px; letter-spacing: -0.6px; margin: 0; text-wrap: balance; }
.h1 { font-family: var(--display); font-weight: 800; font-size: 27px; line-height: 31px; letter-spacing: -0.5px; margin: 0; text-wrap: balance; }
.h2 { font-family: var(--display); font-weight: 800; font-size: 21px; line-height: 26px; letter-spacing: -0.3px; margin: 0; }
.h3 { font-family: var(--display); font-weight: 700; font-size: 17px; line-height: 22px; margin: 0; }
.h4 { font-family: var(--display); font-weight: 700; font-size: 15px; line-height: 20px; margin: 0; }
.body { font-size: 15px; line-height: 23px; color: var(--ink-2); margin: 0; }
.small { font-size: 13px; line-height: 19px; margin: 0; }
.label { font-size: 13px; line-height: 18px; font-weight: 500; margin: 0; }
.caption { font-size: 12px; line-height: 16px; color: var(--muted); margin: 0; }
.eyebrow { font-size: 13px; line-height: 18px; font-weight: 500; color: var(--muted); margin: 0; }
.muted { color: var(--muted); }
.mint { color: var(--mint-text); }
.gold { color: var(--ink); }
.num { font-variant-numeric: tabular-nums; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- Layout helpers ---------- */
.row { display: flex; align-items: center; }
.col { display: flex; flex-direction: column; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.g4 { gap: 4px; } .g6 { gap: 6px; } .g8 { gap: 8px; } .g10 { gap: 10px; } .g12 { gap: 12px; } .g14 { gap: 14px; } .g16 { gap: 16px; } .g20 { gap: 20px; } .g24 { gap: 24px; } .g28 { gap: 28px; }
.ico { width: 18px; height: 18px; display: inline-flex; flex: none; }
.ico svg { width: 100%; height: 100%; }
.ico-sm { width: 14px; height: 14px; display: inline-flex; flex: none; }
.ico-sm svg { width: 100%; height: 100%; }

/* ---------- Logo and marks ---------- */
.logo { display: inline-flex; align-items: center; gap: 2px; }
.wordmark { font-family: var(--display); font-weight: 800; line-height: 1; letter-spacing: -0.5px; }
.replay { background: none; border: none; padding: 4px 0; color: var(--ink); }
.wordmark svg { display: inline-block; width: 0.32em; height: 0.72em; vertical-align: 0; margin: 0 0.03em; overflow: visible; }
.co-mark { display: inline-flex; align-items: center; justify-content: center; flex: none; box-shadow: inset 0 0 0 1px rgba(14, 14, 14, 0.06); }
.avatar { width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-family: var(--display); font-weight: 800; font-size: 14px; flex: none; color: #fff; }
.art { width: 100%; height: 100%; display: block; }

/* ---------- Controls ---------- */
.icon-btn {
  width: 42px; height: 42px; border-radius: 50%; border: none; background: var(--surface);
  display: inline-flex; align-items: center; justify-content: center; flex: none; box-shadow: var(--shadow-sm); color: var(--ink);
  transition: transform 0.15s;
}
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn.ghost { box-shadow: none; background: transparent; }
.icon-btn .badge-dot { position: absolute; top: 9px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: #E5484D; box-shadow: 0 0 0 2px var(--surface); }

.btn {
  height: 54px; border-radius: 27px; border: none; padding: 0 24px;
  font-family: var(--display); font-weight: 700; font-size: 16px; letter-spacing: -0.1px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: transform 0.15s, background 0.2s, box-shadow 0.2s;
  position: relative; overflow: hidden; white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn-ink { background: var(--ink); color: #fff; }
.btn-mint { background: var(--mint); color: var(--ink); }
.btn-gold { background: var(--so); color: #FFFFFF; }
.btn-gold svg { color: var(--so-star); }
.btn-ghost { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.btn-outline { background: transparent; color: var(--mint-text); box-shadow: inset 0 0 0 2px var(--mint-text); }
.btn-sm { height: 40px; border-radius: 20px; font-size: 14px; padding: 0 16px; }
.btn-xs { height: 34px; border-radius: 17px; font-size: 13px; padding: 0 13px; }
.btn-block { width: 100%; }
.link { background: none; border: none; padding: 6px 0; font-weight: 600; font-size: 14px; color: var(--mint-text); }
.link.muted { color: var(--muted); font-weight: 500; }

/* Apply button that fills as you read */
.btn-read { background: var(--chip); color: var(--muted); }
.btn-read .fill { position: absolute; inset: 0; width: var(--p, 0%); background: var(--mint); transition: width 0.15s linear; }
.btn-read > span:not(.fill) { position: relative; display: inline-flex; align-items: center; gap: 8px; }
.btn-read.ready { color: var(--ink); background: var(--mint); animation: readyPop 0.5s var(--spring); }

.chips { display: flex; gap: 8px; overflow-x: auto; padding: 4px 20px 14px; margin: 0 -20px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; border: none; background: var(--surface); border-radius: 18px; box-shadow: inset 0 0 0 1px var(--line);
  padding: 8px 14px; font-size: 13px; font-weight: 600; white-space: nowrap; color: var(--ink-2); transition: background 0.2s, color 0.2s;
}
.chip[aria-pressed="true"] { background: var(--ink); color: #fff; box-shadow: none; }
.chip .count { font-weight: 500; opacity: 0.6; margin-left: 4px; }
.tag { display: inline-flex; align-items: center; gap: 4px; background: var(--chip); color: var(--ink-2); border-radius: 8px; padding: 5px 9px; font-size: 12px; font-weight: 500; }
.tag.match { background: var(--mint-tint); color: var(--mint-deep); }
.pill { display: inline-flex; align-items: center; gap: 5px; border-radius: 14px; padding: 5px 10px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.pill-gold { background: var(--so); color: #FFFFFF; }
.pill-gold .ico-sm { color: var(--so-star); }
.pill-mint { background: var(--mint-tint); color: var(--mint-deep); }
.pill-grey { background: var(--chip); color: var(--ink-2); }
.pill-glass { background: rgba(255, 255, 255, 0.92); color: var(--ink); box-shadow: var(--shadow-sm); }
.pill-dark { background: rgba(14, 14, 14, 0.78); color: #fff; }

.card-surface { background: var(--surface); border-radius: 22px; box-shadow: var(--shadow-sm); }

/* Minimal hover: colour only, no movement. */
.btn, .chip, .tab, .icon-btn, .save-btn, .round, .row-link, .link, .post-actions button, .segmented button, .story .inner, .job-attach { transition: background-color 0.2s ease, color 0.2s ease, opacity 0.2s ease, filter 0.2s ease, transform 0.15s ease; }
@media (hover: hover) {
  .btn:hover { filter: brightness(0.95); }
  .btn-ghost:hover { background: #F7F7F5; filter: none; }
  .chip:not([aria-pressed="true"]):hover { background: var(--chip); }
  .tab:not([aria-current="page"]):hover { color: var(--ink); }
  .icon-btn:hover, .save-btn:hover { background: #F2F3F0; }
  .link:hover { opacity: 0.7; }
  .post-actions button:not([aria-pressed="true"]):not(.vouch):hover { color: var(--ink); }
  .story:hover .inner { opacity: 0.85; }
  .job-attach:hover { background: #EDEEEA; }
  .segmented button:not([aria-pressed="true"]):hover { color: var(--ink); }
}

/* ---------- Discover ---------- */
.filter-btn { position: relative; height: 40px; border-radius: 20px; border: none; background: var(--surface); box-shadow: var(--shadow-sm); padding: 0 14px 0 12px; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
.filter-btn svg { width: 18px; height: 18px; }
.filter-btn .n { min-width: 18px; height: 18px; border-radius: 9px; background: var(--ink); color: #fff; font-size: 11px; line-height: 18px; text-align: center; padding: 0 5px; }
@media (hover: hover) { .filter-btn:hover { background: #F2F3F0; } }
.fgroup { display: flex; flex-direction: column; gap: 10px; }
.fgroup .opts { display: flex; flex-wrap: wrap; gap: 8px; }
.discover-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 0 14px; }
.discover-head .h1 { font-size: 30px; line-height: 34px; letter-spacing: -0.7px; }
.deck { position: relative; flex: 1; min-height: 0; margin: 26px 16px 0; perspective: 1600px; }
.card {
  position: absolute; inset: 0 0 18px; background: var(--surface); border-radius: 30px; box-shadow: var(--shadow-md);
  overflow: hidden; display: flex; flex-direction: column; padding: 8px;
  transform-origin: 50% 100%; transition: transform 0.5s var(--apple), opacity 0.3s ease, box-shadow 0.3s;
  user-select: none; -webkit-user-select: none; touch-action: none; cursor: grab;
}
.card.dragging { transition: none; cursor: grabbing; box-shadow: var(--shadow-lg); }
/* Cards waiting behind peek out above the top card, like a Rolodex. */
.card.back-1 { transform: translateY(-14px) scale(0.95); }
.card.back-2 { transform: translateY(-27px) scale(0.9); opacity: 0.6; }
.card.back-1, .card.back-2 { pointer-events: none; transform-origin: 50% 0; }
.card.top.arrive { animation: arrive 0.6s var(--apple); }
.card .media { position: relative; border-radius: 23px; overflow: hidden; flex: 1 1 54%; min-height: 150px; }
.card .media .art { position: absolute; inset: 0; }
.card .media .shade { position: absolute; inset: auto 0 0 0; height: 45%; background: linear-gradient(to top, rgba(14,14,14,0.38), rgba(14,14,14,0)); }
.card .on-media { position: absolute; left: 12px; right: 12px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.card .on-media.top { top: 12px; }
.card .on-media.bottom { bottom: 12px; }
.card .co-pill { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,0.94); border-radius: 22px; padding: 4px 12px 4px 4px; box-shadow: var(--shadow-sm); max-width: 100%; min-width: 0; }
.card .body-area h2 { font-size: 29px; line-height: 33px; letter-spacing: -0.6px; }
.card .body-area { padding: 16px 12px 8px; display: flex; flex-direction: column; gap: 10px; flex: 0 0 auto; }
.meta-row { display: flex; flex-wrap: wrap; gap: 6px 14px; color: var(--ink-2); }
.meta-row span { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 500; }
.meta-row .ico-sm { color: var(--muted); }
.why { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; color: var(--mint-deep); }
.why .ico-sm { color: var(--mint-mark); }
.readline { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 2px; }
.readline .swipe-hint { color: var(--muted); }
.readline .track { flex: 1; height: 4px; border-radius: 2px; background: var(--chip); overflow: hidden; }
.readline .track span { display: block; height: 100%; background: var(--mint-mark); border-radius: 2px; }

.match-ring { position: relative; width: 46px; height: 46px; border-radius: 50%; background: rgba(255,255,255,0.94); box-shadow: var(--shadow-sm); display: inline-flex; align-items: center; justify-content: center; flex: none; }
.match-ring svg { position: absolute; inset: 3px; width: 40px; height: 40px; transform: rotate(-90deg); }
.match-ring b { font-family: var(--display); font-weight: 800; font-size: 13px; position: relative; letter-spacing: -0.3px; }
.save-btn { width: 40px; height: 40px; border-radius: 50%; border: none; background: rgba(255,255,255,0.94); box-shadow: var(--shadow-sm); display: inline-flex; align-items: center; justify-content: center; color: var(--ink); }
.save-btn svg { width: 18px; height: 18px; }
.save-btn[aria-pressed="true"] { color: var(--mint-text); }

/* Stamps sit centred on the card art, since swipes now go up and down. */
.stamp {
  position: absolute; top: 120px; left: 50%; z-index: 3; padding: 7px 14px; border-radius: 12px;
  font-family: var(--display); font-weight: 800; font-size: 20px; letter-spacing: 0.04em; opacity: 0; pointer-events: none;
  display: inline-flex; align-items: center; gap: 6px; box-shadow: var(--shadow-md);
}
.stamp svg { width: 20px; height: 20px; }
.stamp-pass { background: #fff; color: var(--ink); transform: translateX(-50%); }
.stamp-apply { background: var(--mint); color: var(--ink); transform: translateX(-50%); }
.stamp-save { background: var(--ink); color: #fff; transform: translateX(-50%); }
.stamp-save svg { color: var(--mint); }
.stamp-apply.locked { background: #fff; color: var(--muted); }

.actions { display: flex; align-items: center; justify-content: center; gap: 22px; padding: 6px 0 8px; }
.round {
  width: 62px; height: 62px; border-radius: 50%; border: none; background: var(--surface); box-shadow: var(--shadow-md);
  display: inline-flex; align-items: center; justify-content: center; color: var(--ink); position: relative; transition: transform 0.2s var(--spring);
}
.round svg { width: 26px; height: 26px; }
.round:hover { background: #F7F7F5; }
.round.gold:hover { background: #2A2B28; }
.round.mint:hover { background: #72E0B9; }
.round.gold { width: 52px; height: 52px; background: var(--so); color: var(--so-star); }
.round.gold .left { background: var(--mint); color: var(--ink); }
.round.gold svg { width: 22px; height: 22px; }
.round.mint { background: var(--mint); }
.round.locked { background: var(--surface); color: var(--muted); }
.round .ring { position: absolute; inset: -4px; width: 70px; height: 70px; transform: rotate(-90deg); }
.round .left { position: absolute; top: -6px; right: -6px; min-width: 20px; height: 20px; border-radius: 10px; background: var(--ink); color: #fff; font-size: 11px; font-weight: 700; line-height: 20px; padding: 0 5px; }

/* ---------- Tab bar ---------- */
.tabbar {
  position: absolute; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); z-index: 15;
  display: flex; justify-content: space-between; background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-radius: 28px; padding: 6px; box-shadow: var(--shadow-lg);
}
.tab { flex: 1; background: none; border: none; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px 6px; border-radius: 22px; font-size: 11px; font-weight: 600; color: var(--muted); position: relative; transition: background 0.25s, color 0.25s; }
.tab svg { width: 22px; height: 22px; }
.tab[data-id="discover"] svg { width: 25px; height: 25px; margin-top: -2px; }
/* Rolodex cards flick out of the wheel; the wheel itself stays still. */
.rc { transform-box: view-box; transform-origin: 36px 25px; }
@media (hover: hover) { .tab[data-id="discover"]:hover .rc { animation: flick 0.9s cubic-bezier(.2,.75,.25,1) both; animation-delay: calc(var(--d) * 0.6); } }
.tab.spin .rc { animation: flick 0.9s cubic-bezier(.2,.75,.25,1) both; animation-delay: calc(var(--d) * 0.6); }
.tab[aria-current="page"] { color: var(--ink); background: var(--mint-tint); }
.tab[aria-current="page"]:not([data-id="discover"]) svg { color: var(--mint-text); }
.tab .dot { position: absolute; top: 4px; left: calc(50% + 6px); min-width: 17px; height: 17px; border-radius: 9px; background: var(--ink); color: #fff; font-size: 10px; line-height: 17px; padding: 0 4px; font-weight: 700; }

/* ---------- Listing ---------- */
.hero { position: relative; height: 270px; flex: none; }
.hero .art { position: absolute; inset: 0; }
.hero .hero-bar { position: absolute; top: max(14px, env(safe-area-inset-top)); left: 16px; right: 16px; display: flex; justify-content: space-between; z-index: 2; }
.sheet-body { position: relative; margin-top: -30px; background: var(--bg); border-radius: 30px 30px 0 0; padding: 22px 20px 30px; display: flex; flex-direction: column; gap: 24px; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.fact { background: var(--surface); border-radius: 16px; padding: 12px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.fact .ico-sm { color: var(--muted); }
.fact p { margin: 0; }
.fact .v { font-size: 14px; font-weight: 600; line-height: 18px; }
.section { display: flex; flex-direction: column; gap: 10px; }
.checks { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.checks li { display: flex; gap: 10px; font-size: 15px; line-height: 22px; color: var(--ink-2); }
.checks li .ico-sm { margin-top: 4px; color: var(--mint-mark); }
.match-panel { background: var(--surface); border-radius: 22px; padding: 16px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 12px; }
.meter { height: 8px; border-radius: 4px; background: var(--chip); overflow: hidden; }
.meter span { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--mint-mark), var(--mint)); }
.quote { position: relative; background: var(--surface); border-radius: 22px; padding: 18px 18px 18px 50px; box-shadow: var(--shadow-sm); }
.quote::before { content: '\201C'; position: absolute; left: 16px; top: 4px; font-family: var(--display); font-weight: 800; font-size: 56px; line-height: 1; color: var(--mint-mark); }
.team-row { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; margin: 0 -20px; padding: 2px 20px; }
.team-row::-webkit-scrollbar { display: none; }
.person-card { flex: none; width: 128px; background: var(--surface); border-radius: 18px; padding: 14px 12px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 8px; }
.row-link {
  display: flex; align-items: center; gap: 12px; background: var(--surface); border: none; border-radius: 20px; box-shadow: var(--shadow-sm);
  padding: 12px; text-align: left; width: 100%; color: var(--ink); transition: transform 0.15s, box-shadow 0.2s;
}
.row-link:hover { background: #FAFAF8; }
.row-link .chev { width: 18px; height: 18px; color: var(--muted); flex: none; }
.thumb { width: 56px; height: 56px; border-radius: 14px; overflow: hidden; flex: none; }
.bottombar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; gap: 10px; align-items: center;
  padding: 12px 16px max(18px, env(safe-area-inset-bottom)); background: rgba(244, 245, 242, 0.92); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid rgba(14, 14, 14, 0.06);
}
.bottombar .grow { flex: 1; }

/* ---------- Company ---------- */
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-sm); padding: 14px 6px; }
.stats > div { text-align: center; display: flex; flex-direction: column; gap: 2px; }
.stats > div + div { border-left: 1px solid var(--line); }
.stats b { font-family: var(--display); font-weight: 800; font-size: 18px; }
.gallery { display: flex; gap: 10px; overflow-x: auto; margin: 0 -20px; padding: 2px 20px 6px; scrollbar-width: none; scroll-snap-type: x mandatory; scroll-padding: 0 20px; }
.gallery::-webkit-scrollbar { display: none; }
.gallery figure { margin: 0; flex: none; width: 210px; scroll-snap-align: start; }
.gallery .frame { height: 140px; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow-sm); }
.gallery figcaption { font-size: 13px; font-weight: 600; margin-top: 8px; }
.big-quote { font-family: var(--display); font-weight: 700; font-size: 21px; line-height: 28px; letter-spacing: -0.3px; margin: 0; text-wrap: pretty; }

/* ---------- Feed ---------- */
.stories { display: flex; gap: 12px; overflow-x: auto; scrollbar-width: none; margin: 0 -20px; padding: 4px 20px 2px; scroll-snap-type: x proximity; scroll-padding: 0 20px; cursor: grab; }
.stories.grabbing, .gallery.grabbing, .team-row.grabbing { cursor: grabbing; scroll-snap-type: none; }
.stories::-webkit-scrollbar { display: none; }
.plain { background: none; border: none; padding: 0; text-align: left; color: inherit; display: flex; align-items: center; min-width: 0; }
.search { display: flex; align-items: center; gap: 10px; background: var(--surface); border-radius: 18px; padding: 0 8px 0 14px; height: 50px; box-shadow: var(--shadow-sm); }
.search:focus-within { box-shadow: inset 0 0 0 2px var(--ink), var(--shadow-sm); }
.search .ico { color: var(--muted); }
.search input { flex: 1; min-width: 0; border: none; background: transparent; font-size: 16px; outline: none; height: 100%; }
.search input::-webkit-search-cancel-button { display: none; }
.search .clear { width: 32px; height: 32px; border-radius: 50%; border: none; background: var(--chip); display: inline-flex; align-items: center; justify-content: center; color: var(--muted); }
.search .clear svg { width: 14px; height: 14px; }
.segmented.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.segmented.four button { padding: 9px 4px; font-size: 13px; }
.story { flex: none; width: 72px; scroll-snap-align: start; background: none; border: none; padding: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; font-weight: 500; color: var(--ink-2); }
.story .ring { display: block; position: relative; width: 68px; height: 68px; border-radius: 50%; padding: 3px; background: conic-gradient(from 200deg, var(--mint-mark), var(--mint), var(--mint-mark)); }
.story .ring.seen { background: var(--line); }
.story .inner { display: block; width: 100%; height: 100%; border-radius: 50%; border: 3px solid var(--bg); overflow: hidden; position: relative; }
.story .inner .art { position: absolute; inset: 0; width: 100%; height: 100%; }
.story .plus { position: absolute; right: -2px; bottom: -2px; width: 24px; height: 24px; border-radius: 50%; background: var(--ink); color: #fff; border: 3px solid var(--bg); display: flex; align-items: center; justify-content: center; }
.story .plus svg { width: 12px; height: 12px; }
.story .name { max-width: 72px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.post { background: var(--surface); border-radius: 26px; box-shadow: var(--shadow-sm); padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.post .media { border-radius: 18px; overflow: hidden; height: 220px; position: relative; }
.post-actions { display: flex; align-items: center; gap: 16px; }
.post-actions button { background: none; border: none; padding: 4px 0; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.post-actions button[aria-pressed="true"] { color: #D9343A; }
.post-actions .ico { width: 20px; height: 20px; }
.post-actions .vouch { margin-left: auto; color: var(--mint-text); background: var(--mint-tint); padding: 6px 10px; border-radius: 14px; }
.post-actions .vouch[aria-pressed="true"] { color: #fff; background: var(--mint-text); }
.milestone { display: flex; align-items: center; gap: 10px; background: var(--mint-tint); color: var(--mint-deep); border-radius: 16px; padding: 12px 14px; font-weight: 600; font-size: 14px; }
.job-attach { display: flex; align-items: center; gap: 12px; background: var(--bg); border: none; border-radius: 18px; padding: 8px; text-align: left; width: 100%; }

/* ---------- Applied ---------- */
.segmented { display: grid; grid-template-columns: 1fr 1fr; background: var(--chip); border-radius: 16px; padding: 4px; }
.segmented button { border: none; background: none; border-radius: 12px; padding: 9px; font-size: 14px; font-weight: 600; color: var(--muted); transition: background 0.2s, color 0.2s; }
.segmented button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.app-card { background: var(--surface); border-radius: 24px; box-shadow: var(--shadow-sm); padding: 14px; display: flex; flex-direction: column; gap: 14px; border: none; text-align: left; width: 100%; color: var(--ink); }
.app-card.standout { box-shadow: inset 0 0 0 2px var(--so), var(--shadow-sm); }
.timeline { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.timeline .step { display: flex; flex-direction: column; gap: 6px; }
.timeline .bar { height: 5px; border-radius: 3px; background: var(--chip); }
.timeline .step.done .bar { background: var(--mint-mark); }
.timeline .step.now .bar { background: linear-gradient(90deg, var(--mint-mark), var(--mint)); }
.timeline .step span { font-size: 11px; font-weight: 600; color: var(--muted); }
.timeline .step.done span, .timeline .step.now span { color: var(--ink); }
.msg-quote { background: var(--chip); color: var(--ink-2); border-radius: 14px; padding: 10px 12px; font-size: 13px; line-height: 19px; }

/* ---------- Profile ---------- */
.banner { height: 150px; position: relative; flex: none; }
.banner .art { position: absolute; inset: 0; }
.me-avatar { width: 96px; height: 96px; border-radius: 50%; background: var(--mint); color: var(--mint-deep); font-family: var(--display); font-weight: 800; font-size: 32px; display: flex; align-items: center; justify-content: center; border: 5px solid var(--bg); box-shadow: var(--shadow-md); }
.star-slots { display: flex; gap: 6px; }
.star-slots span { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--so); color: var(--so-star); }
.star-slots span.used { background: var(--chip); color: #A3A59F; }
.star-slots.on-dark span { background: var(--mint); color: var(--ink); }
.star-slots.on-dark span.used { background: rgba(255, 255, 255, 0.12); color: rgba(255, 255, 255, 0.4); }
.so-panel { background: var(--so); color: #FFFFFF; border-radius: 22px; padding: 16px; display: flex; align-items: center; gap: 14px; }
.so-panel .caption { color: #B5B7B1; }
.star-slots svg { width: 15px; height: 15px; }
.work-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.work-grid figure { margin: 0; position: relative; border-radius: 18px; overflow: hidden; aspect-ratio: 4 / 3; box-shadow: var(--shadow-sm); max-width: 100%; }
.work-grid figcaption { position: absolute; left: 8px; bottom: 8px; right: 8px; }

/* ---------- Sheet ---------- */
.scrim { position: absolute; inset: 0; background: rgba(14, 14, 14, 0.4); z-index: 20; animation: fadeIn 0.25s ease; }
.sheet {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 21; background: var(--surface);
  border-radius: 32px 32px 0 0; padding: 10px 22px max(26px, env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 16px;
  animation: sheetUp 0.42s var(--ease); max-height: 92%; overflow-y: auto; box-shadow: 0 -10px 40px rgba(14,14,14,0.15);
}
.grabber { width: 40px; height: 5px; border-radius: 3px; background: var(--line); align-self: center; }
.star-hero { width: 56px; height: 56px; border-radius: 18px; background: var(--so); color: var(--so-star); display: inline-flex; align-items: center; justify-content: center; flex: none; animation: starPop 0.6s var(--spring); }
.star-hero svg { width: 28px; height: 28px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field textarea {
  background: var(--bg); border: 1px solid var(--line); border-radius: 18px; padding: 14px; font-size: 15px; line-height: 22px; resize: none; min-height: 112px;
}
.field textarea:focus { outline: 2px solid var(--ink); outline-offset: 1px; background: #fff; }
.prompts { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -22px; padding: 0 22px; }
.prompts::-webkit-scrollbar { display: none; }
.prompts button { flex: none; border: none; background: var(--chip); color: var(--ink-2); border-radius: 14px; padding: 7px 12px; font-size: 12px; font-weight: 600; }
.error { color: var(--error); font-size: 12px; font-weight: 500; }
.burst { position: relative; width: 96px; height: 96px; display: flex; align-items: center; justify-content: center; }
.burst .core { width: 84px; height: 84px; border-radius: 28px; background: var(--so); color: var(--so-star); display: flex; align-items: center; justify-content: center; animation: starPop 0.7s var(--spring); }
.burst .core svg { width: 40px; height: 40px; }
.burst i { position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; border-radius: 50%; background: var(--mint); animation: spark 0.9s var(--ease) forwards; }

/* ---------- Toast ---------- */
.toast {
  position: absolute; left: 16px; right: 16px; bottom: 104px; z-index: 30; background: var(--ink); color: #fff;
  border-radius: 18px; padding: 12px 14px; font-size: 14px; line-height: 20px; animation: toastIn 0.35s var(--spring);
  display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow-lg);
}
.toast.high { bottom: 100px; }
.toast svg { width: 18px; height: 18px; flex: none; }
.toast .act { background: none; border: none; color: var(--mint); font-weight: 700; font-size: 14px; padding: 4px 2px; }

/* ---------- Splash ---------- */
.splash {
  position: absolute; inset: 0; z-index: 50; background: var(--bg);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; padding-bottom: 60px;
  transition: opacity 0.45s ease, transform 0.45s ease;
}
.splash.out { opacity: 0; transform: scale(1.04); pointer-events: none; }
.splash .load { width: 120px; height: 4px; border-radius: 2px; background: var(--chip); overflow: hidden; margin-top: 6px; opacity: 0; animation: fadeIn 0.3s ease 0.4s forwards; }
.splash .load span { display: block; height: 100%; width: 0; background: var(--mint-mark); border-radius: 2px; animation: load 3.2s var(--apple) 0.4s forwards; }
.splash .tagline { font-family: var(--display); font-weight: 700; font-size: 19px; color: var(--ink-2); margin: 0; opacity: 0; animation: fadeUp 0.6s ease 2.3s forwards; letter-spacing: -0.2px; }
.splash .mark { animation: pop 0.5s var(--ease) both; }
.splash .rc { animation: flick 1.1s cubic-bezier(.2,.75,.25,1) both; animation-delay: calc(0.45s + var(--d) * 1.4); }
.splash .word { opacity: 0; animation: fadeUp 0.5s ease 1.75s forwards; }
.splash .l2 { transform-box: view-box; transform-origin: 23.5px 72px; animation: swipe 0.7s var(--ease) 2.1s both; }
.skip { position: absolute; bottom: max(30px, env(safe-area-inset-bottom)); background: none; border: none; color: var(--muted); font-size: 14px; font-weight: 600; padding: 10px; }

.empty { text-align: center; padding: 40px 28px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.empty .art-blob { width: 160px; height: 110px; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-md); margin-bottom: 8px; }

/* ---------- Motion ---------- */
@keyframes load { 0% { width: 0; } 60% { width: 72%; } 100% { width: 100%; } }
@keyframes flick { 0% { transform: rotate(var(--from)); } 70% { transform: rotate(6deg); } 100% { transform: rotate(0); } }
@keyframes spin { from { transform: rotate(0); } to { transform: rotate(720deg); } }
@keyframes pop { from { opacity: 0; transform: translateY(24px) scale(0.9); } to { opacity: 1; transform: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes swipe { 0% { transform: rotate(0); } 55% { transform: rotate(18deg); } 80% { transform: rotate(10deg); } 100% { transform: rotate(12deg); } }
@keyframes pushIn { from { transform: translateX(100%); } to { transform: none; } }
@keyframes popIn { from { transform: translateX(-28%); opacity: 0.5; } to { transform: none; opacity: 1; } }
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes toastIn { from { transform: translateY(16px) scale(0.96); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes arrive { 0% { transform: translateY(-14px) scale(0.95) rotateX(12deg); } 70% { transform: rotateX(-1.5deg); } 100% { transform: none; } }
@keyframes readyPop { 0% { transform: scale(1); } 40% { transform: scale(1.05); } 100% { transform: scale(1); } }
@keyframes starPop { 0% { transform: scale(0.4) rotate(-20deg); opacity: 0; } 100% { transform: none; opacity: 1; } }
@keyframes spark { from { transform: translate(-50%, -50%) rotate(var(--a)) translateY(0) scale(1); opacity: 1; } to { transform: translate(-50%, -50%) rotate(var(--a)) translateY(-70px) scale(0.3); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0ms !important; transition-duration: 0.01ms !important; }
  /* The intro is the brand moment, so it still plays, just without the card-level motion elsewhere. */
  .splash .mark { animation-duration: 0.5s !important; }
  .splash .rc { animation-duration: 1.1s !important; animation-delay: calc(0.45s + var(--d) * 1.4) !important; }
  .splash .word { animation-duration: 0.5s !important; animation-delay: 1.75s !important; }
  .splash .l2 { animation-duration: 0.7s !important; animation-delay: 2.1s !important; }
  .splash .tagline { animation-duration: 0.6s !important; animation-delay: 2.3s !important; }
  .splash .load { animation-duration: 0.3s !important; animation-delay: 0.4s !important; }
  .splash .load span { animation-duration: 3.2s !important; animation-delay: 0.4s !important; }
  .splash { transition-duration: 0.45s !important; }
  .tab.spin .rc { animation-duration: 0.9s !important; animation-delay: calc(var(--d) * 0.6) !important; }
}
