/* Phase 5: чист medical/corporate визуален слой върху статичната архитектура. */
:root {
  --bg: #fbfdff;
  --surface: #f3f7fa;
  --surface-strong: #eaf3f8;
  --card: #ffffff;
  --text: #172533;
  --muted: #5b6b78;
  --line: #d7e4ec;
  --accent: #0a87bd;
  --accent-dark: #075f89;
  --accent-soft: #dff2fa;
  --success-soft: #e7f5ef;
  --shadow: 0 16px 42px rgba(20, 54, 76, 0.09);
  --shadow-soft: 0 10px 24px rgba(20, 54, 76, 0.06);
  --max: 1160px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  background:
    linear-gradient(180deg, #eef8fc 0, #fbfdff 520px),
    var(--bg);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--accent-dark);
}

:focus-visible {
  outline: 3px solid rgba(10, 135, 189, 0.35);
  outline-offset: 3px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 14px clamp(18px, 4vw, 52px);
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid rgba(215, 228, 236, 0.9);
  box-shadow: 0 8px 28px rgba(20, 54, 76, 0.06);
  backdrop-filter: blur(12px);
}

.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}

.brand img {
  width: clamp(142px, 16vw, 190px);
}

.site-nav,
.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
}

.site-nav a,
.site-footer a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 6px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}

.site-nav a:hover,
.site-footer a:hover {
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.language-link {
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--accent-dark) !important;
}

.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(68px, 9vw, 104px) clamp(18px, 4vw, 34px);
}

.soft-section {
  max-width: none;
  padding-left: max(clamp(18px, 4vw, 34px), calc((100vw - var(--max)) / 2 + 34px));
  padding-right: max(clamp(18px, 4vw, 34px), calc((100vw - var(--max)) / 2 + 34px));
  background: linear-gradient(180deg, var(--surface) 0, #f8fbfd 100%);
  border-block: 1px solid rgba(215, 228, 236, 0.8);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(320px, 0.86fr);
  gap: clamp(34px, 6vw, 72px);
  align-items: center;
  min-height: calc(100vh - 86px);
  padding-top: clamp(58px, 8vw, 92px);
}

.hero-content {
  max-width: 720px;
  animation: fadeUp 780ms ease both;
}

.hero h1,
.section-header h2 {
  margin: 0;
  line-height: 1.08;
  color: var(--text);
}

.hero h1 {
  max-width: 760px;
  font-size: clamp(42px, 6.8vw, 78px);
  font-weight: 800;
}

.hero-subtitle {
  max-width: 680px;
  margin: 18px 0 0;
  color: var(--accent-dark);
  font-size: clamp(19px, 2.2vw, 25px);
  font-weight: 700;
  line-height: 1.35;
  animation: fadeUp 780ms 120ms ease both;
}

.section-header {
  max-width: 820px;
  margin: 0 auto 38px;
  text-align: center;
}

.section-header h2 {
  font-size: clamp(30px, 4vw, 48px);
  font-weight: 800;
}

.section-header p:not(.eyebrow) {
  margin: 16px auto 0;
  max-width: 780px;
  color: var(--muted);
  font-size: 18px;
}

.section-subtitle {
  color: var(--accent-dark) !important;
  font-size: clamp(18px, 2vw, 22px) !important;
  font-weight: 800;
}

.lead {
  max-width: 700px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 22px);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
  animation: fadeUp 780ms 220ms ease both;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 20px;
  border: 1px solid var(--accent);
  border-radius: 7px;
  background: var(--accent);
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
  box-shadow: var(--shadow-soft);
}

.button:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

.button.secondary {
  background: #ffffff;
  color: var(--accent-dark);
  border-color: var(--line);
  box-shadow: none;
}

.button.secondary:hover {
  background: var(--accent-soft);
}

.hero-media {
  margin: 0;
  position: relative;
  animation: fadeUp 820ms 180ms ease both;
}

.hero-media::before {
  content: "";
  position: absolute;
  inset: -18px 22px 22px -18px;
  z-index: -1;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--accent-soft), var(--success-soft));
  border: 1px solid rgba(10, 135, 189, 0.12);
}

.hero-media img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.text-block {
  max-width: 920px;
  margin: 0 auto;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
  font-size: 18px;
  text-align: center;
}

.text-block p:first-child {
  margin-top: 0;
}

.text-block p:last-child {
  margin-bottom: 0;
}

.grid {
  display: grid;
  gap: 18px;
}

.two-column {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

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

.item,
.card,
.contact-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
  animation: fadeUp 700ms ease both;
}

.grid > :nth-child(2),
.contact-grid > :nth-child(2) {
  animation-delay: 80ms;
}

.grid > :nth-child(3),
.contact-grid > :nth-child(3) {
  animation-delay: 160ms;
}

.grid > :nth-child(4) {
  animation-delay: 240ms;
}

.item {
  padding: 24px;
}

.card {
  padding: clamp(22px, 3vw, 30px);
}

.item h3,
.card h3 {
  margin: 0 0 10px;
  color: var(--accent-dark);
  font-size: 21px;
  line-height: 1.25;
}

.item p {
  margin-bottom: 0;
  color: var(--muted);
}

.card ul {
  margin: 16px 0 0;
  padding-left: 21px;
}

.card li + li {
  margin-top: 9px;
}

.icon-divider {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin: 42px auto 0;
  padding: 18px;
  border: 1px solid rgba(215, 228, 236, 0.95);
  border-radius: 14px;
  background: linear-gradient(135deg, #ffffff 0%, #f3f9fc 100%);
  box-shadow: var(--shadow-soft);
}

.icon-divider span {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--accent-dark);
  font-size: 14px;
  font-weight: 800;
}

.icon-divider svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
  animation: softPulse 2600ms ease-in-out infinite;
}

.icon-divider span:nth-child(2) svg {
  animation-delay: 160ms;
}

.icon-divider span:nth-child(3) svg {
  animation-delay: 320ms;
}

.icon-divider span:nth-child(4) svg {
  animation-delay: 480ms;
}

.icon-divider span:nth-child(5) svg {
  animation-delay: 640ms;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(270px, 390px);
  gap: clamp(24px, 5vw, 46px);
  align-items: center;
}

.split > div {
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: var(--shadow-soft);
  animation: fadeUp 700ms ease both;
}

.resource-block,
.context-block {
  margin-top: 22px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(180deg, #ffffff 0%, #f7fbfd 100%);
}

.resource-block h3,
.context-block h3 {
  margin: 0 0 8px;
  color: var(--accent-dark);
  font-size: 20px;
}

.resource-block p,
.context-block p {
  margin: 0;
}

.resource-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.resource-links a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid rgba(10, 135, 189, 0.24);
  border-radius: 7px;
  background: #ffffff;
  color: var(--accent-dark);
  font-weight: 800;
  text-decoration: none;
}

.resource-links a:hover {
  background: var(--accent-soft);
  border-color: rgba(10, 135, 189, 0.42);
}

.split figure {
  margin: 0;
}

.split img {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #ffffff;
  padding: 12px;
  box-shadow: var(--shadow-soft);
  animation: fadeUp 700ms 120ms ease both;
}

.partner-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  margin-top: 28px;
}

.partner-strip img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  padding: 10px;
  transition: transform 180ms ease, border-color 180ms ease;
}

.partner-strip img:hover {
  transform: translateY(-2px);
  border-color: rgba(10, 135, 189, 0.35);
}

.contact-section {
  padding-bottom: clamp(84px, 10vw, 124px);
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.contact-card {
  display: block;
  min-height: 132px;
  padding: 24px;
  color: var(--text);
  text-decoration: none;
}

a.contact-card:hover {
  border-color: rgba(10, 135, 189, 0.4);
  background: #f8fcfe;
}

.contact-card span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
}

.contact-card strong {
  overflow-wrap: anywhere;
  font-size: 18px;
  line-height: 1.35;
}

.note {
  color: var(--muted);
  font-size: 14px;
}

.section > .note,
.contact-section > .note {
  margin-top: 18px;
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(180px, 0.8fr) minmax(260px, 1.4fr);
  gap: 24px;
  align-items: center;
  padding: 34px clamp(18px, 4vw, 52px);
  border-top: 1px solid var(--line);
  background: #ffffff;
}

.site-footer img {
  width: 150px;
}

.site-footer p {
  margin: 8px 0 0;
}

.site-footer .note {
  margin: 0;
  justify-self: end;
  max-width: 320px;
}

@media (max-width: 980px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-nav {
    justify-content: flex-start;
  }

  .hero,
  .split,
  .two-column,
  .services-grid,
  .contact-grid,
  .site-footer,
  .resource-links {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    text-align: center;
  }

  .hero-content,
  .hero h1,
  .hero-subtitle,
  .lead {
    margin-left: auto;
    margin-right: auto;
  }

  .actions {
    justify-content: center;
  }

  .site-footer .note {
    justify-self: start;
  }
}

@media (max-width: 680px) {
  body {
    background: linear-gradient(180deg, #eef8fc 0, #fbfdff 420px);
  }

  .site-header {
    padding: 12px 16px;
  }

  .site-nav a,
  .site-footer a {
    font-size: 14px;
    padding-inline: 8px;
  }

  .section {
    padding: 58px 18px;
  }

  .soft-section {
    padding-left: 18px;
    padding-right: 18px;
  }

  .hero-media::before {
    inset: -10px 12px 12px -10px;
    border-radius: 14px;
  }

  .partner-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
    filter: blur(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

@keyframes softPulse {
  0%, 100% {
    transform: translateY(0) scale(1);
    opacity: 0.82;
  }
  50% {
    transform: translateY(-1px) scale(1.06);
    opacity: 1;
  }
}

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