/* Next Million Dollar Idea — shared styles
   Palette mirrors the mobile app (lib/utils/theme.dart) */

:root {
  --green: #1db954;
  --green-dim: #17a344;
  --green-deep: #064e3b;
  --bg: #121212;
  --surface: #181818;
  --card: #282828;
  --line: #2f2f2f;
  --text: #ffffff;
  --muted: #b3b3b3;
  --muted-dim: #8a8a8a;
  --radius: 14px;
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; }

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

header.site {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 24px;
  background: rgba(18, 18, 18, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  letter-spacing: -0.2px;
}
.brand:hover { text-decoration: none; }

.brand .mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--green), var(--green-deep));
  font-size: 17px;
  flex: none;
}

header.site nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
}
header.site nav a { color: var(--muted); }
header.site nav a:hover { color: var(--text); text-decoration: none; }
header.site nav a.cta {
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--green);
  color: #08130c;
  font-weight: 600;
}
header.site nav a.cta:hover { background: #23d365; }

/* ---------- layout ---------- */

main { max-width: var(--maxw); margin: 0 auto; padding: 0 24px 96px; }
main.doc { max-width: 780px; }

section { padding: 72px 0; }
section + section { border-top: 1px solid var(--line); }

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

.hero {
  position: relative;
  overflow: hidden;
  padding: 96px 24px 88px;
  text-align: center;
  border-bottom: 1px solid var(--line);
}
.hero::before {
  content: "";
  position: absolute;
  inset: -40% 50% auto;
  width: 900px;
  height: 900px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(29, 185, 84, 0.16) 0%, transparent 62%);
  pointer-events: none;
}
.hero > * { position: relative; }

.eyebrow {
  display: inline-block;
  padding: 5px 14px;
  margin-bottom: 22px;
  border: 1px solid rgba(29, 185, 84, 0.35);
  border-radius: 999px;
  background: rgba(29, 185, 84, 0.08);
  color: var(--green);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0 auto 20px;
  max-width: 15ch;
  font-size: clamp(38px, 7vw, 68px);
  line-height: 1.05;
  letter-spacing: -1.8px;
  font-weight: 800;
}
.hero h1 .accent {
  background: linear-gradient(120deg, var(--green), #6ee7a8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p.lead {
  margin: 0 auto 34px;
  max-width: 58ch;
  color: var(--muted);
  font-size: clamp(16px, 2.1vw, 19px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 13px 28px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s ease, border-color .15s ease, transform .1s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: none; }
.btn-primary { background: var(--green); color: #08130c; }
.btn-primary:hover { background: #23d365; }
.btn-ghost { background: transparent; border-color: #3d3d3d; color: var(--text); }
.btn-ghost:hover { border-color: var(--muted); background: rgba(255, 255, 255, 0.04); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-block { width: 100%; justify-content: center; }

/* ---------- generic sections ---------- */

.section-head { max-width: 620px; margin-bottom: 44px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head h2 {
  margin: 0 0 12px;
  font-size: clamp(26px, 3.6vw, 36px);
  letter-spacing: -0.8px;
  line-height: 1.2;
}
.section-head p { margin: 0; color: var(--muted); font-size: 17px; }

.grid { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

.card {
  padding: 26px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.card .ico {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: 16px;
  border-radius: 11px;
  background: rgba(29, 185, 84, 0.12);
  font-size: 20px;
}
.card h3 { margin: 0 0 8px; font-size: 17px; letter-spacing: -0.2px; }
.card p { margin: 0; color: var(--muted); font-size: 14.5px; }

/* numbered steps */
.step .num {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 16px;
  border-radius: 50%;
  background: var(--green);
  color: #08130c;
  font-weight: 700;
  font-size: 15px;
}

/* ---------- doc pages ---------- */

main.doc h1 {
  margin: 48px 0 6px;
  font-size: clamp(30px, 5vw, 40px);
  letter-spacing: -1px;
}
main.doc h2 {
  margin: 40px 0 12px;
  font-size: 21px;
  letter-spacing: -0.3px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
main.doc h3 { margin: 26px 0 8px; font-size: 16.5px; color: var(--text); }
main.doc p, main.doc li { color: var(--muted); }
main.doc strong { color: var(--text); font-weight: 600; }
main.doc ul, main.doc ol { padding-left: 22px; }
main.doc li { margin-bottom: 7px; }

.meta { color: var(--muted-dim); font-size: 13.5px; margin-top: 0; }

.callout {
  padding: 18px 20px;
  margin: 26px 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--green);
  border-radius: 10px;
  font-size: 14.5px;
  color: var(--muted);
}
.callout strong { color: var(--text); }

table {
  width: 100%;
  margin: 20px 0;
  border-collapse: collapse;
  font-size: 14px;
  display: block;
  overflow-x: auto;
}
th, td {
  padding: 11px 14px;
  border: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  color: var(--muted);
}
th { background: var(--surface); color: var(--text); font-weight: 600; white-space: nowrap; }

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

.form-wrap { max-width: 620px; margin: 0 auto; }

.field { margin-bottom: 20px; }
.field label {
  display: block;
  margin-bottom: 7px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.field .hint { display: block; margin-top: 6px; font-size: 12.5px; color: var(--muted-dim); }

input[type="text"],
input[type="password"],
select,
textarea {
  width: 100%;
  padding: 13px 15px;
  background: var(--card);
  border: 1px solid transparent;
  border-radius: 10px;
  color: var(--text);
  font-size: 15px;
  font-family: inherit;
  line-height: 1.5;
}
input::placeholder, textarea::placeholder { color: var(--muted-dim); }
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--green);
  background: #2e2e2e;
}
textarea { resize: vertical; min-height: 150px; }
select { appearance: none; cursor: pointer; }

.counter { float: right; font-size: 12.5px; color: var(--muted-dim); font-weight: 400; }
.counter.over { color: #f87171; }

.alert {
  padding: 14px 16px;
  margin-bottom: 22px;
  border-radius: 10px;
  font-size: 14.5px;
  display: none;
}
.alert.show { display: block; }
.alert.ok { background: rgba(29, 185, 84, 0.12); border: 1px solid rgba(29, 185, 84, 0.4); color: #7ee2a4; }
.alert.err { background: rgba(248, 113, 113, 0.1); border: 1px solid rgba(248, 113, 113, 0.35); color: #fca5a5; }

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

footer.site {
  padding: 44px 24px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}
.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
}
footer.site nav { display: flex; flex-wrap: wrap; gap: 20px; font-size: 14px; }
footer.site nav a { color: var(--muted); }
footer.site nav a:hover { color: var(--text); text-decoration: none; }
footer.site .copy { color: var(--muted-dim); font-size: 13.5px; }

@media (max-width: 640px) {
  header.site { padding: 12px 16px; }
  header.site nav { gap: 14px; font-size: 13.5px; }
  header.site nav a.hide-sm { display: none; }
  main { padding: 0 18px 72px; }
  section { padding: 56px 0; }
  .hero { padding: 68px 18px 64px; }
}
