:root {
  color-scheme: light;
  --bg: #f7f3ea;
  --surface: #fffaf0;
  --surface-strong: #ffffff;
  --text: #17201d;
  --muted: #637067;
  --line: #ded6c6;
  --accent: #0c7c77;
  --accent-strong: #075e5a;
  --accent-soft: #d9f1ed;
  --gold: #d89b23;
  --danger: #af3c3c;
  --shadow: 0 18px 45px rgba(38, 32, 22, 0.12);
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #101815;
  --surface: #15221e;
  --surface-strong: #1c2d28;
  --text: #f2f5ef;
  --muted: #adbbb2;
  --line: #31423c;
  --accent: #50d0be;
  --accent-strong: #7ae0d1;
  --accent-soft: #203c37;
  --gold: #f0bd52;
  --danger: #ff8f8f;
  --shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at top left, color-mix(in srgb, var(--accent) 18%, transparent), transparent 32rem),
    linear-gradient(180deg, var(--bg), color-mix(in srgb, var(--bg) 88%, var(--accent-soft)));
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

tel-app {
  display: block;
  min-height: 100vh;
}

.shell {
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 18px;
}

.hero {
  display: grid;
  gap: 18px;
  padding: 22px 0 18px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  display: grid;
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--gold));
  box-shadow: var(--shadow);
  color: #ffffff;
  font-size: 1.45rem;
  font-weight: 900;
}

.brand h1 {
  margin: 0;
  font-size: clamp(1.35rem, 6vw, 2.7rem);
  letter-spacing: 0;
  line-height: 1.05;
}

.brand p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--text);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.search-panel {
  display: grid;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.search-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.search-field {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 50px;
  flex: 1;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
}

.search-field span {
  color: var(--accent);
  font-size: 1.1rem;
}

.search-field input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
}

.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 0.9rem;
}

.stats a {
  color: var(--accent-strong);
  font-weight: 800;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.filter-group {
  display: grid;
  gap: 7px;
}

.filter-group.is-hidden {
  display: none;
}

.filter-label {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.chip-list {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
}

.chip {
  flex: 0 0 auto;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 13px;
  background: var(--surface-strong);
  color: var(--text);
  white-space: nowrap;
}

.chip[aria-pressed="true"] {
  border-color: color-mix(in srgb, var(--accent) 54%, var(--line));
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-weight: 700;
}

.notice {
  display: none;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid color-mix(in srgb, var(--gold) 55%, var(--line));
  border-radius: 8px;
  background: color-mix(in srgb, var(--gold) 12%, var(--surface));
  color: var(--text);
  font-size: 0.92rem;
}

.notice.is-visible {
  display: block;
}

.content {
  display: grid;
  gap: 18px;
  padding: 8px 0 36px;
}

.category {
  display: grid;
  gap: 14px;
}

.category-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px;
}

.category h2 {
  margin: 0;
  font-size: clamp(1.12rem, 4vw, 1.55rem);
}

.category-count {
  color: var(--muted);
  font-size: 0.9rem;
  white-space: nowrap;
}

.subcategory-listing {
  display: grid;
  gap: 16px;
}

.subcategory {
  display: grid;
  gap: 10px;
}

.subcategory-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 2px 0;
  border-top: 1px solid var(--line);
}

.subcategory:first-child .subcategory-header {
  border-top: 0;
  padding-top: 0;
}

.subcategory-header h3 {
  margin: 0;
  color: var(--accent-strong);
  font-size: 1rem;
}

.subcategory-header span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 0.83rem;
  font-weight: 900;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 12px;
}

.card {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 14px;
  min-height: 128px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.07);
}

.photo {
  width: 72px;
  height: 72px;
  overflow: hidden;
  border: 3px solid var(--accent-soft);
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-soft), color-mix(in srgb, var(--gold) 28%, var(--surface)));
}

.photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  color: var(--accent-strong);
  font-size: 1.35rem;
  font-weight: 900;
}

.card-body {
  min-width: 0;
}

.card h3 {
  margin: 0;
  font-size: 1.03rem;
  line-height: 1.2;
}

.description {
  margin: 3px 0 7px;
  color: var(--muted);
  font-size: 0.92rem;
}

.meta {
  display: grid;
  gap: 4px;
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.88rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0 12px;
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
}

.action svg {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  fill: currentColor;
}

.action.whatsapp {
  background: #148d52;
}

.action.instagram {
  background: linear-gradient(135deg, #7f35c9, #e13f7a 52%, #f2a33a);
}

.empty {
  padding: 28px 14px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 820px) {
  .shell {
    padding: 14px;
  }

  .hero {
    padding-top: 14px;
  }

  .hero.is-searching {
    gap: 8px;
    padding-top: 8px;
  }

  .hero.is-searching .topbar,
  .hero.is-searching .filter-group,
  .hero.is-searching .stats,
  .hero.is-searching .notice {
    display: none;
  }

  .hero.is-searching .search-panel {
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }

  .brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 14px;
  }

  .brand p {
    font-size: 0.86rem;
  }

  .search-panel {
    padding: 12px;
  }

  .search-row {
    align-items: stretch;
  }

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

  .card {
    grid-template-columns: 64px 1fr;
    gap: 12px;
    padding: 12px;
  }

  .photo {
    width: 64px;
    height: 64px;
  }
}
