/* =========================================================
   Jess 41 — Choisis ton dîner
   Mobile-first, premium, romantic Asian night
   ========================================================= */

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

:root {
  --bg: #0a0612;
  --bg-deep: #06030c;
  --bg-elevated: #14101e;
  --rose: #f4b8c4;
  --rose-deep: #e899ad;
  --gold: #d4af7a;
  --gold-soft: #e6cba0;
  --cream: #f5ede4;
  --muted: rgba(245, 237, 228, 0.62);
  --muted-soft: rgba(245, 237, 228, 0.42);
  --border: rgba(245, 237, 228, 0.09);
  --border-strong: rgba(245, 237, 228, 0.18);
  --shadow-card: 0 30px 60px -25px rgba(0, 0, 0, 0.75), 0 8px 24px -12px rgba(0, 0, 0, 0.5);
  --shadow-modal: 0 -30px 80px -10px rgba(0, 0, 0, 0.8);
  --radius: 32px;
  --radius-sm: 20px;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --font-display: 'Cormorant Garamond', 'Hoefler Text', 'Didot', Georgia, 'Times New Roman', serif;
  --font-body: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Inter', 'Helvetica Neue', system-ui, sans-serif;
}

html,
body {
  background: var(--bg-deep);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
}

body {
  background:
    radial-gradient(ellipse 90% 55% at 25% -5%, rgba(244, 184, 196, 0.18), transparent 55%),
    radial-gradient(ellipse 70% 45% at 110% 25%, rgba(212, 175, 122, 0.12), transparent 55%),
    radial-gradient(ellipse 100% 60% at 50% 110%, rgba(140, 70, 130, 0.22), transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 100%);
  background-attachment: fixed;
  min-height: 100dvh;
}

/* Subtle film grain layer */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.4 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.app {
  position: relative;
  z-index: 1;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 20px;
  padding-top: max(20px, env(safe-area-inset-top));
  padding-bottom: max(40px, env(safe-area-inset-bottom));
  padding-left: max(20px, env(safe-area-inset-left));
  padding-right: max(20px, env(safe-area-inset-right));
}

/* =============== HERO =============== */

.hero {
  padding: 36px 4px 32px;
  text-align: center;
  position: relative;
}

.hero__date {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 999px;
  background: rgba(245, 237, 228, 0.04);
  border: 1px solid var(--border);
  font-size: 11px;
  letter-spacing: 0.28em;
  color: var(--gold);
  text-transform: uppercase;
  font-weight: 500;
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(72px, 26vw, 112px);
  line-height: 0.95;
  margin: 26px 0 14px;
  letter-spacing: -0.025em;
  background: linear-gradient(180deg, #fff 0%, var(--rose) 55%, var(--gold) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.hero__title em {
  font-style: italic;
  font-weight: 400;
  display: inline-block;
  transform: translateY(-0.04em);
}

.hero__subtitle {
  font-size: 13px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--rose);
  margin: 0 0 22px;
  font-weight: 500;
}

.hero__text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--muted);
  max-width: 320px;
  margin: 0 auto 14px;
}

.hero__cities {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 16px;
  color: var(--gold-soft);
  letter-spacing: 0.06em;
  margin-top: 6px;
}

.hero__choice {
  margin-top: 28px;
  padding: 16px 24px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(244, 184, 196, 0.16), rgba(212, 175, 122, 0.14));
  border: 1px solid rgba(244, 184, 196, 0.28);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  box-shadow: 0 12px 40px -16px rgba(244, 184, 196, 0.3);
  animation: choiceIn 0.5s var(--ease);
}

.hero__choice-label {
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero__choice-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 500;
  color: var(--cream);
  letter-spacing: 0.01em;
}

.hero__choice-hint {
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 4px;
}

@keyframes choiceIn {
  from { opacity: 0; transform: translateY(8px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* =============== FILTERS =============== */

.filters {
  display: flex;
  gap: 8px;
  padding: 6px;
  margin: 8px -6px 28px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
}

.filters::-webkit-scrollbar { display: none; }

.filter {
  flex-shrink: 0;
  padding: 12px 22px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(245, 237, 228, 0.04);
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: transform 0.25s var(--ease), background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  -webkit-tap-highlight-color: transparent;
  scroll-snap-align: start;
}

.filter:hover {
  color: var(--cream);
  border-color: var(--border-strong);
}

.filter:active { transform: scale(0.95); }

.filter.is-active {
  background: linear-gradient(135deg, var(--rose), var(--gold));
  color: #1a0f20;
  border-color: transparent;
  font-weight: 600;
  box-shadow: 0 8px 24px -10px rgba(244, 184, 196, 0.5);
}

/* =============== MAP =============== */

.map-wrap {
  margin: 4px -4px 28px;
}

.map {
  height: 240px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-card);
  background: #0f0a18;
}

.map.is-empty {
  opacity: 0.35;
}

.map__legend {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 18px;
  margin-top: 14px;
  padding: 0 6px;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.map__legend .map__dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: middle;
  box-shadow: 0 0 0 2px rgba(245, 237, 228, 0.18);
}

.map__dot--ok { background: #b8e0bc; }
.map__dot--check { background: var(--gold-soft); }
.map__dot--no { background: var(--rose); }

/* Leaflet marker pin */
.map-marker__dot {
  display: block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(10, 6, 18, 0.85);
  box-shadow: 0 0 0 2px rgba(245, 237, 228, 0.35), 0 6px 14px -4px rgba(0, 0, 0, 0.6);
  transition: transform 0.2s var(--ease);
}

.map-marker.is-chosen .map-marker__dot {
  box-shadow: 0 0 0 3px var(--rose), 0 6px 14px -4px rgba(244, 184, 196, 0.6);
}

.map-marker.is-restricted {
  opacity: 0.45;
  transition: opacity 0.2s ease;
}

.map-marker.is-restricted:hover {
  opacity: 1;
}

.map-marker.is-restricted .map-marker__dot {
  transform: scale(0.78);
}

.map-marker:hover .map-marker__dot {
  transform: scale(1.2);
}

.map-marker.is-restricted:hover .map-marker__dot {
  transform: scale(1);
}

/* Leaflet popup theming */
.leaflet-popup-content-wrapper {
  background: var(--bg-elevated);
  color: var(--cream);
  border-radius: 18px;
  border: 1px solid var(--border-strong);
  box-shadow: 0 24px 50px -16px rgba(0, 0, 0, 0.8);
}

.leaflet-popup-tip {
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
}

.leaflet-popup-content {
  margin: 14px 16px;
  font-family: var(--font-body);
  line-height: 1.4;
}

.leaflet-container a.leaflet-popup-close-button {
  color: var(--muted);
}

.leaflet-control-attribution {
  background: rgba(10, 6, 18, 0.7) !important;
  color: var(--muted) !important;
  font-size: 9px !important;
}

.leaflet-control-attribution a {
  color: var(--gold-soft) !important;
}

.map-popup__city {
  font-size: 9px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 4px;
}

.map-popup__name {
  font-family: var(--font-display);
  font-size: 20px;
  line-height: 1.05;
  color: var(--cream);
  margin-bottom: 6px;
}

.map-popup__michelin {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-soft);
  margin-bottom: 6px;
}

.map-popup__family {
  display: inline-block;
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
  margin-bottom: 10px;
}

.map-popup__family[data-status="ok"] { background: rgba(176, 220, 180, 0.16); color: #b8e0bc; }
.map-popup__family[data-status="check"] { background: rgba(230, 203, 160, 0.16); color: var(--gold-soft); }
.map-popup__family[data-status="no"] { background: rgba(232, 153, 173, 0.16); color: var(--rose); }

.map-popup__action {
  display: block;
  margin-top: 6px;
  padding: 8px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: rgba(245, 237, 228, 0.05);
  color: var(--cream);
  font-family: inherit;
  font-size: 11px;
  letter-spacing: 0.08em;
  cursor: pointer;
  width: 100%;
  text-align: center;
  transition: background 0.2s ease;
}

.map-popup__action:hover {
  background: rgba(245, 237, 228, 0.12);
}

/* =============== GRID =============== */

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
}

/* =============== CARD =============== */

.card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-elevated);
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border);
  transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease), border-color 0.3s ease;
  isolation: isolate;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  animation: cardIn 0.6s var(--ease) backwards;
}

.card:nth-child(1) { animation-delay: 0s; }
.card:nth-child(2) { animation-delay: 0.07s; }
.card:nth-child(3) { animation-delay: 0.14s; }
.card:nth-child(4) { animation-delay: 0.21s; }
.card:nth-child(5) { animation-delay: 0.28s; }
.card:nth-child(6) { animation-delay: 0.35s; }

@keyframes cardIn {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (hover: hover) {
  .card:hover {
    transform: translateY(-4px);
    box-shadow: 0 40px 80px -25px rgba(0, 0, 0, 0.85), 0 12px 28px -10px rgba(0, 0, 0, 0.5);
  }
  .card:hover .card__image-inner {
    transform: scale(1.06);
  }
}

.card:active { transform: scale(0.985); }

.card.is-chosen {
  border-color: rgba(244, 184, 196, 0.55);
  box-shadow:
    0 0 0 1px rgba(244, 184, 196, 0.6),
    0 30px 70px -20px rgba(244, 184, 196, 0.25),
    var(--shadow-card);
}

/* Restos qui n'acceptent pas une enfant de 6 ans : visuellement en retrait,
   mais conservés pour info — hover / focus restaure pour inspection. */
.card.is-restricted {
  opacity: 0.5;
  transition: opacity 0.3s ease;
}

.card.is-restricted .card__image-inner {
  filter: grayscale(0.85) brightness(0.72);
  transition: filter 0.4s var(--ease);
}

.card.is-restricted .card__michelin {
  opacity: 0.7;
}

.card.is-restricted:hover,
.card.is-restricted:focus-within {
  opacity: 0.92;
}

@media (hover: hover) {
  .card.is-restricted:hover .card__image-inner {
    filter: grayscale(0.35) brightness(0.85);
  }
}

.card.is-restricted.is-chosen {
  opacity: 1;
}

.card.is-restricted.is-chosen .card__image-inner {
  filter: none;
}

.card__media {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: linear-gradient(135deg, #2a1a35, #1a0f20);
}

.card__image-inner {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.8s var(--ease);
}

.card__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
    rgba(10, 6, 18, 0.1) 0%,
    rgba(10, 6, 18, 0) 35%,
    rgba(10, 6, 18, 0.55) 65%,
    rgba(10, 6, 18, 0.96) 100%);
  pointer-events: none;
}

.card__city {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(10, 6, 18, 0.55);
  border: 1px solid rgba(245, 237, 228, 0.16);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cream);
  font-weight: 500;
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
}

.card__chosen-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 3;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--rose), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1a0f20;
  font-size: 17px;
  font-weight: 700;
  box-shadow: 0 8px 24px -6px rgba(244, 184, 196, 0.6);
  animation: badgePop 0.5s var(--ease);
}

.card__michelin {
  position: absolute;
  top: 60px;
  left: 18px;
  z-index: 2;
  padding: 6px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(212, 175, 122, 0.92), rgba(230, 203, 160, 0.92));
  border: 1px solid rgba(245, 237, 228, 0.25);
  color: #1a0f06;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  box-shadow: 0 8px 20px -10px rgba(212, 175, 122, 0.7);
}

.card__family {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  white-space: nowrap;
}

.card__family[data-status="ok"] {
  background: rgba(176, 220, 180, 0.14);
  color: #b8e0bc;
  border: 1px solid rgba(176, 220, 180, 0.32);
}

.card__family[data-status="check"] {
  background: rgba(230, 203, 160, 0.14);
  color: var(--gold-soft);
  border: 1px solid rgba(230, 203, 160, 0.32);
}

.card__family[data-status="no"] {
  background: rgba(232, 153, 173, 0.12);
  color: var(--rose);
  border: 1px solid rgba(232, 153, 173, 0.28);
}

.card__family-icon {
  font-size: 11px;
  font-weight: 700;
}

@keyframes badgePop {
  0% { transform: scale(0) rotate(-30deg); }
  60% { transform: scale(1.15) rotate(5deg); }
  100% { transform: scale(1) rotate(0); }
}

.card__content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: 24px 22px 22px;
}

.card__vibe {
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 10px;
  font-weight: 500;
}

.card__name {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 400;
  line-height: 1.02;
  margin-bottom: 8px;
  color: var(--cream);
  letter-spacing: -0.015em;
}

.card__description {
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-bottom: 18px;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.card__meta-item {
  display: inline-flex;
  align-items: center;
}

.card__actions {
  display: flex;
  gap: 10px;
}

/* =============== BUTTONS =============== */

.btn {
  flex: 1;
  padding: 13px 18px;
  border-radius: 999px;
  border: none;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.3s ease, background 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  min-height: 44px;
}

.btn:active { transform: scale(0.96); }

.btn--ghost {
  background: rgba(245, 237, 228, 0.07);
  color: var(--cream);
  border: 1px solid rgba(245, 237, 228, 0.14);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
}

.btn--ghost:hover {
  background: rgba(245, 237, 228, 0.12);
  border-color: rgba(245, 237, 228, 0.22);
}

.btn--primary {
  background: linear-gradient(135deg, var(--rose), var(--gold));
  color: #1a0f20;
  box-shadow: 0 10px 28px -10px rgba(244, 184, 196, 0.55);
  position: relative;
  overflow: hidden;
}

.btn--primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--rose-deep), var(--gold));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn--primary:hover::before { opacity: 1; }

.btn--primary > * { position: relative; z-index: 1; }

/* =============== MODAL =============== */

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
  animation: fadeIn 0.35s ease;
}

.modal__panel {
  position: relative;
  width: 100%;
  max-width: 480px;
  max-height: 94vh;
  background: linear-gradient(180deg, #1c1428 0%, #100a1a 100%);
  border-radius: 36px 36px 0 0;
  border: 1px solid var(--border);
  border-bottom: none;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  animation: slideUp 0.45s var(--ease);
  padding-bottom: max(28px, env(safe-area-inset-bottom));
  box-shadow: var(--shadow-modal);
}

.modal__handle {
  position: sticky;
  top: 0;
  width: 100%;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 4;
  pointer-events: none;
}

.modal__handle::after {
  content: '';
  width: 40px;
  height: 4px;
  border-radius: 999px;
  background: rgba(245, 237, 228, 0.25);
  margin-top: 8px;
}

.modal__close {
  position: absolute;
  top: 22px;
  right: 18px;
  z-index: 5;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(245, 237, 228, 0.16);
  background: rgba(10, 6, 18, 0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  color: var(--cream);
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s var(--ease), background 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  font-family: inherit;
}

.modal__close:active { transform: scale(0.92); }
.modal__close:hover { background: rgba(10, 6, 18, 0.75); }

.modal__image {
  width: 100%;
  aspect-ratio: 16 / 12;
  background-size: cover;
  background-position: center;
  background-color: #1a0f20;
  position: relative;
}

.modal__image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 6, 18, 0) 60%, rgba(28, 20, 40, 0.9) 100%);
}

.modal__body {
  padding: 24px 28px 8px;
  position: relative;
}

.modal__city {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
  font-weight: 500;
}

.modal__name {
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 400;
  line-height: 1;
  margin-bottom: 10px;
  letter-spacing: -0.018em;
  color: var(--cream);
}

.modal__vibe {
  font-size: 11px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 22px;
  font-weight: 500;
}

.modal__description {
  font-size: 15px;
  line-height: 1.7;
  color: var(--muted);
  margin-bottom: 24px;
}

.modal__family {
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  margin-bottom: 18px;
  background: rgba(245, 237, 228, 0.03);
}

.modal__family[data-status="ok"] {
  background: rgba(176, 220, 180, 0.08);
  border-color: rgba(176, 220, 180, 0.35);
}

.modal__family[data-status="check"] {
  background: rgba(230, 203, 160, 0.08);
  border-color: rgba(230, 203, 160, 0.35);
}

.modal__family[data-status="no"] {
  background: rgba(232, 153, 173, 0.07);
  border-color: rgba(232, 153, 173, 0.3);
}

.modal__family-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.modal__family-pill {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
}

.modal__family-pill[data-status="ok"] { background: rgba(176, 220, 180, 0.18); color: #b8e0bc; }
.modal__family-pill[data-status="check"] { background: rgba(230, 203, 160, 0.18); color: var(--gold-soft); }
.modal__family-pill[data-status="no"] { background: rgba(232, 153, 173, 0.16); color: var(--rose); }

.modal__family-title {
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.modal__family-note {
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
}

.modal__facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 18px;
  background: rgba(245, 237, 228, 0.04);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  margin-bottom: 22px;
}

.modal__facts > div {
  min-width: 0;
}

.modal__facts > .modal__facts-wide {
  grid-column: 1 / -1;
}

.modal__facts dt {
  font-size: 9px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted-soft);
  margin-bottom: 6px;
  font-weight: 500;
}

.modal__facts dd {
  font-size: 14px;
  color: var(--cream);
  font-weight: 500;
}

.modal__location {
  margin-bottom: 22px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  background: rgba(245, 237, 228, 0.04);
}

.modal__map {
  height: 180px;
  width: 100%;
  background: #0f0a18;
}

.modal__map .leaflet-control-container { display: none; }

.modal__address {
  margin: 0;
  padding: 14px 18px 16px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--cream);
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.modal__address::before {
  content: '◉';
  color: var(--gold);
  font-size: 12px;
  margin-top: 2px;
  flex-shrink: 0;
}

.modal__link {
  display: block;
  text-align: center;
  padding: 14px;
  border-radius: 999px;
  background: rgba(245, 237, 228, 0.05);
  border: 1px solid rgba(245, 237, 228, 0.14);
  color: var(--cream);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  margin-bottom: 12px;
  transition: transform 0.2s var(--ease), background 0.3s ease;
  -webkit-tap-highlight-color: transparent;
}

.modal__link:active { transform: scale(0.98); }
.modal__link:hover { background: rgba(245, 237, 228, 0.1); }

.modal__choose {
  width: 100%;
  padding: 17px;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* =============== FOOTER =============== */

.footer {
  text-align: center;
  margin-top: 56px;
  padding: 24px 20px;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--muted-soft);
}

/* =============== ANIMATIONS =============== */

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

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

@keyframes scaleIn {
  from { transform: scale(0.94) translateY(10px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}

[hidden] { display: none !important; }

/* =============== TIGHT SCREENS (Z Flip closed, narrow) =============== */

@media (max-width: 380px) {
  .app { padding-left: 16px; padding-right: 16px; }
  .hero { padding: 28px 0 26px; }
  .card__content { padding: 22px 20px 20px; }
  .card__name { font-size: 26px; }
  .modal__body { padding: 22px 22px 8px; }
  .modal__name { font-size: 36px; }
}

/* =============== DESKTOP / LARGE =============== */

@media (min-width: 720px) {
  .app { max-width: 940px; padding: 0 32px; padding-top: 32px; padding-bottom: 60px; }
  .hero { padding: 60px 0 48px; }
  .hero__title { font-size: clamp(96px, 11vw, 148px); }
  .hero__text { font-size: 16px; max-width: 480px; }
  .grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .map { height: 360px; }
  .card__media { aspect-ratio: 4 / 5; }
  .card__name { font-size: 32px; }

  .modal { align-items: center; padding: 24px; }
  .modal__panel {
    border-radius: 36px;
    border-bottom: 1px solid var(--border);
    animation: scaleIn 0.35s var(--ease);
    max-height: 88vh;
  }
  .modal__handle { display: none; }
  .modal__image { aspect-ratio: 16 / 9; }
  .modal__name { font-size: 46px; }
}

@media (min-width: 1024px) {
  .app { max-width: 1100px; }
  .hero__title { font-size: 156px; }
}

/* =============== ACCESSIBILITY =============== */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

button:focus-visible,
a:focus-visible,
.filter:focus-visible {
  outline: 2px solid var(--rose);
  outline-offset: 3px;
}
