/* EzBill public website. Brand tokens follow apps/mobile/lib/app/theme.dart. */

@font-face { font-family: "Inter"; src: url("../fonts/Inter-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }

:root {
  --primary: #004ac6;
  --primary-bright: #2563eb;
  --primary-soft: #eff6ff;
  --primary-tint: #e0e8ff;
  --ink: #0f1b33;
  --ink-2: #434655;
  --muted: #6b7280;
  --line: #e2e8f0;
  --bg: #ffffff;
  --bg-alt: #f5f8ff;
  --success: #16a34a;
  --radius: 16px;
  --radius-lg: 24px;
  --shadow: 0 1px 2px rgba(15, 27, 51, 0.06), 0 8px 24px rgba(15, 27, 51, 0.06);
  --shadow-lg: 0 24px 60px rgba(0, 40, 120, 0.18);
  --max: 1160px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 0.5em; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 700; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 600; }
p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--primary); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header .bar { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.3rem; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { color: var(--ink-2); font-weight: 500; font-size: 0.97rem; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--primary); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--ink); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 22px; border-radius: 12px; font-weight: 600; font-size: 1rem;
  border: 2px solid transparent; transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
  cursor: pointer;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 8px 20px rgba(0, 74, 198, 0.28); }
.btn-primary:hover { background: #003da3; }
.btn-ghost { background: #fff; color: var(--primary); border-color: var(--primary-tint); }
.btn-ghost:hover { border-color: var(--primary); }
.btn-light { background: #fff; color: var(--primary); }
.nav .btn { padding: 10px 18px; color: #fff; }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(37, 99, 235, 0.16), transparent 60%),
    radial-gradient(700px 400px at -10% 110%, rgba(0, 74, 198, 0.10), transparent 60%),
    var(--bg-alt);
  padding: 80px 0 96px;
}
.hero .grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: #fff; color: var(--primary); border: 1px solid var(--primary-tint);
  padding: 6px 14px; border-radius: 999px; font-size: 0.85rem; font-weight: 600; margin-bottom: 20px;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.hero p.lead { font-size: 1.2rem; color: var(--ink-2); max-width: 560px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.hero .trust { display: flex; flex-wrap: wrap; gap: 22px; margin-top: 32px; color: var(--ink-2); font-size: 0.95rem; }
.hero .trust span { display: inline-flex; align-items: center; gap: 8px; }
.check { width: 20px; height: 20px; flex: none; color: var(--success); }

.devices { position: relative; height: 500px; }
.phone {
  position: absolute; width: 230px; border-radius: 36px; background: #0a1a3d; padding: 10px;
  box-shadow: var(--shadow-lg);
}
.phone img { border-radius: 27px; }
.phone.front { right: 30px; top: 0; transform: rotate(3deg); z-index: 2; }
.phone.back { left: 10px; top: 40px; transform: rotate(-6deg); opacity: 0.95; }

/* Sections */
section { padding: 96px 0; }
.section-head { max-width: 680px; margin: 0 auto 56px; text-align: center; }
.section-head p { color: var(--ink-2); font-size: 1.1rem; }
.alt { background: var(--bg-alt); }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 30px; box-shadow: var(--shadow);
}
.card p { color: var(--ink-2); margin: 0; }
.icon {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center;
  background: var(--primary-soft); color: var(--primary); margin-bottom: 18px;
}
.icon svg { width: 26px; height: 26px; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split ul { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 14px; }
.split li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink-2); }
.panel {
  background: linear-gradient(150deg, #0b3fb0, #2563eb 60%, #4f8bff);
  border-radius: var(--radius-lg); padding: 40px; color: #fff; box-shadow: var(--shadow-lg);
}
.panel .row { display: flex; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.18); }
.panel .row:last-child { border-bottom: 0; }
.panel .row svg { width: 28px; height: 28px; flex: none; }
.panel .row b { display: block; font-size: 1.05rem; }
.panel .row span { color: #dce7ff; font-size: 0.95rem; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: step; }
.step { position: relative; padding: 30px; border-radius: var(--radius-lg); background: #fff; border: 1px solid var(--line); }
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--primary); color: #fff; font-weight: 700; margin-bottom: 16px;
}
.step p { color: var(--ink-2); margin: 0; }

.cta {
  background: linear-gradient(120deg, #0b3fb0 0%, #2563eb 60%, #4f8bff 100%);
  color: #fff; border-radius: 28px; padding: 56px; display: flex; align-items: center;
  justify-content: space-between; gap: 32px; box-shadow: var(--shadow-lg);
}
.cta h2 { margin: 0 0 8px; }
.cta p { color: #dce7ff; margin: 0; font-size: 1.1rem; }

/* Page header for inner pages */
.page-head { background: var(--bg-alt); padding: 64px 0 48px; border-bottom: 1px solid var(--line); }
.page-head p { color: var(--ink-2); font-size: 1.1rem; max-width: 720px; margin: 0; }
.updated { color: var(--muted); font-size: 0.95rem; margin-top: 12px !important; }

/* Long-form text */
.prose { max-width: 780px; padding: 56px 24px 96px; margin: 0 auto; }
.prose h2 { font-size: 1.5rem; margin-top: 2em; }
.prose h3 { margin-top: 1.5em; }
.prose p, .prose li { color: #26324a; }
.prose ul { padding-left: 1.3em; }
.prose li { margin-bottom: 0.4em; }
.prose table { width: 100%; border-collapse: collapse; margin: 1em 0 1.5em; font-size: 0.95rem; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }
.prose th { background: var(--bg-alt); font-weight: 600; }
.note { background: var(--primary-soft); border: 1px solid var(--primary-tint); border-radius: var(--radius); padding: 18px 20px; }

/* Small helpers (the CSP allows no inline style attributes) */
.muted-text { color: var(--ink-2); }
.pt-0 { padding-top: 0; }
.pt-48 { padding-top: 48px; }
.center { text-align: center; }
.page-head.notfound { padding: 120px 0; }
.notfound-lead { margin: 0 auto 28px !important; }

/* Support */
.contact-section { padding-top: 72px; padding-bottom: 32px; }
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; position: relative; }
.faq { max-width: 820px; margin: 0 auto; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 12px; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--primary); font-size: 1.4rem; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--ink-2); margin: 12px 0 0; }

/* Footer */
.site-footer { background: #0a1a3d; color: #c7d2ee; padding: 64px 0 32px; }
.site-footer .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: #fff; margin: 0 0 14px; font-size: 1rem; }
.site-footer a { color: #c7d2ee; display: block; margin-bottom: 8px; }
.site-footer a:hover { color: #fff; }
.site-footer .brand { display: flex; color: #fff; margin-bottom: 12px; }
.site-footer .legal { border-top: 1px solid rgba(255, 255, 255, 0.12); margin-top: 40px; padding-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 0.9rem; }

/* Responsive */
@media (max-width: 960px) {
  .hero .grid, .split { grid-template-columns: 1fr; }
  .devices { height: 480px; max-width: 460px; margin: 0 auto; width: 100%; }
  .cards, .steps, .contact-grid { grid-template-columns: 1fr 1fr; }
  .site-footer .cols { grid-template-columns: 1fr 1fr; }
  .cta { flex-direction: column; align-items: flex-start; padding: 40px; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .nav { display: none; position: absolute; top: 72px; left: 0; right: 0; background: #fff; flex-direction: column; align-items: stretch; gap: 0; padding: 8px 16px 16px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .nav.open { display: flex; }
  .nav a { padding: 12px 4px; }
  .nav .btn { margin-top: 8px; }
  .nav-toggle { display: block; }
  .hero { padding: 48px 0 64px; }
  .devices { height: 420px; }
  .phone { width: 210px; border-radius: 32px; padding: 8px; }
  .phone img { border-radius: 25px; }
  .phone.front { right: auto; left: 50%; transform: translateX(-50%) rotate(2deg); }
  .phone.back { display: none; }
  section { padding: 64px 0; }
  .cards, .steps, .contact-grid, .site-footer .cols { grid-template-columns: 1fr; }
  .contact-grid { margin-top: 24px; }
  .cta { padding: 32px 24px; }
}
