/*
 * Budvex web site (budvex.com). Plain CSS, no build step.
 *
 * Colors: copied 1:1 from docs/tasarim/tokens/renkler.json (light and dark). Never write a color
 * anywhere else in this folder; when renkler.json changes, update these two blocks to match.
 * Type, spacing and radii follow docs/tasarim/DESIGN.md (sections 4-6).
 */

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('fonts/inter-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('fonts/inter-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('fonts/inter-600.woff2') format('woff2');
}

/* renkler.json → light */
:root {
  color-scheme: light dark;
  --bg-canvas: #f4f6f9;
  --bg-surface: #ffffff;
  --bg-surface-raised: #e8edf3;
  --bg-hero: #2f40a8;
  --bg-hero-raised: #4051b8;
  --text-primary: #0e1a2b;
  --text-secondary: #4a5a6e;
  --text-muted: #5f6f82;
  --text-on-hero: #ffffff;
  --text-on-hero-secondary: #d3d9fa;
  --text-on-primary: #ffffff;
  --text-on-accent: #0b1624;
  --border-default: #d6dee8;
  --border-subtle: #e8edf3;
  --border-hero: #4051b8;
  --brand-primary: #3b4fc4;
  --brand-primary-on-hero: #ffffff;
  --brand-primary-soft: #e6e9fb;
  --brand-on-primary-soft: #2b3a9e;
  --brand-accent: #f2a72e;
  --brand-accent-text: #8f5a06;
  --brand-accent-soft: #fcf0da;
  --brand-on-accent-soft: #7a4b05;
  --finance-profit: #1b7f45;
  --finance-profit-soft: #e2f3e8;
  --finance-on-profit-soft: #156837;
  --finance-loss: #c8372d;
  --finance-loss-soft: #fce8e6;
  --finance-on-loss-soft: #a52d25;
  --chart-1: #3b4fc4;
  --chart-2: #0b7a72;
  --chart-3: #b04a7a;
  --chart-4: #a86a12;
  --chart-5: #5f6f82;
  --chart-6: #7a4fb5;
  --overlay-scrim: #0e1a2b;
}

/* renkler.json → dark */
@media (prefers-color-scheme: dark) {
  :root {
    --bg-canvas: #0b1624;
    --bg-surface: #122235;
    --bg-surface-raised: #1a2e45;
    --bg-hero: #1b2452;
    --bg-hero-raised: #28336e;
    --text-primary: #e8eef4;
    --text-secondary: #9fb0c3;
    --text-muted: #7d8fa4;
    --text-on-hero: #e8eef4;
    --text-on-hero-secondary: #b3bfff;
    --text-on-primary: #0b1624;
    --text-on-accent: #0b1624;
    --border-default: #243a55;
    --border-subtle: #1a2e45;
    --border-hero: #28336e;
    --brand-primary: #9aaaff;
    --brand-primary-on-hero: #e8eef4;
    --brand-primary-soft: #1c2550;
    --brand-on-primary-soft: #b3bfff;
    --brand-accent: #f2ae3d;
    --brand-accent-text: #f2ae3d;
    --brand-accent-soft: #3a2a10;
    --brand-on-accent-soft: #f7c46e;
    --finance-profit: #5bd27a;
    --finance-profit-soft: #15372a;
    --finance-on-profit-soft: #7be096;
    --finance-loss: #ff6b61;
    --finance-loss-soft: #40201f;
    --finance-on-loss-soft: #ff8c83;
    --chart-1: #9aaaff;
    --chart-2: #5ed3c8;
    --chart-3: #f08fb8;
    --chart-4: #f2ae3d;
    --chart-5: #9fb0c3;
    --chart-6: #b79af0;
    --overlay-scrim: #000000;
  }
}

/* --- Base ------------------------------------------------------------------------------------ */

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

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

body {
  margin: 0;
  background: var(--bg-canvas);
  color: var(--text-primary);
  font-family:
    'Inter',
    system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    sans-serif;
  font-size: 15px;
  line-height: 22px;
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  display: block;
}

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

:focus-visible {
  outline: 2px solid var(--brand-primary);
  outline-offset: 2px;
  border-radius: 4px;
}

p {
  margin: 0 0 12px;
}

ul,
ol {
  margin: 0 0 12px;
  padding-left: 20px;
}

li + li {
  margin-top: 4px;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 500;
}

.num {
  font-variant-numeric: tabular-nums;
}

.wrap {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Text pages: same left edge as the header, lines no wider than 720px. */
.narrow > * {
  max-width: 720px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 20px;
  top: -100px;
  z-index: 10;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--bg-surface);
  color: var(--text-primary);
  font-weight: 500;
}

.skip-link:focus {
  top: 12px;
}

/* --- Indigo band (as on the app's Overview) --------------------------------------------------- */

.band {
  background: var(--bg-hero);
  color: var(--text-on-hero);
  padding-bottom: 56px;
}

.band :focus-visible {
  outline-color: var(--text-on-hero);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--text-on-hero);
  font-size: 17px;
  line-height: 22px;
  font-weight: 500;
  text-decoration: none;
}

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

.nav {
  display: flex;
  gap: 4px;
}

.nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border-radius: 12px;
  color: var(--text-on-hero-secondary);
  font-weight: 500;
  text-decoration: none;
}

.nav a:hover,
.nav a[aria-current='page'] {
  color: var(--text-on-hero);
  background: var(--bg-hero-raised);
}

.hero {
  display: grid;
  gap: 32px;
  padding-top: 24px;
}

.hero h1,
.page-title {
  font-size: 32px;
  line-height: 38px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.hero .lead,
.page-lead {
  margin: 12px 0 0;
  max-width: 34em;
  color: var(--text-on-hero-secondary);
  font-size: 17px;
  line-height: 24px;
}

.page-head {
  padding-top: 16px;
}

.stores {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.store {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  min-width: 152px;
  height: 50px;
  padding: 0 16px;
  border-radius: 12px;
  background: var(--bg-hero-raised);
  color: var(--text-on-hero);
}

.store small {
  font-size: 12px;
  line-height: 16px;
  color: var(--text-on-hero-secondary);
}

.store strong {
  font-size: 15px;
  line-height: 20px;
  font-weight: 500;
}

.hero-note {
  margin: 12px 0 0;
  color: var(--text-on-hero-secondary);
  font-size: 13px;
  line-height: 18px;
}

/* Example of the app's main number, drawn like the Overview band. */
.preview {
  align-self: center;
  margin: 0;
  padding: 24px 20px;
  border: 1px solid var(--border-hero);
  border-radius: 24px;
  background: var(--bg-hero-raised);
  text-align: center;
}

.preview-label {
  color: var(--text-on-hero-secondary);
  font-size: 13px;
  line-height: 18px;
}

.preview-amount {
  margin-top: 4px;
  font-size: 32px;
  line-height: 38px;
  font-weight: 600;
}

.preview-note {
  margin-top: 4px;
  color: var(--text-on-hero-secondary);
  font-size: 13px;
  line-height: 18px;
}

.preview-bar {
  width: 60%;
  height: 4px;
  margin: 16px auto 0;
  border-radius: 2px;
  background: var(--bg-hero);
}

.preview-bar span {
  display: block;
  width: 58%;
  height: 100%;
  border-radius: 2px;
  background: var(--text-on-hero);
}

.preview figcaption {
  margin-top: 16px;
  color: var(--text-on-hero-secondary);
  font-size: 12px;
  line-height: 16px;
}

/* --- Content sheet ------------------------------------------------------------------------- */

.sheet {
  position: relative;
  margin-top: -24px;
  padding: 32px 0 16px;
  border-radius: 24px 24px 0 0;
  background: var(--bg-canvas);
}

.section + .section {
  margin-top: 48px;
}

.section > h2 {
  margin-bottom: 12px;
  font-size: 22px;
  line-height: 28px;
}

.section-intro {
  max-width: 40em;
  color: var(--text-secondary);
}

.grid {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

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

.card h3 {
  margin: 12px 0 4px;
  font-size: 17px;
  line-height: 22px;
}

.card p,
.card li {
  color: var(--text-secondary);
}

.card p:last-child,
.card ul:last-child {
  margin-bottom: 0;
}

.icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-surface-raised);
  color: var(--brand-primary);
}

.icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.plan-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.plan-head h3 {
  margin: 0;
}

.badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 10px;
  background: var(--brand-accent-soft);
  color: var(--brand-on-accent-soft);
  font-size: 11px;
  line-height: 14px;
  font-weight: 500;
}

.price {
  margin: 4px 0 12px;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 18px;
}

.footnote {
  margin-top: 12px;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 18px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 20px;
  border-radius: 12px;
  background: var(--brand-primary);
  color: var(--text-on-primary);
  font-size: 17px;
  line-height: 22px;
  font-weight: 500;
  text-decoration: none;
}

.button:hover {
  background: var(--brand-on-primary-soft);
}

.button svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.mail {
  font-weight: 500;
  overflow-wrap: anywhere;
}

/* --- Long pages: legal, help ------------------------------------------------------------------ */

.doc h2 {
  margin: 32px 0 12px;
  font-size: 17px;
  line-height: 22px;
}

.doc h2:first-child {
  margin-top: 0;
}

.doc h3 {
  margin: 16px 0 4px;
  font-size: 15px;
  line-height: 20px;
}

.doc li,
.doc p {
  max-width: 42em;
}

.draft {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 32px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--brand-accent-soft);
  color: var(--brand-on-accent-soft);
}

.draft svg {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  fill: currentColor;
}

.draft p {
  margin: 0;
}

.todo {
  padding: 0 4px;
  border-radius: 4px;
  background: var(--bg-surface-raised);
  color: var(--text-primary);
}

.table-wrap {
  overflow-x: auto;
  margin: 0 0 12px;
  border: 1px solid var(--border-default);
  border-radius: 16px;
  background: var(--bg-surface);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  line-height: 18px;
}

th,
td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-subtle);
  text-align: left;
  vertical-align: top;
}

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

th {
  color: var(--text-secondary);
  font-weight: 500;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
}

.steps li {
  position: relative;
  min-height: 28px;
  padding-left: 40px;
}

.steps li + li {
  margin-top: 12px;
}

.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: -3px;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--brand-primary-soft);
  color: var(--brand-on-primary-soft);
  font-size: 13px;
  font-weight: 500;
}

.faq {
  margin-top: 16px;
  border: 1px solid var(--border-default);
  border-radius: 16px;
  background: var(--bg-surface);
}

.faq details + details {
  border-top: 1px solid var(--border-subtle);
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 56px;
  padding: 12px 16px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '+';
  flex: none;
  color: var(--text-secondary);
  font-size: 20px;
  line-height: 20px;
}

.faq details[open] summary::after {
  content: '\2212';
}

.faq .answer {
  padding: 0 16px 16px;
  color: var(--text-secondary);
}

.faq .answer p:last-child {
  margin-bottom: 0;
}

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

.site-footer {
  margin-top: 48px;
  padding: 24px 0 40px;
  border-top: 1px solid var(--border-default);
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 18px;
}

.site-footer .wrap {
  display: grid;
  gap: 8px;
}

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

.footer-links li + li {
  margin-top: 0;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--text-primary);
}

.site-footer p {
  margin: 0;
}

/* --- Wider screens ------------------------------------------------------------------------------ */

@media (min-width: 640px) {
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 880px) {
  .hero {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    align-items: center;
    padding-top: 40px;
  }

  .grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 400px) {
  .nav a {
    padding: 0 8px;
  }

  .store {
    flex: 1 1 140px;
    min-width: 0;
  }
}
