/* ===== Base ===== */
.ld-root {
  --ld-primary: #1e64ff;
  --ld-primary-700: #0f4fd9;
  --ld-text: #0f172a;
  --ld-muted: #5b667a;
  --ld-surface: #ffffff;
  --ld-border: #e5eaf2;
  --ld-shadow: 0 14px 40px rgba(15, 23, 42, 0.12);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ld-text);
}
.ld-root * { box-sizing: border-box; }
.ld-root .ld-container { width: min(1240px, calc(100% - 32px)); margin: 0 auto; }
.ld-root .ld-section { padding: 24px 0; }
.ld-root .ld-section__head h2 { margin: 0 0 14px; font-size: 28px; }
.ld-root .ld-badge { display: none; }

.ld-root .ld-hero { position: relative; overflow: hidden; padding: 56px 0 28px; background: linear-gradient(108deg, #0c326f 8%, #1d63cb 55%, #2f81db 100%); }
.ld-root .ld-hero__overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(9, 28, 68, .55), rgba(10, 38, 95, .1) 45%, rgba(4, 20, 54, .5)); }
.ld-root .ld-decor { display: none; }
.ld-root .ld-hero__content { position: relative; z-index: 2; display: grid; gap: 18px; grid-template-columns: 1fr; align-items: end; }
.ld-root .ld-hero__left { position: relative; z-index: 2; }
.ld-root .ld-hero h1 { margin: 0 0 16px; color: #fff; font-size: clamp(36px, 5vw, 68px); line-height: 1.04; max-width: 620px; }
.ld-root .ld-hero p { margin: 0 0 20px; color: #e8f0ff; font-size: 33px; max-width: 620px; font-size: clamp(18px, 2vw, 35px); }
.ld-root .ld-search { display: grid; grid-template-columns: 1fr; gap: 10px; padding: 8px; border-radius: 12px; background: #fff; box-shadow: var(--ld-shadow); }
.ld-root .ld-search input, .ld-root .ld-search select, .ld-root .ld-search button { height: 54px; border-radius: 8px; font-size: 16px; }
.ld-root .ld-search input, .ld-root .ld-search select { border: 1px solid var(--ld-border); padding: 0 14px; }
.ld-root .ld-search button { border: 0; color: #fff; font-weight: 700; background: linear-gradient(90deg, var(--ld-primary), var(--ld-primary-700)); }

.ld-root .ld-hero__visual { min-height: 300px; border-radius: 16px; background-image: var(--ld-hero-bg); background-size: cover; background-position: center right; box-shadow: 0 18px 40px rgba(5, 16, 40, .42); }
.ld-root .ld-hero__stats { display: flex; flex-direction: column; gap: 18px; padding: 26px; border-radius: 18px; background: rgba(255,255,255,.11); border: 1px solid rgba(255,255,255,.2); backdrop-filter: blur(14px) saturate(160%); box-shadow: 0 8px 32px rgba(0,0,0,.18); }
.ld-root .ld-hero__stats article { display: flex; align-items: center; gap: 14px; border: 0; border-radius: 0; padding: 0; background: none; }

/* keep existing section/card styles */
.ld-root .ld-trust-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
.ld-root .ld-trust-card { padding: 16px; border: 1px solid var(--ld-border); border-radius: 12px; background: #fff; }
.ld-root .ld-trust-card h3 { margin: 0 0 8px; font-size: 18px; }
.ld-root .ld-trust-card p { margin: 0; color: var(--ld-muted); }
.ld-root .ld-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.ld-root .ld-grid--4 { grid-template-columns: 1fr; }
.ld-root .ld-grid--3 { grid-template-columns: 1fr; }
.ld-root .ld-card { background: #fff; border: 1px solid var(--ld-border); border-radius: 14px; padding: 14px; box-shadow: 0 2px 8px rgba(15,23,42,.04); }
.ld-root .ld-type-card img { width: calc(100% + 28px); margin: -14px -14px 14px; aspect-ratio: 3/2; object-fit: cover; border-radius: 14px 14px 0 0; display: block; }
.ld-root .ld-type-card h3 { margin: 0 0 8px; font-size: 18px; }
.ld-root .ld-type-card p { margin: 0; color: var(--ld-muted); }
.ld-root .ld-type-card__foot { margin-top: 12px; display: flex; justify-content: space-between; }
.ld-root .ld-cities-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.ld-root .ld-city-card { display: block; border-radius: 14px; overflow: hidden; background: #fff; border: 1px solid var(--ld-border); text-decoration: none; transition: .25s ease; }
.ld-root .ld-city-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; display: block; transition: transform .35s ease; }
.ld-root .ld-city-card__meta { padding: 12px; }
.ld-root .ld-city-card__meta h3 { margin: 0 0 4px; color: var(--ld-text); font-size: 17px; }
.ld-root .ld-city-card__meta p { margin: 0; color: var(--ld-muted); font-size: 14px; }
.ld-root .ld-city-card:hover, .ld-root .ld-city-card:focus-visible { transform: translateY(-4px); box-shadow: 0 12px 24px rgba(15,23,42,.13); }
.ld-root .ld-city-card:hover img, .ld-root .ld-city-card:focus-visible img { transform: scale(1.05); }
.ld-root .ld-bureau-card h3 { margin: 0 0 8px; }
.ld-root .ld-bureau-card p { margin: 0 0 10px; color: var(--ld-muted); }
.ld-root .ld-bureau-card__meta { display: flex; justify-content: space-between; font-size: 14px; }
.ld-root .ld-seo-block { background: #f7faff; border-radius: 14px; padding: 20px; }
.ld-root .ld-seo-block h2 { margin: 0 0 10px; font-size: 26px; }
.ld-root .ld-seo-block p { margin: 0; color: var(--ld-muted); }
.ld-root .ld-section { padding: 32px 0; }
.ld-root .ld-section__head h2 { margin: 0 0 20px; font-size: 28px; font-weight: 700; }
.ld-root .ld-section__head--row { display: flex; align-items: center; justify-content: space-between; }
.ld-root .ld-section__head--row h2 { margin: 0; }
.ld-root .ld-link-all { color: var(--ld-primary); text-decoration: none; font-size: 15px; font-weight: 500; white-space: nowrap; }
.ld-root .ld-link-all:hover { text-decoration: underline; }
.ld-root .ld-link-all--center { display: block; text-align: center; margin-top: 16px; font-size: 14px; }

/* ===== Hero ===== */
.ld-root .ld-hero {
  position: relative;
  overflow: hidden;
  padding: 56px 0 48px;
  background-image: var(--ld-hero-bg);
  background-size: cover;
  background-position: center;
}
.ld-root .ld-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(6,22,62,.82) 0%, rgba(8,30,80,.65) 40%, rgba(4,18,50,.35) 70%, rgba(2,10,30,.15) 100%);
}
.ld-root .ld-hero__content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.ld-root .ld-hero__left {
  flex: 1 1 400px;
  max-width: 620px;
}
.ld-root .ld-hero h1 {
  margin: 0 0 16px;
  color: #fff;
  font-size: clamp(32px, 4.5vw, 60px);
  line-height: 1.08;
  font-weight: 800;
}
.ld-root .ld-hero p {
  margin: 0 0 24px;
  color: #e0eaff;
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.5;
  max-width: 540px;
}

/* Search form */
.ld-root .ld-search {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 32px rgba(0,0,0,.22);
  overflow: hidden;
  max-width: 600px;
}
.ld-root .ld-search__city-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.ld-root .ld-search__pin {
  position: absolute;
  left: 14px;
  width: 18px;
  height: 18px;
  pointer-events: none;
  flex-shrink: 0;
}
.ld-root .ld-search input,
.ld-root .ld-search select,
.ld-root .ld-search button {
  height: 54px;
  border-radius: 0;
  font-size: 15px;
}
.ld-root .ld-search__city-wrap { border-bottom: 1px solid var(--ld-border); }
.ld-root .ld-search input {
  flex: 1;
  border: 0;
  padding: 0 14px 0 40px;
  outline: none;
  width: 100%;
}
.ld-root .ld-search select {
  border: 0;
  border-bottom: 1px solid var(--ld-border);
  padding: 0 14px;
  background: #fff;
  color: var(--ld-muted);
  outline: none;
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235b667a' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}
.ld-root .ld-search button {
  border: 0;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  background: linear-gradient(90deg, var(--ld-primary), var(--ld-primary-700));
  cursor: pointer;
  transition: opacity .2s;
}
.ld-root .ld-search button:hover { opacity: .9; }

/* Popular tags */
.ld-root .ld-hero__popular {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.ld-root .ld-hero__popular > span {
  color: #c0d0f0;
  font-size: 14px;
  font-weight: 500;
}
.ld-root .ld-hero__popular a {
  color: #e8f0ff;
  font-size: 13px;
  text-decoration: none;
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,.25);
  transition: background .2s;
}
.ld-root .ld-hero__popular a:hover { background: rgba(255,255,255,.12); }

/* Stats card — desktop positioning */
.ld-root .ld-hero__stats {
  flex-shrink: 0;
  width: 100%;
  max-width: 320px;
  align-self: flex-start;
}
.ld-root .ld-hero__stats-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background: rgba(255,255,255,.15);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ld-root .ld-hero__stats-icon svg { width: 26px; height: 26px; filter: brightness(0) invert(1); }
.ld-root .ld-hero__stats-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
}
.ld-root .ld-hero__stats strong {
  display: block;
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 800;
  line-height: 1.1;
  color: #fff;
  white-space: nowrap;
}
.ld-root .ld-hero__stats span {
  display: block;
  font-size: 13px;
  color: rgba(255,255,255,.72);
  line-height: 1.3;
}

/* ===== Translation types ===== */
.ld-root .ld-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
.ld-root .ld-grid--4 { grid-template-columns: 1fr; }
.ld-root .ld-grid--3 { grid-template-columns: 1fr; }
.ld-root .ld-card {
  background: #fff;
  border: 1px solid var(--ld-border);
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(15,23,42,.05);
  transition: box-shadow .2s, transform .2s;
}
.ld-root .ld-card:hover { box-shadow: var(--ld-shadow); transform: translateY(-2px); }
.ld-root .ld-type-card img {
  width: calc(100% + 40px);
  margin: -20px -20px 16px;
  aspect-ratio: 3/2;
  object-fit: cover;
  border-radius: 14px 14px 0 0;
  display: block;
  height: auto;
}
.ld-root .ld-type-card h3 { margin: 0 0 8px; font-size: 17px; font-weight: 700; }
.ld-root .ld-type-card p { margin: 0; color: var(--ld-muted); font-size: 14px; line-height: 1.5; }
.ld-root .ld-type-card__foot {
  margin-top: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}
.ld-root .ld-type-card__foot a { color: var(--ld-primary); text-decoration: none; font-weight: 500; }
.ld-root .ld-type-card__foot a:hover { text-decoration: underline; }
.ld-root .ld-type-card__foot span { color: #4a6fa5; font-weight: 600; }

/* ===== Two-column layout ===== */
.ld-root .ld-two-col { display: grid; grid-template-columns: 1fr; gap: 0; }

/* ===== Cities ===== */
.ld-root .ld-cities-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.ld-root .ld-city-card {
  display: block;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--ld-border);
  text-decoration: none;
  transition: transform .25s ease, box-shadow .25s ease;
}
.ld-root .ld-city-card img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
}
.ld-root .ld-city-card__meta { padding: 10px 12px; }
.ld-root .ld-city-card__meta h3 { margin: 0 0 3px; color: var(--ld-text); font-size: 15px; font-weight: 600; }
.ld-root .ld-city-card__meta p { margin: 0; color: var(--ld-muted); font-size: 13px; }
.ld-root .ld-city-card:hover,
.ld-root .ld-city-card:focus-visible { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(15,23,42,.12); }
.ld-root .ld-city-card:hover img,
.ld-root .ld-city-card:focus-visible img { transform: scale(1.04); }

/* ===== Top bureaus ===== */
.ld-root .ld-top-bureaus {
  background: #fff;
  border: 1px solid var(--ld-border);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 2px 12px rgba(15,23,42,.06);
  margin-top: 32px;
}
.ld-root .ld-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.ld-root .ld-tab {
  padding: 7px 14px;
  border: 1px solid var(--ld-border);
  border-radius: 20px;
  background: #fff;
  font-size: 13px;
  color: var(--ld-muted);
  cursor: pointer;
  transition: all .2s;
}
.ld-root .ld-tab--active {
  background: var(--ld-primary);
  border-color: var(--ld-primary);
  color: #fff;
  font-weight: 600;
}
.ld-root .ld-tab:hover:not(.ld-tab--active) { border-color: var(--ld-primary); color: var(--ld-primary); }
.ld-root .ld-bureau-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.ld-root .ld-bureau-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--ld-border);
}
.ld-root .ld-bureau-list li:last-child .ld-bureau-row { border-bottom: 0; padding-bottom: 0; }
.ld-root .ld-bureau-rank {
  width: 22px;
  text-align: center;
  font-size: 14px;
  color: var(--ld-muted);
  font-weight: 600;
  flex-shrink: 0;
}
.ld-root .ld-bureau-logo {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #eef3ff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  color: var(--ld-primary);
  flex-shrink: 0;
}
.ld-root .ld-bureau-info {
  flex: 1;
  min-width: 0;
}
.ld-root .ld-bureau-info strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ld-root .ld-bureau-info span { font-size: 12px; color: var(--ld-muted); }
.ld-root .ld-bureau-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex-shrink: 0;
}
.ld-root .ld-bureau-rating {
  font-size: 13px;
  font-weight: 600;
  color: #f59e0b;
}
.ld-root .ld-bureau-rating em {
  font-style: normal;
  color: var(--ld-muted);
  font-weight: 400;
}
.ld-root .ld-bureau-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  background: #e8f5e9;
  color: #2e7d32;
  font-weight: 500;
}

/* ===== Popular services ===== */
.ld-root .ld-services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.ld-root .ld-svc-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--ld-border);
  border-radius: 12px;
  text-decoration: none;
  color: var(--ld-text);
  transition: box-shadow .2s, transform .2s;
}
.ld-root .ld-svc-item:hover { box-shadow: 0 8px 20px rgba(15,23,42,.1); transform: translateY(-2px); }
.ld-root .ld-svc-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: #eef3ff;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ld-root .ld-svc-icon svg { width: 22px; height: 22px; }
.ld-root .ld-svc-name { flex: 1; font-size: 14px; font-weight: 500; line-height: 1.35; }
.ld-root .ld-svc-price { font-size: 13px; color: #4a6fa5; font-weight: 600; white-space: nowrap; }

/* ===== Trust grid ===== */
.ld-root .ld-trust-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
  padding: 0 0 8px;
}
.ld-root .ld-trust-card {
  padding: 20px;
  border: 1px solid var(--ld-border);
  border-radius: 14px;
  background: #fff;
}
.ld-root .ld-trust-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: #eef3ff;
  border-radius: 12px;
  margin-bottom: 12px;
}
.ld-root .ld-trust-icon svg { width: 24px; height: 24px; }
.ld-root .ld-trust-card h3 { margin: 0 0 8px; font-size: 16px; font-weight: 700; }
.ld-root .ld-trust-card p { margin: 0; color: var(--ld-muted); font-size: 14px; line-height: 1.5; }

/* ===== Responsive ===== */
@media (min-width: 640px) {
  .ld-root .ld-search { grid-template-columns: 1fr; }
  .ld-root .ld-cities-grid { grid-template-columns: repeat(3, 1fr); }
  .ld-root .ld-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .ld-root .ld-grid--3 { grid-template-columns: repeat(2, 1fr); }
  .ld-root .ld-trust-grid { grid-template-columns: repeat(2, 1fr); }
  .ld-root .ld-services-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 980px) {
  .ld-root .ld-search { grid-template-columns: 2fr 1.2fr auto; }
  .ld-root .ld-cities-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .ld-root .ld-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ld-root .ld-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ld-root .ld-hero__content { grid-template-columns: minmax(420px, 1.1fr) minmax(300px, .9fr) minmax(250px, .5fr); }
  .ld-root .ld-hero__visual { min-height: 430px; }
  .ld-root .ld-section__head h2 { font-size: 34px; }
  .ld-root .ld-search {
    grid-template-columns: 1.6fr 1fr auto;
    border-radius: 12px;
  }
  .ld-root .ld-search__city-wrap { border-bottom: 0; border-right: 1px solid var(--ld-border); }
  .ld-root .ld-search select { border-bottom: 0; border-right: 1px solid var(--ld-border); }
  .ld-root .ld-search button { border-radius: 0 10px 10px 0; }
  .ld-root .ld-cities-grid { grid-template-columns: repeat(3, 1fr); }
  .ld-root .ld-two-col { grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 32px; align-items: start; }
  .ld-root .ld-top-bureaus { margin-top: 0; }
  .ld-root .ld-grid--4 { grid-template-columns: repeat(4, 1fr); }
  .ld-root .ld-grid--3 { grid-template-columns: repeat(3, 1fr); }
  .ld-root .ld-section__head h2 { font-size: 32px; }
  .ld-root .ld-trust-grid { grid-template-columns: repeat(5, 1fr); }
  .ld-root .ld-services-grid { grid-template-columns: repeat(3, 1fr); }
  .ld-root .ld-hero__stats { width: 320px; max-width: 320px; }
}

@media (min-width: 1100px) {
  .ld-root .ld-cities-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 640px) {
  .ld-root .ld-hero__stats { max-width: 100%; }
  .ld-root .ld-hero { padding: 40px 0 32px; }
  .ld-root .ld-section { padding: 20px 0; }
  .ld-root .ld-top-bureaus { margin-top: 20px; }
}

/* На самых маленьких экранах (<480px) длинные названия услуг не помещаются
   в 2 колонки — переключаем на одну. */
@media (max-width: 479px) {
  .ld-root .ld-services-grid { grid-template-columns: 1fr; }
  .ld-root .ld-svc-item { padding: 12px 14px; }
}

/* ===== Section more link ===== */
.ld-section-more { text-align: right; margin-top: 12px; }
.ld-section-more a { color: var(--ld-primary); text-decoration: none; font-size: 14px; font-weight: 500; }
.ld-section-more a:hover { text-decoration: underline; }
