/* ==========================================================================
   NINHO.IA — Design System
   Fase 0 · Protótipo navegável
   Paleta: verde-profundo + âmbar (derivada do logo teal/laranja)
   ========================================================================== */

/* ---------- 1. TOKENS ---------- */
:root {
  /* Marca — verdes profundos */
  --ink-950: #031714;
  --ink-900: #05221E;
  --ink-800: #082F2A;
  --forest-700: #0B3D37;
  --forest-600: #0F5148;
  --teal-600: #12776F;
  --teal-500: #17998C;
  --teal-400: #22B3A3;
  --mint-400: #2ED3B7;
  --mint-200: #A9EEDF;
  --mint-50: #E9F9F4;

  /* Marca — âmbar / destaque */
  --amber-700: #B06A05;
  --amber-600: #D98A0B;
  --amber-500: #F5A524;
  --amber-400: #FFBE4D;
  --amber-100: #FFF1D6;
  --amber-50: #FFF9EC;

  /* Neutros */
  --paper: #FAFAF8;
  --paper-2: #F2F4F2;
  --card: #FFFFFF;
  --line: #E3E9E6;
  --line-strong: #CFD9D5;
  --text: #0E2320;
  --text-2: #3D544F;
  --muted: #6E837E;
  --muted-2: #93A5A0;
  --white: #FFFFFF;

  /* Semânticos */
  --success: #12A67C;
  --success-bg: #E6F7F0;
  --warning: #D98A0B;
  --warning-bg: #FFF4E0;
  --danger: #D64545;
  --danger-bg: #FDECEC;
  --info: #2A7DE1;
  --info-bg: #EAF2FD;

  /* Tipografia */
  --font-display: 'Plus Jakarta Sans', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;

  /* Raio */
  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-full: 999px;

  /* Sombra */
  --sh-xs: 0 1px 2px rgba(5, 34, 30, .06);
  --sh-sm: 0 2px 8px rgba(5, 34, 30, .07);
  --sh-md: 0 8px 24px rgba(5, 34, 30, .09);
  --sh-lg: 0 18px 48px rgba(5, 34, 30, .14);
  --sh-glow: 0 10px 40px rgba(23, 153, 140, .28);

  /* Espaço */
  --nav-h: 68px;
  --wrap: 1240px;

  /* Transição */
  --t: .22s cubic-bezier(.4, 0, .2, 1);
}

/* ---------- 2. RESET ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, video { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: none; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
table { border-collapse: collapse; width: 100%; }
:focus-visible { outline: 2px solid var(--teal-400); outline-offset: 2px; border-radius: 4px; }

/* ---------- 3. TIPOGRAFIA ---------- */
h1, h2, h3, h4, h5 { font-family: var(--font-display); font-weight: 700; line-height: 1.15; letter-spacing: -.02em; color: var(--ink-900); }
h1 { font-size: clamp(2.1rem, 5vw, 3.6rem); letter-spacing: -.035em; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.5rem); letter-spacing: -.03em; }
h3 { font-size: clamp(1.15rem, 2vw, 1.5rem); }
h4 { font-size: 1.05rem; }
h5 { font-size: .95rem; }
p { color: var(--text-2); }

.display { font-family: var(--font-display); }
.lead { font-size: clamp(1rem, 1.6vw, 1.18rem); color: var(--text-2); line-height: 1.65; }
.small { font-size: .875rem; }
.xsmall { font-size: .78rem; }
.muted { color: var(--muted); }
.strong { font-weight: 700; }
.center { text-align: center; }
.mono { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-variant-numeric: tabular-nums; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--teal-600);
}
.eyebrow::before { content: ''; width: 22px; height: 2px; background: var(--amber-500); border-radius: 2px; }
.eyebrow.on-dark { color: var(--mint-200); }

.grad-text {
  background: linear-gradient(100deg, var(--mint-400) 0%, var(--amber-400) 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- 4. LAYOUT ---------- */
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.wrap-sm { max-width: 780px; }
.wrap-xs { max-width: 520px; }
.section { padding: clamp(56px, 8vw, 104px) 0; }
.section-sm { padding: clamp(36px, 5vw, 64px) 0; }

.grid { display: grid; gap: 24px; }
.g-2 { grid-template-columns: repeat(2, 1fr); }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.g-4 { grid-template-columns: repeat(4, 1fr); }
.flex { display: flex; }
.fcol { flex-direction: column; }
.aic { align-items: center; }
.ais { align-items: flex-start; }
.jcb { justify-content: space-between; }
.jcc { justify-content: center; }
.wrapf { flex-wrap: wrap; }
.gap-4 { gap: 4px; } .gap-6 { gap: 6px; } .gap-8 { gap: 8px; }
.gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; } .gap-32 { gap: 32px; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; } .mt-48 { margin-top: 48px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; } .mb-32 { margin-bottom: 32px; }
.full { width: 100%; }
.hidden { display: none !important; }

.dark { background: var(--ink-900); color: #D9E6E3; }
.dark h1, .dark h2, .dark h3, .dark h4 { color: var(--white); }
.dark p { color: #A9C0BB; }

/* ---------- 5. LOGO ---------- */
.logo { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 800; font-size: 1.24rem; letter-spacing: -.03em; color: var(--ink-900); }
.logo-mark { width: 34px; height: 34px; flex: none; }
.logo .dotia { color: var(--teal-500); font-weight: 700; }
.on-dark .logo, .dark .logo { color: var(--white); }
.on-dark .logo .dotia, .dark .logo .dotia { color: var(--mint-400); }

/* ---------- 6. BOTÕES ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 12px 22px; border-radius: var(--r-full);
  font-family: var(--font-display); font-weight: 700; font-size: .93rem; letter-spacing: -.01em;
  cursor: pointer; transition: var(--t); white-space: nowrap; border: 1.5px solid transparent;
  line-height: 1.2;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 17px; height: 17px; flex: none; }

.btn-primary { background: var(--ink-900); color: var(--white); box-shadow: var(--sh-sm); }
.btn-primary:hover { background: var(--forest-700); box-shadow: var(--sh-md); transform: translateY(-1px); }

.btn-accent { background: linear-gradient(120deg, var(--amber-500), var(--amber-400)); color: var(--ink-950); box-shadow: 0 6px 20px rgba(245, 165, 36, .34); }
.btn-accent:hover { filter: brightness(1.05); transform: translateY(-1px); box-shadow: 0 10px 28px rgba(245, 165, 36, .42); }

.btn-teal { background: var(--teal-500); color: var(--white); }
.btn-teal:hover { background: var(--teal-600); transform: translateY(-1px); }

.btn-ghost { background: transparent; color: var(--ink-900); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink-900); background: var(--paper-2); }
.on-dark .btn-ghost, .dark .btn-ghost { color: var(--white); border-color: rgba(255,255,255,.28); }
.on-dark .btn-ghost:hover, .dark .btn-ghost:hover { background: rgba(255,255,255,.09); border-color: rgba(255,255,255,.55); }

.btn-white { background: var(--white); color: var(--ink-900); }
.btn-white:hover { background: var(--mint-50); }

.btn-soft { background: var(--mint-50); color: var(--forest-600); }
.btn-soft:hover { background: var(--mint-200); }

.btn-sm { padding: 8px 15px; font-size: .82rem; }
.btn-sm svg { width: 15px; height: 15px; }
.btn-lg { padding: 15px 30px; font-size: 1rem; }
.btn-block { width: 100%; }
.btn:disabled, .btn.is-disabled { opacity: .42; pointer-events: none; }

.icon-btn {
  width: 40px; height: 40px; border-radius: var(--r-full);
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--white); border: 1px solid var(--line); color: var(--text-2);
  transition: var(--t); cursor: pointer;
}
.icon-btn:hover { border-color: var(--ink-900); color: var(--ink-900); }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn.is-active { background: var(--ink-900); border-color: var(--ink-900); color: var(--amber-400); }

/* ---------- 7. BADGES / CHIPS / PILLS ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: var(--r-full);
  font-size: .73rem; font-weight: 700; letter-spacing: .01em;
  background: var(--paper-2); color: var(--text-2); white-space: nowrap;
}
.badge svg { width: 13px; height: 13px; }
.badge-verified { background: var(--mint-50); color: var(--forest-600); }
.badge-premium { background: linear-gradient(120deg, var(--ink-900), var(--forest-600)); color: var(--amber-400); }
.badge-360 { background: var(--amber-50); color: var(--amber-700); }
.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warn { background: var(--warning-bg); color: var(--warning); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-info { background: var(--info-bg); color: var(--info); }
.badge-new { background: var(--ink-900); color: var(--mint-400); }
.badge-drop { background: #FFEDE6; color: #C9541B; }
.badge-hot { background: linear-gradient(120deg, #FF7A45, var(--amber-500)); color: #fff; }

.chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 16px; border-radius: var(--r-full);
  background: var(--white); border: 1.5px solid var(--line);
  font-size: .85rem; font-weight: 600; color: var(--text-2);
  cursor: pointer; transition: var(--t); user-select: none;
}
.chip:hover { border-color: var(--teal-400); color: var(--forest-600); }
.chip.is-active { background: var(--ink-900); border-color: var(--ink-900); color: var(--white); }
.chip.is-active .chip-x { opacity: .7; }
.chip svg { width: 15px; height: 15px; }

/* ---------- 8. CARDS ---------- */
.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 24px; transition: var(--t);
}
.card-hover:hover { box-shadow: var(--sh-md); transform: translateY(-3px); border-color: var(--line-strong); }
.card-flat { border: none; box-shadow: var(--sh-sm); }
.card-tight { padding: 16px; }
.card-dark { background: var(--ink-900); border-color: rgba(255,255,255,.09); color: #C9DAD6; }
.card-dark h3, .card-dark h4 { color: var(--white); }

/* ---------- 9. FORMULÁRIOS ---------- */
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; }
.label { font-size: .84rem; font-weight: 700; color: var(--text); font-family: var(--font-display); }
.label .req { color: var(--danger); }
.hint { font-size: .78rem; color: var(--muted); }
.input, .select, .textarea {
  width: 100%; padding: 12px 15px;
  border: 1.5px solid var(--line); border-radius: var(--r-sm);
  background: var(--white); font-size: .94rem; color: var(--text);
  transition: var(--t);
}
.input::placeholder, .textarea::placeholder { color: var(--muted-2); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--teal-500); box-shadow: 0 0 0 4px rgba(23,153,140,.12); }
.textarea { min-height: 108px; resize: vertical; line-height: 1.55; }
.select { appearance: none; cursor: pointer; padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236E837E' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center; background-size: 17px;
}
.input-icon { position: relative; }
.input-icon svg { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.input-icon .input { padding-left: 44px; }

.check { display: flex; align-items: flex-start; gap: 11px; cursor: pointer; padding: 4px 0; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--teal-500); flex: none; cursor: pointer; }
.check span { font-size: .89rem; color: var(--text-2); }

/* Cartão selecionável (radio visual) */
.pick {
  border: 2px solid var(--line); border-radius: var(--r-md); padding: 18px;
  cursor: pointer; transition: var(--t); background: var(--white); position: relative;
}
.pick:hover { border-color: var(--teal-400); }
.pick.is-active { border-color: var(--ink-900); background: var(--mint-50); box-shadow: var(--sh-sm); }
.pick.is-active::after {
  content: '✓'; position: absolute; top: 12px; right: 14px;
  width: 22px; height: 22px; border-radius: 50%; background: var(--ink-900); color: var(--amber-400);
  display: grid; place-items: center; font-size: .72rem; font-weight: 800;
}
.pick-title { font-family: var(--font-display); font-weight: 700; font-size: .96rem; color: var(--ink-900); }
.pick-desc { font-size: .82rem; color: var(--muted); margin-top: 3px; line-height: 1.45; }

.switch { position: relative; display: inline-block; width: 46px; height: 26px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch-track { position: absolute; inset: 0; background: var(--line-strong); border-radius: var(--r-full); transition: var(--t); cursor: pointer; }
.switch-track::before { content: ''; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; background: var(--white); border-radius: 50%; transition: var(--t); box-shadow: var(--sh-xs); }
.switch input:checked + .switch-track { background: var(--teal-500); }
.switch input:checked + .switch-track::before { transform: translateX(20px); }

/* ---------- 10. PROGRESSO ---------- */
.progress { height: 8px; background: var(--paper-2); border-radius: var(--r-full); overflow: hidden; }
.progress-bar { height: 100%; background: linear-gradient(90deg, var(--teal-500), var(--mint-400)); border-radius: var(--r-full); transition: width .5s cubic-bezier(.4,0,.2,1); }
.progress-bar.amber { background: linear-gradient(90deg, var(--amber-600), var(--amber-400)); }

.meter { height: 6px; background: var(--paper-2); border-radius: var(--r-full); overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--teal-500); border-radius: var(--r-full); }

/* ---------- 11. NINHO SCORE ---------- */
.score-ring { position: relative; width: 92px; height: 92px; flex: none; }
.score-ring svg { transform: rotate(-90deg); width: 100%; height: 100%; }
.score-ring .track { fill: none; stroke: var(--paper-2); stroke-width: 9; }
.score-ring .fill { fill: none; stroke: url(#scoreGrad); stroke-width: 9; stroke-linecap: round; transition: stroke-dashoffset 1s ease; }
.score-ring .val {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 800; font-size: 1.5rem; color: var(--ink-900); letter-spacing: -.04em;
}
.score-ring .val small { display: block; font-size: .58rem; font-weight: 700; color: var(--muted); letter-spacing: .09em; margin-top: -3px; }

.trust-item { display: flex; align-items: flex-start; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.trust-item:last-child { border-bottom: none; }
.trust-ico { width: 21px; height: 21px; border-radius: 50%; display: grid; place-items: center; flex: none; font-size: .68rem; font-weight: 800; margin-top: 2px; }
.trust-ok { background: var(--success-bg); color: var(--success); }
.trust-pend { background: var(--warning-bg); color: var(--warning); }
.trust-none { background: var(--paper-2); color: var(--muted-2); }
.trust-txt { font-size: .87rem; font-weight: 600; color: var(--text); }
.trust-src { font-size: .74rem; color: var(--muted); margin-top: 1px; line-height: 1.4; }

/* ---------- 12. IMÓVEL — CARD ---------- */
.prop-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; transition: var(--t); display: flex; flex-direction: column; }
.prop-card:hover { box-shadow: var(--sh-md); transform: translateY(-4px); border-color: var(--line-strong); }
.prop-media { position: relative; aspect-ratio: 4/3; overflow: hidden; background: var(--paper-2); }
.prop-media .ph { position: absolute; inset: 0; display: grid; place-items: center; transition: transform .5s ease; }
.prop-card:hover .prop-media .ph { transform: scale(1.05); }
.prop-badges { position: absolute; top: 11px; left: 11px; display: flex; gap: 6px; flex-wrap: wrap; max-width: calc(100% - 62px); z-index: 2; }
.prop-fav { position: absolute; top: 11px; right: 11px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.94); display: grid; place-items: center; transition: var(--t); border: none; cursor: pointer; }
.prop-fav:hover { background: var(--white); transform: scale(1.08); }
.prop-fav svg { width: 17px; height: 17px; stroke: var(--text-2); fill: none; stroke-width: 2; }
.prop-fav.is-active svg { fill: var(--danger); stroke: var(--danger); }
.prop-score { position: absolute; bottom: 11px; right: 11px; z-index: 2; display: flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: var(--r-full); background: rgba(5,34,30,.86); backdrop-filter: blur(8px); color: var(--white); font-size: .74rem; font-weight: 800; font-family: var(--font-display); }
.prop-score b { color: var(--amber-400); }
.prop-body { padding: 17px 18px 19px; display: flex; flex-direction: column; flex: 1; }
.prop-price { font-family: var(--font-display); font-size: 1.32rem; font-weight: 800; color: var(--ink-900); letter-spacing: -.03em; }
.prop-price-old { font-size: .8rem; color: var(--muted-2); text-decoration: line-through; margin-left: 7px; font-weight: 500; }
.prop-title { font-size: .93rem; font-weight: 600; color: var(--text); margin-top: 5px; line-height: 1.35; }
.prop-loc { font-size: .82rem; color: var(--muted); margin-top: 3px; display: flex; align-items: center; gap: 5px; }
.prop-loc svg { width: 13px; height: 13px; flex: none; }
.prop-specs { display: flex; gap: 14px; margin-top: 13px; padding-top: 13px; border-top: 1px solid var(--line); font-size: .8rem; color: var(--text-2); flex-wrap: wrap; }
.prop-specs span { display: flex; align-items: center; gap: 5px; }
.prop-specs svg { width: 14px; height: 14px; color: var(--muted); flex: none; }
.prop-foot { margin-top: auto; padding-top: 13px; font-size: .78rem; color: var(--muted); display: flex; justify-content: space-between; align-items: center; gap: 8px; }

/* Placeholder de foto (sem imagens externas) */
.ph { background: linear-gradient(135deg, var(--forest-700) 0%, var(--teal-600) 50%, var(--teal-500) 100%); }
.ph-2 { background: linear-gradient(135deg, #0F5148 0%, #17998C 60%, #2ED3B7 100%); }
.ph-3 { background: linear-gradient(135deg, #05221E 0%, #12776F 70%, #B06A05 100%); }
.ph-4 { background: linear-gradient(135deg, #0B3D37 0%, #D98A0B 100%); }
.ph-5 { background: linear-gradient(135deg, #082F2A 0%, #22B3A3 55%, #FFBE4D 100%); }
.ph svg { width: 34%; max-width: 84px; opacity: .17; color: #fff; }

/* ---------- 13. NAVBAR ---------- */
.nav {
  position: sticky; top: 0; z-index: 90; height: var(--nav-h);
  background: rgba(250,250,248,.86); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a { font-size: .89rem; font-weight: 600; color: var(--text-2); transition: var(--t); }
.nav-links a:hover, .nav-links a.is-active { color: var(--ink-900); }
.nav-actions { display: flex; align-items: center; gap: 11px; }
.nav.on-dark { background: rgba(5,34,30,.82); border-bottom-color: rgba(255,255,255,.09); }
.nav.on-dark .nav-links a { color: #A9C0BB; }
.nav.on-dark .nav-links a:hover, .nav.on-dark .nav-links a.is-active { color: var(--white); }
.nav-burger { display: none; }

/* ---------- 14. FOOTER ---------- */
.footer { background: var(--ink-950); color: #8FA8A3; padding: 64px 0 32px; }
.footer h5 { color: var(--white); font-size: .85rem; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 15px; }
.footer a { color: #8FA8A3; font-size: .87rem; line-height: 2; transition: var(--t); }
.footer a:hover { color: var(--mint-400); }
.footer-bottom { margin-top: 44px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.09); font-size: .79rem; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ---------- 15. APP SHELL (área logada) ---------- */
.app { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }
.side { background: var(--ink-950); padding: 22px 15px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; }
.side-logo { padding: 4px 10px 24px; }
.side-group { margin-bottom: 22px; }
.side-group-t { font-size: .68rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; color: #4F6A66; padding: 0 12px; margin-bottom: 7px; }
.side a { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: var(--r-sm); font-size: .88rem; font-weight: 600; color: #9BB3AE; transition: var(--t); }
.side a:hover { background: rgba(255,255,255,.06); color: var(--white); }
.side a.is-active { background: var(--teal-600); color: var(--white); }
.side a svg { width: 17px; height: 17px; flex: none; }
.side a .n { margin-left: auto; background: var(--amber-500); color: var(--ink-950); font-size: .68rem; font-weight: 800; padding: 1px 7px; border-radius: var(--r-full); }
.main { background: var(--paper); min-width: 0; }
.topbar { height: 66px; background: var(--white); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 26px; position: sticky; top: 0; z-index: 40; gap: 16px; }
.content { padding: 28px 26px 60px; }

.avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--teal-500), var(--forest-700)); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: .8rem; font-family: var(--font-display); flex: none; }

/* ---------- 16. STATS ---------- */
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-md); padding: 18px 20px; }
.stat-l { font-size: .78rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.stat-v { font-family: var(--font-display); font-size: 1.85rem; font-weight: 800; color: var(--ink-900); letter-spacing: -.035em; margin-top: 5px; line-height: 1; }
.stat-d { font-size: .78rem; font-weight: 700; margin-top: 6px; display: flex; align-items: center; gap: 4px; }
.stat-up { color: var(--success); }
.stat-down { color: var(--danger); }

/* ---------- 17. TABS ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { padding: 11px 17px; font-size: .89rem; font-weight: 700; color: var(--muted); border-bottom: 2.5px solid transparent; margin-bottom: -1px; cursor: pointer; transition: var(--t); white-space: nowrap; font-family: var(--font-display); }
.tab:hover { color: var(--text); }
.tab.is-active { color: var(--ink-900); border-bottom-color: var(--amber-500); }

/* ---------- 18. ALERTAS ---------- */
.alert { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r-md); font-size: .87rem; line-height: 1.5; border: 1px solid transparent; }
.alert svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.alert-info { background: var(--info-bg); color: #1B5FB0; border-color: #C9DDF7; }
.alert-warn { background: var(--warning-bg); color: var(--amber-700); border-color: #F4DCAF; }
.alert-ok { background: var(--success-bg); color: #0B7A5B; border-color: #B7E5D4; }
.alert-danger { background: var(--danger-bg); color: #A62F2F; border-color: #F3C7C7; }
.alert-ia { background: linear-gradient(120deg, var(--ink-900), var(--forest-600)); color: #CBE6E1; border: none; }
.alert-ia strong { color: var(--amber-400); }

/* ---------- 19. IA ---------- */
.ia-badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px;
  border-radius: var(--r-full); font-size: .72rem; font-weight: 800; letter-spacing: .02em;
  background: linear-gradient(120deg, var(--ink-900), var(--teal-600)); color: var(--mint-400);
}
.ia-badge svg { width: 12px; height: 12px; }

.ia-bubble { display: flex; gap: 11px; align-items: flex-start; }
.ia-ava { width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, var(--ink-900), var(--teal-500)); display: grid; place-items: center; flex: none; }
.ia-ava svg { width: 16px; height: 16px; color: var(--mint-400); }
.ia-msg { background: var(--white); border: 1px solid var(--line); border-radius: 4px 14px 14px 14px; padding: 12px 15px; font-size: .88rem; color: var(--text-2); line-height: 1.55; }
.ia-msg.me { background: var(--ink-900); color: #D5E7E3; border: none; border-radius: 14px 4px 14px 14px; }

/* ---------- 20. STEPPER ---------- */
.stepper { display: flex; gap: 5px; overflow-x: auto; padding-bottom: 6px; }
.step-dot { flex: 1; min-width: 26px; height: 5px; border-radius: var(--r-full); background: var(--line); transition: var(--t); }
.step-dot.done { background: var(--teal-500); }
.step-dot.now { background: var(--amber-500); }

/* ---------- 21. TIMELINE / PIPELINE ---------- */
.tl { position: relative; padding-left: 28px; }
.tl::before { content: ''; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.tl-item { position: relative; padding-bottom: 20px; }
.tl-item::before { content: ''; position: absolute; left: -25px; top: 5px; width: 12px; height: 12px; border-radius: 50%; background: var(--white); border: 2.5px solid var(--line-strong); }
.tl-item.done::before { background: var(--teal-500); border-color: var(--teal-500); }
.tl-item.now::before { background: var(--amber-500); border-color: var(--amber-500); box-shadow: 0 0 0 4px var(--amber-100); }

/* ---------- 22. MAPA (mock) ---------- */
.map-mock {
  position: relative; border-radius: var(--r-md); overflow: hidden;
  background:
    radial-gradient(circle at 22% 28%, rgba(46,211,183,.14), transparent 42%),
    radial-gradient(circle at 74% 66%, rgba(245,165,36,.13), transparent 40%),
    repeating-linear-gradient(0deg, rgba(11,61,55,.055) 0 1px, transparent 1px 46px),
    repeating-linear-gradient(90deg, rgba(11,61,55,.055) 0 1px, transparent 1px 46px),
    #EDF2F0;
}
.map-mock::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(112deg, transparent 30%, rgba(23,153,140,.1) 30.4%, rgba(23,153,140,.1) 32%, transparent 32.4%),
    linear-gradient(-62deg, transparent 54%, rgba(23,153,140,.1) 54.4%, rgba(23,153,140,.1) 56%, transparent 56.4%);
  pointer-events: none;
}
.map-pin {
  position: absolute; transform: translate(-50%, -100%); z-index: 3;
  background: var(--ink-900); color: var(--white); font-size: .74rem; font-weight: 800;
  padding: 5px 10px; border-radius: var(--r-full); white-space: nowrap; cursor: pointer;
  box-shadow: var(--sh-sm); transition: var(--t); font-family: var(--font-display);
}
.map-pin:hover, .map-pin.is-active { background: var(--amber-500); color: var(--ink-950); transform: translate(-50%, -100%) scale(1.1); z-index: 5; }
.map-pin::after { content: ''; position: absolute; bottom: -4px; left: 50%; transform: translateX(-50%) rotate(45deg); width: 8px; height: 8px; background: inherit; }
.map-area { position: absolute; border-radius: 50%; background: rgba(23,153,140,.14); border: 1.5px dashed rgba(23,153,140,.45); }

/* ---------- 23. MODAL ---------- */
.modal-bg { position: fixed; inset: 0; background: rgba(3,23,20,.62); backdrop-filter: blur(4px); z-index: 200; display: grid; place-items: center; padding: 20px; opacity: 0; pointer-events: none; transition: var(--t); }
.modal-bg.is-open { opacity: 1; pointer-events: auto; }
.modal { background: var(--white); border-radius: var(--r-lg); max-width: 520px; width: 100%; max-height: 88vh; overflow-y: auto; box-shadow: var(--sh-lg); transform: translateY(14px) scale(.98); transition: var(--t); }
.modal-bg.is-open .modal { transform: none; }
.modal-h { padding: 22px 24px 0; display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.modal-b { padding: 18px 24px 24px; }

/* ---------- 24. TOAST ---------- */
.toasts { position: fixed; bottom: 22px; right: 22px; z-index: 300; display: flex; flex-direction: column; gap: 10px; max-width: 340px; }
.toast { background: var(--ink-900); color: #DCEBE8; padding: 13px 17px; border-radius: var(--r-md); font-size: .87rem; box-shadow: var(--sh-lg); display: flex; gap: 10px; align-items: flex-start; animation: toastIn .3s cubic-bezier(.2,1.2,.4,1); }
.toast svg { width: 17px; height: 17px; color: var(--mint-400); flex: none; margin-top: 1px; }
@keyframes toastIn { from { opacity: 0; transform: translateX(30px); } to { opacity: 1; transform: none; } }

/* ---------- 25. UTIL VISUAL ---------- */
.divider { height: 1px; background: var(--line); margin: 22px 0; }
.glass { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.13); backdrop-filter: blur(12px); border-radius: var(--r-md); }
.dot-sep::before { content: '·'; margin: 0 7px; color: var(--muted-2); }
.ring-amber { box-shadow: 0 0 0 3px var(--amber-100); }
.scroll-x { overflow-x: auto; scrollbar-width: thin; }
.scroll-x::-webkit-scrollbar { height: 6px; }
.scroll-x::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 3px; }
.noscroll { overflow: hidden; }

.reveal { opacity: 0; transform: translateY(20px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.7,.3,1); }
.reveal.in { opacity: 1; transform: none; }

.aurora { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.aurora::before, .aurora::after { content: ''; position: absolute; border-radius: 50%; filter: blur(90px); opacity: .34; }
.aurora::before { width: 520px; height: 520px; background: var(--teal-400); top: -180px; right: -120px; }
.aurora::after { width: 420px; height: 420px; background: var(--amber-500); bottom: -190px; left: -110px; opacity: .22; }

/* ---------- 26. RESPONSIVO ---------- */
@media (max-width: 1080px) {
  .g-4 { grid-template-columns: repeat(2, 1fr); }
  .app { grid-template-columns: 1fr; }
  .side { display: none; }
}
@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-burger { display: inline-flex; }
  .g-3 { grid-template-columns: repeat(2, 1fr); }
  .hide-mob { display: none !important; }
}
@media (max-width: 620px) {
  .wrap { padding: 0 18px; }
  .g-2, .g-3, .g-4 { grid-template-columns: 1fr; }
  .content { padding: 20px 18px 48px; }
  .topbar { padding: 0 18px; }
  .btn-lg { padding: 13px 24px; font-size: .93rem; }
  .toasts { left: 16px; right: 16px; max-width: none; }
}

/* ---------- 27. APP · CICLO 2 ---------- */
.kvl2 { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: .88rem; }
.kvl2:last-of-type { border-bottom: none; }

.kanban { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 12px; align-items: flex-start; }
.kcol { flex: none; width: 236px; background: var(--paper-2); border-radius: var(--r-md); padding: 12px; }
.kcol-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.kcol-h b { font-family: var(--font-display); font-size: .8rem; letter-spacing: -.01em; }
.kcol-h span { font-size: .72rem; font-weight: 800; background: var(--white); color: var(--muted); padding: 1px 8px; border-radius: var(--r-full); }
.kcol .card { margin-bottom: 9px; }
.kcol-empty { border: 1.5px dashed var(--line-strong); border-radius: var(--r-sm); padding: 16px 10px; text-align: center; font-size: .74rem; color: var(--muted-2); }

.lead-row { display: grid; grid-template-columns: 1.4fr 1fr 1fr .9fr .8fr auto; gap: 12px; align-items: center; padding: 13px 16px; border-bottom: 1px solid var(--line); font-size: .86rem; transition: var(--t); }
.lead-row:hover { background: var(--mint-50); }
.lead-row:last-child { border-bottom: none; }
.lead-head { background: var(--paper-2); font-size: .74rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }

.hist { position: relative; padding-left: 30px; }
.hist::before { content: ''; position: absolute; left: 9px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.hist-i { position: relative; padding: 0 0 20px; }
.hist-i::before { content: ''; position: absolute; left: -26px; top: 4px; width: 14px; height: 14px; border-radius: 50%; background: var(--white); border: 2.5px solid var(--line-strong); }
.hist-i.ia::before { background: var(--teal-500); border-color: var(--teal-500); }
.hist-i.lead::before { background: var(--amber-500); border-color: var(--amber-500); }
.hist-i.user::before { background: var(--ink-900); border-color: var(--ink-900); }
.hist-i.alert::before { background: var(--danger); border-color: var(--danger); }
.hist-d { font-size: .74rem; color: var(--muted); font-weight: 600; }
.hist-t { font-size: .87rem; color: var(--text-2); margin-top: 3px; line-height: 1.5; }

.ring-stat { display: flex; align-items: center; gap: 14px; }
.mini-ring { width: 46px; height: 46px; border-radius: 50%; flex: none; display: grid; place-items: center; font-family: var(--font-display); font-weight: 800; font-size: .82rem; }

@media (max-width: 900px) {
  .lead-row { grid-template-columns: 1fr auto; }
  .lead-row .lr-hide { display: none; }
  .lead-head { display: none; }
}

@media print { .nav, .footer, .side, .topbar { display: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } .reveal { opacity: 1; transform: none; } }
