/* =========================
   Coach Hybrid - App CSS
   Orange premium + Dark mode
   Mobile-first, no overflow
========================= */

:root{
  /* Neutres */
  --bg: #F6F6F8;
  --card: #FFFFFF;
  --text: #111111;
  --muted: #6B7280;
  --border: #EAEAEA;

  /* Orange "basic fit" (subtil) */
  --accent: #FF6A00;
  --accent2: #FF8C1A;

  --radius: 16px;
  --shadow: 0 12px 30px rgba(0,0,0,.05);
}

[data-theme="dark"]{
  --bg: #0F0F12;
  --card: #17171C;
  --text: #F3F4F6;
  --muted: #9CA3AF;
  --border: #26262C;
  --shadow: 0 12px 30px rgba(0,0,0,.40);
}

*{ box-sizing:border-box; }

html, body{
  height: 100%;
}

body{
  margin:0;
  background:var(--bg);
  color:var(--text);
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  transition: background .25s ease, color .25s ease;
}

a{
  color:inherit;
  text-decoration:none;
}

#app{
  max-width: 820px;
  margin: 0 auto;
  padding: 18px;
  overflow-x: hidden; /* anti scroll horizontal */
}

/* Typography helpers */
.h1{
  font-size: 22px;
  letter-spacing: -0.2px;
  margin: 0;
}
.p{
  margin: 6px 0 0 0;
  color: var(--muted);
  font-size: 14px;
}
.small{
  font-size: 12px;
  color: var(--muted);
}

/* Spacing helpers */
.mt12{ margin-top: 12px; }
.mt16{ margin-top: 16px; }

/* Cards */
.card{
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  min-width: 0;              /* anti overflow */
  transition: background .25s ease, border .25s ease;
}

/* Header row */
.splitTitle{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 12px;
}
.link{
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
}

/* Responsive layout (GRID stable) */
.row{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 720px){
  .row.two{ grid-template-columns: 1fr 1fr; }
}

/* KPI blocks */
.kpi{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap: 12px;
}
.kpi .label{
  color: var(--muted);
  font-size: 13px;
}
.kpi .value{
  font-size: 18px;
  font-weight: 750;
  letter-spacing: -0.2px;
}

/* Progress */
.progress{
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(0,0,0,.05);
}
[data-theme="dark"] .progress{
  background: rgba(255,255,255,.06);
}
.progress > div{
  height: 100%;
  width: 35%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
}

/* Buttons */
.btn{
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 14px;
  font-weight: 650;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  box-shadow: 0 10px 25px rgba(255,106,0,.25);
  transition: transform .1s ease, filter .15s ease;
}
.btn:active{ transform: scale(.98); }
.btn:hover{ filter: brightness(1.02); }

/* Badges */
.badges{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}
.badge{
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 650;
  color: var(--accent);
  background: rgba(255,106,0,.10);
  border: 1px solid rgba(255,106,0,.18);
}
[data-theme="dark"] .badge{
  background: rgba(255,106,0,.12);
  border: 1px solid rgba(255,106,0,.22);
}

/* Theme toggle */
.toggleTheme{
  cursor: pointer;
  user-select: none;
  font-size: 14px;
  color: var(--muted);
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
}

/* =========================
   Onboarding (premium)
========================= */
.ob-wrap{
  min-height: calc(100vh - 36px);
  display:flex;
  align-items:flex-start;
  justify-content:center;
  padding-top: 18px;
}

.ob-card{
  width: 100%;
  max-width: 520px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 18px;
}

.ob-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom: 12px;
}

.ob-close{
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
}

.ob-back{
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 12px;
  cursor:pointer;
  font-weight: 600;
}

.ob-progress{
  margin-top: 10px;
}
.ob-progress .progress{
  height: 8px;
}
.ob-step{
  margin-top: 8px;
  font-size: 12px;
  color: var(--muted);
}

.ob-title{
  font-size: 20px;
  letter-spacing: -0.2px;
  margin-top: 14px;
  line-height: 1.25;
}

.ob-helper{
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.ob-options{
  margin-top: 16px;
  display:grid;
  gap: 10px;
}

.ob-option{
  width: 100%;
  text-align:left;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(0,0,0,.02);
  padding: 14px 14px;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 12px;
  font-weight: 700;
  color: var(--text);
  transition: transform .08s ease, border .15s ease, background .15s ease;
}
[data-theme="dark"] .ob-option{
  background: rgba(255,255,255,.04);
}

.ob-option:active{ transform: scale(.99); }
.ob-option:hover{ border-color: rgba(255,106,0,.35); }

.ob-pill{
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

.ob-cta{
  margin-top: 16px;
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 14px;
  font-weight: 750;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  box-shadow: 0 10px 25px rgba(255,106,0,.22);
}

/* checkbox list nicer */
.ob-check{
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 12px 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(0,0,0,.02);
}
[data-theme="dark"] .ob-check{
  background: rgba(255,255,255,.04);
}
.ob-check input{ transform: scale(1.1); }