/*
 * DebitMate - debit-mate.com
 *
 * The palette is not invented here. Every value in the tokens below is copied
 * from the app's own theme.css and the iPhone app's theme/index.ts, so the site
 * and the product are recognisably the same thing: deep navy surfaces, a gold
 * accent, indigo controls.
 *
 * Deliberately one stylesheet, no build step, no framework. The whole site is
 * plain HTML that opens by double-clicking it.
 */

/* ---------------------------------------------------------------- tokens */

:root {
  /* Surfaces: darkest at the edges, lifting toward the content */
  --abyss: #050a1c;
  --void: #070d24;
  --base: #0b1130;
  --surface: #101a45;
  --surface-2: #131d4f;
  --surface-3: #1a2456;
  --elevated: #1e2a63;
  --hairline: #26326e;
  --hairline-soft: #1c2657;

  /* Brand */
  --gold: #c9a84c;
  --gold-bright: #e0c674;
  --gold-dim: #8a7433;
  --indigo: #5c6bc0;
  --indigo-bright: #7986cb;
  --indigo-deep: #3949ab;

  /* Text */
  --ink: #e8eaf6;
  --ink-soft: #c5cae9;
  --ink-muted: #8b96d0;
  --ink-faint: #5c68a5;

  /* Semantic */
  --positive: #4ade80;
  --negative: #f87171;
  --warning: #fbbf24;
  --info: #38bdf8;

  --radius-card: 18px;
  --radius-control: 10px;

  --shadow-card: 0 8px 16px rgba(0, 0, 0, .45), 0 2px 4px rgba(0, 0, 0, .3);
  --shadow-lift: 0 18px 40px rgba(0, 0, 0, .55), 0 4px 10px rgba(0, 0, 0, .35);

  --wrap: 1140px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ------------------------------------------------------------- baseline */

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

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink-soft);
  background: var(--base);
  /* A slow lift from the abyss at the edges toward the content, so the page
     has depth without a single visible gradient band. */
  background-image:
    radial-gradient(1200px 600px at 50% -10%, rgba(92, 107, 192, .18), transparent 70%),
    radial-gradient(900px 500px at 90% 10%, rgba(201, 168, 76, .07), transparent 70%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--gold-bright); text-decoration: none; }
a:hover { color: var(--gold); }

:focus-visible {
  outline: 2px solid var(--gold-bright);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Money and any figure that must not jitter as its digits change - the same
   rule the app applies to every amount it draws. */
.num { font-variant-numeric: tabular-nums; }

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

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--gold);
  color: var(--abyss);
  padding: 12px 20px;
  font-weight: 600;
  z-index: 200;
}
.skip:focus { left: 0; }

/* ------------------------------------------------------------ typography */

h1, h2, h3, h4, h5 {
  color: var(--ink);
  line-height: 1.2;
  letter-spacing: -.02em;
  margin: 0 0 .5em;
  font-weight: 600;
}

h1 { font-size: clamp(2.4rem, 6vw, 4rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); letter-spacing: -.03em; }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

.eyebrow {
  display: inline-block;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}

.lead {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--ink-muted);
  max-width: 62ch;
}

.gold-text {
  color: var(--gold);
  background: linear-gradient(100deg, var(--gold) 0%, var(--gold-bright) 45%, var(--gold-dim) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }
.muted { color: var(--ink-faint); font-size: .9rem; }

/* --------------------------------------------------------------- header */

header.site {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 13, 36, .82);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--hairline-soft);
}

.nav {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 68px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -.03em;
  color: var(--ink);
  margin-right: auto;
}
.logo:hover { color: var(--ink); }
.logo .mark {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, var(--gold), var(--gold-dim));
  color: var(--abyss);
  font-weight: 700;
  font-size: .95rem;
  box-shadow: var(--shadow-card);
}
.logo .mark span { transform: translateY(-.5px); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links a {
  color: var(--ink-muted);
  font-size: .92rem;
  font-weight: 500;
  padding: 8px 13px;
  border-radius: var(--radius-control);
}
.nav-links a:hover { color: var(--ink); background: rgba(92, 107, 192, .12); }
.nav-links a.active { color: var(--ink); }
.nav-links a.nav-cta {
  color: var(--abyss);
  background: linear-gradient(145deg, var(--gold-bright), var(--gold));
  font-weight: 600;
  margin-left: 8px;
}
.nav-links a.nav-cta:hover { filter: brightness(1.08); }

.menu-toggle {
  display: none;
  background: none;
  border: 1px solid var(--hairline);
  color: var(--ink);
  font-size: 1.1rem;
  padding: 6px 12px;
  border-radius: var(--radius-control);
  cursor: pointer;
}

@media (max-width: 880px) {
  .menu-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 12px 20px 20px;
    background: var(--void);
    border-bottom: 1px solid var(--hairline-soft);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 14px; }
  .nav-links a.nav-cta { margin: 6px 0 0; text-align: center; }
}

/* -------------------------------------------------------------- buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius-control);
  font-size: .95rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .16s ease, filter .16s ease, background .16s ease;
  font-family: inherit;
}
.btn:active { transform: translateY(1px); }

.btn-gold {
  background: linear-gradient(145deg, var(--gold-bright), var(--gold));
  color: var(--abyss);
  box-shadow: var(--shadow-card);
}
.btn-gold:hover { filter: brightness(1.08); color: var(--abyss); }

.btn-indigo {
  background: var(--indigo-deep);
  color: #fff;
  box-shadow: var(--shadow-card);
}
.btn-indigo:hover { background: var(--indigo); color: #fff; }

.btn-ghost {
  background: rgba(92, 107, 192, .1);
  border-color: var(--hairline);
  color: var(--ink);
}
.btn-ghost:hover { background: rgba(92, 107, 192, .2); color: var(--ink); }

.btn[disabled] { opacity: .5; cursor: not-allowed; }

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 32px 0 18px;
}
.center .actions { justify-content: center; }

/* -------------------------------------------------------------- section */

section { padding: 96px 0; }
section.tight { padding: 64px 0; }

.section-head { max-width: 68ch; margin-bottom: 48px; }
.center .section-head { margin-left: auto; margin-right: auto; }

.band {
  background: linear-gradient(180deg, transparent, rgba(5, 10, 28, .6));
  border-top: 1px solid var(--hairline-soft);
  border-bottom: 1px solid var(--hairline-soft);
}

/* ----------------------------------------------------------------- hero */

.hero {
  padding: 88px 0 72px;
  position: relative;
  overflow: hidden;
}
.hero h1 { max-width: 16ch; }
.hero .lead { margin-top: 20px; }
.hero-note {
  color: var(--ink-faint);
  font-size: .88rem;
  margin-top: 4px;
}
.hero-note strong { color: var(--ink-muted); font-weight: 500; }

/* --------------------------------------------------------------- device */

/*
 * A suggestion of the app rather than a screenshot. Screenshots of a personal
 * finance app either show made-up numbers, which is dishonest, or somebody's
 * real ones, which is worse.
 */
.device {
  margin-top: 56px;
  border-radius: var(--radius-card);
  border: 1px solid var(--hairline);
  background: var(--surface);
  box-shadow: var(--shadow-lift);
  overflow: hidden;
}
.device-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 16px;
  background: var(--void);
  border-bottom: 1px solid var(--hairline-soft);
}
.device-bar i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--hairline);
  display: block;
}
.device-bar .title {
  margin-left: 10px;
  font-size: .78rem;
  color: var(--ink-faint);
  letter-spacing: .04em;
}
.device-body {
  display: grid;
  grid-template-columns: 190px 1fr;
  min-height: 340px;
}
.device-side {
  background: var(--void);
  border-right: 1px solid var(--hairline-soft);
  padding: 18px 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.device-side b {
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 600;
  padding: 8px 12px 4px;
}
.device-side span {
  padding: 9px 12px;
  border-radius: 8px;
  font-size: .87rem;
  color: var(--ink-muted);
}
.device-side span.on {
  background: rgba(92, 107, 192, .18);
  color: var(--ink);
  box-shadow: inset 2px 0 0 var(--gold);
}
.device-main { padding: 22px; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.stat {
  background: var(--surface-2);
  border: 1px solid var(--hairline-soft);
  border-radius: 12px;
  padding: 14px 16px;
}
.stat b {
  display: block;
  font-size: .68rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  font-weight: 600;
  margin-bottom: 6px;
}
.stat i {
  font-style: normal;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.stat i.pos { color: var(--positive); }
.stat i.warn { color: var(--warning); }

.rows { display: flex; flex-direction: column; gap: 8px; }
.row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid var(--hairline-soft);
  font-size: .9rem;
}
.row .who { color: var(--ink); }
.row .when { display: block; font-size: .76rem; color: var(--ink-faint); }
.row .amt { font-variant-numeric: tabular-nums; color: var(--ink-soft); }
.row.paid { box-shadow: inset 3px 0 0 var(--positive); }
.row.due { box-shadow: inset 3px 0 0 var(--warning); }
.row.over { box-shadow: inset 3px 0 0 var(--negative); }

@media (max-width: 760px) {
  .device-body { grid-template-columns: 1fr; }
  .device-side { flex-direction: row; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--hairline-soft); }
  .device-side b { display: none; }
}

/* ---------------------------------------------------------------- cards */

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.grid.two { grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); }

.card {
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  border: 1px solid var(--hairline-soft);
  border-radius: var(--radius-card);
  padding: 30px;
  box-shadow: var(--shadow-card);
  transition: border-color .2s ease, transform .2s ease;
}
.card:hover { border-color: var(--hairline); transform: translateY(-2px); }
.card h3 { margin-bottom: .6em; }
.card p { color: var(--ink-muted); font-size: .95rem; margin: 0; }

.card .icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: rgba(92, 107, 192, .16);
  border: 1px solid var(--hairline);
  color: var(--gold);
  font-size: 1.1rem;
  margin-bottom: 18px;
}

/* Feature list inside a card */
.ticks { list-style: none; margin: 0; padding: 0; }
.ticks li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 9px;
  color: var(--ink-muted);
  font-size: .94rem;
}
.ticks li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: .55em;
  width: 11px;
  height: 6px;
  border-left: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  transform: rotate(-45deg);
}
.ticks li:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------- pricing */

.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  align-items: start;
}
.plan {
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  border: 1px solid var(--hairline-soft);
  border-radius: var(--radius-card);
  padding: 32px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.plan.featured {
  border-color: var(--gold-dim);
  box-shadow: var(--shadow-lift), 0 0 0 1px rgba(201, 168, 76, .25);
}
.plan .tag {
  align-self: flex-start;
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--abyss);
  background: var(--gold);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 16px;
}
.plan h3 { font-size: 1.3rem; margin-bottom: 4px; }
.plan .price {
  font-size: 2.6rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
  margin: 14px 0 2px;
}
.plan .price small {
  font-size: .95rem;
  font-weight: 500;
  color: var(--ink-faint);
  letter-spacing: 0;
}
.plan .note { color: var(--ink-faint); font-size: .85rem; margin-bottom: 22px; }
.plan .ticks { margin-bottom: 26px; }
.plan .btn { width: 100%; margin-top: auto; }

/* ----------------------------------------------------------------- misc */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
@media (max-width: 880px) { .split { grid-template-columns: 1fr; gap: 36px; } }

.callout {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius-control);
  padding: 20px 24px;
  color: var(--ink-muted);
  font-size: .95rem;
}
.callout strong { color: var(--ink); }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 13px;
  border-radius: 999px;
  border: 1px solid var(--hairline);
  background: rgba(92, 107, 192, .1);
  font-size: .8rem;
  color: var(--ink-muted);
}
.pill::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--positive);
}
.pill.ios::before { background: var(--info); }

/* Comparison / spec table */
.table-scroll { overflow-x: auto; border-radius: var(--radius-card); border: 1px solid var(--hairline-soft); }
table.spec {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  background: var(--surface);
  font-size: .93rem;
}
table.spec th, table.spec td {
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--hairline-soft);
}
table.spec th {
  background: var(--void);
  color: var(--ink);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
table.spec td { color: var(--ink-muted); }
table.spec td:first-child { color: var(--ink); }
table.spec tr:last-child td { border-bottom: 0; }

/* --------------------------------------------------------------- forms */

form.enquiry { max-width: 640px; }
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: .85rem;
  font-weight: 500;
  color: var(--ink-soft);
  margin-bottom: 7px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-control);
  border: 1px solid var(--hairline);
  background: var(--void);
  color: var(--ink);
  font-family: inherit;
  font-size: .95rem;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--indigo);
  box-shadow: 0 0 0 3px rgba(92, 107, 192, .22);
}
.field .hint { font-size: .8rem; color: var(--ink-faint); margin-top: 6px; }

/* The honeypot. Never shown, never announced to a screen reader, and anything
   typed into it is a bot. */
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }

.notice {
  padding: 14px 18px;
  border-radius: var(--radius-control);
  font-size: .92rem;
  margin-bottom: 18px;
}
.notice.bad {
  background: rgba(248, 113, 113, .12);
  border: 1px solid rgba(248, 113, 113, .4);
  color: #fca5a5;
}
.notice.good {
  background: rgba(74, 222, 128, .1);
  border: 1px solid rgba(74, 222, 128, .35);
  color: #86efac;
}

/* --------------------------------------------------------------- reveal */

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------- footer */

footer.site {
  border-top: 1px solid var(--hairline-soft);
  background: var(--abyss);
  padding: 64px 0 32px;
  margin-top: 40px;
}
.foot-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 44px;
}
@media (max-width: 780px) { .foot-grid { grid-template-columns: 1fr 1fr; gap: 32px; } }
.foot-brand p {
  color: var(--ink-faint);
  font-size: .9rem;
  max-width: 34ch;
  margin-top: 14px;
}
.foot-col h5 {
  font-size: .72rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 14px;
  font-weight: 600;
}
.foot-col a {
  display: block;
  color: var(--ink-muted);
  font-size: .92rem;
  padding: 4px 0;
}
.foot-col a:hover { color: var(--gold-bright); }

.foot-legal {
  border-top: 1px solid var(--hairline-soft);
  padding-top: 24px;
  color: var(--ink-faint);
  font-size: .82rem;
}
.foot-legal strong { color: var(--ink-muted); font-weight: 500; }
.foot-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
  color: var(--ink-faint);
  font-size: .82rem;
}

/* ----------------------------------------------------------------- code */

code {
  font-family: ui-monospace, 'Cascadia Mono', 'SF Mono', Menlo, Consolas, monospace;
  font-size: .88em;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--void);
  border: 1px solid var(--hairline-soft);
  color: var(--gold-bright);
  word-break: break-word;
}
.card code { background: rgba(5, 10, 28, .6); }

em { color: var(--ink-soft); font-style: italic; }

/* Columns of different heights should start level, not float to the middle. */
.split.top { align-items: start; }
