/* Trycut web: one stylesheet for every page. Colors mirror the app's dark theme tokens
   (mobile/src/ui/theme/palette.ts). System fonts only (CSP: no external fonts). */
:root {
  --bg-base: #000000;
  --bg-surface: #1c1c1e;
  --bg-elevated: #2c2c2e;
  --label-primary: #ffffff;
  --label-secondary: rgba(235, 235, 245, 0.64);
  --label-tertiary: rgba(235, 235, 245, 0.32);
  --separator: rgba(84, 84, 88, 0.65);
  --fill-glass: rgba(120, 120, 128, 0.26);
  --accent-pro: #e7d3b0;
  --on-pro: #000000;
  --radius-m: 12px;
  --radius-l: 16px;
  --radius-xl: 24px;
  --gutter: 16px;
  --measure: 720px;
  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg-base);
  color: var(--label-primary);
  font-family:
    -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
    sans-serif;
  font-size: 17px;
  line-height: 1.5;
  overflow-wrap: break-word;
}

a {
  color: var(--label-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--label-tertiary);
}

a:hover {
  text-decoration-color: var(--label-primary);
}

a:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--label-primary);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip {
  position: absolute;
  top: -100px;
  inset-inline-start: var(--gutter);
  background: var(--bg-elevated);
  padding: 8px 12px;
  border-radius: var(--radius-m);
  z-index: 10;
}

.skip:focus {
  top: 8px;
}

.wrap {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--separator);
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  min-height: 56px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.brand {
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
}

.site-nav a {
  color: var(--label-secondary);
  text-decoration: none;
  display: inline-block;
  padding: 10px 0;
}

.site-nav a:hover,
.site-nav a[aria-current='page'] {
  color: var(--label-primary);
}

/* Main */
main {
  padding: 32px 0 48px;
}

h1 {
  font-size: 34px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

h2 {
  font-size: 22px;
  line-height: 1.25;
  margin: 40px 0 8px;
}

h3 {
  font-size: 17px;
  margin: 24px 0 4px;
}

p,
ul,
ol {
  margin: 0 0 16px;
}

ul,
ol {
  padding-inline-start: 22px;
}

li {
  margin-bottom: 6px;
}

.lead {
  font-size: 20px;
  color: var(--label-secondary);
}

.muted {
  color: var(--label-secondary);
}

.small {
  font-size: 15px;
}

.eyebrow {
  color: var(--accent-pro);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 8px;
}

/* Language switch on legal pages */
.lang-switch {
  margin: 0 0 16px;
  font-size: 15px;
  color: var(--label-secondary);
}

.updated {
  color: var(--label-secondary);
  font-size: 15px;
  margin-bottom: 24px;
}

/* Cards */
.card {
  background: var(--bg-surface);
  border-radius: var(--radius-l);
  padding: 20px;
  margin: 0 0 16px;
}

.card > :last-child {
  margin-bottom: 0;
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin: 16px 0;
}

@media (min-width: 560px) {
  .grid {
    grid-template-columns: 1fr 1fr;
  }
}

.grid .card {
  margin: 0;
}

.card h3 {
  margin-top: 0;
}

/* Store links */
.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0 8px;
}

.store {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-height: 56px;
  min-width: 180px;
  padding: 8px 20px;
  border-radius: var(--radius-m);
  background: var(--label-primary);
  color: var(--bg-base);
  text-decoration: none;
  line-height: 1.2;
}

.store span {
  font-size: 12px;
}

.store strong {
  font-size: 19px;
}

.store:hover {
  background: rgba(255, 255, 255, 0.88);
}

/* Pricing */
.price {
  font-size: 28px;
  font-weight: 700;
  margin: 4px 0;
}

.badge {
  display: inline-block;
  background: var(--accent-pro);
  color: var(--on-pro);
  font-size: 12px;
  font-weight: 600;
  border-radius: 999px;
  padding: 2px 10px;
}

/* Tables */
.table-scroll {
  overflow-x: auto;
  margin: 0 0 16px;
  border: 1px solid var(--separator);
  border-radius: var(--radius-m);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

caption {
  text-align: start;
  padding: 12px 12px 0;
  color: var(--label-secondary);
}

th,
td {
  text-align: start;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--separator);
}

tr:last-child td {
  border-bottom: 0;
}

th {
  font-weight: 600;
  background: var(--bg-surface);
}

/* FAQ */
details {
  background: var(--bg-surface);
  border-radius: var(--radius-m);
  margin: 0 0 8px;
  padding: 0 16px;
}

summary {
  cursor: pointer;
  font-weight: 600;
  padding: 14px 0;
  min-height: 44px;
}

details > :not(summary) {
  margin-top: 0;
}

details[open] {
  padding-bottom: 4px;
}

.toc {
  background: var(--bg-surface);
  border-radius: var(--radius-m);
  padding: 16px 16px 8px;
  margin: 0 0 24px;
  font-size: 15px;
}

.toc ol {
  margin-bottom: 8px;
}

pre {
  white-space: pre-wrap;
  background: var(--bg-surface);
  border-radius: var(--radius-m);
  padding: 16px;
  font-size: 13px;
  line-height: 1.45;
  overflow-x: auto;
}

code {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 0.9em;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--separator);
  padding: 24px 0 40px;
  font-size: 15px;
  color: var(--label-secondary);
}

.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
}

.site-footer a {
  color: var(--label-secondary);
  display: inline-block;
  padding: 6px 0;
}

@media (min-width: 720px) {
  h1 {
    font-size: 44px;
  }
  main {
    padding-top: 56px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
