/* Digibex — shared styles.
   To match the existing digibex.co.uk branding, change the colour tokens below. */
:root {
  --bg: #F5F4F0;
  --surface: #FFFFFF;
  --surface-2: #ECEAE4;
  --ink: #1F2433;
  --muted: #565B6A;
  --line: #E0DED7;
  --brand: #3B6E64;        /* Digibex teal (logo square) */
  --brand-ink: #FFFFFF;
  --brand-soft: #E2EDEA;
  --accent: #B0613A;       /* text-safe version of the orange dot */
  --dot: #DD9A6E;          /* the orange dot in the logo */
  --accent-soft: #F8EADF;
  --ok: #2F6E52;
  --ok-soft: #E1F0E8;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(31,36,51,.05), 0 6px 18px rgba(31,36,51,.05);
  --display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --body: "Lexend", "Segoe UI", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #14181C; --surface: #1C2127; --surface-2: #232A31; --ink: #EEF0EE; --muted: #A7AEB4;
    --line: #2E363E; --brand: #7FBDAF; --brand-ink: #14181C; --brand-soft: #1F3531;
    --accent: #EBA67A; --dot: #EBA67A; --accent-soft: #3A2A20; --ok: #78D0A6; --ok-soft: #1C3328;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 18px rgba(0,0,0,.25);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 300 16px/1.7 var(--body); letter-spacing: .01em; -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; }
a { color: var(--brand); }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.15; letter-spacing: -0.005em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 5.5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }
section { padding: 72px 0; }
.eyebrow { font-weight: 600; font-size: .85rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: .6em; }
.lede { font-size: 1.15rem; color: var(--muted); max-width: 46ch; }
.muted { color: var(--muted); }
.center { text-align: center; }
.center .lede { margin-inline: auto; }

/* Header */
.site-head { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 72px; gap: 16px; flex-wrap: wrap; }
.logo { font-family: var(--display); font-weight: 700; font-size: 1.6rem; color: var(--ink); text-decoration: none; display: flex; align-items: center; gap: 10px; letter-spacing: -0.01em; }
.logo-mark { width: 38px; height: 38px; border-radius: 9px; background: var(--brand); color: #fff; display: flex; align-items: center; justify-content: center; font-family: var(--body); font-weight: 600; font-size: 1.45rem; line-height: 1; padding-bottom: 3px; }
.logo-mark i, .logo .dot { font-style: normal; color: var(--dot); }
.logo .dot { color: var(--brand); }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 500; }
.nav a:hover { color: var(--ink); }
@media (max-width: 860px) { .nav a:not(.btn) { display: none; } }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 22px; border-radius: 999px; text-decoration: none; border: 2px solid transparent; cursor: pointer; font: inherit; font-weight: 500; transition: transform .15s, box-shadow .15s; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand); color: var(--brand-ink) !important; box-shadow: none; }
.btn-ghost { background: transparent; color: var(--ink) !important; border-color: var(--line); }
.btn-sm { padding: 8px 16px; font-size: .95rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* Hero */
.hero { padding: 80px 0 64px; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; } }
.hero h1 em { font-style: normal; color: var(--brand); }
.hero h1 { font-size: clamp(2.2rem, 5.5vw, 3.6rem); }
.trust { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 28px; color: var(--muted); font-size: .95rem; }
.trust span::before { content: "✓ "; color: var(--ok); font-weight: 700; }

.phone-stack { position: relative; height: 420px; }
.phone { position: absolute; width: 200px; height: 400px; border-radius: 32px; background: var(--surface); border: 8px solid var(--ink); box-shadow: var(--shadow); padding: 18px 14px; overflow: hidden; }
.phone.p1 { left: 8%; top: 10px; transform: rotate(-6deg); }
.phone.p2 { right: 8%; top: 20px; transform: rotate(5deg); }
.phone .bar { height: 10px; border-radius: 5px; background: var(--surface-2); margin: 10px 0; }
.phone .bar.short { width: 60%; }
.phone .chip { display: inline-block; font-size: .7rem; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); }
.phone .tile { border-radius: 12px; padding: 10px; margin-top: 10px; font-size: .78rem; font-weight: 600; line-height: 1.35; }
.phone .t1 { background: var(--ok-soft); color: var(--ok); }
.phone .t2 { background: var(--accent-soft); color: var(--accent); }
.phone .t3 { background: var(--brand-soft); color: var(--brand); }
.phone .title { font-family: var(--display); font-weight: 700; font-size: 1rem; }
@media (max-width: 860px) { .phone-stack { height: 360px; } .phone { width: 170px; height: 340px; } }

/* Cards & grids */
.grid { display: grid; gap: 20px; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.g2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 960px) { .g4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 860px) { .g3, .g2 { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .g4 { grid-template-columns: 1fr; } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.card p:last-child { margin-bottom: 0; }
.icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-size: 1.3rem; background: var(--brand-soft); margin-bottom: 14px; }
.alt { background: var(--surface-2); }

/* Steps */
.step-num { font-family: var(--display); font-weight: 700; font-size: 2rem; color: var(--accent); line-height: 1; margin-bottom: 8px; }

/* Portfolio */
.work .tag { display: inline-block; font-size: .75rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); color: var(--muted); margin: 0 6px 10px 0; }
.work h3 { margin-top: 4px; }

/* Pricing */
.price-card { display: flex; flex-direction: column; }
.price-card.featured { border: 2px solid var(--brand); position: relative; }
.price-card.featured::before { content: "Best for most ideas"; position: absolute; top: -13px; left: 24px; background: var(--brand); color: var(--brand-ink); font-size: .75rem; font-weight: 700; padding: 3px 12px; border-radius: 999px; }
.price { font-family: var(--display); font-size: 2.1rem; font-weight: 700; margin: 6px 0 2px; }
.price small { font-size: .95rem; font-weight: 500; color: var(--muted); font-family: var(--body); }
.ticks { list-style: none; padding: 0; margin: 16px 0 20px; flex: 1; }
.ticks li { padding: 5px 0 5px 26px; position: relative; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 800; }
.care { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 18px; }
@media (max-width: 1000px) { .care { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .care { grid-template-columns: 1fr; } }
.care div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.care strong { display: block; font-family: var(--display); font-size: 1.1rem; }

/* FAQ */
details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; margin-bottom: 10px; }
summary { font-weight: 700; cursor: pointer; }
details p { margin: 10px 0 0; color: var(--muted); }

/* CTA band */
.cta-band { background: var(--brand); color: var(--brand-ink); border-radius: 24px; padding: 48px 32px; text-align: center; }
.cta-band .lede { color: inherit; opacity: .85; margin-inline: auto; }
.cta-band .btn-primary { background: var(--brand-ink); color: var(--brand) !important; }

/* Footer */
.site-foot { padding: 40px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: .92rem; }
.site-foot .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }

/* ===== Planner (start.html) ===== */
.planner { padding: 40px 0 72px; }
.progress { height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; margin: 8px 0 28px; }
.progress span { display: block; height: 100%; background: var(--brand); width: 0; transition: width .3s; }
.q { display: none; }
.q.active { display: block; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.q h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); }
.options { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 20px 0; }
@media (max-width: 600px) { .options { grid-template-columns: 1fr; } }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; }
.opt label { display: block; height: 100%; background: var(--surface); border: 2px solid var(--line); border-radius: 14px; padding: 14px 16px; cursor: pointer; transition: border-color .15s, background .15s; }
.opt label strong { display: block; }
.opt label span { color: var(--muted); font-size: .9rem; }
.opt input:checked + label { border-color: var(--brand); background: var(--brand-soft); }
.opt input:focus-visible + label { outline: 3px solid var(--accent); outline-offset: 2px; }
.field { margin: 16px 0; }
.field label { display: block; font-weight: 700; margin-bottom: 6px; }
.field input, .field textarea, .field select { width: 100%; font: inherit; color: var(--ink); background: var(--surface); border: 2px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--brand); }
.field textarea { min-height: 120px; resize: vertical; }
.nav-row { display: flex; justify-content: space-between; gap: 12px; margin-top: 24px; }
.hint { font-size: .9rem; color: var(--muted); }
.error { color: var(--accent); font-weight: 600; min-height: 1.4em; }

.result-head { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 20px 0; }
@media (max-width: 640px) { .result-head { grid-template-columns: 1fr; } }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.stat .k { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.stat .v { font-family: var(--display); font-weight: 700; font-size: 1.45rem; }
.brief { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.brief h3 { margin-top: 18px; }
.brief h3:first-child { margin-top: 0; }
.brief ul { margin: 6px 0 0; padding-left: 20px; }
.pill { display: inline-block; font-size: .78rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--ok-soft); color: var(--ok); }
.pill.later { background: var(--surface-2); color: var(--muted); }
.notice { background: var(--accent-soft); border-radius: 12px; padding: 14px 16px; margin-top: 16px; }
@media print { .site-head, .site-foot, .nav-row, .no-print { display: none !important; } body { background: #fff; } }

strong, b, summary, .opt label strong { font-weight: 600; }
section[id] { scroll-margin-top: 80px; }
.founding { margin-top: 24px; background: var(--accent-soft); border-radius: var(--radius); padding: 18px 22px; display: grid; gap: 4px; }
.founding strong { font-family: var(--display); font-size: 1.15rem; }

/* Finish my AI-built app */
.rescue { margin-top: 32px; display: grid; grid-template-columns: 1fr 1.2fr; gap: 28px; align-items: start; border: 2px dashed var(--dot); }
.rescue-steps { display: grid; gap: 12px; }
.rescue-steps > div { background: var(--surface-2); border-radius: 12px; padding: 14px 16px; }
.rescue-steps strong { display: block; font-family: var(--display); font-size: 1.1rem; }
.rescue-steps .btn { justify-self: start; }
@media (max-width: 860px) { .rescue { grid-template-columns: 1fr; } }
.logo small { font-family: var(--body); font-weight: 400; font-size: .55em; color: var(--muted); margin-left: 3px; letter-spacing: .02em; }
