*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #070708;
  --bg-elevated: #0e0e10;
  --surface: #141416;
  --surface-2: #1c1c1f;
  --border: #2a2a2e;
  --border-soft: rgba(255, 255, 255, 0.06);
  --text: #f4f3f0;
  --text-muted: #8c8b88;
  --muted: #8c8b88;
  --accent: #f59e0b;
  --accent-bright: #fbbf24;
  --accent-dim: #d97706;
  --accent-soft: rgba(245, 158, 11, 0.12);
  --accent-line: rgba(245, 158, 11, 0.35);
  --success: #34d399;
  --radius: 10px;
  --radius-lg: 16px;
  --max-width: 1120px;
  --font: 'Pretendard Variable', Pretendard, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  --font-brand: 'Allura', 'Segoe Script', cursive;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100%;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.ambient-dots {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100dvh;
  z-index: 1;
  pointer-events: none;
}

main,
footer {
  position: relative;
  z-index: 2;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(ellipse 90% 55% at 50% -15%, rgba(245, 158, 11, 0.16), transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 30%, rgba(120, 80, 20, 0.12), transparent 50%),
    radial-gradient(ellipse 40% 35% at 0% 70%, rgba(40, 40, 48, 0.8), transparent 55%),
    linear-gradient(180deg, #0a0a0c 0%, var(--bg) 40%, #050506 100%);
  pointer-events: none;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 20%, #000 20%, transparent 75%);
  pointer-events: none;
  opacity: 0.5;
}

a {
  color: inherit;
}

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

ul,
ol {
  list-style: none;
}

.wrap {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 1px solid transparent;
}

.site-header .wrap {
  position: relative;
  height: 68px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand img {
  height: 28px;
  width: 28px;
}

.brand-word {
  font-family: var(--font-brand);
  font-size: 28px;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.15;
  color: var(--text);
  white-space: nowrap;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.header-info-btn {
  flex-shrink: 0;
}

.header-info-btn[hidden] {
  display: none;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.1s;
  white-space: nowrap;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-bright), var(--accent-dim));
  color: #0a0a0a;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #fcd34d, var(--accent));
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--accent-line);
  color: var(--accent-bright);
}

.btn-sm {
  padding: 9px 14px;
  font-size: 13px;
}

.btn-block {
  width: 100%;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  padding: 0;
  overflow: clip;
}

.hero-sticky {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 96px 24px 72px;
}

.hero-brand-static {
  font-family: var(--font-brand);
  font-size: clamp(40px, 7vw, 64px);
  line-height: 1;
  color: var(--text);
  margin-bottom: 18px;
}

.hero-after {
  position: relative;
  width: min(100%, 1040px);
  margin: 0 auto;
  text-align: center;
}

.hero h1 {
  font-size: clamp(22px, 3.8vw, 40px);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.03em;
  margin-bottom: 14px;
  white-space: nowrap;
}

.hero-sub {
  font-size: clamp(15px, 1.6vw, 17px);
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 22px;
}

.hero-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
}

.hero-cta-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.hero-cta .btn {
  min-width: 180px;
}

.hero-cta-meta {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

.hero-visual {
  width: 100%;
  max-width: 920px;
  margin: 0 auto;
}

.hero-pain {
  max-width: 720px;
  margin: 72px auto 0;
  text-align: center;
}

.hero-pain .pain-from {
  margin-bottom: 18px;
}

.hero-pain .pain-to {
  margin-bottom: 0;
}

.closing-brand {
  font-family: var(--font-brand);
  font-size: clamp(36px, 6vw, 56px);
  line-height: 1;
  margin-bottom: 12px;
  color: var(--text);
}

/* Hero preview — timeline board */

.preview {
  position: relative;
  text-align: left;
  background:
    linear-gradient(165deg, rgba(255, 255, 255, 0.04), transparent 42%),
    #101014;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 40px 90px -48px rgba(0, 0, 0, 0.9);
}

.preview-code {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(180deg, rgba(8, 8, 10, 0.98), rgba(12, 12, 14, 0.96));
  font-family: 'Cascadia Code', 'SF Mono', 'Consolas', 'Menlo', monospace;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preview.is-computing .preview-code {
  opacity: 1;
  visibility: visible;
}

.preview.is-computing.is-diagonal .preview-code,
.preview.is-built .preview-code {
  opacity: 0;
  visibility: hidden;
  transition: opacity 1.6s ease, visibility 0s linear 1.6s;
}

.preview-code-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.28);
}

.preview-code-dots {
  width: 42px;
  height: 10px;
  flex-shrink: 0;
  border-radius: 999px;
  background:
    radial-gradient(circle at 5px 50%, #ff5f57 4px, transparent 5px),
    radial-gradient(circle at 21px 50%, #febc2e 4px, transparent 5px),
    radial-gradient(circle at 37px 50%, #28c840 4px, transparent 5px);
}

.preview-code-bar b {
  font-size: 12px;
  font-weight: 650;
  letter-spacing: -0.01em;
  color: var(--text);
}

.preview-code-bar em {
  margin-left: auto;
  font-style: normal;
  font-size: 11px;
  color: var(--accent-bright);
}

.preview-code-stream {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 0;
  padding: 16px 18px 18px;
  font-size: clamp(11px, 1.35vw, 13px);
  line-height: 1.45;
  letter-spacing: 0.01em;
  overflow: hidden;
}

.preview-code-scan {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 28%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(251, 191, 36, 0.07),
    rgba(251, 191, 36, 0.16),
    transparent
  );
  opacity: 0;
  pointer-events: none;
}

.preview-code-line {
  position: relative;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
  color: rgba(244, 243, 240, 0.78);
  clip-path: inset(0 100% 0 0);
  opacity: 0;
}

.preview-code-line .tok-prompt {
  color: var(--accent-bright);
  margin-right: 4px;
}

.preview-code-line .tok-kw {
  color: #c4b5fd;
}

.preview-code-line .tok-fn {
  color: #7dd3fc;
}

.preview-code-line .tok-str {
  color: #86efac;
}

.preview-code-line .tok-var {
  color: #fde68a;
}

.preview-code-line .tok-num {
  color: #fda4af;
}

.preview-code-line .tok-ok {
  color: var(--success);
}

.preview-code-line .tok-dim {
  color: rgba(140, 139, 136, 0.9);
}

.preview-ui {
  position: relative;
  z-index: 1;
  opacity: 0;
  pointer-events: none;
  clip-path: polygon(0 0, 0 0, 0 0);
}

.preview.is-diagonal .preview-ui,
.preview.is-built .preview-ui {
  opacity: 1;
  pointer-events: auto;
  clip-path: none;
}

.preview-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.25);
}

.preview-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.preview-tabs span {
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--text-muted);
}

.preview-tabs span.is-on {
  color: #0a0a0a;
  background: var(--accent-bright);
  font-weight: 700;
}

.preview-live {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.04em;
  color: var(--accent-bright);
}

.preview-live::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--success);
  vertical-align: middle;
}

@media (prefers-reduced-motion: no-preference) {
  .preview-live::before {
    animation: preview-live 1.6s ease-in-out infinite;
  }

  @keyframes preview-live {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.35; transform: scale(0.75); }
  }
}

.preview-body {
  padding: 18px;
  display: grid;
  gap: 14px;
}

.preview-timeline {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 14px;
  align-items: start;
}

.preview-day {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding-top: 6px;
}

.preview-day b {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
}

.preview-day span {
  font-size: 11px;
  color: var(--text-muted);
}

.preview-cards {
  display: grid;
  gap: 8px;
}

.preview-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.preview-card em {
  font-style: normal;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
}

.preview-card strong {
  font-size: 14px;
  font-weight: 650;
}

.preview-card small {
  font-size: 11px;
  color: var(--text-muted);
}

.preview-card--soft {
  opacity: 0.88;
}

.preview-card--accent {
  background: var(--accent-soft);
  border-color: var(--accent-line);
}

.preview-card--accent em {
  background: var(--accent);
  color: #0a0a0a;
}

.preview-channels {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 4px;
}

.preview-chip {
  font-size: 12px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.03);
}

.preview-chip.is-sync {
  color: var(--accent-bright);
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

/* Apple-like scroll progress */
[data-scroll-fade],
[data-scroll-lift] {
  --p: 0;
  will-change: transform, opacity;
}

[data-scroll-fade] {
  opacity: calc(0.18 + var(--p) * 0.82);
  transform: none;
}

[data-scroll-lift] {
  opacity: calc(0.35 + var(--p) * 0.65);
  transform: scale(calc(0.985 + var(--p) * 0.015));
  transform-origin: center center;
}

.app-frame {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  overflow: hidden;
  box-shadow:
    0 -40px 80px -40px rgba(0, 0, 0, 0.85),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.app-titlebar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: #0a0a0b;
  border-bottom: 1px solid var(--border-soft);
}

.app-traffic {
  display: flex;
  gap: 6px;
}

.app-traffic i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #2e2e32;
  display: block;
}

.app-titlebar-label {
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.app-shell {
  display: grid;
  grid-template-columns: 112px 1fr;
  min-height: 280px;
}

.app-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 10px;
  background: #0c0c0e;
  border-right: 1px solid var(--border-soft);
}

.app-nav-item {
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-muted);
}

.app-nav-item.is-active {
  background: var(--accent-soft);
  color: var(--accent-bright);
  font-weight: 600;
}

.app-main {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 14px;
  padding: 16px;
  background: linear-gradient(160deg, #121214 0%, #0e0e10 100%);
}

.app-pane {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 14px;
}

.app-pane-label {
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-bright);
  margin-bottom: 12px;
}

.mock-cal {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.mock-cal span {
  aspect-ratio: 1;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.04);
}

.mock-cal span.on {
  background: var(--accent);
}

.mock-cal span.dim {
  background: rgba(245, 158, 11, 0.22);
}

.app-deadline {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-soft);
  font-size: 12px;
}

.app-deadline span {
  flex-shrink: 0;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent-bright);
  font-weight: 700;
  font-size: 11px;
}

.app-deadline b {
  font-weight: 600;
  color: var(--text);
}

.mock-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mock-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid transparent;
  font-size: 12px;
  color: var(--text-muted);
}

.mock-row b {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mock-tag {
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
}

.mock-tag.sync {
  background: var(--accent-soft);
  color: var(--accent-bright);
}

/* ---------- Pain copy (under hero preview) ---------- */

.pain-from {
  font-size: clamp(18px, 2.6vw, 24px);
  font-weight: 500;
  line-height: 1.45;
  color: var(--text-muted);
  margin-bottom: 28px;
}

.pain-to {
  font-size: clamp(22px, 3.4vw, 34px);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.pain-to em {
  font-style: normal;
  color: var(--accent-bright);
}

.pain-to .pain-brand {
  font-family: var(--font-brand);
  font-weight: 400;
  font-size: 1.15em;
  letter-spacing: 0;
}

/* ---------- Product scenes ---------- */

.product {
  padding: 40px 0 80px;
}

.scene {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 48px;
  align-items: center;
  padding: 56px 0;
  border-top: 1px solid var(--border-soft);
}

.scene-reverse {
  grid-template-columns: 1.1fr 1fr;
}

.scene-reverse .scene-copy {
  order: 2;
}

.scene-reverse .scene-panel {
  order: 1;
}

.scene-copy h2 {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.scene-copy p {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 38ch;
  line-height: 1.65;
}

.scene-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
}

.scene-cal-head {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 8px;
  font-size: 10px;
  color: var(--text-muted);
  text-align: center;
}

.scene-cal {
  margin-bottom: 18px;
}

.scene-events {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.scene-events li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  font-size: 13px;
  color: var(--text-muted);
}

.scene-events li span {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
}

.scene-events li.accent {
  background: var(--accent-soft);
  color: var(--text);
}

.scene-events li.accent span {
  background: var(--accent);
  color: #0a0a0a;
}

.scene-settle {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.settle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-soft);
}

.settle-row b {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
}

.settle-row span {
  font-size: 12px;
  color: var(--text-muted);
}

.settle-row strong {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.settle-row.pending {
  border-color: var(--accent-line);
  background: var(--accent-soft);
}

.settle-row.pending span {
  color: var(--accent-bright);
}

.settle-sum {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 4px 2px;
  margin-top: 4px;
  border-top: 1px solid var(--border-soft);
  font-size: 13px;
  color: var(--text-muted);
}

.settle-sum b {
  font-size: 18px;
  color: var(--accent-bright);
  letter-spacing: -0.02em;
}

.scene-channels {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.channel-hint {
  margin-top: 8px;
  padding: 12px 14px;
  font-size: 13px;
  color: var(--text-muted);
  border-left: 2px solid var(--accent-line);
}

/* ---------- How ---------- */

.how {
  padding: 88px 0;
  border-top: 1px solid var(--border-soft);
}

.how-title {
  text-align: center;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 48px;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
}

.step {
  padding: 0;
  background: none;
  border: none;
}

.step-num {
  display: block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--accent-bright);
  margin-bottom: 16px;
}

.step h3 {
  font-size: 18px;
  font-weight: 650;
  margin-bottom: 10px;
}

.step p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---------- Closing ---------- */

.closing {
  padding: 88px 0 100px;
  border-top: 1px solid var(--border-soft);
  text-align: center;
}

.closing-note {
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.6;
}

/* ---------- Auth (signup / login) ---------- */

.auth {
  padding: 24px 0 8px;
}

.auth-page {
  padding: 56px 0 80px;
  min-height: calc(100vh - 68px - 80px);
  display: flex;
  align-items: center;
}

.auth-page .wrap {
  max-width: 1240px;
}

.auth-layout {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 40px 64px;
  align-items: start;
  width: 100%;
}

.auth-intro {
  text-align: left;
  width: max-content;
  max-width: 100%;
  margin: 0;
  padding-top: 12px;
  position: sticky;
  top: 96px;
}

.auth-intro h2 {
  font-size: 40px;
  margin-bottom: 12px;
}

.auth-intro p,
#auth-desc {
  max-width: none;
  margin: 0;
  white-space: nowrap;
}

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 44px;
}

.eyebrow {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-bright);
  margin-bottom: 10px;
}

.section-head h2 {
  font-size: 30px;
  font-weight: 700;
  margin-bottom: 12px;
}

.section-head p {
  color: var(--text-muted);
  font-size: 15px;
}

.auth-card {
  max-width: none;
  min-width: 0;
  width: 100%;
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
}

.auth-form {
  display: grid;
  gap: 16px;
}

.auth-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.auth-form-row-verify {
  align-items: end;
}

.auth-form-row-verify .auth-verify-btn {
  height: 48px;
}

.auth-form label {
  display: grid;
  gap: 6px;
  font-size: 0.88rem;
  color: var(--muted);
}

.auth-form input {
  width: 100%;
  min-height: 48px;
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
}

.auth-form input:disabled {
  opacity: 0.55;
}

.password-field {
  position: relative;
  display: block;
}

.password-field input {
  padding-right: 64px;
}

.password-toggle {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 0.8rem;
  cursor: pointer;
  padding: 6px 8px;
}

.password-rules {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  font-size: 0.8rem;
  color: var(--muted);
  margin: -4px 0 0;
  line-height: 1.45;
}

.password-rules li:not(:last-child)::after {
  content: ',';
  margin-right: 0.35em;
  color: var(--muted);
}

.password-rules .ok {
  color: #4ade80;
}

.password-rules .bad {
  color: #f87171;
}

.auth-verify-btn {
  width: 100%;
  justify-content: center;
}

.auth-form .btn-primary {
  width: 100%;
  justify-content: center;
  margin-top: 4px;
}

.auth-status {
  min-height: 1.2em;
  font-size: 0.88rem;
  margin: 0;
}

.auth-status.ok {
  color: #4ade80;
}

.auth-status.err {
  color: #f87171;
}

.auth-note {
  margin-top: 16px;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.55;
}

.auth-switch {
  margin-top: 18px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.auth-switch button {
  border: none;
  background: none;
  padding: 0;
  margin-left: 4px;
  color: var(--accent-bright);
  font-size: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.auth-switch + .auth-switch {
  margin-top: 8px;
}

/* ---------- Admin ---------- */

.admin-page {
  padding: 56px 0 80px;
  min-height: calc(100vh - 68px - 80px);
}

.admin-head {
  margin-bottom: 28px;
}

.admin-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
}

.admin-card-follow {
  margin-top: 20px;
}

.admin-card-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.admin-count {
  font-size: 15px;
  font-weight: 600;
  color: var(--accent-bright);
  margin: 4px 0 20px;
}

.admin-table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.admin-table th,
.admin-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.admin-table td.admin-msg {
  white-space: pre-wrap;
  max-width: 320px;
}

.admin-table th {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ---------- Footer ---------- */

footer {
  border-top: 1px solid var(--border-soft);
  padding: 40px 0 44px;
}

.footer-inner {
  display: grid;
  gap: 32px;
}

.footer-contact {
  text-align: center;
}

.footer-contact p {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.55;
}

.footer-email {
  font-size: inherit;
  font-weight: 600;
  color: var(--accent-bright);
  text-decoration: none;
}

.footer-email:hover {
  color: var(--accent);
}

.footer-meta {
  display: grid;
  gap: 22px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-brand img {
  height: 20px;
  width: 20px;
}

.footer-brand span {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.01em;
}

.footer-legal {
  display: grid;
  gap: 10px;
  max-width: 42rem;
}

.footer-legal-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  align-items: center;
}

.footer-legal-nav a {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  opacity: 0.88;
}

.footer-legal-nav a:hover {
  color: var(--accent-bright);
  opacity: 1;
}

.footer-legal-more,
.footer-legal-disclaimer,
.footer-legal-trademark {
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-muted);
  opacity: 0.72;
}

.footer-legal-more a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-legal-more a:hover {
  color: var(--accent-bright);
}

.footer-legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 0;
  align-items: baseline;
}

.footer-legal p {
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-muted);
  opacity: 0.72;
  text-align: left;
}

.footer-legal a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-legal a:hover {
  color: var(--accent-bright);
}

.footer-biz {
  display: grid;
  gap: 2px;
}

.footer-biz p {
  margin: 0;
  font-size: 12px;
  line-height: 1.65;
  color: var(--text-muted);
  opacity: 0.85;
}

.footer-biz p:first-child {
  display: flex;
  flex-wrap: wrap;
  column-gap: 0;
}

.footer-biz span:not(:last-child)::after {
  content: ' · ';
}

.footer-biz a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer-biz a:hover {
  color: var(--accent-bright);
}

.footer-escrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 14px;
  max-width: 28rem;
}

.footer-escrow form {
  display: none;
}

.footer-escrow a {
  display: block;
  flex-shrink: 0;
  line-height: 0;
}

.footer-escrow img {
  display: block;
  width: 56px;
  height: 56px;
}

.og-preview-fallback {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
}

.footer-escrow-note {
  margin: 0;
  flex: 1 1 180px;
  font-size: 11px;
  line-height: 1.5;
  color: var(--text-muted);
  opacity: 0.7;
}

/* ---------- Legal pages ---------- */

.legal-page {
  padding: 48px 0 72px;
  min-height: 70vh;
}

.legal-wrap {
  max-width: 760px;
}

.legal-head {
  margin-bottom: 36px;
}

.legal-eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.legal-head h1 {
  margin: 0 0 16px;
  font-size: clamp(28px, 4vw, 36px);
  line-height: 1.2;
  color: var(--text);
}

.legal-meta {
  margin: 0 0 16px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-muted);
}

.legal-meta a {
  color: var(--accent-bright);
}

.legal-body {
  font-size: 15px;
  line-height: 1.75;
  color: var(--text);
}

.legal-body h2 {
  margin: 36px 0 12px;
  font-size: 18px;
  line-height: 1.4;
  scroll-margin-top: 88px;
}

.legal-body h3 {
  margin: 22px 0 8px;
  font-size: 15px;
  line-height: 1.4;
  color: var(--text);
}

.legal-body p,
.legal-body ul,
.legal-body ol {
  margin: 0 0 12px;
}

.legal-body ul,
.legal-body ol {
  padding-left: 1.25em;
}

.legal-body li {
  margin-bottom: 6px;
}

.legal-body a {
  color: var(--accent-bright);
}

/* ---------- Responsive ---------- */

@media (max-width: 920px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .app-nav {
    flex-direction: row;
    flex-wrap: wrap;
    border-right: none;
    border-bottom: 1px solid var(--border-soft);
  }

  .app-main {
    grid-template-columns: 1fr;
  }

  .scene,
  .scene-reverse {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .scene-reverse .scene-copy,
  .scene-reverse .scene-panel {
    order: initial;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .auth-layout {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .auth-intro {
    position: static;
    width: auto;
    text-align: center;
  }

  .auth-intro p,
  #auth-desc {
    max-width: none;
    margin: 0 auto;
    white-space: normal;
  }
}

@media (max-width: 720px) {
  .site-header .wrap {
    gap: 8px;
  }

  .brand {
    position: static;
    transform: none;
    margin-right: auto;
  }

  .brand-word {
    font-size: 22px;
  }

  .header-info-btn,
  .header-actions .btn-ghost:not([data-download]) {
    display: none;
  }

  .header-actions [data-download].btn-ghost {
    display: inline-flex;
  }

  .header-actions [data-download] {
    padding-left: 12px;
    padding-right: 12px;
  }

  .hero-sticky {
    padding: 80px 16px 24px;
  }

  .hero-br {
    display: none;
  }

  .hero h1 {
    white-space: normal;
    font-size: clamp(20px, 5.2vw, 28px);
  }

  .app-frame {
    border-radius: 12px 12px 0 0;
  }

  .hero-pain {
    margin-top: 52px;
  }

  .scene {
    padding: 40px 0;
  }

  .auth-form-row {
    grid-template-columns: 1fr;
  }

  .auth-intro h2 {
    font-size: 32px;
  }

  .footer-inner {
    gap: 28px;
  }
}

@media (min-width: 721px) {
  .footer-meta {
    grid-template-columns: 1fr auto;
    align-items: start;
  }

  .footer-brand,
  .footer-biz,
  .footer-legal {
    grid-column: 1;
  }

  .footer-escrow {
    grid-column: 2;
    grid-row: 1 / span 3;
    max-width: 280px;
    align-self: center;
  }
}

/* ---------- Motion ---------- */

@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transition: opacity 0.9s cubic-bezier(0.16, 0.84, 0.44, 1);
  }

  .reveal.in-view {
    opacity: 1;
  }

  .reveal-d1 { transition-delay: 90ms; }
  .reveal-d2 { transition-delay: 180ms; }
  .reveal-d3 { transition-delay: 270ms; }

  .reveal-group > .reveal:nth-child(1) { transition-delay: 0ms; }
  .reveal-group > .reveal:nth-child(2) { transition-delay: 90ms; }
  .reveal-group > .reveal:nth-child(3) { transition-delay: 180ms; }

  .mock-cal span.on.pulse {
    animation: cal-breathe 2.8s ease-in-out infinite;
  }

  @keyframes cal-breathe {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.25); }
  }

  .mock-tag.sync {
    animation: sync-blink 3.2s ease-in-out infinite;
  }

  @keyframes sync-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.55; }
  }

  .hero-mock {
    transition: transform 0.35s cubic-bezier(0.16, 0.84, 0.44, 1);
    transform-style: preserve-3d;
    will-change: transform;
  }

  .preview.is-computing .preview-code-scan {
    animation: preview-code-scan 1.35s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  @keyframes preview-code-scan {
    0% { opacity: 0; transform: translateX(-30%); }
    20% { opacity: 1; }
    100% { opacity: 0; transform: translateX(380%); }
  }

  .preview.is-computing .preview-code-line {
    animation: preview-code-write 0.68s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  }

  .preview.is-computing .preview-code-line:nth-child(2) { animation-delay: 0.04s; }
  .preview.is-computing .preview-code-line:nth-child(3) { animation-delay: 0.18s; }
  .preview.is-computing .preview-code-line:nth-child(4) { animation-delay: 0.34s; }
  .preview.is-computing .preview-code-line:nth-child(5) { animation-delay: 0.5s; }
  .preview.is-computing .preview-code-line:nth-child(6) { animation-delay: 0.68s; }
  .preview.is-computing .preview-code-line:nth-child(7) { animation-delay: 0.86s; }
  .preview.is-computing .preview-code-line:nth-child(8) { animation-delay: 1.04s; }
  .preview.is-computing .preview-code-line:nth-child(9) { animation-delay: 1.22s; }
  .preview.is-computing .preview-code-line:nth-child(10) { animation-delay: 1.4s; }
  .preview.is-computing .preview-code-line:nth-child(11) { animation-delay: 1.58s; }
  .preview.is-computing .preview-code-line:nth-child(12) { animation-delay: 1.76s; }

  @keyframes preview-code-write {
    0% {
      clip-path: inset(0 100% 0 0);
      opacity: 0.3;
    }
    100% {
      clip-path: inset(0 0 0 0);
      opacity: 1;
    }
  }

  /* Table (preview-ui) diagonal: starts when is-diagonal after ~3 code lines */
  .preview.is-diagonal .preview-ui {
    animation: preview-ui-reveal 5.6s cubic-bezier(0.4, 0, 0.2, 1) both;
  }

  @keyframes preview-ui-reveal {
    0% {
      opacity: 0.3;
      clip-path: polygon(0 0, 0% 0, 0 0%);
      filter: brightness(1.22);
    }
    100% {
      opacity: 1;
      clip-path: polygon(0 0, 230% 0, 0 230%);
      filter: brightness(1);
    }
  }

  .btn-primary {
    position: relative;
    overflow: hidden;
  }

  .btn-primary::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.28) 50%, transparent 70%);
    transform: translateX(-120%);
    transition: transform 0.55s ease;
  }

  .btn-primary:hover::after {
    transform: translateX(120%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-after {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .preview-code {
    display: none;
  }

  .preview-ui {
    opacity: 1;
    pointer-events: auto;
    clip-path: none;
  }

  [data-scroll-fade],
  [data-scroll-lift] {
    opacity: 1 !important;
    transform: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
