/* ============================================================
   PATITAS CONECTADAS — Sistema de Diseño Principal
   Encoding: UTF-8
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Plus+Jakarta+Sans:wght@600;700;800&display=swap');

/* ─── VARIABLES ────────────────────────────────────────── */
:root {
  /* Colores base */
  --bg-primary:       #07101f;
  --bg-secondary:     #0d1a2d;
  --bg-card:          #112035;
  --bg-card-2:        #162840;
  --bg-card-hover:    #1a3050;
  --bg-input:         #0a1726;
  --bg-overlay:       rgba(7, 16, 31, 0.85);

  /* Acentos */
  --accent:           #f97316;
  --accent-dark:      #c2591a;
  --accent-light:     #fb923c;
  --accent-glow:      rgba(249, 115, 22, 0.25);

  /* Estados */
  --green:            #22c55e;
  --green-bg:         rgba(34, 197, 94, 0.12);
  --red:              #ef4444;
  --red-bg:           rgba(239, 68, 68, 0.12);
  --yellow:           #f59e0b;
  --yellow-bg:        rgba(245, 158, 11, 0.12);
  --blue:             #3b82f6;
  --blue-bg:          rgba(59, 130, 246, 0.12);
  --purple:           #a855f7;
  --purple-bg:        rgba(168, 85, 247, 0.12);

  /* Texto */
  --text-primary:     #f0f6ff;
  --text-secondary:   #8faec8;
  --text-muted:       #4a6278;
  --text-accent:      #f97316;

  /* Bordes */
  --border:           #1a2e42;
  --border-light:     #223348;
  --border-accent:    rgba(249, 115, 22, 0.4);

  /* Tipografía */
  --font-body:        'Inter', system-ui, -apple-system, sans-serif;
  --font-display:     'Plus Jakarta Sans', 'Inter', sans-serif;

  /* Sombras */
  --shadow-sm:        0 1px 4px rgba(0,0,0,0.4);
  --shadow-md:        0 4px 16px rgba(0,0,0,0.5);
  --shadow-lg:        0 8px 32px rgba(0,0,0,0.6);
  --shadow-accent:    0 4px 24px rgba(249, 115, 22, 0.35);

  /* Radios */
  --radius-sm:        6px;
  --radius:           10px;
  --radius-lg:        16px;
  --radius-xl:        24px;
  --radius-full:      9999px;

  /* Transiciones */
  --transition:       0.2s ease;
  --transition-slow:  0.4s ease;

  /* Layout */
  --max-width:        1280px;
  --nav-height:       64px;
}

/* ─── RESET ─────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover { color: var(--accent-light); }

ul, ol { list-style: none; }

input, textarea, select, button {
  font-family: inherit;
  font-size: inherit;
}

/* ─── SCROLLBAR ──────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: var(--radius-full); }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ─── LAYOUT ─────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.container--sm  { max-width: 720px; }
.container--md  { max-width: 960px; }
.container--lg  { max-width: 1100px; }

/* ─── NAVEGACIÓN ─────────────────────────────────────────── */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: rgba(7, 16, 31, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.navbar__inner {
  display: flex;
  align-items: center;
  height: 100%;
  gap: 8px;
}

.navbar__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  text-decoration: none;
  flex-shrink: 0;
}

.navbar__logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: var(--shadow-accent);
}

.navbar__logo span { color: var(--accent); }

.navbar__region {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
  margin-left: 8px;
}

.navbar__region:hover {
  border-color: var(--border-light);
  color: var(--text-primary);
}

.navbar__nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.navbar__link {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition);
}

.navbar__link:hover {
  color: var(--text-primary);
  background: var(--bg-card);
}

.navbar__link--active {
  color: var(--text-primary);
  background: var(--bg-card);
}

.navbar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 12px;
}

.navbar__search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 0.83rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition);
  min-width: 200px;
}

.navbar__search:hover {
  border-color: var(--border-light);
  color: var(--text-secondary);
}

.navbar__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.navbar__hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: all var(--transition);
}

/* ─── BOTONES ────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition);
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
  user-select: none;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.btn--primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 2px 12px var(--accent-glow);
}

.btn--primary:hover {
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  box-shadow: var(--shadow-accent);
  transform: translateY(-1px);
  color: #fff;
}

.btn--outline {
  background: transparent;
  color: var(--text-primary);
  border-color: var(--border-light);
}

.btn--outline:hover {
  background: var(--bg-card);
  border-color: var(--border-accent);
  color: var(--text-primary);
}

.btn--ghost {
  background: transparent;
  color: var(--text-secondary);
  border-color: transparent;
}

.btn--ghost:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}

.btn--danger {
  background: var(--red-bg);
  color: var(--red);
  border-color: rgba(239, 68, 68, 0.3);
}

.btn--danger:hover {
  background: var(--red);
  color: #fff;
}

.btn--success {
  background: var(--green-bg);
  color: var(--green);
  border-color: rgba(34, 197, 94, 0.3);
}

.btn--success:hover {
  background: var(--green);
  color: #fff;
}

.btn--sm {
  padding: 6px 14px;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
  gap: 5px;
}

.btn--lg {
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: var(--radius-lg);
  gap: 9px;
}

.btn--full { width: 100%; }

.btn--icon {
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: var(--radius);
}

/* ─── TARJETAS ───────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition);
}

.card:hover {
  border-color: var(--border-light);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card__image {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: var(--bg-secondary);
}

.card__image--portrait { aspect-ratio: 3/4; }

.card__body {
  padding: 16px;
}

.card__footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

/* Tarjeta de caso */
.case-card {
  position: relative;
  cursor: pointer;
}

.case-card__photo-wrap {
  position: relative;
  aspect-ratio: 4/3;
  overflow: hidden;
  background: var(--bg-secondary);
}

.case-card__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.case-card:hover .case-card__photo {
  transform: scale(1.04);
}

.case-card__status-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
}

.case-card__save {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 32px;
  height: 32px;
  background: rgba(7, 16, 31, 0.7);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  transition: all var(--transition);
  font-size: 0.9rem;
}

.case-card__save:hover { color: var(--red); border-color: var(--red); }

.case-card__time {
  position: absolute;
  bottom: 8px;
  right: 10px;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.8);
  background: rgba(0,0,0,0.55);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  backdrop-filter: blur(4px);
}

.case-card__body {
  padding: 14px;
}

.case-card__name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
  font-family: var(--font-display);
}

.case-card__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.case-card__meta i { opacity: 0.7; }

.case-card__location {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 12px;
}

.case-card__actions {
  display: flex;
  gap: 6px;
}

/* ─── BADGES ─────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.73rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.badge--lost {
  background: var(--red-bg);
  color: var(--red);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.badge--found {
  background: var(--blue-bg);
  color: var(--blue);
  border: 1px solid rgba(59, 130, 246, 0.25);
}

.badge--sighting {
  background: var(--yellow-bg);
  color: var(--yellow);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge--reunited {
  background: rgba(168, 85, 247, 0.12);
  color: var(--purple);
  border: 1px solid rgba(168, 85, 247, 0.25);
}

.badge--active {
  background: var(--green-bg);
  color: var(--green);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.badge--pending {
  background: var(--yellow-bg);
  color: var(--yellow);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.badge--dog   { background: rgba(59,130,246,0.1);  color: #60a5fa; }
.badge--cat   { background: rgba(168,85,247,0.1);  color: #c084fc; }
.badge--other { background: rgba(34,197,94,0.1);   color: #4ade80; }

/* ─── FORMULARIOS ────────────────────────────────────────── */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 7px;
  letter-spacing: 0.01em;
}

.form-label .required {
  color: var(--red);
  margin-left: 3px;
}

.form-control {
  width: 100%;
  padding: 11px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 0.9rem;
  transition: all var(--transition);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.form-control::placeholder { color: var(--text-muted); }

.form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
  background: var(--bg-secondary);
}

.form-control:invalid:not(:placeholder-shown) {
  border-color: var(--red);
}

textarea.form-control {
  resize: vertical;
  min-height: 100px;
}

select.form-control {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238faec8' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  cursor: pointer;
}

.form-text {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 5px;
}

.form-error {
  font-size: 0.78rem;
  color: var(--red);
  margin-top: 5px;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Radio y Checkbox personalizados */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
}

.form-check input[type="checkbox"],
.form-check input[type="radio"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  accent-color: var(--accent);
  cursor: pointer;
  margin-top: 1px;
}

/* ─── OPTION CARDS (para "perdí/encontré/vi") ───────────── */
.option-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.option-card {
  padding: 24px 20px;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  color: var(--text-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  position: relative;
  overflow: hidden;
}

.option-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent, rgba(249,115,22,0.03));
  opacity: 0;
  transition: opacity var(--transition);
}

.option-card:hover::before { opacity: 1; }

.option-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-accent);
  transform: translateY(-3px);
  color: var(--text-primary);
}

.option-card.selected,
.option-card input:checked ~ & {
  border-color: var(--accent);
  background: rgba(249,115,22,0.06);
}

.option-card__icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin: 0 auto;
}

.option-card__icon--red    { background: var(--red-bg); }
.option-card__icon--blue   { background: var(--blue-bg); }
.option-card__icon--yellow { background: var(--yellow-bg); }
.option-card__icon--green  { background: var(--green-bg); }

.option-card__title {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
}

.option-card__desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.option-card__priority {
  font-size: 0.72rem;
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ─── HERO SECTION ───────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  padding: 80px 0 60px;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(249,115,22,0.08) 0%, transparent 70%),
              radial-gradient(ellipse 50% 40% at 80% 100%, rgba(59,130,246,0.05) 0%, transparent 60%);
}

.hero__bg-grid {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(249,115,22,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(249,115,22,0.03) 1px, transparent 1px);
  background-size: 50px 50px;
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 780px;
  margin: 0 auto;
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px;
  background: rgba(249,115,22,0.1);
  border: 1px solid rgba(249,115,22,0.2);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.hero__title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.hero__title span {
  color: var(--accent);
  position: relative;
}

.hero__subtitle {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 40px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 20px;
}

.hero__stats {
  display: flex;
  gap: 32px;
  justify-content: center;
  margin-top: 48px;
  flex-wrap: wrap;
}

.hero__stat {
  text-align: center;
}

.hero__stat-number {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.hero__stat-number span { color: var(--accent); }

.hero__stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* ─── SECCIÓN ACCIONES PRINCIPALES ──────────────────────── */
.action-section {
  padding: 60px 0;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.section-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 32px;
  line-height: 1.6;
}

/* ─── GRID DE CASOS ──────────────────────────────────────── */
.cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

/* ─── MAPA ───────────────────────────────────────────────── */
.map-container {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
}

.map-container .leaflet-container {
  background: var(--bg-secondary) !important;
}

.map-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.map-legend {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.map-legend__item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.map-legend__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ─── TIMELINE ───────────────────────────────────────────── */
.timeline {
  position: relative;
  padding-left: 28px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 9px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), var(--border));
}

.timeline__item {
  position: relative;
  padding-bottom: 20px;
}

.timeline__item:last-child { padding-bottom: 0; }

.timeline__dot {
  position: absolute;
  left: -24px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--border-light);
}

.timeline__item--active .timeline__dot {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
}

.timeline__item--reunited .timeline__dot {
  background: var(--purple);
  border-color: var(--purple);
}

.timeline__time {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.timeline__text {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ─── ALERT / NOTIF ──────────────────────────────────────── */
.alert {
  padding: 14px 16px;
  border-radius: var(--radius);
  font-size: 0.875rem;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  border: 1px solid transparent;
  margin-bottom: 16px;
}

.alert i { margin-top: 1px; flex-shrink: 0; }

.alert--success {
  background: var(--green-bg);
  color: var(--green);
  border-color: rgba(34, 197, 94, 0.2);
}

.alert--error {
  background: var(--red-bg);
  color: var(--red);
  border-color: rgba(239, 68, 68, 0.2);
}

.alert--warning {
  background: var(--yellow-bg);
  color: var(--yellow);
  border-color: rgba(245, 158, 11, 0.2);
}

.alert--info {
  background: var(--blue-bg);
  color: var(--blue);
  border-color: rgba(59, 130, 246, 0.2);
}

/* ─── STATS CARDS ────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all var(--transition);
}

.stat-card:hover {
  border-color: var(--border-light);
  transform: translateY(-2px);
}

.stat-card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

.stat-card__icon--orange { background: var(--accent-glow); color: var(--accent); }
.stat-card__icon--green  { background: var(--green-bg);    color: var(--green); }
.stat-card__icon--blue   { background: var(--blue-bg);     color: var(--blue); }
.stat-card__icon--purple { background: var(--purple-bg);   color: var(--purple); }

.stat-card__value {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.stat-card__label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ─── BREADCRUMBS ────────────────────────────────────────── */
.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
  flex-wrap: wrap;
  padding: 12px 0;
}

.breadcrumbs a {
  color: var(--text-muted);
  transition: color var(--transition);
}

.breadcrumbs a:hover { color: var(--text-secondary); }

.breadcrumbs__sep { opacity: 0.4; font-size: 0.7rem; }

.breadcrumbs__current { color: var(--text-secondary); }

/* ─── PROVINCIA CARD ─────────────────────────────────────── */
.province-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: all var(--transition);
  text-decoration: none;
  color: var(--text-primary);
  position: relative;
  overflow: hidden;
}

.province-card:hover {
  border-color: var(--border-light);
  background: var(--bg-card-hover);
  transform: translateY(-1px);
  color: var(--text-primary);
}

.province-card--coming-soon {
  opacity: 0.6;
}

.province-card--coming-soon::after {
  content: 'Próximamente';
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 0.65rem;
  color: var(--text-muted);
  background: var(--bg-secondary);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
}

.province-card__emoji {
  font-size: 1.8rem;
  flex-shrink: 0;
}

.province-card__name {
  font-weight: 700;
  font-size: 0.95rem;
}

.province-card__count {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ─── REUNION CARD ───────────────────────────────────────── */
.reunion-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition);
  position: relative;
}

.reunion-card:hover {
  border-color: rgba(168,85,247,0.3);
  box-shadow: 0 4px 20px rgba(168,85,247,0.1);
  transform: translateY(-2px);
}

.reunion-card__photo {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
}

.reunion-card__heart {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 32px;
  height: 32px;
  background: rgba(168,85,247,0.8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: white;
}

.reunion-card__body {
  padding: 16px;
}

.reunion-card__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 6px;
}

.reunion-card__meta {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.reunion-card__story {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ─── CÓMO FUNCIONA ──────────────────────────────────────── */
.how-it-works {
  padding: 60px 0;
  background: linear-gradient(180deg, transparent, rgba(249,115,22,0.02), transparent);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  position: relative;
}

.step-card {
  text-align: center;
  padding: 28px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  position: relative;
}

.step-card__num {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  width: 28px;
  height: 28px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
  color: white;
  box-shadow: 0 2px 8px var(--accent-glow);
}

.step-card__icon {
  font-size: 2rem;
  margin: 10px 0 14px;
}

.step-card__title {
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 8px;
  font-family: var(--font-display);
}

.step-card__desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ─── TABS ───────────────────────────────────────────────── */
.tabs {
  display: flex;
  gap: 4px;
  background: var(--bg-secondary);
  padding: 4px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  flex-wrap: wrap;
}

.tab {
  padding: 8px 18px;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  border: none;
  background: none;
  transition: all var(--transition);
  white-space: nowrap;
}

.tab:hover { color: var(--text-secondary); background: var(--bg-card); }

.tab.active {
  background: var(--bg-card-2);
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
  font-weight: 600;
}

.tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 18px;
  padding: 0 5px;
  background: var(--bg-overlay);
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 700;
  margin-left: 5px;
}

/* ─── FOOTER ─────────────────────────────────────────────── */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 48px 0 24px;
  margin-top: auto;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}

.footer__brand-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer__brand-desc {
  font-size: 0.83rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
}

.footer__social {
  display: flex;
  gap: 8px;
}

.footer__social-link {
  width: 34px;
  height: 34px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  transition: all var(--transition);
}

.footer__social-link:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

.footer__col-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer__link {
  font-size: 0.83rem;
  color: var(--text-muted);
  transition: color var(--transition);
}

.footer__link:hover { color: var(--text-secondary); }

.footer__bottom {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.footer__copy {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.footer__bottom-links {
  display: flex;
  gap: 16px;
}

.footer__bottom-link {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* ─── LOADING / SPINNER ──────────────────────────────────── */
.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.spinner--sm {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-overlay {
  position: absolute;
  inset: 0;
  background: var(--bg-overlay);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: inherit;
  z-index: 10;
  backdrop-filter: blur(4px);
}

/* ─── MODAL ──────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(6px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  transform: translateY(16px);
  transition: transform var(--transition);
  box-shadow: var(--shadow-lg);
}

.modal-overlay.open .modal { transform: translateY(0); }

.modal__header {
  padding: 20px 24px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.modal__title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
}

.modal__close {
  width: 32px;
  height: 32px;
  border-radius: var(--radius);
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.modal__close:hover {
  background: var(--red-bg);
  color: var(--red);
  border-color: rgba(239,68,68,0.3);
}

.modal__body { padding: 20px 24px; }

.modal__footer {
  padding: 16px 24px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

/* ─── MAPA POPUP ─────────────────────────────────────────── */
.leaflet-popup-content-wrapper {
  background: var(--bg-card) !important;
  border: 1px solid var(--border-light) !important;
  border-radius: var(--radius-lg) !important;
  box-shadow: var(--shadow-lg) !important;
  color: var(--text-primary) !important;
}

.leaflet-popup-tip {
  background: var(--bg-card) !important;
}

/* ─── UTILIDADES ─────────────────────────────────────────── */
.text-muted   { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-accent  { color: var(--accent); }
.text-success { color: var(--green); }
.text-danger  { color: var(--red); }
.text-warning { color: var(--yellow); }

.font-display { font-family: var(--font-display); }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }

.text-sm  { font-size: 0.85rem; }
.text-xs  { font-size: 0.75rem; }
.text-lg  { font-size: 1.1rem; }
.text-xl  { font-size: 1.25rem; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.flex-wrap { flex-wrap: wrap; }

.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mt-8 { margin-top: 32px; }
.mb-2 { margin-bottom: 8px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.mb-8 { margin-bottom: 32px; }

.p-4 { padding: 16px; }
.p-6 { padding: 24px; }

.w-full { width: 100%; }
.hidden { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 24px 0;
}

.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ─── ANIMACIONES ────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.5; }
}

@keyframes shimmer {
  from { background-position: -200% 0; }
  to   { background-position: 200% 0; }
}

.animate-fadeInUp {
  animation: fadeInUp 0.4s ease forwards;
}

.skeleton {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-2) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius);
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 rgba(34,197,94,0.6);
  animation: livePulse 1.5s ease-out infinite;
}

@keyframes livePulse {
  0%   { box-shadow: 0 0 0 0 rgba(34,197,94,0.6); }
  70%  { box-shadow: 0 0 0 6px rgba(34,197,94,0); }
  100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); }
}

/* ─── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 1024px) {
  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .navbar__nav { display: none; }
  .navbar__search { display: none; }
  .navbar__hamburger { display: flex; }
  
  .navbar__nav.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-primary);
    border-top: 1px solid var(--border);
    padding: 20px;
    gap: 8px;
    overflow-y: auto;
    z-index: 999;
  }

  .navbar__link {
    padding: 12px 16px;
    font-size: 1rem;
  }

  .hero { padding: 48px 0 40px; }

  .hero__stats { gap: 20px; }

  .footer__grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .cases-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }

  .option-cards {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .container { padding: 0 14px; }
  .hero__ctas { flex-direction: column; align-items: stretch; }
  .hero__ctas .btn { justify-content: center; }
  .cases-grid { grid-template-columns: 1fr 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .btn--lg { padding: 12px 20px; font-size: 0.9rem; }
  .modal { border-radius: var(--radius-lg); }
}
