/* Homepage visual system: brand-forward, compact and responsive. */
body.home-page {
  --home-ink: #263746;
  --home-muted: #665f55;
  --home-green: #27ae60;
  --home-green-deep: #1f8d50;
  --home-navy: #2c3e50;
  --home-coral: #e07a45;
  --home-cream: #faf6f0;
  --home-border: #e6dccb;
  --home-shadow: 0 14px 34px rgba(74, 58, 38, 0.10);
  background: var(--home-cream);
  color: var(--home-ink);
}

body.home-page .home-hero {
  position: relative;
  overflow: hidden;
  padding: 24px 20px 64px;
  color: var(--home-ink);
  text-align: left;
  background:
    radial-gradient(circle at 8% 18%, rgba(224, 122, 69, 0.10), transparent 24%),
    radial-gradient(circle at 92% 6%, rgba(39, 174, 96, 0.14), transparent 26%),
    linear-gradient(135deg, #fffaf3 0%, #f7f0e4 58%, #edf8f1 100%);
}

body.home-page .home-hero::before {
  content: "";
  position: absolute;
  inset: auto auto -90px -70px;
  width: 240px;
  height: 240px;
  border: 34px solid rgba(39, 174, 96, 0.06);
  border-radius: 50%;
  pointer-events: none;
}

body.home-page .home-hero-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(390px, 0.96fr);
  gap: clamp(28px, 4vw, 58px);
  align-items: center;
  width: min(1120px, 100%);
  margin: 0 auto;
}

body.home-page .home-hero-copy {
  min-width: 0;
}

body.home-page .home-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--home-navy);
  text-decoration: none;
}

body.home-page .home-brand-mark {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  color: #fff;
  background: linear-gradient(145deg, #35bd72, #218f50);
  border: 3px solid rgba(255, 255, 255, 0.92);
  border-radius: 15px 15px 20px 15px;
  box-shadow: 0 8px 18px rgba(39, 174, 96, 0.22);
  transform: rotate(-2deg);
}

body.home-page .home-brand-mark::after {
  content: "";
  position: absolute;
  right: -4px;
  top: -4px;
  width: 12px;
  height: 12px;
  background: var(--home-coral);
  border: 2px solid #fffaf3;
  border-radius: 50%;
}

body.home-page .home-brand-mark svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.home-page .home-brand-name {
  display: grid;
  gap: 1px;
  line-height: 1.15;
}

body.home-page .home-brand-name strong {
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

body.home-page .home-brand-name small {
  color: #56806a;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

body.home-page .home-hero-kicker {
  position: relative;
  z-index: 1;
  width: fit-content;
  margin: 24px 0 10px;
  padding: 5px 12px;
  color: #1e7043;
  background: #e9f7ee;
  border: 1px solid #cce9d6;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}

body.home-page .home-hero h1 {
  position: relative;
  z-index: 1;
  max-width: 650px;
  margin: 0;
  color: var(--home-navy);
  font-size: clamp(1.95rem, 2.75vw, 2.45rem);
  font-weight: 900;
  line-height: 1.32;
  letter-spacing: -0.005em;
  text-shadow: none;
}

body.home-page .hero-title-break {
  display: block;
}

body.home-page .home-hero-lead {
  position: relative;
  z-index: 1;
  max-width: 610px;
  margin: 15px 0 0;
  color: var(--home-muted);
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.8;
}

body.home-page .home-hero-visual {
  position: relative;
  min-width: 0;
  height: 330px;
  margin: 0;
  overflow: hidden;
  background: #fff9ed;
  border: 1px solid rgba(214, 195, 164, 0.68);
  border-radius: 32px 32px 84px 32px;
  box-shadow: 0 22px 44px rgba(74, 58, 38, 0.14);
  transform: rotate(1deg);
}

body.home-page .home-hero-visual::after {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 24px 24px 70px 24px;
  pointer-events: none;
}

body.home-page .home-hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 72% center;
}

body.home-page .header-nav {
  position: relative;
  z-index: 1;
  justify-content: flex-start;
  margin-top: 22px;
  gap: 8px;
}

body.home-page .header-nav a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 38px;
  padding: 7px 13px;
  color: #3d3a34;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid #ded2bf;
  border-radius: 999px;
  box-shadow: 0 4px 12px rgba(83, 68, 46, 0.06);
  backdrop-filter: blur(6px);
}

body.home-page .header-nav a:hover {
  color: #176f41;
  background: #fff;
  border-color: #9ed8b5;
  box-shadow: 0 7px 16px rgba(39, 174, 96, 0.12);
}

body.home-page .top-search {
  position: relative;
  z-index: 4;
  width: 100%;
  margin: -34px auto 0;
  padding: 0 16px 8px;
  background: transparent;
  border: 0;
  box-shadow: none;
}

body.home-page .top-search-inner {
  max-width: 940px;
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid #dfd4c3;
  border-radius: 20px;
  box-shadow: var(--home-shadow);
  backdrop-filter: blur(12px);
}

body.home-page .top-search h2 {
  margin: 0 0 8px;
  color: var(--home-navy);
  font-size: 1.03rem;
}

body.home-page .top-search-form {
  grid-template-columns: minmax(0, 1fr) 124px;
  gap: 10px;
}

body.home-page .top-search-input {
  height: 50px;
  color: var(--home-ink);
  background: #fff;
  border: 1.5px solid #d6c8b4;
  border-radius: 13px;
  padding: 9px 16px;
  font-weight: 600;
}

body.home-page .top-search-button {
  height: 50px;
  background: linear-gradient(135deg, #31b96d, #218f50);
  border-radius: 13px;
  box-shadow: 0 7px 16px rgba(39, 174, 96, 0.25);
}

body.home-page .trust-summary {
  max-width: 880px;
  margin: 8px auto 12px;
  gap: 10px;
}

body.home-page .trust-item {
  padding: 12px 13px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid #e1d6c6;
  border-top: 3px solid #43b87a;
  border-radius: 15px;
  box-shadow: 0 7px 18px rgba(83, 68, 46, 0.08);
}

body.home-page .hero-assurance {
  margin: 2px auto 10px;
}

body.home-page .hero-assurance span {
  color: #4f5d54;
  background: #fff;
  border-color: #dfd4c3;
}

body.home-page .site-promo-note {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  width: calc(100% - 32px);
  max-width: 848px;
  margin: 0 auto 14px;
  padding: 9px 13px;
  color: #594a36;
  background: #fffaf0;
  border: 1px solid #eadabd;
  border-left: 4px solid #d9902e;
  border-radius: 11px;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.65;
  text-align: left;
}

body.home-page .site-promo-label {
  flex: 0 0 auto;
  margin-top: 1px;
  padding: 1px 7px;
  color: #8a4a1f;
  background: #ffedcf;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 900;
  white-space: nowrap;
}

body.home-page .conversion-panel {
  margin-top: 0;
}

body.home-page main {
  width: min(880px, calc(100% - 32px));
}

body.home-page .home-section {
  --section-accent: var(--home-green);
  position: relative;
  overflow: hidden;
  border-color: rgba(205, 190, 168, 0.58);
  box-shadow: 0 10px 24px rgba(82, 65, 43, 0.07);
}

body.home-page .home-section::after {
  content: "";
  position: absolute;
  z-index: 0;
  top: -38px;
  right: -34px;
  width: 112px;
  height: 112px;
  border: 22px solid color-mix(in srgb, var(--section-accent) 10%, transparent);
  border-radius: 50%;
  pointer-events: none;
}

body.home-page .home-section > * {
  position: relative;
  z-index: 1;
}

body.home-page .home-section h2,
body.home-page .home-section--featured .home-section-head h2 {
  border-left-color: var(--section-accent);
}

body.home-page .home-section--featured {
  --section-accent: #27ae60;
  background: #fff;
}

body.home-page .home-section--categories {
  --section-accent: #e07a45;
  background: linear-gradient(145deg, #fffdf9, #fff6ec);
}

body.home-page .home-section--rankings {
  --section-accent: #3a78b8;
  background: linear-gradient(145deg, #fbfdff, #eff6fd);
}

body.home-page .home-section--keywords {
  --section-accent: #2d9c73;
  background: linear-gradient(145deg, #fbfffc, #edf9f2);
}

body.home-page .home-section--municipalities {
  --section-accent: #d99a32;
  background: linear-gradient(145deg, #fffefa, #fff8e9);
}

body.home-page .home-section--guides {
  --section-accent: #7b68b4;
  background: linear-gradient(145deg, #fefeff, #f3f0fb);
}

body.home-page .home-section--rules {
  --section-accent: #66737f;
  background: #f8faf9;
}

body.home-page .home-section--categories .discovery-chip,
body.home-page .home-section--rankings .popular-ranking-card,
body.home-page .home-section--keywords .discovery-chip,
body.home-page .home-section--municipalities .municipality-chip,
body.home-page .home-section--guides .discovery-chip {
  background: rgba(255, 255, 255, 0.90);
  border-color: color-mix(in srgb, var(--section-accent) 24%, #ded7cd);
}

body.home-page .home-section--rankings .popular-ranking-card {
  border-radius: 15px;
  box-shadow: 0 5px 14px rgba(58, 120, 184, 0.08);
}

body.home-page .home-section--guides .discovery-chip.priority {
  color: #514482;
  background: rgba(255, 255, 255, 0.92);
  border-color: #d5cdef;
}

body.home-page .home-section--rules .rule-grid > div {
  background: #fff;
  border-color: #dfe5e1;
}

body.home-page .home-item-cta {
  background: linear-gradient(135deg, #258fd8, #1478bf);
}

body.home-page a:focus-visible,
body.home-page button:focus-visible,
body.home-page input:focus-visible,
body.home-page summary:focus-visible {
  outline: 3px solid rgba(39, 174, 96, 0.34);
  outline-offset: 3px;
}

@media (max-width: 900px) {
  body.home-page .home-hero-shell {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
    gap: 24px;
  }

  body.home-page .home-hero-visual {
    height: 290px;
  }

  body.home-page .home-hero h1 {
    font-size: 2rem;
  }
}

@media (max-width: 820px) {
  body.home-page .home-hero-shell {
    display: block;
  }

  body.home-page .home-hero-copy {
    max-width: 680px;
    margin: 0 auto;
  }

  body.home-page .home-hero-visual {
    display: none;
  }
}

@media (max-width: 700px) {
  body.home-page .home-hero {
    padding: 16px 14px 42px;
  }

  body.home-page .home-hero-shell {
    display: block;
  }

  body.home-page .home-hero-visual {
    display: none;
  }

  body.home-page .home-brand-mark {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
    border-radius: 12px 12px 16px 12px;
  }

  body.home-page .home-brand-mark svg {
    width: 21px;
    height: 21px;
  }

  body.home-page .home-brand-name strong {
    font-size: 0.9rem;
  }

  body.home-page .home-brand-name small {
    font-size: 0.64rem;
  }

  body.home-page .home-hero-kicker {
    margin: 14px 0 7px;
    padding: 4px 9px;
    font-size: 0.68rem;
  }

  body.home-page .home-hero h1 {
    max-width: 350px;
    font-size: 1.48rem;
    line-height: 1.34;
  }

  body.home-page .hero-title-break {
    display: block;
  }

  body.home-page .home-hero-lead {
    max-width: 340px;
    margin-top: 9px;
    font-size: 0.82rem;
    line-height: 1.65;
  }

  body.home-page .header-nav {
    flex-wrap: nowrap;
    justify-content: flex-start;
    width: calc(100vw - 28px);
    max-width: none;
    margin-top: 13px;
    padding: 0 0 4px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  body.home-page .header-nav::-webkit-scrollbar {
    display: none;
  }

  body.home-page .header-nav a {
    flex: 0 0 auto;
    min-height: 34px;
    padding: 6px 10px;
    font-size: 0.72rem;
    white-space: nowrap;
  }

  body.home-page .top-search {
    margin-top: -24px;
    padding: 0 14px 6px;
  }

  body.home-page .top-search-inner {
    padding: 12px;
    border-radius: 16px;
  }

  body.home-page .top-search h2 {
    margin-bottom: 6px;
    font-size: 0.92rem;
  }

  body.home-page .top-search-form {
    grid-template-columns: minmax(0, 1fr) 86px;
    gap: 7px;
  }

  body.home-page .top-search-input,
  body.home-page .top-search-button {
    height: 44px;
  }

  body.home-page .top-search-input {
    min-width: 0;
    padding: 8px 11px;
    font-size: 0.84rem;
  }

  body.home-page .top-search-button {
    font-size: 0.86rem;
  }

  body.home-page .trust-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 4px auto 8px;
    padding: 0 14px;
    gap: 8px;
  }

  body.home-page .trust-item {
    min-height: 60px;
    padding: 8px 7px;
    border-radius: 13px;
  }

  body.home-page .trust-label {
    margin-bottom: 1px;
    font-size: 0.63rem;
  }

  body.home-page .trust-value {
    font-size: 0.94rem;
  }

  body.home-page .hero-assurance {
    margin: 0 auto 8px;
    padding: 0 14px;
    gap: 5px;
  }

  body.home-page .hero-assurance span {
    padding: 3px 8px;
    font-size: 0.66rem;
  }

  body.home-page .site-promo-note {
    display: block;
    width: calc(100% - 28px);
    margin-bottom: 10px;
    padding: 8px 10px;
    font-size: 0.70rem;
    line-height: 1.55;
  }

  body.home-page .site-promo-label {
    display: inline-block;
    margin: 0 7px 2px 0;
  }

  body.home-page .conversion-panel {
    padding: 0 14px;
  }

  body.home-page .conversion-panel-inner {
    padding: 13px;
  }

  body.home-page .conversion-panel h2 {
    margin-bottom: 9px;
    font-size: 0.96rem;
  }

  body.home-page .conversion-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
  }

  body.home-page .conversion-link,
  body.home-page .conversion-link.featured {
    grid-column: span 1;
    min-height: 61px;
    padding: 8px 7px 8px 38px;
    border-radius: 12px;
    font-size: 0.74rem;
    line-height: 1.45;
  }

  body.home-page .conversion-link.featured {
    grid-column: 1 / -1;
    min-height: 52px;
  }

  body.home-page .conversion-icon {
    left: 8px;
    width: 23px;
    height: 23px;
  }

  body.home-page main {
    display: block;
    width: calc(100% - 28px);
  }

  body.home-page .home-section {
    margin-bottom: 12px;
    padding: 14px 12px;
    border-radius: 16px;
  }

  body.home-page .home-section::after {
    width: 88px;
    height: 88px;
    border-width: 17px;
  }

  body.home-page .home-item-card {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    padding: 12px;
  }

  body.home-page .home-item-image {
    min-height: 0;
    height: 214px;
    aspect-ratio: auto;
  }

  body.home-page .home-item-body {
    gap: 9px;
  }

  body.home-page .home-item-title {
    font-size: 0.92rem;
    line-height: 1.55;
  }

  body.home-page .home-item-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  body.home-page .home-item-stats > div,
  body.home-page .home-item-stats .home-item-rate {
    min-width: 0;
    min-height: 64px;
    padding: 8px 9px;
  }

  body.home-page .home-item-actions {
    width: 100%;
  }

  body.home-page .home-item-cta {
    width: 100%;
    min-height: 43px;
    justify-content: center;
  }

  body.home-page .home-section--categories .discovery-grid,
  body.home-page .home-section--keywords .discovery-grid,
  body.home-page .home-section--guides .discovery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
  }

  body.home-page .home-section--categories .discovery-chip,
  body.home-page .home-section--keywords .discovery-chip,
  body.home-page .home-section--guides .discovery-chip {
    min-height: 39px;
    padding: 7px 9px;
    border-radius: 12px;
    font-size: 0.74rem;
    line-height: 1.35;
  }
}

@media (max-width: 380px) {
  body.home-page .home-hero h1 {
    font-size: 1.38rem;
  }

  body.home-page .top-search-form {
    grid-template-columns: minmax(0, 1fr) 80px;
  }

  body.home-page .home-item-image {
    height: 200px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.home-page .home-hero-visual {
    transform: none;
  }
}
