/* ============================================================
   micoco.ai — an ebike for your brain
   Shared stylesheet
   Accessibility-first: 19px base, high contrast, generous spacing
   ============================================================ */

:root {
  /* Color tokens */
  --teal-900: #134E4A;
  --teal-700: #0F766E;
  --teal-500: #14B8A6;
  --teal-100: #CCFBF1;
  --teal-50:  #F0FDFA;

  --amber-700: #B45309;
  --amber-500: #D97706;
  --amber-100: #FEF3C7;

  --cream:   #FEFCF7;
  --white:   #FFFFFF;
  --ink:     #1F2937;
  --slate:   #475569;
  --muted:   #94A3B8;
  --border:  #E2E8F0;
  --rose-100: #FFE4E6;
  --rose-700: #BE123C;
  --green-100: #D1FAE5;
  --green-700: #047857;

  /* Type */
  --serif: 'Fraunces', 'Source Serif Pro', Georgia, 'Times New Roman', serif;
  --sans:  'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Layout */
  --maxw: 1140px;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow:    0 8px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 60px rgba(15, 23, 42, 0.12);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 19px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
  color: var(--teal-900);
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2.2rem, 4.5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
h3 { font-size: 1.35rem; }
h4 { font-size: 1.1rem; }

p { margin: 0 0 1.2em; }
strong { color: var(--teal-900); }

a {
  color: var(--teal-700);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { color: var(--amber-700); }

ul, ol { padding-left: 1.4em; margin: 0 0 1.2em; }
li { margin-bottom: 0.5em; }

img { max-width: 100%; height: auto; display: block; }

/* ---------- Layout ---------- */
.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 72px 0; }
section.tight { padding: 48px 0; }

.center { text-align: center; }
.muted { color: var(--slate); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(254, 252, 247, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  max-width: var(--maxw);
  margin: 0 auto;
}
.logo {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.4rem;
  color: var(--teal-900);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.logo-mark {
  width: 32px; height: 32px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--teal-700), var(--amber-500));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
  font-weight: 700;
  font-family: var(--sans);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0; padding: 0;
}
.nav-links a {
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
  font-size: 1rem;
}
.nav-links a:hover { color: var(--teal-700); }
.nav-cta { margin-left: 8px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 14px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.1s ease, box-shadow 0.2s ease, background 0.2s;
  cursor: pointer;
}
.btn-primary {
  background: var(--teal-700);
  color: white;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--teal-900);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}
.btn-secondary {
  background: white;
  color: var(--teal-900);
  border-color: var(--border);
}
.btn-secondary:hover {
  border-color: var(--teal-500);
  color: var(--teal-900);
}
.btn-amber {
  background: var(--amber-500);
  color: white;
}
.btn-amber:hover { background: var(--amber-700); color: white; }
.btn-lg { padding: 18px 32px; font-size: 1.1rem; }

/* ---------- Hero ---------- */
.hero {
  padding: 80px 0 56px;
  background: radial-gradient(ellipse at top right, var(--teal-50), var(--cream) 60%);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.hero h1 { margin-bottom: 0.4em; }
.hero .lede {
  font-size: 1.25rem;
  color: var(--slate);
  margin-bottom: 1.6em;
  max-width: 520px;
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-image {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-lg);
}
.eyebrow {
  display: inline-block;
  background: var(--amber-100);
  color: var(--amber-700);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 999px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

/* ---------- Cards / Feature grid ---------- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.card {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.1s;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.card h3 { margin-top: 0.2em; }
.card-icon {
  width: 44px;
  height: 44px;
  background: var(--teal-50);
  color: var(--teal-700);
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 14px;
}
.card-icon.amber { background: var(--amber-100); color: var(--amber-700); }

/* ---------- Pipeline diagram ---------- */
.pipeline {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  margin: 36px 0;
}
.step {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 18px;
  position: relative;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.step-num {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  width: 28px;
  height: 28px;
  background: var(--teal-700);
  color: white;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: var(--sans);
}
.step h4 { margin: 8px 0 6px; font-size: 0.95rem; }
.step p { font-size: 0.85rem; color: var(--slate); margin: 0; }
.step-icon { font-size: 1.6rem; margin-bottom: 4px; }

/* ---------- Sample report card ---------- */
.report {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  font-family: var(--sans);
}
.report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border);
  padding-bottom: 16px;
  margin-bottom: 20px;
}
.report-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  align-items: center;
}
.report-row:last-child { border-bottom: 0; }
.pill {
  font-size: 0.8rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--green-100);
  color: var(--green-700);
}
.pill.warn  { background: var(--amber-100); color: var(--amber-700); }
.pill.alert { background: var(--rose-100);  color: var(--rose-700); }

/* ---------- Pricing ---------- */
.tiers {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: stretch;
}
.tier {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  display: flex;
  flex-direction: column;
}
.tier.featured {
  border: 2px solid var(--teal-700);
  position: relative;
  box-shadow: var(--shadow-lg);
}
.tier.featured::before {
  content: 'Most popular';
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--teal-700);
  color: white;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: 999px;
}
.tier h3 { margin-top: 0; }
.price {
  font-family: var(--serif);
  font-size: 2.6rem;
  color: var(--teal-900);
  font-weight: 600;
  margin: 8px 0 4px;
}
.price small { font-size: 1rem; color: var(--slate); font-family: var(--sans); }
.tier ul { list-style: none; padding: 0; margin: 24px 0; flex: 1; }
.tier li {
  padding: 8px 0 8px 28px;
  position: relative;
}
.tier li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--teal-700);
  font-weight: 700;
}

/* ---------- Form ---------- */
.form {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  max-width: 560px;
  margin: 0 auto;
  box-shadow: var(--shadow);
}
.field { margin-bottom: 20px; }
.field label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--teal-900);
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  font-size: 1rem;
  font-family: var(--sans);
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--cream);
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid var(--teal-500);
  outline-offset: 1px;
  border-color: var(--teal-500);
  background: white;
}
.field .hint { font-size: 0.85rem; color: var(--slate); margin-top: 4px; }
.checkbox-row { display: flex; gap: 10px; align-items: flex-start; }
.checkbox-row input { width: auto; margin-top: 6px; }

/* ---------- Dashboard preview ---------- */
.dash {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.dash-side {
  background: var(--teal-900);
  color: white;
  padding: 28px 20px;
}
.dash-side h4 { color: white; margin-top: 0; }
.dash-side ul { list-style: none; padding: 0; }
.dash-side li {
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.95rem;
  margin-bottom: 4px;
}
.dash-side li.active,
.dash-side li:hover {
  background: rgba(255,255,255,0.1);
}
.dash-main { padding: 28px; }
.tile {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 18px;
}
.tile h4 { margin-top: 0; color: var(--teal-900); display: flex; align-items: center; justify-content: space-between; }

/* ---------- Callout ---------- */
.callout {
  background: linear-gradient(135deg, var(--teal-700), var(--teal-900));
  color: white;
  border-radius: var(--radius);
  padding: 48px 40px;
  text-align: center;
}
.callout h2 { color: white; }
.callout p { color: rgba(255,255,255,0.9); max-width: 620px; margin: 0 auto 24px; }
.callout .btn-secondary {
  background: white;
  color: var(--teal-900);
  border-color: white;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--teal-900);
  color: rgba(255,255,255,0.85);
  padding: 56px 0 32px;
  margin-top: 48px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255,255,255,0.15);
}
.site-footer h5 {
  color: white;
  font-family: var(--serif);
  font-size: 1.05rem;
  margin: 0 0 14px;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.95rem;
}
.site-footer a:hover { color: var(--amber-100); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  padding-top: 24px;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.7);
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- Trust strip ---------- */
.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  justify-content: center;
  align-items: center;
  padding: 24px 0;
  color: var(--slate);
  font-size: 0.95rem;
}
.trust span { display: inline-flex; align-items: center; gap: 8px; }

/* ---------- Memory Explorer (calendar interface) ---------- */
.explorer {
  display: grid;
  grid-template-columns: 320px 320px 1fr;
  gap: 0;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  min-height: 620px;
}
.exp-pane {
  padding: 24px;
  border-right: 1px solid var(--border);
  overflow-y: auto;
  max-height: 720px;
}
.exp-pane:last-child { border-right: 0; }
.exp-pane h4 { margin-top: 0; color: var(--teal-900); font-size: 1rem; }

/* Calendar */
.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.cal-header button {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: 8px;
  width: 32px;
  height: 32px;
  cursor: pointer;
  font-size: 1rem;
  color: var(--teal-900);
}
.cal-header button:hover { background: var(--teal-50); border-color: var(--teal-500); }
.cal-month {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--teal-900);
  font-size: 1.05rem;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.cal-dow {
  text-align: center;
  font-size: 0.7rem;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  padding: 4px 0;
}
.cal-day {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 0.9rem;
  cursor: pointer;
  position: relative;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink);
}
.cal-day.empty { cursor: default; color: transparent; }
.cal-day:hover:not(.empty) { background: var(--teal-50); }
.cal-day.has-content {
  font-weight: 600;
}
.cal-day.has-content::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--amber-500);
}
.cal-day.selected {
  background: var(--teal-700);
  color: white;
  border-color: var(--teal-700);
}
.cal-day.selected::after { background: white; }
.cal-day.today {
  border-color: var(--teal-500);
}

/* Day conversations list */
.day-empty {
  text-align: center;
  color: var(--muted);
  padding: 60px 20px;
  font-size: 0.95rem;
}
.conv-item {
  padding: 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  margin-bottom: 10px;
  cursor: pointer;
  background: var(--cream);
  transition: background 0.15s, border-color 0.15s;
}
.conv-item:hover {
  background: var(--teal-50);
  border-color: var(--teal-500);
}
.conv-item.selected {
  background: var(--teal-50);
  border-color: var(--teal-700);
  border-left-width: 3px;
}
.conv-time {
  font-size: 0.8rem;
  color: var(--slate);
  font-weight: 600;
  margin-bottom: 4px;
}
.conv-title {
  font-weight: 600;
  color: var(--teal-900);
  margin-bottom: 4px;
  font-size: 0.95rem;
}
.conv-blurb {
  font-size: 0.85rem;
  color: var(--slate);
  margin: 0;
}

/* Conversation detail */
.detail-empty {
  text-align: center;
  color: var(--muted);
  padding: 80px 20px;
}
.detail-meta {
  font-size: 0.85rem;
  color: var(--slate);
  margin-bottom: 4px;
}
.detail-title {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--teal-900);
  margin: 0 0 16px;
}
.detail-row {
  margin-bottom: 16px;
}
.detail-label {
  font-size: 0.75rem;
  color: var(--slate);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}
.detail-text { color: var(--ink); }
.detail-callout {
  background: var(--teal-50);
  border-left: 3px solid var(--teal-700);
  padding: 12px 14px;
  border-radius: 6px;
  margin-bottom: 8px;
  font-size: 0.95rem;
}
.detail-callout.amber {
  background: #FFFBEB;
  border-left-color: var(--amber-500);
}

/* Audio player */
.audio-player {
  background: var(--teal-900);
  color: white;
  border-radius: 12px;
  padding: 18px;
  margin-top: 16px;
}
.audio-controls {
  display: flex;
  align-items: center;
  gap: 14px;
}
.audio-play {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--amber-500);
  border: 0;
  color: white;
  font-size: 1.1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.audio-play:hover { background: var(--amber-700); }
.audio-bar {
  flex: 1;
  height: 6px;
  background: rgba(255,255,255,0.2);
  border-radius: 3px;
  position: relative;
  cursor: pointer;
}
.audio-progress {
  position: absolute;
  left: 0; top: 0;
  height: 100%;
  width: 18%;
  background: var(--amber-500);
  border-radius: 3px;
}
.audio-time {
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}
.audio-note {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.7);
  margin: 10px 0 0;
}

@media (max-width: 980px) {
  .explorer { grid-template-columns: 1fr; }
  .exp-pane { border-right: 0; border-bottom: 1px solid var(--border); max-height: none; }
  .exp-pane:last-child { border-bottom: 0; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .grid-3, .tiers { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .pipeline { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .dash { grid-template-columns: 1fr; }
  .dash-side { padding: 18px; }
  .nav-links { display: none; }
  .nav-cta { display: inline-block; }
  section { padding: 56px 0; }
}
@media (max-width: 520px) {
  body { font-size: 17px; }
  .pipeline { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .report-row { grid-template-columns: 1fr; gap: 6px; }
  .callout { padding: 32px 20px; }
  .form { padding: 24px; }
}
