/* ============================================================
   NosuApp — estilos globais
   Dark suave (violeta/grafite) · destaque roxo · mobile first
   ============================================================ */

:root {
  --bg: #0e0e11;
  --bg-grad-top: #141417;
  --bg-grad-bottom: #0c0c0f;
  --bg-card: #151518;
  --bg-elevated: #1c1c21;
  --border: #29292f;
  --accent: #6366f1;
  --accent-2: #4f7cf6;
  --accent-hover: #818cf8;
  --accent-soft: rgba(99, 102, 241, 0.14);
  --on-accent: #ffffff;
  --text: #f4f4f6;
  --text-dim: #9a9aa6;
  --success: #34d399;
  --danger: #fb7185;
  --radius: 16px;
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.4);
}

/* ---------- Estilo minimalista (preto, destaque monocromático) ----------
   Vence a paleta do coach (data-coach) com !important nas variáveis. */
body[data-style="minimal"] {
  --bg: #0c0c0e !important;
  --bg-grad-top: #141417 !important;
  --bg-grad-bottom: #0a0a0c !important;
  --bg-card: #141416 !important;
  --bg-elevated: #1b1b1e !important;
  --border: #2a2a2e !important;
  --accent: #e8e8ec !important;
  --accent-2: #c9c9d0 !important;
  --accent-hover: #ffffff !important;
  --accent-soft: rgba(255, 255, 255, 0.08) !important;
  --on-accent: #111114 !important;
  --text: #f5f5f6 !important;
  --text-dim: #9a9aa2 !important;
}

/* ---------- Tema claro (pastel, nao branco puro) ---------- */
body[data-theme="light"] {
  --bg: #f3f0fa;
  --bg-grad-top: #faf8ff;
  --bg-grad-bottom: #eee9f8;
  --bg-card: #f6f2fc;
  --bg-elevated: #ece6f8;
  --bg-card-2: rgba(79, 70, 229, 0.06);
  --border: #e3ddf0;
  --accent: #4f46e5;
  --accent-2: #2563eb;
  --accent-hover: #4338ca;
  --accent-soft: rgba(79, 70, 229, 0.12);
  --text: #2b2542;
  --text-dim: #6c6588;
  --success: #10b981;
  --danger: #ef4444;
  --shadow: 0 8px 28px rgba(90, 70, 130, 0.12);
  background:
    radial-gradient(1100px 520px at 75% -10%, rgba(99, 102, 241, 0.10), transparent 60%),
    radial-gradient(900px 480px at 0% 0%, rgba(236, 72, 153, 0.06), transparent 55%),
    linear-gradient(160deg, var(--bg-grad-top) 0%, var(--bg-grad-bottom) 60%);
  background-attachment: fixed;
}

/* ---------- Reduzir animacoes (acessibilidade) ---------- */
body.reduce-motion *,
body.reduce-motion *::before,
body.reduce-motion *::after {
  animation-duration: 0.001s !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001s !important;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* html sem fundo próprio: o fundo do body pinta a tela inteira
   (evita faixa de cor diferente quando o conteúdo é curto) */
html {
  height: 100%;
}

body {
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  min-height: 100%;
  /* fundo neutro e sóbrio (sem glow colorido) */
  background:
    radial-gradient(1100px 600px at 82% -12%, rgba(99, 102, 241, 0.05), transparent 62%),
    linear-gradient(170deg, var(--bg-grad-top) 0%, var(--bg-grad-bottom) 58%);
  background-attachment: fixed;
}

/* No minimalista, fundo é preto puro sem qualquer glow */
body[data-style="minimal"] {
  background:
    linear-gradient(170deg, #141417 0%, #0b0b0d 58%) !important;
  background-attachment: fixed;
}

.hidden {
  display: none !important;
}

/* ---------- Layout ---------- */
.container {
  max-width: 480px;
  margin: 0 auto;
  padding: 1.25rem 1rem 6rem;
}

h1 {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.subtitle {
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* ---------- Navegação inferior (estilo taskbar Win11: flutuante + centralizada) ---------- */
.bottom-nav {
  position: fixed;
  bottom: calc(0.6rem + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: auto;
  background: rgba(34, 29, 49, 0.85);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  padding: 0.25rem;
  z-index: 50;
  gap: 0.1rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.bottom-nav a {
  position: relative;
  color: var(--text-dim);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  transition: color 0.15s, background 0.15s;
}

.bottom-nav a:hover {
  background: var(--bg-elevated);
  color: var(--text);
}

/* Esconde o texto — só ícone fica visível */
.bottom-nav a > :not(.nav-icon) {
  display: none;
}

/* Tooltip no hover */
.bottom-nav a::after {
  content: attr(data-label);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.7rem;
  font-weight: 500;
  white-space: nowrap;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
}

.bottom-nav a:hover::after {
  opacity: 1;
}

.bottom-nav a .nav-icon {
  font-size: 1.1rem;
  display: flex;
}

/* Ícones SVG (estilo linha, como na referência) */
.nav-icon svg {
  width: 19px;
  height: 19px;
  display: block;
}

.ic {
  display: flex;
  align-items: center;
  justify-content: center;
}

.ic svg {
  width: 18px;
  height: 18px;
  display: block;
}

.menu-btn svg {
  width: 18px;
  height: 18px;
  display: block;
  margin: 0 auto;
}

.lock-icon {
  display: flex;
  justify-content: center;
  color: var(--text-dim);
  margin-bottom: 0.75rem;
}

.lock-icon svg {
  width: 44px;
  height: 44px;
}

.bottom-nav a.active {
  color: var(--accent-hover);
}

/* ---------- Header ---------- */
.app-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.premium-badge {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  letter-spacing: 0.03em;
  box-shadow: 0 2px 10px rgba(139, 92, 246, 0.4);
}

.logout-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.78rem;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s;
}

.logout-btn:hover {
  color: var(--text);
  border-color: var(--accent);
}

.clear-chat-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-dim);
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s;
}
.clear-chat-btn svg { width: 15px; height: 15px; }
.clear-chat-btn:hover { color: #fb7185; border-color: #fb7185; }

/* ---------- Botões ---------- */
/* Botão principal em tom neutro (até a marca definitiva) */
.btn {
  display: inline-block;
  width: 100%;
  background: #f2f2f4;
  color: #141417;
  border: none;
  border-radius: var(--radius);
  padding: 0.85rem 1.25rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.1s, background 0.15s, opacity 0.15s;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.btn:hover:not(:disabled) {
  background: #ffffff;
}

.btn:active:not(:disabled) {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-dim);
  box-shadow: none;
}

.btn-ghost:hover:not(:disabled) {
  background: var(--bg-elevated);
  box-shadow: none;
}

/* ---------- Página de Rotinas ---------- */
.rotina-card { margin-bottom: 1rem; }
.rotina-head { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 0.8rem; }
.rotina-emoji { font-size: 1.4rem; }
.rotina-title { font-size: 1.15rem; font-weight: 700; flex: 1; }
.rotina-start {
  background: var(--accent); color: var(--on-accent); border: none; border-radius: 999px;
  padding: 0.45rem 0.95rem; font-size: 0.82rem; font-weight: 700; cursor: pointer;
}
.rotina-start:disabled { opacity: 0.4; cursor: not-allowed; }
.rotina-steps { list-style: none; padding: 0; margin: 0 0 0.7rem; display: flex; flex-direction: column; gap: 0.4rem; }
.rotina-steps li { display: flex; align-items: center; gap: 0.6rem; background: var(--bg-elevated); border-radius: 10px; padding: 0.6rem 0.8rem; font-size: 0.92rem; }
.rotina-steps li span { flex: 1; }
.rotina-empty { color: var(--text-dim); justify-content: center; }
.rotina-del { background: none; border: none; color: var(--text-dim); font-size: 1.2rem; line-height: 1; cursor: pointer; padding: 0 0.2rem; }
.rotina-del:hover { color: var(--danger); }
.rotina-add { background: none; border: 1px dashed var(--border); color: var(--text-dim); border-radius: 10px; padding: 0.55rem; width: 100%; font-size: 0.88rem; font-weight: 600; cursor: pointer; }
.rotina-add:hover { border-color: var(--accent); color: var(--accent); }
/* Runner */
.rotina-run { text-align: center; padding: 2rem 1.3rem; }
.rotina-run-top { display: flex; justify-content: space-between; color: var(--text-dim); font-size: 0.85rem; margin-bottom: 1.5rem; }
.rotina-run-name { font-weight: 700; color: var(--text); }
.rotina-run-step { font-size: 1.5rem; font-weight: 700; line-height: 1.35; min-height: 4rem; display: flex; align-items: center; justify-content: center; margin-bottom: 1.8rem; }
.rotina-run-actions { display: flex; flex-direction: column; gap: 0.6rem; }

/* ---------- Página de Foco (Pomodoro) ---------- */
.focus-card { display: flex; flex-direction: column; align-items: center; gap: 1.3rem; padding: 1.6rem 1.2rem; }
.focus-ring-wrap { position: relative; width: 230px; height: 230px; }
.focus-ring { width: 100%; height: 100%; }
.focus-ring-bg { fill: none; stroke: var(--bg-elevated); stroke-width: 12; }
.focus-ring-fill { fill: none; stroke: var(--accent); stroke-width: 12; stroke-linecap: round; transition: stroke-dashoffset 0.3s linear; }
.focus-ring-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.focus-time { font-size: 3.1rem; font-weight: 800; letter-spacing: 0.02em; font-variant-numeric: tabular-nums; }
.focus-mode { font-size: 0.85rem; color: var(--text-dim); margin-top: 0.2rem; text-transform: uppercase; letter-spacing: 0.08em; }
.focus-presets { display: flex; gap: 0.5rem; flex-wrap: wrap; justify-content: center; }
.focus-preset {
  background: var(--bg-elevated); border: 1.5px solid var(--border); color: var(--text-dim);
  border-radius: 999px; padding: 0.5rem 1rem; font-size: 0.85rem; font-weight: 600; cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.focus-preset.is-active { border-color: var(--accent); color: var(--text); }
.focus-actions { display: flex; gap: 0.7rem; width: 100%; }
.focus-actions .btn { flex: 1; }
.focus-coach { display: flex; align-items: center; gap: 0.8rem; }
.focus-coach-ico { font-size: 1.4rem; }
.focus-coach p { font-size: 0.92rem; color: var(--text-dim); }
.focus-stats { display: flex; gap: 0.9rem; margin-top: 1rem; }
.focus-stat { flex: 1; background: var(--bg-card); border: 1px solid var(--border); border-radius: 14px; padding: 1rem; text-align: center; }
.focus-stat-num { font-size: 1.8rem; font-weight: 800; color: var(--accent); }
.focus-stat-label { font-size: 0.75rem; color: var(--text-dim); margin-top: 0.2rem; }

.btn-danger {
  background: transparent;
  border: 1px solid var(--danger);
  color: var(--danger);
  box-shadow: none;
  width: 100%;
}
.btn-danger:hover:not(:disabled) {
  background: var(--danger);
  color: #fff;
  box-shadow: none;
}
.danger-group { border-color: color-mix(in srgb, var(--danger) 30%, transparent); }
.danger-label { color: var(--danger); }

/* ---------- Formulários ---------- */
input[type='text'],
input[type='email'],
input[type='password'],
select {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 0.8rem 1rem;
  font-size: 1rem;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

input:focus,
select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

label.field-label {
  display: block;
  font-size: 0.85rem;
  color: var(--text-dim);
  margin: 1rem 0 0.4rem;
}

/* ---------- Auth ---------- */
.auth-screen {
  padding-top: 2.5rem;
}

.brand {
  text-align: center;
  margin-bottom: 1.5rem;
}

/* Logo provisória em tom neutro (até o usuário enviar a marca) */
.brand-logo {
  width: 64px;
  height: 64px;
  margin: 0 auto 0.6rem;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(109, 40, 217, 0.35);
}

.brand-logo svg {
  width: 100%;
  height: 100%;
  display: block;
}

.brand h1 {
  font-size: 1.7rem;
}

.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  box-shadow: var(--shadow);
}

.auth-card h2 {
  margin-bottom: 0.25rem;
}

.auth-card .btn {
  margin-top: 1.25rem;
}

.verify-code-input {
  text-align: center;
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: 0.5em;
  padding-left: 0.5em;
}
.verify-code-input::placeholder {
  letter-spacing: 0.5em;
  font-weight: 600;
}

.auth-toggle {
  display: block;
  width: 100%;
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 0.88rem;
  margin-top: 1rem;
  cursor: pointer;
}

.auth-toggle strong {
  color: var(--accent-hover);
}

.auth-error,
.auth-info {
  border-radius: 12px;
  padding: 0.65rem 0.85rem;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}

.auth-error {
  background: rgba(251, 113, 133, 0.12);
  border: 1px solid rgba(251, 113, 133, 0.4);
  color: var(--danger);
}

.auth-info {
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  color: var(--accent-hover);
}

/* ---------- Onboarding ---------- */
.onboarding {
  padding-top: 2.5rem;
}

.onboarding h1 {
  margin-bottom: 0.5rem;
}

.style-options {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

.style-option {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  font-size: 0.95rem;
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
}

.style-option:hover {
  border-color: var(--accent);
}

.style-option small {
  display: block;
  color: var(--text-dim);
  font-size: 0.8rem;
}

.style-option.selected {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.onboarding .btn {
  margin-top: 1.5rem;
}

/* ---------- Lista de hábitos ---------- */
#habit-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.habit-card {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 4px solid var(--habit-color, var(--accent));
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  transition: opacity 0.2s, transform 0.1s;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.habit-card.done {
  opacity: 0.5;
}

.habit-card.done .habit-name {
  text-decoration: line-through;
}

.habit-info {
  flex: 1;
  min-width: 0;
}

.habit-name {
  display: block;
  font-weight: 600;
}

.habit-meta {
  display: block;
  font-size: 0.75rem;
  color: var(--text-dim);
}

.streak {
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
}

/* Checkbox customizado — adota a cor do hábito */
.habit-check {
  position: relative;
  display: inline-block;
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

.habit-check input {
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.checkmark {
  position: absolute;
  inset: 0;
  border: 2px solid var(--border);
  border-radius: 8px;
  pointer-events: none;
  transition: all 0.15s;
}

.habit-check input:checked + .checkmark {
  background: var(--habit-color, var(--accent));
  border-color: var(--habit-color, var(--accent));
}

.habit-check input:checked + .checkmark::after {
  content: '✓';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
}

.empty-state {
  color: var(--text-dim);
  text-align: center;
  padding: 2rem 0;
  font-size: 0.9rem;
}

/* Pontinho de cor (dashboard) */
.color-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 0.5rem;
  vertical-align: middle;
}

/* FAB adicionar hábito */
.fab {
  position: fixed;
  bottom: calc(4.5rem + env(safe-area-inset-bottom));
  right: 1rem;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #f2f2f4;
  color: #141417;
  border: none;
  font-size: 1.75rem;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
  z-index: 40;
  transition: transform 0.1s;
}

.fab:active {
  transform: scale(0.94);
}

/* ---------- Seletor de cor ---------- */
.color-picker {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
  margin-top: 0.3rem;
}

.color-swatch {
  cursor: pointer;
}

.color-swatch input {
  display: none;
}

.color-swatch span {
  display: block;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--swatch);
  border: 2px solid transparent;
  box-shadow: 0 0 0 2px var(--bg-card);
  transition: transform 0.1s;
}

.color-swatch input:checked + span {
  border-color: #fff;
  transform: scale(1.12);
}

/* ---------- Seletor de ícones ---------- */
.icon-picker {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 0.35rem;
  margin-top: 0.3rem;
  max-height: 132px;
  overflow-y: auto;
  padding: 0.2rem;
}

@media (max-width: 480px) {
  .icon-picker { grid-template-columns: repeat(8, 1fr); }
}

.icon-swatch {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  background: var(--bg-card-2, rgba(255, 255, 255, 0.04));
  border: 1.5px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.1s, border-color 0.1s, color 0.1s;
}
.icon-swatch svg {
  width: 20px;
  height: 20px;
}

.icon-swatch:hover {
  transform: scale(1.1);
}

.icon-swatch.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}

/* ---------- Banner de upgrade ---------- */
.upgrade-banner {
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
  font-size: 0.88rem;
}

.upgrade-banner a {
  color: var(--accent-hover);
  font-weight: 600;
}

/* ---------- Modal ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 8, 16, 0.72);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  z-index: 100;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-bottom: none;
  border-radius: var(--radius) var(--radius) 0 0;
  padding: 1.5rem 1.25rem 2rem;
  width: 100%;
  max-width: 480px;
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: var(--shadow);
}

.modal h2 {
  margin-bottom: 0.5rem;
}

.modal-actions {
  display: flex;
  gap: 0.6rem;
  margin-top: 1.5rem;
}

.weekday-picker {
  display: flex;
  gap: 0.35rem;
  margin-top: 0.4rem;
  flex-wrap: wrap;
}

.weekday-picker label {
  flex: 1;
  min-width: 40px;
  text-align: center;
  font-size: 0.78rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.5rem 0;
  cursor: pointer;
}

.weekday-picker input {
  display: none;
}

.weekday-picker label:has(input:checked) {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ---------- Chat (coach) ---------- */
.chat-container {
  display: flex;
  flex-direction: column;
  height: calc(100dvh - 4.5rem);
  max-width: 480px;
  margin: 0 auto;
  padding: 1rem;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding-bottom: 1rem;
}

.bubble {
  max-width: 85%;
  padding: 0.7rem 1rem;
  border-radius: 16px;
  font-size: 0.95rem;
  white-space: pre-wrap;
}

.bubble-coach {
  background: var(--bg-elevated);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.bubble-user {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.chat-form {
  display: flex;
  gap: 0.5rem;
  padding-bottom: env(safe-area-inset-bottom);
}

.chat-form input {
  flex: 1;
}

.chat-form button {
  width: auto;
  padding: 0.8rem 1.2rem;
}

/* ---------- Paywall ---------- */
.paywall {
  text-align: center;
  padding-top: 3rem;
}

.paywall .lock-icon {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.paywall ul {
  list-style: none;
  text-align: left;
  margin: 1.5rem auto;
  max-width: 320px;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.paywall ul li::before {
  content: '✦ ';
  color: var(--accent);
}

/* ---------- Dashboard ---------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.22);
}

.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.92rem;
}

.stat-row:last-child {
  border-bottom: none;
}

.big-stat {
  font-size: 2.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent-hover), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.chart {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
  height: 140px;
  margin-top: 0.75rem;
}

.chart-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  height: 100%;
}

.chart-bar-track {
  flex: 1;
  width: 100%;
  max-width: 32px;
  background: var(--bg-elevated);
  border-radius: 6px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.chart-bar {
  width: 100%;
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  border-radius: 6px 6px 0 0;
  min-height: 2px;
  transition: height 0.4s ease;
}

.chart-label {
  font-size: 0.7rem;
  color: var(--text-dim);
}

.report-box {
  background: var(--bg-elevated);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem;
  margin-top: 0.75rem;
  font-size: 0.9rem;
  white-space: pre-wrap;
}

/* ---------- Planos ---------- */
.plans-page {
  padding-bottom: 7rem;
}

.plans-hero {
  text-align: center;
  padding: 1rem 0 1.5rem;
}

.plans-hero-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-hover);
  margin-bottom: 0.5rem;
}

.plans-hero-title {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
}

.plans-hero-sub {
  color: var(--text-dim);
  font-size: 0.88rem;
  max-width: 300px;
  margin: 0 auto;
}

/* Cards lado a lado (mobile: empilhados) */
.plan-cards {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.plan-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.1rem 1.1rem;
  position: relative;
}

.plan-card--premium {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 8px 32px rgba(139, 92, 246, 0.18);
}

.plan-card-badge {
  position: absolute;
  top: -11px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
  white-space: nowrap;
}

.plan-card-head {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.plan-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-dim);
}

.plan-label--premium {
  color: var(--accent-hover);
}

.plan-price {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0.3rem 0 0.25rem;
  line-height: 1;
}

.plan-price span {
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--text-dim);
}

.plan-desc {
  font-size: 0.82rem;
  color: var(--text-dim);
  line-height: 1.45;
}

/* Lista de features dentro do card */
.feature-list {
  list-style: none;
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 1.25rem;
}

.feature-list li {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--text);
}

.feature-group-title {
  font-size: 0.7rem !important;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-dim) !important;
  margin-top: 0.75rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}

.feature-group-title:first-child {
  margin-top: 0;
  border-top: none;
}

.feat-icon {
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  width: 16px;
  text-align: center;
}

.feat-icon.ok {
  color: var(--success);
}

.feat-icon.no {
  color: var(--border);
}

.feat-tag {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: var(--accent-soft);
  color: var(--accent-hover);
  border: 1px solid var(--accent);
  border-radius: 4px;
  padding: 0.1rem 0.35rem;
  margin-left: auto;
  flex-shrink: 0;
}

.plan-card-footer {
  margin-top: auto;
}

.btn--premium {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  box-shadow: 0 4px 18px rgba(139, 92, 246, 0.4);
}

.btn--premium:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--accent-hover), var(--accent-2));
  filter: brightness(1.08);
}

.plan-fine {
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 0.65rem;
  line-height: 1.4;
}

/* Detalhe dos recursos novos */
.features-detail {
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
}

.features-detail-title {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.72rem;
}

.feature-spotlight {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
}

.feature-spotlight:last-child {
  border-bottom: none;
}

.feature-spotlight-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-spotlight strong {
  display: block;
  font-size: 0.88rem;
  margin-bottom: 0.2rem;
}

.feature-spotlight p {
  font-size: 0.8rem;
  color: var(--text-dim);
  line-height: 1.5;
}

/* ============================================================
   TEMAS POR ESTILO DE COACH
   O body recebe data-coach="sargento|empatico|neutro" após o login.
   neutro = paleta violeta padrão (definida no :root).
   ============================================================ */

/* Sargento — preto pesado, contraste alto, vermelho/laranja */
body[data-coach='sargento']:not([data-theme='light']) {
  --bg: #050505;
  --bg-grad-top: #1a0a0a;
  --bg-grad-bottom: #000000;
  --bg-card: #121212;
  --bg-elevated: #1d1d1d;
  --border: #303030;
  --accent: #ef4444;
  --accent-2: #f97316;
  --accent-hover: #f87171;
  --accent-soft: rgba(239, 68, 68, 0.16);
  --text: #ffffff;
  --text-dim: #909090;
}

/* Empático — verde/teal acolhedor, fundo menos escuro */
body[data-coach='empatico']:not([data-theme='light']) {
  --bg: #0f1d18;
  --bg-grad-top: #173a2d;
  --bg-grad-bottom: #0c1813;
  --bg-card: #16271f;
  --bg-elevated: #1e332a;
  --border: #2e4a3e;
  --accent: #10b981;
  --accent-2: #14b8a6;
  --accent-hover: #34d399;
  --accent-soft: rgba(16, 185, 129, 0.16);
  --text: #f0faf5;
  --text-dim: #93ac9f;
}

/* ---------- Header: botão de menu ---------- */
.header-left {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

.menu-btn {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 11px;
  color: var(--text);
  font-size: 1.05rem;
  cursor: pointer;
  transition: border-color 0.15s;
}

.menu-btn:hover {
  border-color: var(--accent);
}

/* ---------- Hub: card de foco do dia ---------- */
.focus-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow);
}

.focus-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.focus-label {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--text-dim);
}

.focus-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0;
}

/* Anel de progresso do dia */
.progress-ring {
  position: relative;
  width: 58px;
  height: 58px;
  flex-shrink: 0;
}

.progress-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring-track {
  fill: none;
  stroke: var(--bg-elevated);
  stroke-width: 5;
}

.ring-fill {
  fill: none;
  stroke: var(--accent);
  stroke-width: 5;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.5s ease;
}

.ring-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
}

/* Linhas de hábito do hub */
#habit-list {
  gap: 0.5rem;
}

.habit-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0.85rem 1rem;
  transition: opacity 0.2s, border-color 0.2s, transform 0.1s;
}

.habit-row:active {
  transform: scale(0.99);
}

.habit-row.done {
  opacity: 0.5;
}

.habit-row.done .habit-name {
  text-decoration: line-through;
}

.habit-icon {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  background: var(--accent-soft);
}
.habit-icon svg {
  width: 22px;
  height: 22px;
}

/* Checkbox redondo (lado direito, como na referência) */
.round-check {
  position: relative;
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  cursor: pointer;
}

.round-check input {
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.round-check span {
  position: absolute;
  inset: 0;
  border: 2px solid var(--border);
  border-radius: 50%;
  pointer-events: none;
  transition: all 0.15s;
}

.round-check input:checked + span {
  background: var(--accent);
  border-color: var(--accent);
}

.round-check input:checked + span::after {
  content: '✓';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--on-accent, #fff);
  font-size: 0.8rem;
  font-weight: 700;
}

/* ---------- Calendário do mês (widget heatmap) ---------- */
.calendar-card {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.cal-big {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 80px;
}

.cal-big-weekday {
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text-dim);
}

.cal-big-day {
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.05;
}

.cal-grid-wrap {
  flex: 1;
  min-width: 0;
}

.cal-month {
  text-align: right;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-dim);
  margin-bottom: 0.4rem;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  text-align: center;
  font-size: 0.7rem;
}

.cal-h {
  color: var(--text-dim);
  font-weight: 600;
  padding: 0.15rem 0;
}

.cal-cell {
  padding: 0.26rem 0;
  border-radius: 7px;
  color: var(--text-dim);
}

/* Intensidade conforme % de check-ins do dia (heatmap) */
.cal-cell.lvl1 {
  background: color-mix(in srgb, var(--accent) 22%, transparent);
  color: var(--text);
}

.cal-cell.lvl2 {
  background: color-mix(in srgb, var(--accent) 45%, transparent);
  color: #fff;
}

.cal-cell.lvl3 {
  background: color-mix(in srgb, var(--accent) 70%, transparent);
  color: #fff;
}

.cal-cell.lvl4 {
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}

.cal-cell.cal-today {
  box-shadow: inset 0 0 0 2px var(--accent);
  color: var(--text);
  font-weight: 700;
}

.cal-cell.cal-future {
  opacity: 0.35;
}

/* ---------- Menu lateral (drawer) ---------- */
.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(2px);
  z-index: 120;
}

.drawer {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 272px;
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  padding: 1.25rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  overflow-y: auto;
}

.drawer-user {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.4rem 0.5rem 1rem;
  font-weight: 600;
  font-size: 1rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.5rem;
}

.drawer-avatar {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  overflow: hidden;
}
.drawer-avatar.has-photo {
  background: none;
}
.drawer-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.drawer-section {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin: 0.85rem 0 0.25rem;
  padding: 0 0.5rem;
}

.drawer a,
.drawer .drawer-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.55rem 0.6rem;
  border-radius: 10px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.92rem;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.12s;
}

.drawer a:hover,
.drawer .drawer-link:hover {
  background: var(--bg-elevated);
}

.drawer a.current {
  background: var(--accent-soft);
  color: var(--accent-hover);
  font-weight: 600;
}

/* ============================================================
   TELA INICIAL TODA PRETA (antes do login não há data-coach)
   ============================================================ */
body[data-page='index']:not([data-coach]):not([data-theme='light']) {
  --bg: #000000;
  --bg-grad-top: #050505;
  --bg-grad-bottom: #000000;
  --bg-card: #0c0c0c;
  --bg-elevated: #161616;
  --border: #242424;
}

/* ---------- Nav inferior: item ativo destacado ---------- */
.bottom-nav a.active {
  background: var(--accent-soft);
  color: var(--accent-hover);
}

/* ---------- Drawer: linha do usuário (topo, como na referência) ---------- */
.drawer-user {
  text-decoration: none;
  color: var(--text);
  cursor: pointer;
  border-radius: 10px;
}

.drawer-user:hover {
  background: var(--bg-elevated);
}

.drawer-user-name {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.drawer-chevron {
  color: var(--text-dim);
  font-size: 1.1rem;
}

/* ---------- Coach: personagem e avatares no chat ---------- */
.coach-hero {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  margin-bottom: 0.9rem;
  box-shadow: var(--shadow);
}

.coach-hero h2 {
  margin-bottom: 0.1rem;
  font-size: 1.05rem;
}

.coach-avatar {
  display: inline-block;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--accent);
}

.coach-avatar svg,
.coach-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.coach-avatar-lg {
  width: 56px;
  height: 56px;
}

.msg-row {
  display: flex;
  align-items: flex-end;
  gap: 0.5rem;
}

.msg-row.msg-user {
  justify-content: flex-end;
}

/* ---------- Perfil ---------- */
.profile-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.profile-banner {
  height: 130px;
  background-color: var(--bg-elevated);
  background-image: linear-gradient(135deg, var(--accent), var(--accent-2));
  background-size: cover;
  background-position: center;
}

.profile-banner[style*='url'] {
  background-image: var(--banner, none);
}

.profile-body {
  padding: 0 1.1rem 1.25rem;
}

.profile-avatar {
  width: 88px;
  height: 88px;
  margin-top: -44px;
  border-radius: 50%;
  border: 4px solid var(--bg-card);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 2rem;
  font-weight: 800;
  overflow: hidden;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-body h2 {
  margin: 0.7rem 0 0.1rem;
  font-size: 1.3rem;
}

.profile-bio {
  margin: 0.8rem 0;
  font-size: 0.92rem;
  color: var(--text);
  white-space: pre-wrap;
}

.profile-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.1rem;
}

.social-chip {
  display: inline-block;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
  font-size: 0.82rem;
  color: var(--text);
  text-decoration: none;
  transition: border-color 0.15s;
}

.social-chip:hover {
  border-color: var(--accent);
}

textarea {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 0.8rem 1rem;
  font-size: 1rem;
  font-family: inherit;
  outline: none;
  resize: vertical;
}

textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

input[type='file'] {
  width: 100%;
  color: var(--text-dim);
  font-size: 0.85rem;
}

input[type='file']::file-selector-button {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  padding: 0.45rem 0.9rem;
  margin-right: 0.6rem;
  cursor: pointer;
}

/* ---------- Calendário interativo ---------- */
.cal-cell.cal-clickable {
  cursor: pointer;
  transition: box-shadow 0.1s;
}

.cal-cell.cal-clickable:hover {
  box-shadow: inset 0 0 0 1.5px var(--accent-hover);
}

.day-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin: 0.9rem 0 1.2rem;
}

.day-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--bg-elevated);
  border-radius: 12px;
  padding: 0.6rem 0.8rem;
  font-size: 0.9rem;
}

.day-item-name {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.day-status {
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.day-status.done {
  color: var(--success);
}

.day-status.missed {
  color: var(--danger);
}

.day-status.pending {
  color: var(--text-dim);
}

.day-status.future {
  color: var(--accent-hover);
}

/* ============================================================
   COACH PROATIVO — banner clicável no topo da home
   ============================================================ */
.coach-nudge {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  padding: 0.7rem 0.85rem;
  margin-bottom: 1rem;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.1s, background 0.15s;
}

.coach-nudge:active {
  transform: scale(0.99);
}

.coach-nudge-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 2px solid var(--accent);
}

.coach-nudge-avatar img {
  width: 100%;
  height: 100%;
  display: block;
}

.coach-nudge-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.coach-nudge-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-hover);
}

.coach-nudge-msg {
  font-size: 0.88rem;
  font-weight: 500;
  line-height: 1.3;
}

.coach-nudge-arrow {
  color: var(--accent-hover);
  font-size: 1.4rem;
  flex-shrink: 0;
}

/* ============================================================
   TEMPLATES de hábito (chips no modal)
   ============================================================ */
.habit-templates {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  margin: 0.3rem 0 0.2rem;
  padding-bottom: 0.4rem;
  scrollbar-width: thin;
}

.habit-template {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  font-size: 0.78rem;
  padding: 0.35rem 0.75rem;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 0.15s;
}

.habit-template:hover {
  border-color: var(--accent);
}

.habit-template-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--swatch);
  flex-shrink: 0;
}

/* ============================================================
   BEM-ESTAR (respiração) — card horizontal
   ============================================================ */
.wellness-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.95rem 1rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow);
}

.wellness-info {
  flex: 1;
  min-width: 0;
}

.wellness-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--text-dim);
  margin-bottom: 0.15rem;
}

.wellness-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.15rem;
}

.wellness-sub {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.btn-pill {
  width: auto;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  border: none;
  font-weight: 600;
  cursor: pointer;
  flex-shrink: 0;
  transition: filter 0.15s;
}

.btn-pill:hover:not(:disabled) {
  filter: brightness(1.1);
}

.btn-pill:disabled {
  opacity: 0.55;
  cursor: default;
}

.btn-pill.is-active {
  background: var(--success);
}

.btn-pill-quit {
  background: transparent;
  color: var(--danger, #ef4444);
  border: 1.5px solid var(--danger, #ef4444);
}

.btn-pill-quit:hover:not(:disabled) {
  background: var(--danger, #ef4444);
  color: #fff;
  filter: none;
}

.challenge-card.is-active-card {
  box-shadow: 0 0 0 1.5px var(--challenge-color) inset;
}

/* ============================================================
   DESAFIOS — lista de mini-desafios
   ============================================================ */
.challenges-card {
  padding: 1rem 1.1rem;
}

.challenges-head {
  margin-bottom: 0.6rem;
}

.challenges-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0;
}

.challenges-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.challenge-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bg-elevated);
  border-left: 3px solid var(--challenge-color, var(--accent));
  border-radius: 12px;
  padding: 0.6rem 0.75rem;
}

.challenge-emoji {
  font-size: 1.3rem;
  flex-shrink: 0;
}

.challenge-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.challenge-name {
  font-weight: 600;
  font-size: 0.9rem;
}

.challenge-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* ============================================================
   RESPIRAÇÃO GUIADA — modal cheio + orbe animada
   ============================================================ */
.breath-modal {
  text-align: center;
}

.breath-techniques {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 0.8rem 0;
}

.breath-technique {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 0.9rem;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.breath-technique strong {
  display: block;
  margin-bottom: 0.2rem;
}

.breath-technique small {
  color: var(--text-dim);
  font-size: 0.78rem;
}

.breath-technique.selected {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.breath-duration {
  text-align: left;
}

/* Sessão ativa */
.breath-session {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem 0;
}

.breath-stage {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 1.5rem;
}

.breath-orb-wrap {
  position: relative;
  width: 220px;
  height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.breath-orb {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--accent-hover), var(--accent) 60%, var(--accent-2));
  box-shadow: 0 0 60px 10px var(--accent-soft);
  transition: transform 4s cubic-bezier(0.45, 0, 0.55, 1);
}

.breath-orb.breath-inspire {
  transform: scale(2.2);
}

.breath-orb.breath-segure {
  transform: scale(2.2);
}

.breath-orb.breath-expire {
  transform: scale(1);
}

.breath-count {
  position: relative;
  z-index: 1;
  font-size: 2.5rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

.breath-remaining {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 1rem;
}

/* ============================================================
   HANDLE @ — input combinado e mensagem de validação
   ============================================================ */
.handle-input {
  display: flex;
  align-items: stretch;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.handle-input:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.handle-prefix {
  display: flex;
  align-items: center;
  padding: 0 0.85rem;
  color: var(--text-dim);
  background: rgba(0, 0, 0, 0.18);
  border-right: 1px solid var(--border);
  font-weight: 600;
}

.handle-input input {
  flex: 1;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0.8rem 1rem;
}

.handle-input input:focus {
  box-shadow: none;
}

.handle-msg {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-top: 0.35rem;
  min-height: 1em;
}

.handle-msg-ok {
  color: var(--success);
}

.handle-msg-warn {
  color: var(--danger);
}

.profile-handle {
  color: var(--text-dim);
  font-size: 0.9rem;
  margin: 0.05rem 0 0.5rem;
}

/* ============================================================
   RANKING
   ============================================================ */
.rank-tabs {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 1rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}

.rank-tab {
  flex-shrink: 0;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-dim);
  font-size: 0.82rem;
  padding: 0.45rem 0.95rem;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.rank-tab.is-active {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent-hover);
  font-weight: 600;
}

.rank-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.rank-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0.6rem 0.85rem;
}

.rank-row.is-me {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.rank-link {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: inherit;
  width: 100%;
}

.rank-link:hover .rank-display {
  color: var(--accent-hover);
}

.rank-row {
  padding: 0;
}

.rank-row > .rank-link {
  padding: 0.6rem 0.85rem;
}

.rank-medal {
  font-size: 1.1rem;
  width: 24px;
  text-align: center;
  flex-shrink: 0;
}

.rank-num {
  font-size: 0.85rem;
  color: var(--text-dim);
  font-weight: 700;
}

.rank-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-elevated);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.rank-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rank-avatar-letter {
  font-weight: 700;
  color: var(--text);
}

.rank-name {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.rank-display {
  font-weight: 600;
  font-size: 0.92rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-handle {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.rank-value {
  font-weight: 700;
  font-size: 0.85rem;
  white-space: nowrap;
  flex-shrink: 0;
}

.my-rank {
  position: sticky;
  bottom: 5rem;
  margin-top: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 0.65rem 1rem;
  text-align: center;
  font-size: 0.9rem;
  box-shadow: var(--shadow);
}

/* ============================================================
   CHALLENGES HUB — página dedicada
   ============================================================ */
.challenges-hub {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.8rem;
}

.challenge-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 4px solid var(--challenge-color, var(--accent));
  border-radius: var(--radius);
  padding: 1rem 1.1rem 1.1rem;
  box-shadow: var(--shadow);
}

.challenge-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.6rem;
}

.challenge-card-emoji {
  font-size: 1.7rem;
}

.challenge-card-days {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--challenge-color, var(--accent));
  background: color-mix(in srgb, var(--challenge-color, var(--accent)) 18%, transparent);
  border: 1px solid color-mix(in srgb, var(--challenge-color, var(--accent)) 40%, transparent);
  border-radius: 999px;
  padding: 0.2rem 0.6rem;
}

.challenge-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.challenge-card-desc {
  font-size: 0.85rem;
  color: var(--text-dim);
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.challenge-card-habit {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-bottom: 0.85rem;
}

.challenge-card-habit strong {
  color: var(--text);
}

.challenge-card .btn-pill {
  width: 100%;
  background: var(--challenge-color, var(--accent));
}

.challenge-see-all {
  list-style: none;
  text-align: center;
  padding-top: 0.5rem;
}

.challenge-see-all a {
  color: var(--accent-hover);
  font-size: 0.85rem;
  text-decoration: none;
  font-weight: 600;
}

@media (min-width: 600px) {
  .challenges-hub {
    grid-template-columns: 1fr 1fr;
  }
}

/* ============================================================
   EXERCÍCIOS EXTRAS — hub e views
   ============================================================ */
.ex-hub {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.ex-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 4px solid var(--ex-color, var(--accent));
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  cursor: pointer;
  color: var(--text);
  text-align: left;
  font: inherit;
  transition: border-color 0.15s, transform 0.1s;
  box-shadow: var(--shadow);
}

.ex-card:hover {
  border-color: var(--accent);
}

.ex-card:active {
  transform: scale(0.99);
}

.ex-emoji {
  font-size: 1.7rem;
  flex-shrink: 0;
  width: 42px;
  text-align: center;
}

.ex-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.ex-name {
  font-weight: 600;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.ex-tag {
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
}

.ex-desc {
  font-size: 0.78rem;
  color: var(--text-dim);
}

.ex-arrow {
  color: var(--text-dim);
  font-size: 1.2rem;
  flex-shrink: 0;
}

.ex-back {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 0.88rem;
  padding: 0 0 0.5rem 0;
  cursor: pointer;
}

.ex-back:hover {
  color: var(--accent-hover);
}

.ex-view .card {
  text-align: center;
}

/* ---------- Grounding ---------- */
.grounding-step {
  padding: 1.5rem 0 1rem;
}

.grounding-emoji {
  font-size: 3rem;
  margin-bottom: 0.6rem;
}

.grounding-count {
  font-size: 4rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  background: linear-gradient(135deg, var(--accent-hover), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.grounding-prompt {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0.8rem 0 0.5rem;
}

.grounding-tip {
  color: var(--text-dim);
  font-size: 0.88rem;
  max-width: 280px;
  margin: 0 auto;
  line-height: 1.45;
}

.grounding-controls {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

.grounding-controls .btn {
  flex: 1;
}

/* ---------- Body scan ---------- */
.bodyscan-zone {
  background: var(--bg-elevated);
  border-radius: 14px;
  padding: 1.5rem 1rem;
  font-size: 1rem;
  line-height: 1.5;
  min-height: 100px;
  margin: 0.8rem 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bodyscan-remaining {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 0.8rem;
}

/* ---------- Reset 1min ---------- */
.reset-pulse {
  width: 100px;
  height: 100px;
  margin: 0.8rem auto 1rem;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-hover), var(--accent) 70%);
  box-shadow: 0 0 40px 4px var(--accent-soft);
}

.reset-pulse.active {
  animation: resetPulse 5s ease-in-out infinite;
}

@keyframes resetPulse {
  0%, 100% { transform: scale(1); opacity: 0.85; }
  50% { transform: scale(1.35); opacity: 1; }
}

.reset-instruction {
  text-align: center;
  color: var(--text-dim);
  font-size: 0.9rem;
  margin-bottom: 1rem;
  line-height: 1.5;
}

/* ============================================================
   MURAL DE CONQUISTAS
   ============================================================ */
.ach-summary {
  margin-bottom: 1rem;
}

.ach-summary-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1rem;
  text-align: center;
  box-shadow: var(--shadow);
}

.ach-summary-num {
  font-size: 2.4rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent-hover), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: block;
  line-height: 1;
}

.ach-summary-of {
  font-size: 1.1rem;
  color: var(--text-dim);
  -webkit-text-fill-color: var(--text-dim);
}

.ach-summary-label {
  display: block;
  color: var(--text-dim);
  font-size: 0.82rem;
  margin-top: 0.4rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.ach-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
}

.ach-tile {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.1rem 0.75rem 0.95rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  /* cor do tier (sobrescrita pelas classes tier-*) */
  --tier: #b08d57;
}
.ach-tile.tier-bronze { --tier: #b08157; }
.ach-tile.tier-prata { --tier: #aab4c0; }
.ach-tile.tier-ouro { --tier: #d6af4c; }
.ach-tile.tier-platina { --tier: #76d0e6; }

.ach-tile.locked {
  opacity: 0.55;
}
.ach-tile.locked .ach-medal {
  color: var(--text-dim);
  background: var(--bg-elevated);
  border-color: var(--border);
}
.ach-tile.locked .ach-tier-label { visibility: hidden; }

.ach-medal {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--tier);
  background: color-mix(in srgb, var(--tier) 14%, transparent);
  border: 1.5px solid color-mix(in srgb, var(--tier) 45%, transparent);
  margin-bottom: 0.15rem;
}
.ach-medal svg { width: 26px; height: 26px; }

.ach-name {
  font-weight: 700;
  font-size: 0.85rem;
}
.ach-tier-label {
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--tier);
}
.ach-desc {
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.35;
}

@media (min-width: 480px) {
  .ach-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================================
   COMPANHEIRO SEMANAL
   ============================================================ */
.buddy-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem 1.25rem;
  text-align: center;
  margin-bottom: 1rem;
  box-shadow: var(--shadow);
}

.buddy-avatar {
  width: 96px;
  height: 96px;
  margin: 0 auto 0.75rem;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent);
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
}

.buddy-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.buddy-name {
  font-size: 1.3rem;
  font-weight: 800;
  margin: 0;
}

.buddy-handle {
  color: var(--accent-hover);
  font-size: 0.95rem;
  margin: 0.1rem 0 0.3rem;
}

.buddy-meta {
  color: var(--text-dim);
  font-size: 0.85rem;
  margin-bottom: 0.9rem;
}

.buddy-pact {
  font-size: 0.9rem;
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: 12px;
  padding: 0.8rem 0.9rem;
  line-height: 1.45;
  margin-bottom: 1rem;
}

.buddy-tip {
  font-size: 0.9rem;
}

.buddy-tip .focus-label {
  margin-bottom: 0.4rem;
}

/* ============================================================
   TASKS — Lista do dia (premium)
   ============================================================ */
.tasks-card {
  padding: 1rem;
}

.task-add {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.task-add input {
  flex: 1;
}

.task-add button {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  font-size: 1.4rem;
  font-weight: 700;
  padding: 0;
}

.tasks-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.task-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  background: var(--bg-elevated);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
}

.task-row.done {
  opacity: 0.55;
}

.task-row.done .task-text {
  text-decoration: line-through;
}

.task-text {
  flex: 1;
  min-width: 0;
  font-size: 0.92rem;
  word-break: break-word;
}

.task-del {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 1.3rem;
  cursor: pointer;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  transition: background 0.15s, color 0.15s;
}

.task-del:hover {
  background: rgba(251, 113, 133, 0.15);
  color: var(--danger);
}

.tasks-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0.75rem 0 0.5rem;
  font-size: 0.82rem;
  color: var(--text-dim);
}

.btn-ghost-link {
  background: none;
  border: none;
  color: var(--accent-hover);
  font-size: 0.82rem;
  cursor: pointer;
  padding: 0;
  font-weight: 600;
}

.tasks-tip {
  font-size: 0.78rem;
  color: var(--text-dim);
  text-align: center;
  margin-top: 0.5rem;
}

/* ============================================================
   RECURSOS NOVOS (folga, opções de hábito, identidade, etc.)
   ============================================================ */

/* Estado vazio guiado */
.empty-onboard {
  text-align: center;
  padding: 1.6rem 1rem;
}
.empty-onboard-emoji { font-size: 2.6rem; }
.empty-onboard h3 { margin: 0.5rem 0 0.3rem; }
.empty-onboard p { color: var(--text-dim); font-size: 0.88rem; margin-bottom: 1rem; }

/* Botão de opções do hábito (⋯) */
.habit-opts {
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 0.4rem;
  margin-right: 0.2rem;
}
.habit-opts:hover { color: var(--text); }

.opts-sheet { display: flex; flex-direction: column; gap: 0.5rem; }
.opts-sheet h2 { margin-bottom: 0.4rem; }
.opts-danger { color: var(--danger, #ef4444); }

/* Barra de folga (proteção de sequência) */
.freeze-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  margin-top: 0.7rem;
  padding: 0.5rem 0.75rem;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 10px;
  font-size: 0.8rem;
}
.freeze-info { color: var(--text); }
.freeze-used { color: #38bdf8; font-size: 0.78rem; }
.btn-mini {
  background: #38bdf8;
  color: #04293a;
  border: none;
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
}

/* Onboarding por identidade */
.identity-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin: 0.3rem 0 0.4rem;
}
.identity-option {
  padding: 0.7rem 0.5rem;
  border: 1.5px solid var(--border, rgba(255,255,255,0.1));
  background: var(--bg-card-2, rgba(255,255,255,0.04));
  color: var(--text);
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  transition: border-color 0.1s, background 0.1s;
}
.identity-option:hover { border-color: var(--accent); }
.identity-option.selected {
  border-color: var(--accent);
  background: var(--accent-soft);
}

/* Lembretes */
.reminder-toggle { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; }

/* Pet do coach + balão de som */
.pet-reaction {
  position: fixed;
  right: 16px;
  bottom: 92px;
  z-index: 900;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  pointer-events: none;
  opacity: 0;
  transform: translateY(14px) scale(0.7);
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.pet-reaction.show {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.pet-bubble {
  background: #fff;
  color: #1f1b2e;
  font-weight: 700;
  font-size: 0.82rem;
  padding: 0.35rem 0.7rem;
  border-radius: 14px;
  position: relative;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
  white-space: nowrap;
  animation: petBubblePop 2.8s ease;
}
.pet-bubble::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 6px solid #fff;
}
.pet-art {
  width: 64px;
  height: 64px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.35));
  animation: petHop 0.6s ease;
}
.pet-art svg { width: 100%; height: 100%; display: block; }
@keyframes petHop {
  0%, 100% { transform: translateY(0); }
  30% { transform: translateY(-8px); }
  60% { transform: translateY(0); }
}
@keyframes petBubblePop {
  0% { transform: scale(0.6); opacity: 0; }
  12% { transform: scale(1.1); opacity: 1; }
  20% { transform: scale(1); }
  85% { opacity: 1; }
  100% { opacity: 0; }
}

/* Página de Configurações */
.settings-group { margin-bottom: 1.1rem; }
.settings-group > .focus-label { margin-bottom: 0.5rem; }
.set-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.2rem 0;
}
.set-row-label { font-size: 0.92rem; }
.set-row-hint { font-size: 0.76rem; color: var(--text-dim); margin-top: 0.15rem; }

.seg {
  display: flex;
  gap: 0.35rem;
  background: var(--bg-elevated);
  border-radius: 999px;
  padding: 0.3rem;
  margin-top: 0.3rem;
}
.seg button {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--text-dim);
  padding: 0.55rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.seg button.active { background: var(--accent); color: var(--on-accent); }

/* Seletor de estilo visual (com amostra de cor) */
.style-opts {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.5rem;
}
.style-opt {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--bg-elevated);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 0.7rem 0.8rem;
  color: var(--text-dim);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.style-opt.active {
  border-color: var(--accent);
  color: var(--text);
}
.style-swatch {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  flex-shrink: 0;
  border: 1px solid var(--border);
}

.set-select {
  background: var(--bg-elevated);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.5rem 0.7rem;
  font-size: 0.9rem;
}

.switch { position: relative; width: 46px; height: 26px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider {
  position: absolute; inset: 0; cursor: pointer;
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 999px; transition: background 0.18s;
}
.switch .slider::before {
  content: ''; position: absolute; width: 18px; height: 18px; left: 4px; top: 3px;
  background: #fff; border-radius: 50%; transition: transform 0.18s;
}
.switch input:checked + .slider { background: var(--accent); border-color: var(--accent); }
.switch input:checked + .slider::before { transform: translateX(20px); }

/* Página Extras */
.extras-section { margin-bottom: 1.5rem; }
.extras-title { font-size: 1.05rem; margin: 1.4rem 0 0.8rem; }
/* Selo Premium com cadeado — usado em tudo que é bloqueado no free */
.lock-badge {
  display: inline-flex; align-items: center; gap: 0.28rem;
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.02em;
  color: var(--accent); background: var(--accent-soft);
  padding: 0.16rem 0.52rem; border-radius: 999px; vertical-align: middle;
  white-space: nowrap;
}
.lock-badge svg { width: 11px; height: 11px; }
.extra-arrow-lock { display: inline-flex; color: var(--text-dim); }
.extra-arrow-lock svg { width: 17px; height: 17px; }
/* Selo Pro (dourado) — diferencia do Premium roxo */
.lock-badge--pro { color: #d97706; background: rgba(251, 191, 36, 0.16); }
.extras-pro-hint { font-size: 0.82rem; color: var(--text-dim); margin: -0.4rem 0 0.8rem; }

/* Ferramentas Nosu Pro */
.pro-tool { margin-bottom: 1rem; }
.pro-tool-head { display: flex; align-items: flex-start; gap: 0.8rem; margin-bottom: 0.9rem; }
.pro-tool-emoji { font-size: 1.7rem; line-height: 1; flex-shrink: 0; }
.pro-tool-title { font-size: 1.05rem; margin: 0; }
.pro-tool-desc { font-size: 0.84rem; color: var(--text-dim); margin: 0.15rem 0 0; }
.pro-tool .btn { width: 100%; }
.pro-tool-body:not(:empty) { margin-top: 0.9rem; }
.pro-quote { font-size: 0.92rem; color: var(--text); background: var(--bg-elevated); border-left: 3px solid var(--accent); border-radius: 0 10px 10px 0; padding: 0.7rem 0.9rem; }
.pro-phase { margin-bottom: 0.8rem; }
.pro-phase h3 { font-size: 0.92rem; color: var(--accent); margin-bottom: 0.3rem; }
.pro-phase ul, .pro-corr-list { margin: 0; padding-left: 1.1rem; font-size: 0.88rem; color: var(--text-dim); display: grid; gap: 0.25rem; }
.pro-phase li b, .pro-corr-list b { color: var(--text); }
.pro-alert { font-size: 0.9rem; background: var(--bg-elevated); border-radius: 12px; padding: 0.9rem; line-height: 1.5; }
.pro-alert.risk { background: rgba(251, 113, 133, 0.12); border: 1px solid rgba(251, 113, 133, 0.4); }
.pro-two-bubble { background: var(--bg-elevated); border-radius: 12px; padding: 0.8rem 0.9rem; margin-bottom: 0.6rem; }
.pro-two-bubble strong { color: var(--accent); font-size: 0.85rem; }
.pro-two-bubble p { margin: 0.2rem 0 0; font-size: 0.92rem; }
.pro-fam-list { list-style: none; margin: 0 0 0.7rem; padding: 0; display: grid; gap: 0.4rem; }
.pro-fam-list li { display: flex; align-items: center; justify-content: space-between; background: var(--bg-elevated); border-radius: 10px; padding: 0.5rem 0.8rem; font-size: 0.92rem; }
.pro-fam-del { background: none; border: none; color: var(--text-dim); cursor: pointer; font-size: 0.85rem; }
.pro-fam-add { display: flex; gap: 0.5rem; }
.pro-fam-add input { flex: 1; background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 10px; color: var(--text); padding: 0.5rem 0.7rem; }
.extras-list { display: grid; gap: 0.6rem; }

.extra-card {
  display: flex; align-items: center; gap: 0.9rem; width: 100%;
  padding: 0.85rem 1rem; border: 1px solid var(--border); border-radius: 14px;
  background: var(--bg-card); color: var(--text); cursor: pointer; text-align: left;
  transition: background 0.18s, border-color 0.18s, transform 0.1s;
}
.extra-card:hover { background: var(--bg-elevated); border-color: var(--accent); }
.extra-card:active { transform: scale(0.99); }
.extra-emoji { font-size: 1.8rem; flex-shrink: 0; }
.extra-info { display: flex; flex-direction: column; gap: 0.15rem; flex: 1; min-width: 0; }
.extra-name { font-weight: 600; font-size: 0.95rem; }
.extra-desc { font-size: 0.8rem; color: var(--text-dim); }
.extra-arrow { color: var(--text-dim); font-size: 1.1rem; flex-shrink: 0; }

/* Bloqueado (cinza, igual conteúdo trancado) */
.extra-card.extra-locked {
  opacity: 0.55;
  filter: grayscale(0.7);
  cursor: not-allowed;
}
.extra-card.extra-locked:hover { background: var(--bg-card); border-color: var(--border); }
.extra-lock-tag {
  font-size: 0.66rem; font-weight: 700; color: var(--accent);
  background: var(--accent-soft); padding: 0.1rem 0.4rem; border-radius: 999px; margin-left: 0.35rem;
}

/* Modal de sessão (respiração / meditação / treino) */
.session-box { position: relative; text-align: center; max-width: 360px; }
.session-close {
  position: absolute; top: 0.6rem; right: 0.8rem; background: none; border: none;
  color: var(--text-dim); font-size: 1.2rem; cursor: pointer; line-height: 1;
}
.session-title { font-size: 1.2rem; margin-bottom: 0.4rem; }
.session-sub { font-size: 0.85rem; color: var(--text-dim); margin-top: 0.5rem; }
.session-finish { padding: 1rem 0; }
.session-check {
  width: 64px; height: 64px; margin: 0 auto 0.8rem; border-radius: 50%;
  background: var(--accent); color: #fff; font-size: 2rem; display: flex; align-items: center; justify-content: center;
}
.session-finish .btn { margin-top: 1rem; }

/* Respiração: círculo que pulsa */
.breath-stage { height: 220px; display: flex; align-items: center; justify-content: center; margin: 1rem 0; }
.breath-circle {
  width: 110px; height: 110px; border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, var(--accent-2), var(--accent));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 600; font-size: 0.95rem;
  box-shadow: 0 0 40px var(--accent-soft);
}

/* Meditação: orbe calma */
.calm-orb {
  width: 90px; height: 90px; margin: 1.2rem auto; border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, var(--accent-2), var(--accent));
  animation: calmPulse 5s ease-in-out infinite; box-shadow: 0 0 40px var(--accent-soft);
}
@keyframes calmPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.18); } }
.calm-text { font-size: 1.05rem; min-height: 3em; display: flex; align-items: center; justify-content: center; }

/* Treino dentro do modal */
.workout-demo-box { height: 150px; display: flex; align-items: center; justify-content: center; margin: 0.5rem 0; }
.workout-demo-box .exdemo-fig { width: 120px; height: 120px; }
.session-ex-name { font-weight: 600; font-size: 1.1rem; margin-top: 0.3rem; }
.session-ex-target { color: var(--accent); font-weight: 600; margin-top: 0.2rem; }
.session-box .btn { margin-top: 1rem; width: 100%; }

/* Página de análise crítica (estilo Critique AI) */
.critique-hero { display: flex; align-items: center; gap: 1rem; }
.critique-grade {
  width: 76px;
  height: 76px;
  flex-shrink: 0;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
}
.critique-grade[data-grade="A"] { background: #22c55e; }
.critique-grade[data-grade="B"] { background: #84cc16; }
.critique-grade[data-grade="C"] { background: #f59e0b; }
.critique-grade[data-grade="D"] { background: #f97316; }
.critique-grade[data-grade="E"] { background: #ef4444; }
.critique-letter { font-size: 2.4rem; font-weight: 800; color: #fff; }
.critique-hero-info { flex: 1; }
.critique-score { font-size: 2rem; font-weight: 800; display: block; }
.critique-score span { font-size: 1rem; font-weight: 600; color: var(--text-dim); }
.critique-grade-label { font-size: 0.82rem; color: var(--text-dim); }
.critique-verdict { font-size: 0.9rem; margin-top: 0.4rem; line-height: 1.5; }

.critique-bars { display: flex; flex-direction: column; gap: 0.9rem; margin-top: 0.3rem; }
.critique-bar-head { display: flex; justify-content: space-between; font-size: 0.86rem; margin-bottom: 0.3rem; }
.critique-bar-track { height: 8px; border-radius: 999px; background: rgba(255,255,255,0.1); overflow: hidden; }
.critique-bar-fill { height: 100%; border-radius: 999px; transition: width 0.4s ease; }
.critique-bar-hint { display: block; font-size: 0.72rem; color: var(--text-dim); margin-top: 0.25rem; }

.critique-section .focus-label.good { color: #22c55e; }
.critique-section .focus-label.bad { color: #ef4444; }
.critique-list { list-style: none; padding: 0; margin: 0.3rem 0 0; display: flex; flex-direction: column; gap: 0.55rem; }
.critique-list li { font-size: 0.86rem; line-height: 1.45; }
.critique-fix-text { font-size: 0.9rem; line-height: 1.5; margin: 0.3rem 0 0.9rem; }
.critique-fix .btn { width: 100%; }

/* Pet na home: humor + carinho + ideia */
/* Card "Ideia do coach" na home (substituiu o pet) */
.coach-idea { padding: 1rem 1.1rem; }
.coach-idea-text { font-size: 0.9rem; color: var(--text-dim); line-height: 1.5; margin-bottom: 0.6rem; }
.coach-idea-label { color: var(--text); font-weight: 700; }

.pet-home {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.9rem 1rem;
}
.pet-home-art {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: transform 0.15s;
}
.pet-home-art svg { width: 100%; height: 100%; display: block; }
.pet-home-art:hover { transform: scale(1.06); }
.pet-home-art.petted { animation: petHop 0.6s ease; }
.pet-home-art.mood-triste { filter: grayscale(0.55) opacity(0.8); }
.pet-home-art.mood-feliz { animation: petWiggle 1.2s ease infinite; }
@keyframes petWiggle {
  0%, 100% { transform: rotate(0); }
  25% { transform: rotate(-4deg); }
  75% { transform: rotate(4deg); }
}
.pet-home-info { flex: 1; min-width: 0; }
.pet-home-mood { font-weight: 600; font-size: 0.92rem; display: block; margin-bottom: 0.3rem; }
.pet-home-idea { font-size: 0.84rem; color: var(--text-dim); line-height: 1.45; margin-bottom: 0.5rem; }
.pet-idea-label { color: var(--text); font-weight: 600; }
.pet-home-actions { display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap; }
.pet-home-hint { font-size: 0.72rem; color: var(--text-dim); }
.pet-heart {
  position: fixed;
  z-index: 950;
  font-size: 1.1rem;
  pointer-events: none;
  animation: heartFloat 1.2s ease forwards;
}
@keyframes heartFloat {
  0% { transform: translateY(0) scale(0.6); opacity: 0; }
  20% { opacity: 1; transform: translateY(-10px) scale(1.1); }
  100% { transform: translateY(-70px) scale(0.9); opacity: 0; }
}

/* Treinos rápidos */
.workout-list { display: flex; flex-direction: column; gap: 0.6rem; }
.workout-pick {
  text-align: left;
  background: var(--bg-card-2, rgba(255,255,255,0.04));
  border: 1px solid var(--border, rgba(255,255,255,0.1));
  border-left: 3px solid #ef4444;
  border-radius: 10px;
  padding: 0.8rem 0.9rem;
  cursor: pointer;
  color: var(--text);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  transition: border-color 0.1s, transform 0.1s;
}
.workout-pick:hover { transform: translateX(2px); }
.workout-pick strong { font-size: 0.95rem; }
.workout-pick small { color: var(--text-dim); font-size: 0.78rem; }

#workout-run { text-align: center; }
.workout-phase {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
}
.workout-phase.work { color: #ef4444; }
.workout-phase.rest { color: #38bdf8; }
.workout-phase.prep { color: var(--text-dim); }
.workout-phase.done { color: var(--success, #22c55e); }
.workout-exercise { font-size: 1.5rem; margin-bottom: 0.3rem; }
.workout-target {
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1;
  margin: 0.2rem 0 0.4rem;
}
.workout-tip { color: var(--text-dim); font-size: 0.82rem; margin: 0.3rem 0 0.6rem; }
.workout-progress { color: var(--text-dim); font-size: 0.75rem; margin-bottom: 0.8rem; }
#workout-done { width: 100%; }
.workout-done-emoji { font-size: 3.4rem; }

/* Demonstração animada do exercício (flipbook de 2 poses) */
.exdemo-wrap {
  width: 140px;
  height: 140px;
  margin: 0 auto 0.6rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.exdemo-wrap svg { width: 100%; height: 100%; }
.exdemo-fig {
  stroke: #a78bfa;
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}
.exdemo-fig .head { fill: #a78bfa; stroke: none; }
.exdemo-fig .pose-a { animation: exPose 1.1s steps(1, end) infinite; }
.exdemo-fig .pose-b { animation: exPose 1.1s steps(1, end) infinite; animation-delay: -0.55s; }
@keyframes exPose {
  0%, 49.99% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

/* Folga no detalhe do dia */
.day-freeze {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  margin: 0.6rem 0;
  min-height: 1px;
}
.day-freeze:empty { margin: 0; }

/* Estatísticas ricas no dashboard */
.stat-row-rich { flex-direction: column; align-items: stretch; gap: 0.3rem; }
.stat-row-main { display: flex; justify-content: space-between; align-items: center; }
.stat-row-name { display: flex; align-items: center; gap: 0.5rem; }
.stat-glyph {
  display: inline-flex;
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--accent);
  background: var(--accent-soft);
}
.stat-glyph svg { width: 17px; height: 17px; }
.stat-row-sub {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* Companheiro: ações e cutucar */
.buddy-actions { display: flex; gap: 0.5rem; justify-content: center; flex-wrap: wrap; }

/* Botão de compartilhar */
.share-btn { width: 100%; margin-top: 0.6rem; }

/* ============================================================
   PLANOS: toggle de cobrança + botão brilhante + boas-vindas
   ============================================================ */

/* Toggle anual/mensal */
.billing-toggle {
  display: flex;
  gap: 0.4rem;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border, rgba(255,255,255,0.08));
  border-radius: 999px;
  padding: 0.3rem;
  margin: 0 auto 1.2rem;
  width: fit-content;
}
.billing-toggle-page { margin-top: 0.5rem; }
.billing-opt {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: none;
  background: transparent;
  color: var(--text-dim);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.billing-opt.active {
  background: var(--accent);
  color: #fff;
}
.billing-badge {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  background: #facc15;
  color: #422006;
  padding: 0.12rem 0.4rem;
  border-radius: 999px;
}

.plan-price-note {
  font-size: 0.76rem;
  color: #c4b5fd;
  margin-top: 0.2rem;
}

/* Botão brilhante — base escura com brilho que varre */
.btn--shine {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #4f46e5, #4c1d95);
  box-shadow: 0 0 18px rgba(124, 58, 237, 0.55);
  isolation: isolate;
}
.btn--shine::after {
  content: '';
  position: absolute;
  top: 0;
  left: -150%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    100deg,
    transparent,
    rgba(255, 255, 255, 0.55),
    transparent
  );
  transform: skewX(-20deg);
  animation: shineSweep 2.6s infinite;
  z-index: 1;
}
@keyframes shineSweep {
  0% { left: -150%; }
  60%, 100% { left: 150%; }
}

/* Fluxo de boas-vindas (tutorial + oferta) */
.welcome-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(10, 8, 20, 0.92);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
}
.welcome-card {
  background: var(--bg-card, #1f1b30);
  border: 1px solid var(--border, rgba(255,255,255,0.1));
  border-radius: 20px;
  padding: 1.8rem 1.4rem;
  max-width: 380px;
  width: 100%;
  text-align: center;
  animation: welcomeIn 0.25s ease;
}
@keyframes welcomeIn {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.welcome-emoji { font-size: 3rem; }
.welcome-title { margin: 0.6rem 0 0.4rem; font-size: 1.3rem; }
.welcome-text { color: var(--text-dim); font-size: 0.92rem; line-height: 1.5; margin-bottom: 1.1rem; }
.welcome-dots { display: flex; gap: 0.35rem; justify-content: center; margin-bottom: 1.1rem; }
.welcome-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: rgba(255,255,255,0.2);
  transition: background 0.15s, width 0.15s;
}
.welcome-dot.active { background: var(--accent); width: 18px; border-radius: 4px; }
.welcome-card .btn { width: 100%; }
.welcome-skip {
  display: block;
  width: 100%;
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 0.82rem;
  cursor: pointer;
  margin-top: 0.7rem;
}

/* Card de oferta dentro do fluxo */
.offer-eyebrow {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #facc15;
  margin-bottom: 0.3rem;
}
.offer-price { margin: 0.4rem 0 1rem; }
.offer-amount { font-size: 2.4rem; font-weight: 800; display: block; }
.offer-amount span { font-size: 1rem; font-weight: 600; color: var(--text-dim); }
.offer-sub { display: block; font-size: 0.8rem; color: #c4b5fd; margin-top: 0.2rem; }

/* ============================================================
   NOSU PRO — visual premium (acento dourado)
   ============================================================ */
.pro-paywall { padding-top: 1.4rem; }

.pro-hero {
  position: relative;
  text-align: center;
  padding: 2.4rem 1.3rem 2.1rem;
  border-radius: 22px;
  margin-bottom: 1.4rem;
  overflow: hidden;
  background:
    radial-gradient(130% 110% at 50% -10%, rgba(251, 191, 36, 0.22), transparent 55%),
    linear-gradient(165deg, #2d2347 0%, #1b1830 100%);
  border: 1px solid rgba(251, 191, 36, 0.28);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.4);
}
.pro-crown { font-size: 2.6rem; display: block; filter: drop-shadow(0 4px 12px rgba(251, 191, 36, 0.45)); }
.pro-kicker {
  display: inline-block; font-size: 0.7rem; font-weight: 800; letter-spacing: 0.2em;
  color: #fbbf24; background: rgba(251, 191, 36, 0.14);
  padding: 0.28rem 0.85rem; border-radius: 999px; margin: 0.6rem 0 0.5rem;
}
.pro-hero h1 { font-size: 1.6rem; line-height: 1.18; margin: 0.3rem 0 0.55rem; }
.pro-hero p { color: var(--text-dim); font-size: 0.95rem; max-width: 32ch; margin: 0 auto; line-height: 1.5; }

.pro-feature-grid { display: grid; gap: 0.6rem; margin-bottom: 1.4rem; }
.pro-feature {
  display: flex; align-items: center; gap: 0.85rem;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 16px; padding: 0.85rem 0.95rem;
  transition: border-color 0.15s, transform 0.15s;
}
.pro-feature:hover { border-color: rgba(251, 191, 36, 0.4); transform: translateX(3px); }
.pro-feature .pf-ico {
  width: 44px; height: 44px; border-radius: 13px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 1.35rem;
  background: rgba(251, 191, 36, 0.12); border: 1px solid rgba(251, 191, 36, 0.18);
}
.pro-feature b { display: block; font-size: 0.96rem; }
.pro-feature span { font-size: 0.8rem; color: var(--text-dim); }

.pro-cta-card {
  text-align: center; border-radius: 22px; padding: 1.8rem 1.4rem;
  background: linear-gradient(165deg, #2d2347, #1b1830);
  border: 1px solid rgba(251, 191, 36, 0.32);
}
.pro-price { display: flex; align-items: baseline; justify-content: center; gap: 0.25rem; }
.pro-price-amount { font-size: 2.5rem; font-weight: 800; }
.pro-price-per { color: var(--text-dim); font-weight: 600; }
.pro-price-note { font-size: 0.8rem; color: var(--text-dim); margin: 0.35rem 0 1.1rem; }
.pro-cta-btn {
  background: linear-gradient(135deg, #fbbf24, #f59e0b) !important;
  color: #3a2606 !important; font-weight: 800;
  border: none !important; box-shadow: 0 10px 28px rgba(251, 191, 36, 0.32);
}
.pro-cta-btn:hover { filter: brightness(1.06); }

/* Banner premium no topo das ferramentas (usuário Pro) */
.pro-tools-hero {
  display: flex; align-items: center; gap: 0.9rem;
  padding: 1.1rem 1.2rem; margin-bottom: 1.2rem; border-radius: 18px;
  background:
    radial-gradient(120% 140% at 0% 0%, rgba(251, 191, 36, 0.16), transparent 60%),
    linear-gradient(165deg, #2d2347, #1b1830);
  border: 1px solid rgba(251, 191, 36, 0.28);
}
.pro-tools-hero .pth-crown { font-size: 1.9rem; }
.pro-tools-hero h2 { font-size: 1.1rem; margin: 0; }
.pro-tools-hero p { font-size: 0.82rem; color: var(--text-dim); margin: 0.1rem 0 0; }

/* Cards de ferramenta — versão premium (ícone em chip dourado) */
.pro-tool {
  margin-bottom: 0.9rem; border-radius: 18px;
  border: 1px solid var(--border); background: var(--bg-card);
  transition: border-color 0.15s;
}
.pro-tool:hover { border-color: rgba(251, 191, 36, 0.35); }
.pro-tool-emoji {
  width: 46px; height: 46px; border-radius: 13px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 1.45rem;
  background: rgba(251, 191, 36, 0.12); border: 1px solid rgba(251, 191, 36, 0.18);
  line-height: 1;
}
.pro-tool .btn {
  background: rgba(251, 191, 36, 0.14); color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.3);
}
.pro-tool .btn:hover { background: rgba(251, 191, 36, 0.22); }
.pro-hint-sm { font-size: 0.78rem; color: var(--text-dim); margin: 0.5rem 0 0; }

/* Check-in de energia (Correlações) */
.mood-checkin { margin-bottom: 0.9rem; }
.mood-q { font-size: 0.85rem; color: var(--text-dim); display: block; margin-bottom: 0.5rem; }
.mood-row { display: flex; gap: 0.4rem; }
.mood-btn {
  flex: 1; font-size: 1.4rem; line-height: 1;
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 12px; padding: 0.45rem 0; cursor: pointer; transition: all 0.15s;
}
.mood-btn:hover { border-color: var(--accent); transform: translateY(-2px); }
.mood-btn.on { background: rgba(251, 191, 36, 0.16); border-color: #fbbf24; transform: scale(1.08); }

/* Metas & marcos */
.pro-goal-input { width: 100%; background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 10px; color: var(--text); padding: 0.6rem 0.8rem; margin-bottom: 0.6rem; }
.pro-goal-title { font-size: 1rem; font-weight: 600; margin: 0 0 0.5rem; }
.goal-progress { height: 8px; background: var(--bg-elevated); border-radius: 999px; overflow: hidden; }
.goal-bar { height: 100%; background: linear-gradient(90deg, #fbbf24, #f59e0b); border-radius: 999px; transition: width 0.3s; }
.goal-list { list-style: none; margin: 0.7rem 0; padding: 0; display: grid; gap: 0.45rem; }
.goal-list li { display: flex; align-items: center; gap: 0.6rem; font-size: 0.92rem; }
.goal-list li.on { color: var(--text-dim); text-decoration: line-through; }
.goal-check { background: none; border: none; color: #fbbf24; font-size: 1.1rem; cursor: pointer; padding: 0; line-height: 1; }

/* Estatísticas avançadas */
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.stat-tile { background: var(--bg-elevated); border-radius: 12px; padding: 0.8rem; text-align: center; }
.stat-num { display: block; font-size: 1.6rem; font-weight: 800; color: #fbbf24; }
.stat-lbl { font-size: 0.74rem; color: var(--text-dim); }

/* Em breve (família) */
.pro-soon { font-size: 0.9rem; line-height: 1.5; background: var(--bg-elevated); border: 1px dashed var(--border); border-radius: 12px; padding: 0.9rem; color: var(--text-dim); }
.pro-soon b { color: var(--text); }

/* Links "Tudo do Premium" */
.pro-prem-links li { padding: 0.2rem 0; }
.pro-prem-links a { color: #c4b5fd; text-decoration: none; }
.pro-prem-links a:hover { text-decoration: underline; }

/* Lembretes */
.lemb-card { padding: 1.2rem; }
.lemb-row { display: flex; align-items: center; gap: 0.8rem; }
.lemb-bell { font-size: 1.6rem; }
.lemb-row-txt { flex: 1; }
.lemb-title { font-size: 1.05rem; font-weight: 600; }
.lemb-sub { font-size: 0.82rem; color: var(--text-dim); }
.lemb-field { margin-top: 1rem; }
.lemb-field label { display: block; font-size: 0.8rem; color: var(--text-dim); margin-bottom: 0.3rem; }
.lemb-field input[type="time"] { width: 100%; background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 10px; color: var(--text); padding: 0.6rem 0.8rem; font: inherit; }
.lemb-actions { display: flex; gap: 0.6rem; margin-top: 1rem; }
.lemb-actions .btn { flex: 1; }
.lemb-statusrow { margin-top: 0.9rem; font-size: 0.85rem; color: var(--text-dim); }
.lemb-status { font-weight: 700; padding: 0.15rem 0.6rem; border-radius: 999px; font-size: 0.78rem; }
.lemb-status.on { color: #34d399; background: rgba(52,211,153,0.14); }
.lemb-status.off { color: var(--text-dim); background: rgba(255,255,255,0.06); }
.lemb-h2 { font-size: 1.05rem; margin-bottom: 0.9rem; }
.lemb-plat { display: flex; gap: 0.8rem; align-items: flex-start; margin-bottom: 0.9rem; }
.lemb-plat:last-child { margin-bottom: 0; }
.lemb-plat-ico { font-size: 1.4rem; }
.lemb-plat b { font-size: 0.92rem; }
.lemb-plat p { font-size: 0.84rem; color: var(--text-dim); margin-top: 0.15rem; }

/* iOS switch */
.switch { position: relative; display: inline-block; width: 50px; height: 30px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; inset: 0; background: #3a3450; border-radius: 999px; transition: 0.2s; }
.slider::before { content: ''; position: absolute; height: 24px; width: 24px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: 0.2s; }
.switch input:checked + .slider { background: #34d399; }
.switch input:checked + .slider::before { transform: translateX(20px); }

/* Tutorial steps */
.lemb-step { display: flex; align-items: center; gap: 0.9rem; padding: 0.9rem 0; border-top: 1px solid var(--border); }
.lemb-step:first-of-type { border-top: none; }
.lemb-num { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 0.85rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.lemb-step-done .lemb-num { background: #34d399; }
.lemb-step-img { flex-shrink: 0; width: 96px; }
.lemb-step-img svg { width: 100%; height: auto; border-radius: 8px; }
.lemb-step-txt { font-size: 0.88rem; line-height: 1.45; color: var(--text); }

/* Diário */
.diario-today { font-size: 1.05rem; margin-bottom: 0.7rem; }
.diario-textarea { width: 100%; min-height: 130px; resize: vertical; background: var(--bg-elevated); border: 1px solid var(--border); border-radius: 12px; color: var(--text); padding: 0.8rem; font: inherit; line-height: 1.5; }
.diario-actions { display: flex; align-items: center; gap: 0.8rem; margin-top: 0.7rem; }
.diario-saved { font-size: 0.85rem; color: #34d399; }
.diario-entry-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.4rem; }
.diario-date { font-size: 0.82rem; font-weight: 600; color: var(--accent); }
.diario-del { background: none; border: none; cursor: pointer; opacity: 0.6; font-size: 0.9rem; }
.diario-del:hover { opacity: 1; }
.diario-entry-text { font-size: 0.94rem; line-height: 1.5; color: var(--text); }

/* Desafios no Extras (clicável) */
.challenge-extra { width: 100%; text-align: left; cursor: pointer; }
.challenge-extra.is-active { opacity: 0.7; }
.challenge-state { font-size: 0.8rem; font-weight: 600; color: var(--accent); white-space: nowrap; }
.challenge-extra.is-active .challenge-state { color: #34d399; }

/* ============================================================
   RESPONSIVO POR DISPOSITIVO
   ============================================================ */

/* Celulares pequenos (≤ 360px): aperta espaçamentos e fontes */
@media (max-width: 360px) {
  body { font-size: 15px; }
  .container { padding: 1rem 0.8rem 6rem; }
  .focus-card, .card { padding: 1rem; }
  .extra-card { padding: 0.7rem 0.8rem; gap: 0.7rem; }
  .extra-emoji { font-size: 1.5rem; }
  .breath-stage { height: 180px; }
  .breath-circle { width: 92px; height: 92px; }
}

/* Tablet / desktop (≥ 768px): coluna mais larga e grades */
@media (min-width: 768px) {
  .container,
  .chat-container {
    max-width: 640px;
  }
  .plan-cards {
    flex-direction: row;
    align-items: stretch;
    flex-wrap: wrap;
  }
  .plan-card { flex: 1 1 30%; min-width: 220px; }
  .extras-list { grid-template-columns: 1fr 1fr; }
  .ach-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Telas largas (≥ 1024px): aproveita mais o espaço */
@media (min-width: 1024px) {
  .container { max-width: 760px; }
  .ach-grid { grid-template-columns: repeat(4, 1fr); }
}

/* Paisagem em telas baixas: garante que modais caibam */
@media (max-height: 520px) {
  .modal { max-height: 92vh; }
  .breath-stage { height: 130px; }
  .breath-circle { width: 80px; height: 80px; }
}
