/* CTDApp marketing site — static, no build step.
   Palette mirrors the app (slate + purple). */

:root {
  --purple: #7c3aed;
  --purple-dark: #6d28d9;
  --ink: #0f172a;
  --ink-2: #1e293b;
  --muted: #64748b;
  --muted-2: #94a3b8;
  --line: #e2e8f0;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #f1f5f9;
  --green: #16a34a;
  --amber: #d97706;
  --radius: 14px;
  --maxw: 1100px;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--purple); text-decoration: none; }
a:hover { color: var(--purple-dark); }

h1, h2, h3 { color: var(--ink); line-height: 1.2; letter-spacing: -0.01em; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.center { text-align: center; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  transition: background .15s, color .15s, border-color .15s, transform .05s;
  cursor: pointer;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--purple); color: #fff; }
.btn-primary:hover { background: var(--purple-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: var(--surface-3); color: var(--ink); }
.btn-lg { padding: 16px 30px; font-size: 17px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255,255,255,.85);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 700; }
.brand:hover { color: var(--ink); }
.brand-name { font-size: 18px; letter-spacing: -0.02em; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--ink-2); font-weight: 500; font-size: 15px; }
.nav-links a:hover { color: var(--purple); }
.nav-links .btn-ghost { font-size: 14px; padding: 8px 16px; }

/* ---------- Hero ---------- */
.hero { background: linear-gradient(180deg, var(--surface-2), var(--surface)); padding: 84px 0 72px; border-bottom: 1px solid var(--line); }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: 13px; font-weight: 700; color: var(--purple); margin: 0 0 14px; }
.hero h1 { font-size: 44px; margin: 0 0 20px; }
.lede { font-size: 19px; color: var(--ink-2); margin: 0 0 28px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-note { color: var(--muted); font-size: 14px; margin-top: 18px; }

.hero-panel { display: flex; justify-content: center; }
.panel-card {
  width: 100%; max-width: 360px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 20px 50px -24px rgba(15,23,42,.35); padding: 22px;
}
.panel-row { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--ink-2); padding: 11px 0; border-bottom: 1px solid var(--surface-3); }
.panel-row:last-of-type { border-bottom: 0; }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.dot-blue { background: var(--purple); }
.dot-green { background: var(--green); }
.dot-amber { background: var(--amber); }
.panel-bar { height: 8px; background: var(--surface-3); border-radius: 999px; margin: 16px 0 8px; overflow: hidden; }
.panel-bar span { display: block; height: 100%; background: var(--purple); border-radius: 999px; }
.panel-meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }
.panel-meta strong { color: var(--ink); }

/* ---------- Sections ---------- */
.section { padding: 76px 0; }
.section-alt { background: var(--surface-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section h2 { font-size: 32px; margin: 0 0 16px; }
.section-lede { font-size: 18px; color: var(--ink-2); margin: 0 auto; }
.section-head { margin-bottom: 44px; }
.section-head h2 { margin: 0; }
.section-head .eyebrow { margin-bottom: 10px; }

/* ---------- Grids ---------- */
.grid { display: grid; gap: 26px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.feature {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 24px; transition: border-color .15s, box-shadow .15s, transform .15s;
}
.feature:hover { border-color: #cbd5e1; box-shadow: 0 14px 34px -22px rgba(15,23,42,.4); transform: translateY(-2px); }
.feature-ico {
  display: inline-flex; align-items: center; justify-content: center;
  width: 46px; height: 46px; border-radius: 12px; background: #ede9fe; margin-bottom: 16px;
}
.feature h3 { font-size: 19px; margin: 0 0 8px; }
.feature p { margin: 0; color: var(--muted); font-size: 15px; }

.benefit { padding: 4px 2px; }
.benefit h3 { font-size: 18px; margin: 0 0 6px; }
.benefit p { margin: 0; color: var(--muted); font-size: 15px; }

.how-grid { gap: 26px; }
.how-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 32px 28px;
}
.how-card h3 { font-size: 21px; margin: 0 0 10px; }
.how-card p { margin: 0; color: var(--ink-2); font-size: 16px; }

/* ---------- Gallery ---------- */
.gallery { margin-bottom: 8px; }
.shot-fig { margin: 0; }
.shot-fig img { width: 100%; height: auto; display: block; border: 1px solid var(--line); border-radius: var(--radius); }
.shot-fig figcaption { margin-top: 12px; color: var(--muted); font-size: 14px; }

/* ---------- Product sketches (illustrative, not screenshots) ---------- */
.mock {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); aspect-ratio: 4 / 3; padding: 16px; overflow: hidden;
  display: flex; flex-direction: column; gap: 12px;
  box-shadow: 0 14px 34px -26px rgba(15,23,42,.4);
}
.mock-title { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }

/* availability matrix */
.mock-legend { display: flex; gap: 14px; font-size: 11px; color: var(--muted); }
.mock-legend span { display: inline-flex; align-items: center; gap: 5px; }
.mock-legend i { width: 9px; height: 9px; border-radius: 3px; flex: 0 0 auto; }
.cell-avail { background: #bbf7d0; }
.cell-resv { background: #fde68a; }
.cell-sold { background: #cbd5e1; }
.matrix { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; flex: 1; }
.matrix b { border-radius: 4px; }

/* pipeline */
.pipe { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; flex: 1; }
.pipe-col { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.pipe-col h4 { margin: 0 0 2px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.pipe-card { background: var(--surface); border: 1px solid var(--line); border-radius: 7px; padding: 8px; }
.pipe-card span { display: block; height: 6px; border-radius: 3px; background: var(--surface-3); }
.pipe-card span + span { margin-top: 5px; width: 60%; }

/* presentation site */
.site-frame { flex: 1; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; background: var(--surface-2); }
.site-bar { display: flex; align-items: center; gap: 6px; padding: 8px 10px; border-bottom: 1px solid var(--line); background: var(--surface); }
.site-bar i { width: 8px; height: 8px; border-radius: 50%; background: var(--surface-3); flex: 0 0 auto; }
.site-url { margin-left: 8px; height: 8px; flex: 1; max-width: 150px; background: var(--surface-3); border-radius: 4px; }
.site-body { position: relative; flex: 1; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.site-hero { height: 48px; border-radius: 8px; background: linear-gradient(135deg, #ede9fe, var(--surface-3)); }
.site-line { height: 8px; border-radius: 4px; background: var(--surface-3); }
.site-line.short { width: 50%; }
.chat-bubble {
  position: absolute; right: 12px; bottom: 12px; background: var(--purple); color: #fff;
  font-size: 11px; font-weight: 600; padding: 7px 11px; border-radius: 12px 12px 4px 12px;
  box-shadow: 0 8px 20px -8px rgba(124,58,237,.6);
}

/* ---------- FAQ ---------- */
.faq { display: flex; flex-direction: column; gap: 12px; }
.faq details {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 4px 20px;
}
.faq summary {
  list-style: none; cursor: pointer; padding: 16px 28px 16px 0; position: relative;
  font-weight: 600; font-size: 17px; color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 0; top: 14px;
  font-size: 22px; font-weight: 400; color: var(--purple); line-height: 1;
}
.faq details[open] summary::after { content: "–"; }
.faq-body { padding: 0 0 16px; }
.faq-body p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- Contact ---------- */
.contact { background: linear-gradient(180deg, var(--surface), var(--surface-2)); }
.contact h2 { font-size: 34px; }
.contact .btn-lg { margin-top: 10px; }

/* ---------- Lead form ---------- */
.lead-form {
  max-width: 640px; margin: 40px auto 22px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 26px; box-shadow: 0 18px 44px -30px rgba(15,23,42,.35);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.lead-form label { display: block; font-size: 14px; font-weight: 600; color: var(--ink-2); margin-bottom: 16px; }
.lead-form label.full { margin-bottom: 18px; }
.lead-form input, .lead-form textarea {
  display: block; width: 100%; margin-top: 6px; padding: 11px 13px;
  font: inherit; font-size: 15px; font-weight: 400; color: var(--ink);
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px;
}
.lead-form input:focus, .lead-form textarea:focus {
  outline: none; border-color: var(--purple); background: var(--surface);
  box-shadow: 0 0 0 3px rgba(124,58,237,.12);
}
.lead-form textarea { resize: vertical; }
.lead-form .btn { width: 100%; }
.form-hint { color: var(--muted); font-size: 13px; text-align: center; margin: 12px 0 0; }

/* ---------- Legal / privacy ---------- */
.legal h1 { font-size: 34px; margin: 0 0 8px; }
.legal .updated { color: var(--muted); font-size: 14px; margin: 0 0 28px; }
.legal h2 { font-size: 22px; margin: 36px 0 12px; }
.legal p, .legal li { color: var(--ink-2); font-size: 16px; }
.legal ul { padding-left: 22px; }
.legal li { margin-bottom: 6px; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: var(--surface); padding: 40px 0; }
.footer-row { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.footer-meta { color: var(--muted); font-size: 14px; margin: 4px 0 0; }
.footer-copy { color: var(--muted-2); font-size: 13px; margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-panel { order: -1; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 680px) {
  .nav-links { gap: 14px; }
  .nav-links a:not(.btn) { display: none; }
  .hero { padding: 56px 0 48px; }
  .hero h1 { font-size: 34px; }
  .lede { font-size: 17px; }
  .section { padding: 56px 0; }
  .section h2 { font-size: 27px; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}
