/* Path of Rolling marketing site — Design Lab token alignment (appTokens / defaults.ts) */
:root {
  --surface-canvas: #0f0e0c;
  --surface-panel: #1a1814;
  --surface-elevated: #252220;
  --surface-raised: #221f1a;
  --surface-inset: #1e1c17;
  --surface-sidebar: #131210;
  --text-primary: #e8e4dc;
  --text-secondary: #b8b4a8;
  --text-muted: #9a948a;
  --text-icon: #8b8b83;
  --accent: #c9a227;
  --accent-hover: #d4ad32;
  --accent-muted: #8b7a3d;
  --accent-subtle: rgba(201, 162, 39, 0.12);
  --accent-subtle-hover: rgba(201, 162, 39, 0.22);
  --accent-border: rgba(201, 162, 39, 0.45);
  --accent-glow: rgba(201, 162, 39, 0.28);
  --border: #3d3832;
  --border-subtle: #2a2622;
  --border-hover: #6a6355;
  --success: #5a9e4a;
  --error: #c94a4a;
  --warning: #d97706;
  --warning-bg: rgba(217, 119, 6, 0.12);
  --category-flow: #4a90d9;
  --category-automation: #4ad97a;
  --category-trade: #d9904a;
  --font-display: "Cormorant Garamond", "Palatino Linotype", Georgia, serif;
  --font-body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "Cascadia Code", monospace;
  --max-width: 1120px;
  --header-h: 4.25rem;
  --radius: 6px;
  --radius-lg: 12px;
  --shadow-panel: 0 16px 48px rgba(0, 0, 0, 0.35);
  --shadow-glow: 0 0 32px var(--accent-glow);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--surface-canvas);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--accent-hover);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  padding: 0.75rem 1rem;
  background: var(--accent);
  color: var(--surface-canvas);
  font-weight: 600;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.container {
  width: min(100% - 2rem, var(--max-width));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border-subtle);
  background: color-mix(in srgb, var(--surface-sidebar) 92%, transparent);
  backdrop-filter: blur(14px);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
  gap: 1rem;
  padding-block: 0.65rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--text-primary);
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.brand:hover {
  color: var(--text-primary);
}

.brand img {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-panel);
  color: var(--text-primary);
  cursor: pointer;
}

.nav-toggle svg {
  width: 1.25rem;
  height: 1.25rem;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.nav a:not(.btn) {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
}

.nav a:not(.btn):hover {
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav {
    display: none;
    position: absolute;
    top: calc(100% + 1px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0.75rem 1rem 1rem;
    background: var(--surface-sidebar);
    border-bottom: 1px solid var(--border-subtle);
  }

  .nav.is-open {
    display: flex;
  }

  .nav a:not(.btn) {
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border-subtle);
  }

  .nav .btn {
    margin-top: 0.75rem;
    width: 100%;
  }

  .site-header {
    position: sticky;
  }

  .site-header .container {
    position: relative;
    flex-wrap: wrap;
  }
}

/* Buttons — match app primaryOutlined / secondary / solid CTA */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    background 150ms ease,
    border-color 150ms ease,
    color 150ms ease,
    box-shadow 150ms ease;
}

.btn-primary {
  background: var(--accent-subtle);
  color: var(--accent);
  border-color: var(--accent-border);
}

.btn-primary:hover {
  background: var(--accent-subtle-hover);
  color: var(--accent-hover);
  border-color: var(--accent);
}

.btn-cta {
  background: var(--accent);
  color: var(--surface-canvas);
  border-color: var(--accent);
}

.btn-cta:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: var(--surface-canvas);
  box-shadow: var(--shadow-glow);
}

.btn-secondary {
  background: var(--surface-elevated);
  color: var(--text-secondary);
  border-color: var(--border);
}

.btn-secondary:hover {
  background: var(--border);
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.btn-ghost {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent-border);
}

.btn-ghost:hover {
  background: var(--accent-subtle);
  color: var(--accent-hover);
}

/* Hero */
.hero {
  padding: 4.5rem 0 3.5rem;
  background:
    radial-gradient(ellipse 75% 50% at 50% -10%, rgba(201, 162, 39, 0.1), transparent 70%),
    var(--surface-canvas);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
    gap: 3rem;
  }
}

.eyebrow {
  display: inline-block;
  margin: 0 0 1rem;
  padding: 0.35rem 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-subtle);
  border: 1px solid var(--accent-border);
  border-radius: 999px;
}

.hero h1 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.75rem);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.hero-lead {
  margin: 0 0 1.75rem;
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 38ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.hero-note {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 42ch;
}

.hero-visual {
  position: relative;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface-panel);
  overflow: hidden;
  box-shadow: var(--shadow-panel);
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(201, 162, 39, 0.07), transparent 50%);
  pointer-events: none;
  z-index: 1;
}

.hero-visual img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: top;
}

.hero-visual-caption {
  padding: 0.85rem 1rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
  border-top: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
}

/* Sections */
section {
  padding: 4rem 0;
}

.section-band {
  background: var(--surface-panel);
  border-block: 1px solid var(--border-subtle);
}

.section-header {
  margin-bottom: 2.5rem;
  max-width: 42rem;
}

.section-header h2 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  font-weight: 600;
  color: var(--text-primary);
}

.section-header p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.section-header strong {
  color: var(--text-primary);
}

/* Feature pills */
.pill-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.pill {
  padding: 1.35rem;
  background: var(--surface-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  transition: border-color 150ms ease, background 150ms ease;
}

.pill:hover {
  border-color: var(--border);
  background: var(--surface-elevated);
}

.pill h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.pill p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

.pill-tag {
  display: inline-block;
  margin-bottom: 0.65rem;
  padding: 0.2rem 0.5rem;
  font-size: 0.68rem;
  font-family: var(--font-mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 4px;
  font-weight: 500;
}

.pill-tag--flow {
  color: var(--category-flow);
  background: rgba(74, 144, 217, 0.14);
}

.pill-tag--auto {
  color: var(--category-automation);
  background: rgba(74, 217, 122, 0.12);
}

.pill-tag--trade {
  color: var(--category-trade);
  background: rgba(217, 144, 74, 0.14);
}

/* Video grid */
.video-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .video-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.video-card {
  background: var(--surface-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-panel);
}

.video-card h3 {
  margin: 0;
  padding: 1rem 1.1rem 0.25rem;
  font-size: 1.05rem;
  color: var(--text-primary);
}

.video-card p {
  margin: 0;
  padding: 0 1.1rem 1rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.video-embed {
  aspect-ratio: 16 / 9;
  background: var(--surface-inset);
  border-bottom: 1px solid var(--border-subtle);
}

.video-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.video-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 1.5rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  align-items: stretch;
}

.tier-card {
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  background: var(--surface-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}

.tier-card--featured {
  border-color: var(--accent-border);
  background: color-mix(in srgb, var(--surface-raised) 88%, var(--accent) 12%);
  box-shadow: 0 0 0 1px rgba(201, 162, 39, 0.12), var(--shadow-glow);
}

.tier-name {
  margin: 0 0 0.25rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--text-primary);
}

.tier-price {
  margin: 0 0 1rem;
  font-family: var(--font-mono);
  font-size: 1.5rem;
  color: var(--accent);
}

.tier-price span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.tier-card ul {
  margin: 0 0 1.25rem;
  padding-left: 1.1rem;
  flex: 1;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.tier-card li {
  margin-bottom: 0.4rem;
}

.tier-card li::marker {
  color: var(--accent-muted);
}

.tier-card .btn {
  width: 100%;
  margin-top: auto;
}

/* Trust block */
.trust-panel {
  padding: 2rem;
  background: var(--warning-bg);
  border: 1px solid color-mix(in srgb, var(--warning) 35%, var(--border));
  border-radius: var(--radius-lg);
}

.trust-panel h2 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--text-primary);
}

.trust-panel h2::before {
  content: "⚠ ";
  color: var(--warning);
}

.trust-list {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-secondary);
}

.trust-list li {
  margin-bottom: 0.65rem;
}

.trust-list strong {
  color: var(--text-primary);
}

.trust-panel-actions {
  margin: 1.25rem 0 0;
}

/* FAQ */
.faq-list {
  display: grid;
  gap: 0.75rem;
}

.faq-item {
  background: var(--surface-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.faq-item summary {
  padding: 1rem 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  float: right;
  color: var(--accent);
  font-family: var(--font-mono);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item div {
  padding: 0 1.15rem 1rem;
  color: var(--text-secondary);
  font-size: 0.925rem;
}

.faq-item div strong {
  color: var(--text-primary);
}

/* Footer */
.site-footer {
  padding: 2.5rem 0 3rem;
  background: var(--surface-sidebar);
  border-top: 1px solid var(--border-subtle);
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: space-between;
  align-items: flex-start;
}

.footer-brand strong {
  color: var(--text-primary);
  font-size: 1rem;
}

.footer-brand p {
  margin: 0.35rem 0 0;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-secondary);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--accent);
}

.disclaimer {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 72ch;
}

/* Legal pages */
.legal-page {
  padding: 3rem 0 4rem;
  max-width: 42rem;
}

.legal-page h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  margin: 0 0 1.5rem;
  color: var(--text-primary);
}

.legal-page h2 {
  font-size: 1.15rem;
  margin: 2rem 0 0.75rem;
  color: var(--text-primary);
}

.legal-page p,
.legal-page li {
  color: var(--text-secondary);
}
