/* ============================================================
   Radar Roo — Estilos
   Paleta: #FF6B35 | #1A1A2E | #F7F7F8 | #2EC4B6
   ============================================================ */

:root {
  --primary: #FF6B35;
  --primary-dark: #E55A25;
  --secondary: #1A1A2E;
  --secondary-light: #262640;
  --neutral: #F7F7F8;
  --accent: #2EC4B6;
  --accent-dark: #24A79B;
  --gray-100: #F2F2F5;
  --gray-200: #E6E6EC;
  --gray-400: #9A9AAB;
  --gray-600: #55556B;
  --shadow-sm: 0 2px 8px rgba(26, 26, 46, .06);
  --shadow-md: 0 8px 24px rgba(26, 26, 46, .12);
  --shadow-lg: 0 16px 40px rgba(26, 26, 46, .18);
}

* { -webkit-tap-highlight-color: transparent; box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
  overscroll-behavior: none;
}

body {
  background: var(--secondary);
  display: flex;
  justify-content: center;
  font-family: 'Inter', system-ui, sans-serif;
  color: var(--secondary);
}

button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, textarea { font-family: inherit; }

.hidden { display: none !important; }

/* ---------- Container do app ---------- */
.app-shell {
  position: relative;
  width: 100%;
  max-width: 480px;
  height: 100dvh;
  background: var(--neutral);
  overflow: hidden;
  margin: 0 auto;
}

@media (min-width: 520px) {
  .app-shell {
    box-shadow: 0 0 80px rgba(0, 0, 0, .55);
    border-left: 1px solid rgba(255,255,255,.05);
    border-right: 1px solid rgba(255,255,255,.05);
  }
}

/* ---------- Telas ---------- */
.scr {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  background: var(--neutral);
  overflow: hidden;
  animation: screenIn .3s ease-out;
}
.scr.active { display: flex; }
.scr.overlay { z-index: 40; background: var(--neutral); }

@keyframes screenIn {
  from { opacity: 0; transform: translateX(18px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* ---------- Botões ---------- */
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--primary); color: #fff;
  font-weight: 700; font-size: 16px;
  border-radius: 999px; padding: 14px 22px;
  min-height: 48px;
  box-shadow: 0 6px 18px rgba(255, 107, 53, .35);
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn-primary:active { transform: scale(.97); background: var(--primary-dark); }
.btn-big { width: 100%; }

.btn-outline {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: transparent; color: var(--secondary);
  border: 1.5px solid var(--gray-200);
  font-weight: 600; font-size: 15px;
  border-radius: 999px; padding: 13px 20px; min-height: 48px;
  transition: background .2s ease, border-color .2s ease, transform .15s ease;
}
.btn-outline:active { transform: scale(.97); background: var(--gray-100); }

.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 13px 20px; min-height: 48px;
  color: var(--primary); background: #FFF1E8;
  border-radius: 999px; font-weight: 600; font-size: 15px;
  transition: transform .15s ease, background .2s ease;
}
.btn-ghost:active { transform: scale(.97); }

.btn-danger {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 14px 22px; min-height: 48px;
  color: #E03131; background: #FDECEC;
  border-radius: 999px; font-weight: 600; font-size: 15px;
  transition: transform .15s ease, background .2s ease;
}
.btn-danger:active { transform: scale(.97); }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%;
  color: var(--gray-600); background: var(--gray-100);
  transition: background .2s ease, transform .15s ease;
}
.icon-btn:active { transform: scale(.94); }

.link-btn {
  display: inline-flex; align-items: center; gap: 4px;
  color: var(--primary); font-weight: 600; font-size: 13px;
  padding: 6px 10px; border-radius: 8px;
}

/* ---------- Inputs ---------- */
.input {
  width: 100%; padding: 15px 18px; min-height: 52px;
  border: 1.5px solid var(--gray-200); border-radius: 16px;
  background: #fff; font-size: 16px; color: var(--secondary);
  outline: none; transition: border-color .2s ease, box-shadow .2s ease;
}
.input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(255,107,53,.12); }
.textarea { resize: none; min-height: 110px; }

/* ---------- Chips ---------- */
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-row.scroll-x { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chip-row.scroll-x::-webkit-scrollbar { display: none; }

.chip {
  padding: 10px 16px; min-height: 44px;
  border-radius: 999px; font-size: 14px; font-weight: 600;
  background: #fff; border: 1.5px solid var(--gray-200); color: var(--gray-600);
  transition: all .2s ease; white-space: nowrap;
}
.chip:active { transform: scale(.96); }
.chip.active {
  background: var(--secondary); color: #fff; border-color: var(--secondary);
  box-shadow: var(--shadow-sm);
}
.chip-sm { padding: 8px 14px; min-height: 40px; font-size: 13px; }

/* ---------- Ripple ---------- */
.ripple { position: relative; overflow: hidden; }
.ripple-ink {
  position: absolute; border-radius: 9999px;
  background: rgba(255,255,255,.5);
  transform: scale(0); animation: rippleAnim .55s ease-out forwards;
  pointer-events: none;
}
.btn-outline .ripple-ink, .btn-ghost .ripple-ink, .chip .ripple-ink, .icon-btn .ripple-ink, .nav-item .ripple-ink, .back-btn .ripple-ink, .sort-btn .ripple-ink {
  background: rgba(26,26,46,.15);
}
@keyframes rippleAnim { to { transform: scale(3); opacity: 0; } }

/* ============================================================
   SPLASH
   ============================================================ */
#scr-splash { background: var(--secondary); align-items: center; justify-content: center; }
.splash-bg {
  background:
    radial-gradient(circle at 20% 15%, rgba(255,107,53,.35), transparent 45%),
    radial-gradient(circle at 85% 80%, rgba(46,196,182,.25), transparent 45%),
    linear-gradient(160deg, #1A1A2E 0%, #232344 55%, #1A1A2E 100%);
}
.splash-content {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center;
  padding: 32px; text-align: center; gap: 14px;
  animation: splashIn .8s ease-out;
}
@keyframes splashIn { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

.radar-logo { position: relative; width: 120px; height: 120px; display: grid; place-items: center; margin-bottom: 10px; }
.radar-core {
  width: 92px; height: 92px; border-radius: 50%;
  background: linear-gradient(145deg, var(--primary), var(--primary-dark));
  display: grid; place-items: center;
  box-shadow: 0 12px 32px rgba(255,107,53,.45);
}
.radar-ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid rgba(255,107,53,.55);
  animation: radarPulse 2.4s ease-out infinite;
}
.radar-ring.ring-2 { animation-delay: .8s; }
.radar-ring.ring-3 { animation-delay: 1.6s; }
@keyframes radarPulse {
  0%   { transform: scale(.6); opacity: .9; }
  100% { transform: scale(1.5); opacity: 0; }
}
.splash-title { color: #fff; font-size: 38px; font-weight: 800; letter-spacing: -.5px; margin: 0; }
.splash-tagline { color: rgba(255,255,255,.72); font-size: 16px; margin: 0 0 18px; max-width: 300px; }
.splash-footer { color: rgba(255,255,255,.45); font-size: 12px; margin-top: 22px; letter-spacing: .3px; }
#btn-start { max-width: 300px; }

/* ============================================================
   ONBOARDING
   ============================================================ */
#scr-onboarding { padding: 24px; overflow-y: auto; }
.ob-progress { display: flex; gap: 8px; justify-content: center; margin: 14px 0 34px; }
.ob-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--gray-200); transition: all .3s ease; }
.ob-dot.active { width: 26px; background: var(--primary); }

.ob-step { display: none; flex-direction: column; align-items: center; text-align: center; gap: 12px; animation: screenIn .3s ease-out; }
.ob-step.active { display: flex; }
.ob-icon {
  width: 76px; height: 76px; border-radius: 24px;
  background: linear-gradient(145deg, #FFF1E8, #FFE2D2);
  color: var(--primary); display: grid; place-items: center; margin-bottom: 6px;
}
.ob-step h2 { font-size: 25px; font-weight: 800; margin: 0; }
.ob-sub { color: var(--gray-600); font-size: 15px; margin: 0 0 10px; }
.ob-step .input { text-align: center; }
.ob-group { width: 100%; margin-top: 14px; text-align: left; }
.ob-group label { display: block; font-size: 13px; font-weight: 700; color: var(--gray-600); margin-bottom: 8px; text-transform: uppercase; letter-spacing: .4px; }
.ob-step .btn-big { margin-top: 18px; }

/* ============================================================
   TELA PRINCIPAL
   ============================================================ */
.tab-pages { flex: 1; overflow: hidden; display: flex; }
.tab-page { display: none; flex: 1; overflow-y: auto; padding: 18px 16px 24px; }
.tab-page.active { display: block; }
#tab-mordomo.tab-page.active { display: flex; flex-direction: column; overflow: hidden; }

.home-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 16px; }
.home-greeting { font-size: 26px; font-weight: 800; margin: 0; letter-spacing: -.4px; }
.home-sub { color: var(--gray-600); margin: 3px 0 0; font-size: 14px; }
.home-location {
  display: inline-flex; align-items: center; gap: 5px;
  background: #fff; border: 1px solid var(--gray-200);
  padding: 8px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 600; color: var(--gray-600);
  box-shadow: var(--shadow-sm); white-space: nowrap;
}

.search-card {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 20px; padding: 6px 6px 6px 16px;
  box-shadow: var(--shadow-md); margin-bottom: 22px;
  border: 1px solid rgba(0,0,0,.03);
}
.search-card input { flex: 1; border: none; outline: none; font-size: 16px; background: transparent; min-height: 48px; color: var(--secondary); }
.btn-surprise {
  width: 48px; height: 48px; border-radius: 16px;
  background: linear-gradient(145deg, var(--primary), var(--primary-dark));
  font-size: 20px; display: grid; place-items: center;
  box-shadow: 0 6px 16px rgba(255,107,53,.4);
  transition: transform .15s ease;
}
.btn-surprise:active { transform: scale(.92) rotate(-8deg); }

.section-title { margin: 18px 0 10px; }
.section-title h2 { font-size: 17px; font-weight: 700; margin: 0; }

.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.cat-item {
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  background: #fff; border: 1px solid var(--gray-200);
  border-radius: 18px; padding: 14px 6px;
  font-size: 11.5px; font-weight: 600; color: var(--gray-600);
  box-shadow: var(--shadow-sm);
  transition: transform .15s ease, box-shadow .2s ease;
}
.cat-item:active { transform: scale(.95); }
.cat-item span { font-size: 26px; }

.filter-block { margin-top: 14px; }
.filter-label { display: block; font-size: 13px; font-weight: 700; color: var(--gray-600); margin-bottom: 8px; }

/* ---------- Bottom nav ---------- */
#bottom-nav {
  display: flex; align-items: center; justify-content: space-around;
  background: #fff; border-top: 1px solid var(--gray-200);
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  z-index: 30;
}
.nav-item {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: var(--gray-400); font-size: 11px; font-weight: 600;
  padding: 6px 14px; border-radius: 14px; position: relative;
  transition: color .2s ease, transform .15s ease;
}
.nav-item:active { transform: scale(.94); }
.nav-item.active { color: var(--primary); }
.nav-mordomo { position: relative; }
.mordomo-badge {
  width: 52px; height: 52px; border-radius: 50%;
  background: linear-gradient(145deg, #7B5CFF, var(--primary));
  display: grid; place-items: center; font-size: 25px;
  margin-top: -30px; margin-bottom: -2px;
  box-shadow: 0 8px 20px rgba(123,92,255,.4);
  border: 3px solid #fff;
}
.nav-mordomo.active .mordomo-badge { filter: saturate(1.2); }

/* ---------- Cabeçalhos de página ---------- */
.page-header { margin-bottom: 16px; }
.page-header h1 { font-size: 24px; font-weight: 800; margin: 0; }
.page-header p { color: var(--gray-600); font-size: 14px; margin: 4px 0 0; }

.sub-header {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 14px 10px; background: var(--neutral);
  border-bottom: 1px solid var(--gray-200);
}
.sub-header h1 { flex: 1; font-size: 18px; font-weight: 800; margin: 0; }
.back-btn, .sort-btn {
  width: 44px; height: 44px; border-radius: 14px;
  background: #fff; display: grid; place-items: center;
  color: var(--secondary); box-shadow: var(--shadow-sm);
  transition: transform .15s ease;
}
.back-btn:active, .sort-btn:active { transform: scale(.93); }
.sort-btn { width: auto; padding: 0 14px; gap: 6px; font-size: 13px; font-weight: 600; }

.results-meta { padding: 10px 16px 4px; font-size: 12px; color: var(--gray-600); font-weight: 600; }

/* ---------- Lista de cards ---------- */
.list-cards { padding: 8px 16px 24px; display: flex; flex-direction: column; gap: 14px; }

.place-card {
  background: #fff; border-radius: 20px; overflow: hidden;
  box-shadow: var(--shadow-sm); border: 1px solid rgba(0,0,0,.03);
  transition: transform .18s ease, box-shadow .2s ease;
  animation: cardIn .3s ease-out backwards;
}
.place-card:active { transform: scale(.985); }
@keyframes cardIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.place-card-img { position: relative; aspect-ratio: 16/9; background: var(--gray-200); overflow: hidden; }
.place-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fav-badge {
  position: absolute; top: 10px; right: 10px;
  background: rgba(26,26,46,.75); color: #fff;
  font-size: 11px; font-weight: 700; padding: 5px 10px; border-radius: 999px;
  backdrop-filter: blur(4px);
}
.place-card-body { padding: 13px 14px 14px; }
.place-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.place-card-name { font-size: 16px; font-weight: 700; margin: 0; line-height: 1.25; }
.place-rating { display: inline-flex; align-items: center; gap: 3px; font-weight: 700; font-size: 13px; color: var(--secondary); white-space: nowrap; }
.place-rating .star { color: #F5A623; }
.place-card-count { font-size: 11px; color: var(--gray-400); font-weight: 500; }

.badge-cat { display: inline-block; font-size: 10.5px; font-weight: 700; padding: 4px 9px; border-radius: 999px; letter-spacing: .2px; }
.cat-comer   { background: #FFF1E8; color: #E55A25; }
.cat-curtir  { background: #F0EBFF; color: #6B4EE6; }
.cat-esporte { background: #E8F2FF; color: #2B6CB0; }
.cat-cultura { background: #FFF6DB; color: #B08900; }
.cat-relaxar { background: #E3F8F5; color: #1F8A80; }

.place-card-meta { display: flex; align-items: center; gap: 12px; margin-top: 9px; font-size: 12.5px; color: var(--gray-600); font-weight: 500; flex-wrap: wrap; }
.place-card-meta span { display: inline-flex; align-items: center; gap: 4px; }
.place-card-desc { font-size: 13px; color: var(--gray-600); margin-top: 8px; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Skeleton ---------- */
.skeleton-card { background: #fff; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-sm); }
.skeleton { position: relative; overflow: hidden; background: var(--gray-200); }
.skeleton::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.7), transparent);
  animation: shimmer 1.4s infinite; transform: translateX(-100%);
}
@keyframes shimmer { to { transform: translateX(100%); } }
.skeleton-img { aspect-ratio: 16/9; }
.skeleton-line { height: 14px; border-radius: 8px; margin: 12px 14px; }
.skeleton-line.short { width: 55%; }
.skeleton-line.mid { width: 80%; }

/* ---------- Empty state ---------- */
.empty-state { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 44px 24px; gap: 8px; }
.empty-icon { font-size: 52px; margin-bottom: 6px; }
.empty-state h3 { font-size: 18px; font-weight: 700; margin: 0; }
.empty-state p { color: var(--gray-600); font-size: 14px; margin: 0 0 16px; max-width: 280px; line-height: 1.5; }

/* ============================================================
   DETALHES
   ============================================================ */
#scr-detalhes { background: var(--neutral); }
.detalhes-content { height: 100%; overflow-y: auto; }
.detalhes-hero { position: relative; height: 260px; background: var(--gray-200); }
.detalhes-hero img { width: 100%; height: 100%; object-fit: cover; display: block; }
.detalhes-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(26,26,46,.35) 0%, transparent 35%, transparent 70%, rgba(26,26,46,.35) 100%);
}
.detalhes-fab {
  position: absolute; top: 14px; z-index: 5;
  width: 44px; height: 44px; border-radius: 14px;
  background: rgba(255,255,255,.92); display: grid; place-items: center;
  box-shadow: var(--shadow-md); color: var(--secondary);
  transition: transform .15s ease;
}
.detalhes-fab:active { transform: scale(.92); }
.detalhes-fab.fav { right: 14px; color: #E03131; }
.detalhes-fab.fav.active { background: #E03131; color: #fff; }
.detalhes-fab.fav.active svg { fill: #fff; }

.detalhes-body { padding: 18px 16px 40px; margin-top: -24px; position: relative; z-index: 4; }
.detalhes-card { background: #fff; border-radius: 20px; padding: 18px; box-shadow: var(--shadow-md); }
.detalhes-title { font-size: 22px; font-weight: 800; margin: 6px 0 2px; letter-spacing: -.3px; }
.detalhes-rating-row { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; color: var(--gray-600); }

.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 16px; }
.info-item { background: var(--neutral); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 3px; }
.info-item .k { font-size: 11px; font-weight: 700; color: var(--gray-400); text-transform: uppercase; letter-spacing: .4px; }
.info-item .v { font-size: 13.5px; font-weight: 600; color: var(--secondary); line-height: 1.3; }

.detalhes-actions { display: flex; gap: 10px; margin-top: 14px; }
.detalhes-actions button { flex: 1; }
.btn-action {
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  background: var(--neutral); border-radius: 14px; padding: 12px 6px;
  font-size: 11.5px; font-weight: 700; color: var(--gray-600);
  transition: background .2s ease, transform .15s ease;
}
.btn-action:active { transform: scale(.96); background: var(--gray-200); }

.detalhes-tabs { display: flex; gap: 8px; margin-top: 18px; background: #fff; border-radius: 999px; padding: 5px; box-shadow: var(--shadow-sm); }
.tab-btn { flex: 1; padding: 10px; border-radius: 999px; font-weight: 700; font-size: 14px; color: var(--gray-400); transition: all .2s ease; }
.tab-btn.active { background: var(--secondary); color: #fff; }
.tab-pane { display: none; margin-top: 14px; }
.tab-pane.active { display: block; animation: screenIn .25s ease-out; }
.tab-pane p { font-size: 14.5px; line-height: 1.65; color: var(--gray-600); margin: 0; }

.review-item { background: #fff; border-radius: 16px; padding: 14px; box-shadow: var(--shadow-sm); margin-bottom: 10px; }
.review-head { display: flex; align-items: center; gap: 10px; }
.review-avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(145deg, var(--primary), #7B5CFF); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 14px; flex-shrink: 0; }
.review-name { font-size: 14px; font-weight: 700; }
.review-stars { color: #F5A623; font-size: 12px; letter-spacing: 1px; }
.review-date { margin-left: auto; font-size: 11px; color: var(--gray-400); font-weight: 500; }
.review-text { font-size: 13.5px; color: var(--gray-600); margin-top: 8px; line-height: 1.5; }

.form-review { background: #fff; border-radius: 20px; padding: 16px; box-shadow: var(--shadow-sm); margin-top: 18px; }
.form-review h3 { font-size: 16px; font-weight: 700; margin: 0 0 12px; }
.stars-input { display: flex; gap: 6px; margin-bottom: 12px; }
.star-btn { font-size: 30px; color: var(--gray-200); transition: transform .15s ease, color .15s ease; line-height: 1; }
.star-btn.on { color: #F5A623; }
.star-btn:active { transform: scale(1.25); }

/* ============================================================
   MORDOMO
   ============================================================ */
#tab-mordomo { background: linear-gradient(180deg, #F3EFFF 0%, var(--neutral) 45%); }
.mordomo-header {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 16px 14px;
  background: linear-gradient(135deg, #2A1B4E 0%, #5B3BA8 55%, var(--primary) 130%);
  color: #fff; border-radius: 0 0 24px 24px;
  box-shadow: var(--shadow-md);
}
.mordomo-avatar {
  width: 54px; height: 54px; border-radius: 50%;
  background: rgba(255,255,255,.18); border: 2px solid rgba(255,255,255,.4);
  display: grid; place-items: center; font-size: 28px;
  animation: mordomoFloat 3s ease-in-out infinite;
}
@keyframes mordomoFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.mordomo-header h1 { font-size: 19px; font-weight: 800; margin: 0; }
.mordomo-header p { font-size: 12px; margin: 2px 0 0; opacity: .85; }
.voice-toggle { margin-left: auto; width: 42px; height: 42px; border-radius: 50%; background: rgba(255,255,255,.2); color: #fff; display: grid; place-items: center; }
.voice-toggle.off { background: rgba(255,255,255,.12); opacity: .6; }

.chat-list { flex: 1; overflow-y: auto; padding: 14px 14px 8px; display: flex; flex-direction: column; gap: 12px; }
.chat-msg { display: flex; gap: 8px; max-width: 88%; animation: msgIn .3s ease-out; }
@keyframes msgIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.chat-msg.user { align-self: flex-end; flex-direction: row-reverse; }
.chat-avatar { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(145deg, #7B5CFF, var(--primary)); display: grid; place-items: center; font-size: 15px; flex-shrink: 0; }
.chat-bubble {
  padding: 11px 14px; border-radius: 18px; font-size: 14px; line-height: 1.5;
  white-space: pre-wrap; word-break: break-word;
}
.chat-msg.mordomo .chat-bubble { background: #fff; color: var(--secondary); border-top-left-radius: 6px; box-shadow: var(--shadow-sm); }
.chat-msg.user .chat-bubble { background: var(--primary); color: #fff; border-top-right-radius: 6px; box-shadow: 0 4px 12px rgba(255,107,53,.3); }

.mini-cards { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; width: 100%; }
.mini-card {
  display: flex; align-items: center; gap: 10px;
  background: var(--neutral); border: 1px solid var(--gray-200);
  border-radius: 14px; padding: 9px; text-align: left; width: 100%;
  transition: transform .15s ease, background .2s ease;
}
.mini-card:active { transform: scale(.97); background: #fff; }
.mini-card img { width: 54px; height: 54px; border-radius: 12px; object-fit: cover; flex-shrink: 0; background: var(--gray-200); }
.mini-card .mc-name { font-size: 13.5px; font-weight: 700; line-height: 1.2; }
.mini-card .mc-meta { font-size: 11.5px; color: var(--gray-600); margin-top: 3px; display: flex; gap: 8px; flex-wrap: wrap; }

.chat-thinking {
  display: flex; align-items: center; gap: 7px;
  padding: 6px 16px; font-size: 13px; font-weight: 600; color: var(--gray-600);
}
.chat-thinking .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); animation: think 1.2s infinite; }
.chat-thinking .dot:nth-child(2) { animation-delay: .2s; }
.chat-thinking .dot:nth-child(3) { animation-delay: .4s; }
@keyframes think { 0%,100% { opacity: .25; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-3px); } }

.mordomo-input-area { padding: 10px 14px calc(12px + env(safe-area-inset-bottom)); background: var(--neutral); }
.voice-warning { font-size: 12px; color: var(--gray-600); margin: 0 0 8px; }
.btn-mic {
  width: 76px; height: 76px; border-radius: 50%;
  background: linear-gradient(145deg, var(--primary), var(--primary-dark));
  color: #fff; display: grid; place-items: center; margin: 0 auto 10px;
  box-shadow: 0 10px 26px rgba(255,107,53,.45);
  transition: transform .15s ease;
  position: relative;
}
.btn-mic:active { transform: scale(.94); }
.btn-mic.listening {
  background: #E03131;
  animation: micPulse 1.3s infinite;
}
@keyframes micPulse {
  0% { box-shadow: 0 0 0 0 rgba(224,49,49,.45); }
  100% { box-shadow: 0 0 0 22px rgba(224,49,49,0); }
}
.chat-text-row { display: flex; gap: 8px; }
.chat-text-row .input { border-radius: 999px; padding: 12px 18px; min-height: 48px; }
.btn-send {
  width: 48px; height: 48px; border-radius: 50%; flex-shrink: 0;
  background: var(--secondary); color: #fff; display: grid; place-items: center;
  transition: transform .15s ease;
}
.btn-send:active { transform: scale(.9); }

/* ============================================================
   PERFIL
   ============================================================ */
.profile-header { display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 18px; }
.profile-avatar {
  width: 84px; height: 84px; border-radius: 50%;
  background: linear-gradient(145deg, var(--primary), #7B5CFF);
  color: #fff; font-size: 32px; font-weight: 800;
  display: grid; place-items: center; margin-bottom: 10px;
  box-shadow: 0 10px 24px rgba(255,107,53,.3);
}
.profile-header h1 { font-size: 22px; font-weight: 800; margin: 0; }
.profile-city { display: inline-flex; align-items: center; gap: 5px; color: var(--gray-600); font-size: 14px; font-weight: 500; margin-top: 4px; }

.profile-card { background: #fff; border-radius: 20px; padding: 16px; box-shadow: var(--shadow-sm); margin-bottom: 14px; }
.profile-card h2 { font-size: 15px; font-weight: 800; margin: 0 0 12px; }
.profile-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.profile-card-head h2 { margin: 0; }
.pref-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--gray-100); font-size: 14px; color: var(--gray-600); }
.pref-row:last-child { border-bottom: none; }
.pref-row b { color: var(--secondary); font-weight: 700; text-align: right; }

.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat { background: var(--neutral); border-radius: 14px; padding: 14px 8px; text-align: center; }
.stat b { display: block; font-size: 22px; font-weight: 800; color: var(--primary); }
.stat span { font-size: 10.5px; color: var(--gray-600); font-weight: 600; line-height: 1.25; display: block; margin-top: 3px; }
.profile-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }

/* ============================================================
   MODAIS
   ============================================================ */
.modal-backdrop {
  position: absolute; inset: 0; z-index: 60;
  background: rgba(26,26,46,.55); backdrop-filter: blur(3px);
  animation: fadeIn .25s ease;
}
.modal {
  position: absolute; inset: 0; z-index: 61;
  display: flex; align-items: flex-end; justify-content: center;
  animation: fadeIn .25s ease;
}
@media (min-width: 520px) { .modal { align-items: center; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal-card {
  background: #fff; width: 100%; max-width: 440px;
  border-radius: 26px 26px 0 0; padding: 22px 20px 26px;
  box-shadow: var(--shadow-lg);
  animation: slideUp .3s ease-out;
  max-height: 88dvh; overflow-y: auto;
}
@media (min-width: 520px) { .modal-card { border-radius: 26px; } }
@keyframes slideUp { from { transform: translateY(60px); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-card h3 { font-size: 18px; font-weight: 800; margin: 0 0 12px; }
.modal-sub { font-size: 13px; color: var(--gray-600); margin: -6px 0 12px; }
.modal-emoji { font-size: 44px; text-align: center; margin-bottom: 6px; }
.modal-actions { display: flex; gap: 10px; margin-top: 18px; }
.modal-actions button { flex: 1; }
.surprise-card { background: var(--neutral); border-radius: 18px; padding: 14px; display: flex; gap: 12px; align-items: center; }
.surprise-card img { width: 70px; height: 70px; border-radius: 14px; object-fit: cover; background: var(--gray-200); }
.surprise-card .sc-name { font-weight: 700; font-size: 15px; }
.surprise-card .sc-meta { font-size: 12px; color: var(--gray-600); margin-top: 3px; }

/* ---------- Toast ---------- */
.toast-container {
  position: absolute; left: 0; right: 0; bottom: 92px; z-index: 80;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  pointer-events: none;
}
.toast {
  background: var(--secondary); color: #fff;
  padding: 12px 20px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 8px;
  animation: toastIn .3s ease-out;
  max-width: 90%;
}
.toast.out { animation: toastOut .3s ease-in forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(14px) scale(.95); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(10px) scale(.95); } }

/* ---------- Scrollbar ---------- */
.tab-page::-webkit-scrollbar, .chat-list::-webkit-scrollbar, .detalhes-content::-webkit-scrollbar,
.ob-step::-webkit-scrollbar, .modal-card::-webkit-scrollbar { width: 0; height: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
