/* ==========================================================================
   Hisab Kitab — design tokens
   Direction: the physical ledger book (bahi-khata) — ruled paper, ink-stamp
   certification, tabular figures. Not a generic fintech look.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Zilla+Slab:wght@400;500;600;700&family=IBM+Plex+Sans:wght@400;500;600&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  --ink:          #1B2A4A;
  --ink-soft:     #2A3C61;
  --paper:        #EDE6D6;
  --paper-light:  #F7F3E9;
  --paper-dark:   #E2D9C4;
  --stamp-red:    #A23B2E;
  --seal-green:   #3F6659;
  --text-dark:    #211D17;
  --text-muted:   #6B6152;
  --rule:         #C9BFA8;
  --rule-strong:  #9E927A;

  --font-display: 'Zilla Slab', Georgia, serif;
  --font-body:    'IBM Plex Sans', -apple-system, sans-serif;
  --font-mono:    'IBM Plex Mono', 'Courier New', monospace;

  --max-w: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--text-dark);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 28px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 0.4em;
  line-height: 1.15;
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 700; }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1em; color: var(--text-dark); }
.muted { color: var(--text-muted); }

.figures, .num, .tag-mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--stamp-red);
  display: inline-block;
  margin-bottom: 0.8em;
}

/* ---- buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 13px 24px;
  border-radius: 3px;
  border: 1.5px solid var(--ink);
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.btn-primary { background: var(--stamp-red); border-color: var(--stamp-red); color: var(--paper-light); }
.btn-primary:hover { transform: translateY(-1px); background: #8c3226; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--paper-light); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 1.6em; }

/* ---- nav ---- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--paper);
  border-bottom: 2px solid var(--ink);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 18px; padding-bottom: 18px;
}
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; color: var(--ink); }
.brand .seal-mini { width: 30px; height: 30px; flex-shrink: 0; }
.nav-links { display: flex; gap: 30px; font-family: var(--font-mono); font-size: 0.88rem; }
.nav-links a { padding: 4px 0; border-bottom: 2px solid transparent; }
.nav-links a:hover, .nav-links a.active { border-bottom-color: var(--stamp-red); color: var(--stamp-red); }
.nav-toggle { display: none; }

@media (max-width: 760px) {
  .nav-links { position: fixed; inset: 0 0 0 auto; width: 78%; max-width: 320px;
    background: var(--paper-light); flex-direction: column; padding: 90px 28px 28px;
    transform: translateX(100%); transition: transform 0.25s ease; border-left: 2px solid var(--ink); gap: 22px; }
  .nav-links.open { transform: translateX(0); }
  .nav-toggle { display: block; background: none; border: none; font-family: var(--font-mono); font-size: 1.6rem; color: var(--ink); cursor: pointer; }
}

/* ---- hero ---- */
.hero { padding: 90px 0 70px; position: relative; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.3fr 0.7fr; gap: 40px; align-items: center; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; } }
.hero h1 { margin-bottom: 0.3em; }
.hero .lede { font-size: 1.15rem; color: var(--text-muted); max-width: 46ch; }

/* ---- seal / stamp signature element ---- */
.seal {
  --sz: 190px;
  width: var(--sz); height: var(--sz);
  border-radius: 50%;
  border: 2.5px solid var(--stamp-red);
  color: var(--stamp-red);
  display: flex; align-items: center; justify-content: center;
  position: relative;
  transform: rotate(-9deg);
  justify-self: center;
  opacity: 0.92;
  mix-blend-mode: multiply;
}
.seal::before {
  content: '';
  position: absolute; inset: 10px;
  border: 1px solid var(--stamp-red);
  border-radius: 50%;
}
.seal-text {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-align: center;
  text-transform: uppercase;
  line-height: 1.5;
}
.seal-text strong { display: block; font-size: 1rem; font-family: var(--font-display); letter-spacing: 0; margin: 2px 0; }
.seal-mini { border-radius: 50%; border: 1.5px solid var(--stamp-red); display: flex; align-items: center; justify-content: center; color: var(--stamp-red); font-family: var(--font-mono); font-size: 0.5rem; transform: rotate(-9deg); }

/* ---- ledger rows (pain points) ---- */
.ledger { border-top: 2px solid var(--ink); margin-top: 40px; }
.ledger-row {
  display: grid; grid-template-columns: 1fr auto; gap: 20px;
  padding: 18px 4px; border-bottom: 1px solid var(--rule);
  align-items: baseline;
}
.ledger-row .item { font-size: 1.02rem; }
.ledger-row .amount { font-family: var(--font-mono); color: var(--stamp-red); white-space: nowrap; }

/* ---- sections ---- */
.section { padding: 70px 0; }
.section-alt { background: var(--paper-dark); }
.section-dark { background: var(--ink); color: var(--paper-light); }
.section-dark h2, .section-dark h3 { color: var(--paper-light); }
.section-dark p { color: #C9D2E0; }
.section-head { max-width: 62ch; margin-bottom: 44px; }

/* ---- cards ---- */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
@media (max-width: 900px) { .grid-4, .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--paper-light);
  border: 1.5px solid var(--ink);
  border-radius: 3px;
  padding: 26px 24px;
  display: flex; flex-direction: column; gap: 10px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: 5px 5px 0 var(--ink); }
.card .num { color: var(--stamp-red); font-size: 0.85rem; }
.card h3 { margin-bottom: 4px; }
.card p { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 0; }
.card .link { margin-top: auto; font-family: var(--font-mono); font-size: 0.85rem; color: var(--seal-green); padding-top: 10px; }

/* ---- process steps (legit numbered — real sequence) ---- */
.steps { counter-reset: step; }
.step { display: grid; grid-template-columns: 64px 1fr; gap: 22px; padding: 26px 0; border-bottom: 1px solid var(--rule); }
.step:first-child { border-top: 1px solid var(--rule); }
.step-num { font-family: var(--font-mono); font-size: 1.6rem; color: var(--stamp-red); }
.step h3 { margin-bottom: 6px; }
.step p { margin-bottom: 0; color: var(--text-muted); }

/* ---- list check ---- */
.check-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; }
.check-list li::before { content: '✓'; font-family: var(--font-mono); color: var(--seal-green); font-weight: 600; flex-shrink: 0; }

/* ---- cta band ---- */
.cta-band { background: var(--ink); color: var(--paper-light); padding: 60px 0; text-align: center; }
.cta-band h2 { color: var(--paper-light); }
.cta-band .btn-row { justify-content: center; }
.cta-band .btn-ghost { border-color: var(--paper-light); color: var(--paper-light); }
.cta-band .btn-ghost:hover { background: var(--paper-light); color: var(--ink); }

/* ---- footer ---- */
.site-footer { background: var(--ink); color: #C9D2E0; padding: 56px 0 26px; border-top: 4px double var(--stamp-red); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { color: var(--paper-light); font-family: var(--font-mono); font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 16px; }
.site-footer a { display: block; margin-bottom: 10px; color: #C9D2E0; font-size: 0.95rem; }
.site-footer a:hover { color: var(--paper-light); }
.footer-bottom { border-top: 1px solid #3A4A6B; padding-top: 22px; font-family: var(--font-mono); font-size: 0.8rem; color: #8695B3; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* ---- page hero (inner pages) ---- */
.page-hero { padding: 60px 0 50px; border-bottom: 2px solid var(--ink); }
.page-hero .icon-seal { width: 64px; height: 64px; margin-bottom: 20px; }

/* generic utility */
.center { text-align: center; }
.mt-0 { margin-top: 0; }
