/**
 * Afrique Tontine (Aftont)
 * Design : noir & blanc + or (richesse) + bleu profond (confiance)
 */
:root {
  --black: #0a0a0a;
  --ink: #141414;
  --white: #ffffff;
  --cream: #f7f5f0;
  --muted: #6b6b6b;
  --line: rgba(10, 10, 10, 0.1);
  --gold: #c9a227;
  --gold-bright: #e0b93a;
  --gold-soft: rgba(201, 162, 39, 0.14);
  --blue: #0e3a5c;
  --blue-deep: #07263d;
  --blue-soft: rgba(14, 58, 92, 0.1);
  --radius: 18px;
  --max: 1180px;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Manrope", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(201, 162, 39, 0.12), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(14, 58, 92, 0.12), transparent 50%),
    linear-gradient(180deg, #fbfaf7 0%, #f3f1eb 45%, #eef2f6 100%);
  min-height: 100vh;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }

.shell {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}
.pat-landing .shell,
.pat-landing .site-nav-inner {
  width: 80%;
  max-width: none;
  margin-inline: auto;
}
@media (max-width: 768px) {
  .pat-landing .shell,
  .pat-landing .site-nav-inner {
    width: 95%;
  }
}

/* ─── Nav ─── */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(16px);
  background: rgba(10, 10, 10, 0.92);
  border-bottom: 1px solid rgba(201, 162, 39, 0.25);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.95rem 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background:
    linear-gradient(145deg, var(--gold-bright), var(--gold) 45%, var(--blue) 100%);
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 24px rgba(201, 162, 39, 0.35);
}
.brand strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.04em;
}
.brand span {
  display: block;
  color: rgba(255,255,255,0.55);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.nav-links {
  display: none;
  gap: 1.25rem;
  align-items: center;
}
.nav-links a {
  color: rgba(255,255,255,0.72);
  font-size: 0.92rem;
  font-weight: 500;
}
.nav-links a:hover { color: var(--gold-bright); }
.nav-cta {
  display: inline-flex;
  gap: 0.5rem;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border: none;
  border-radius: 999px;
  padding: 0.78rem 1.25rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform .2s, background .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-gold {
  background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  color: #111;
  box-shadow: 0 10px 28px rgba(201, 162, 39, 0.35);
}
.btn-blue {
  background: linear-gradient(135deg, #16507a, var(--blue-deep));
  color: #fff;
}
.btn-ghost {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.28);
}
.btn-dark {
  background: var(--black);
  color: #fff;
}
.btn-outline {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
}

/* ─── Hero ─── */
.hero {
  position: relative;
  min-height: min(92vh, 860px);
  display: grid;
  align-items: end;
  overflow: hidden;
  color: #fff;
  isolation: isolate;
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.85) contrast(1.05);
}
.hero-shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(7, 18, 28, 0.35) 0%, rgba(7, 18, 28, 0.55) 40%, rgba(7, 10, 14, 0.92) 100%),
    linear-gradient(90deg, rgba(10,10,10,0.55), transparent 55%);
}
.hero-content {
  padding: 7rem 0 4.5rem;
  max-width: 720px;
}
.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  background: var(--gold-soft);
  border: 1px solid rgba(201, 162, 39, 0.45);
  color: var(--gold-bright);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}
.hero h1 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 7vw, 5.2rem);
  line-height: 0.95;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.hero h1 em {
  font-style: italic;
  color: var(--gold-bright);
}
.hero p {
  margin: 0 0 1.75rem;
  max-width: 36rem;
  color: rgba(255,255,255,0.78);
  font-size: 1.08rem;
  line-height: 1.65;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ─── Sections ─── */
section { padding: 5rem 0; }
.section-head {
  max-width: 640px;
  margin-bottom: 2.5rem;
}
.section-head .eyebrow {
  color: var(--blue);
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 0.75rem;
  margin-bottom: 0.7rem;
}
.section-head h2 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.05;
}
.section-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-top: -3rem;
  position: relative;
  z-index: 2;
}
.stat {
  background: rgba(255,255,255,0.92);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  box-shadow: 0 18px 40px rgba(10,10,10,0.06);
}
.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--blue);
}
.stat span {
  color: var(--muted);
  font-size: 0.9rem;
}

.grid-3 {
  display: grid;
  gap: 1.25rem;
}
.feature {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.feature:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 50px rgba(14, 58, 92, 0.12);
}
.feature img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}
.feature-body { padding: 1.35rem 1.4rem 1.5rem; }
.feature-body h3 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
}
.feature-body p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}
.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--gold-soft);
  color: var(--gold);
  margin-bottom: 0.9rem;
  font-weight: 800;
}

.split {
  display: grid;
  gap: 2rem;
  align-items: center;
}
.split-visual {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  min-height: 360px;
  box-shadow: 0 30px 60px rgba(7, 38, 61, 0.2);
}
.split-visual img {
  width: 100%;
  height: 100%;
  min-height: 360px;
  object-fit: cover;
}
.split-badge {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  background: rgba(10,10,10,0.86);
  color: #fff;
  padding: 0.9rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(201,162,39,0.4);
  max-width: 240px;
}
.split-badge strong {
  display: block;
  color: var(--gold-bright);
  font-family: var(--font-display);
  font-size: 1.35rem;
}
.split-badge span { font-size: 0.85rem; color: rgba(255,255,255,0.7); }

.flow {
  display: grid;
  gap: 0.85rem;
}
.flow-step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1rem;
  align-items: start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1rem 1.1rem;
}
.flow-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.85rem;
}
.flow-step h4 { margin: 0 0 0.25rem; font-size: 1rem; }
.flow-step p { margin: 0; color: var(--muted); font-size: 0.92rem; }

.roles {
  display: grid;
  gap: 0.75rem;
}
.role-chip {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 1rem 1.15rem;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--line);
}
.role-chip strong { font-size: 0.98rem; }
.role-chip span { color: var(--muted); font-size: 0.86rem; }
.role-tag {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--blue);
  background: var(--blue-soft);
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
}

.cta-band {
  margin: 1rem 0 3rem;
  border-radius: 28px;
  padding: 2.5rem;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(10,10,10,0.55), rgba(7,38,61,0.75)),
    url("https://images.unsplash.com/photo-1556742049-0cfed4f6a45d?auto=format&fit=crop&w=1600&q=80") center/cover;
  display: grid;
  gap: 1rem;
}
.cta-band h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
}
.cta-band p { margin: 0; color: rgba(255,255,255,0.8); max-width: 34rem; }

.footer {
  background: var(--black);
  color: rgba(255,255,255,0.7);
  padding: 2.5rem 0;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
}
.footer strong {
  color: #fff;
  font-family: var(--font-display);
  font-size: 1.3rem;
}

/* ─── Auth gate premium ─── */
.app-body { background: var(--black); }
.auth-gate {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr;
}
.auth-visual {
  position: relative;
  min-height: 34vh;
  overflow: hidden;
  display: none;
}
.auth-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}
.auth-visual-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(7,18,28,0.25), rgba(7,10,14,0.88)),
    linear-gradient(90deg, rgba(10,10,10,0.55), transparent 60%);
}
.auth-visual-copy {
  position: relative;
  z-index: 1;
  color: #fff;
  padding: 3.5rem 2.5rem;
  max-width: 34rem;
  align-self: end;
}
.auth-kicker {
  display: inline-block;
  color: var(--gold-bright);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  margin: 0 0 1rem;
}
.auth-visual-copy h1 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 4vw, 3.8rem);
  line-height: 0.98;
  font-weight: 700;
}
.auth-visual-copy h1 em {
  font-style: italic;
  color: var(--gold-bright);
}
.auth-visual-copy p {
  margin: 0;
  color: rgba(255,255,255,0.75);
  line-height: 1.6;
}
.auth-panel {
  background:
    radial-gradient(700px 320px at 100% 0%, rgba(201,162,39,0.12), transparent 55%),
    linear-gradient(180deg, #111 0%, #0a0a0a 100%);
  color: #fff;
  padding: 2rem 1.35rem 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.auth-brand { margin-bottom: 1.75rem; }
.auth-brand strong { color: #fff; }
.auth-mode-tabs,
.auth-method-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  margin-bottom: 1rem;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 999px;
  padding: 0.3rem;
}
.auth-mode,
.auth-method {
  border: 0;
  background: transparent;
  color: rgba(255,255,255,0.65);
  border-radius: 999px;
  padding: 0.7rem 0.8rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
}
.auth-mode.is-active,
.auth-method.is-active {
  background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  color: #111;
}
.auth-method-tabs { margin-bottom: 1.25rem; }
.auth-form .field label { color: rgba(255,255,255,0.55); }
.auth-form .field input,
.auth-form .field textarea,
.auth-form .field select {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.12);
  color: #fff;
}
.auth-form .field input::placeholder { color: rgba(255,255,255,0.35); }
.phone-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem;
  align-items: center;
}
.phone-prefix {
  background: rgba(201,162,39,0.15);
  border: 1px solid rgba(201,162,39,0.35);
  color: var(--gold-bright);
  border-radius: 12px;
  padding: 0.75rem 0.85rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}
.field-hint {
  margin: 0.4rem 0 0;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.4);
}
.btn-block { width: 100%; margin-top: 0.35rem; }
.auth-demo {
  margin-top: 1.4rem;
  padding: 1rem;
  border-radius: 16px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  font-size: 0.84rem;
  color: rgba(255,255,255,0.7);
  line-height: 1.55;
}
.auth-demo p { margin: 0.15rem 0; }
.auth-demo code {
  color: var(--gold-bright);
  font-family: ui-monospace, monospace;
  font-size: 0.8rem;
}
.auth-back {
  margin-top: 1.25rem;
  color: rgba(255,255,255,0.55);
  font-size: 0.9rem;
}
.auth-back:hover { color: var(--gold-bright); }

/* App shell */
.app-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr;
  background:
    radial-gradient(900px 420px at 0% 0%, rgba(201,162,39,0.08), transparent 50%),
    radial-gradient(800px 400px at 100% 0%, rgba(14,58,92,0.1), transparent 50%),
    var(--cream);
}
.app-side {
  background: linear-gradient(180deg, #0f0f0f, #070707);
  color: #fff;
  padding: 1.35rem;
  border-bottom: 1px solid rgba(201,162,39,0.2);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.side-user {
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  font-size: 0.9rem;
  line-height: 1.45;
}
.side-nav {
  display: grid;
  gap: 0.35rem;
  flex: 1;
}
.side-link {
  text-align: left;
  border: 0;
  background: transparent;
  color: rgba(255,255,255,0.7);
  padding: 0.85rem 1rem;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
}
.side-link:hover { background: rgba(255,255,255,0.06); color: #fff; }
.side-link.is-active {
  background: linear-gradient(135deg, rgba(201,162,39,0.22), rgba(14,58,92,0.35));
  color: #fff;
  border: 1px solid rgba(201,162,39,0.3);
}
.app-main { padding: 1.25rem; }
.app-top {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  margin-bottom: 1.1rem;
}
.app-top .eyebrow {
  margin: 0 0 0.25rem;
  color: var(--blue);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.app-top h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.3rem);
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}
.panel-soft {
  background: rgba(255,255,255,0.92);
  box-shadow: 0 18px 40px rgba(10,10,10,0.05);
}
.panel h3 {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 1.45rem;
}
.field { margin-bottom: 0.9rem; }
.field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
  color: var(--muted);
}
.field input, .field select, .field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  background: #fff;
}
.tontine-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.05rem 1.1rem;
  margin-bottom: 0.75rem;
  background:
    linear-gradient(135deg, rgba(201,162,39,0.06), transparent 40%),
    linear-gradient(180deg, #fff, #fbfaf7);
  transition: transform .2s, box-shadow .2s;
}
.tontine-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(14,58,92,0.1);
}
.tontine-card strong { display: block; margin-bottom: 0.25rem; font-size: 1.05rem; }
.muted { color: var(--muted); }
.badge {
  display: inline-flex;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: var(--gold-soft);
  color: #8a6d10;
  font-size: 0.72rem;
  font-weight: 800;
}
.qr-box {
  width: 180px;
  height: 180px;
  border-radius: 16px;
  border: 1px solid var(--line);
  padding: 0.5rem;
  background: #fff;
}
.toast {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  background: var(--black);
  color: #fff;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  border-left: 4px solid var(--gold);
  z-index: 100;
  display: none;
}
.toast.show { display: block; animation: rise .35s ease; }
@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (min-width: 760px) {
  .nav-links { display: flex; }
  .stats { grid-template-columns: repeat(4, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .split { grid-template-columns: 1.05fr 0.95fr; }
  .auth-gate { grid-template-columns: 1.15fr 0.85fr; }
  .auth-visual { display: grid; min-height: 100vh; }
  .auth-panel { padding: 3rem 3.2rem; }
  .app-layout { grid-template-columns: 290px 1fr; }
  .app-side {
    border-bottom: 0;
    border-right: 1px solid rgba(201,162,39,0.2);
    min-height: 100vh;
    position: sticky;
    top: 0;
  }
}
@media (min-width: 900px) {
  .detail-grid { grid-template-columns: 1.2fr 0.8fr !important; }
}
