/* Portal Pro Tenge — responsive fixed version */
:root {
  --bg: #f4f7f5;
  --surface: #ffffff;
  --primary: #064e3b;
  --primary-2: #047857;
  --accent: #f59e0b;
  --text: #1f2937;
  --muted: #5b6472;
  --border: #e5e7eb;
  --success-bg: #ecfdf5;
  --warning-bg: #fff7ed;
  --shadow: 0 10px 28px rgba(15, 23, 42, .08);
  --radius: 22px;
  --container: 1180px;
}

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

html {
  scroll-behavior: smooth;
  max-width: 100%;
  overflow-x: hidden;
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  max-width: 100%;
  overflow-x: hidden;
}

img,
svg,
video,
canvas {
  max-width: 100%;
  height: auto;
}

a {
  word-break: break-word;
}

.container {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
}

.site-header {
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  color: white;
}

.site-header__inner {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
  padding: 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: white;
  text-decoration: none;
  min-width: 0;
}

.brand__mark {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border-radius: 14px;
  background: #d1fae5;
  color: var(--primary);
  display: grid;
  place-items: center;
  font-weight: 800;
}

.brand__title {
  font-size: clamp(22px, 3vw, 26px);
  font-weight: 800;
  line-height: 1.15;
}

.brand__subtitle {
  font-size: 14px;
  color: #d1fae5;
  line-height: 1.35;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px 16px;
  flex-wrap: wrap;
  min-width: 0;
}

.site-nav__link {
  color: #ecfdf5;
  text-decoration: none;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.25;
}

.site-nav__link:hover,
.site-nav__link.is-active {
  color: #bbf7d0;
  text-decoration: underline;
}

.language-switcher {
  display: flex;
  gap: 8px;
  margin-left: 8px;
  flex-wrap: wrap;
}

.language-switcher__link {
  border: 1px solid rgba(255, 255, 255, .45);
  color: white;
  text-decoration: none;
  border-radius: 999px;
  padding: 6px 10px;
  font-weight: 700;
  font-size: 13px;
  white-space: nowrap;
}

.language-switcher__link.is-active {
  background: white;
  color: var(--primary);
}

.hero {
  margin: 36px 0;
  background: var(--surface);
  padding: clamp(28px, 5vw, 56px) clamp(18px, 4vw, 42px);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .9fr);
  gap: 34px;
  align-items: center;
}

.hero > *,
.hero__panel,
.info-panel,
.card,
.content-box,
.page-head,
.site-footer__inner > *,
.lesson-item,
.contact-card {
  min-width: 0;
}

.hero__eyebrow {
  color: var(--primary-2);
  font-weight: 800;
  margin-bottom: 10px;
}

.hero__title {
  font-size: clamp(30px, 5vw, 44px);
  line-height: 1.12;
  color: var(--primary);
  margin-bottom: 18px;
}

.hero__text {
  font-size: clamp(16px, 2.2vw, 18px);
  color: var(--muted);
  margin-bottom: 26px;
}

.hero__panel,
.info-panel {
  background: var(--success-bg);
  border: 1px solid #a7f3d0;
  border-radius: 20px;
  padding: clamp(20px, 3vw, 28px);
}

.hero__panel h2,
.info-panel h2 {
  color: var(--primary);
  margin-bottom: 14px;
  line-height: 1.25;
}

.hero__panel ul,
.info-panel ul {
  padding-left: 20px;
}

.hero__panel li,
.info-panel li {
  margin-bottom: 10px;
}

.button {
  display: inline-block;
  background: var(--primary-2);
  color: white;
  text-decoration: none;
  border: 0;
  border-radius: 12px;
  padding: 13px 22px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: .2s;
}

.button:hover {
  background: #065f46;
  transform: translateY(-2px);
}

.button--secondary {
  background: #e8fff4;
  color: var(--primary);
  border: 1px solid #a7f3d0;
}

.section {
  margin: 42px 0;
}

.section__title {
  text-align: center;
  font-size: clamp(26px, 4vw, 31px);
  color: var(--primary);
  margin-bottom: 12px;
  line-height: 1.2;
}

.section__lead {
  text-align: center;
  max-width: 780px;
  margin: 0 auto 28px;
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(245px, 100%), 1fr));
  gap: 22px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: clamp(20px, 3vw, 26px);
  box-shadow: 0 8px 22px rgba(15, 23, 42, .06);
  text-decoration: none;
  color: inherit;
  transition: .2s;
}

.card:hover {
  transform: translateY(-4px);
  border-color: #10b981;
}

.card__title {
  color: var(--primary-2);
  font-size: 22px;
  margin-bottom: 10px;
  line-height: 1.25;
}

.card__text {
  color: var(--muted);
}

.card__link {
  display: inline-block;
  margin-top: 14px;
  color: var(--primary-2);
  font-weight: 800;
}

.page-head {
  margin: 36px 0 26px;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(28px, 5vw, 42px);
}

.page-head__title {
  font-size: clamp(28px, 5vw, 38px);
  color: var(--primary);
  margin-bottom: 12px;
  line-height: 1.2;
}

.page-head__lead {
  color: var(--muted);
  font-size: clamp(16px, 2.2vw, 18px);
  max-width: 850px;
}

.content-box {
  background: var(--surface);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: clamp(22px, 4vw, 32px);
  margin-bottom: 28px;
}

.content-box h2 {
  color: var(--primary);
  margin-bottom: 14px;
  line-height: 1.25;
}

.content-box p {
  color: var(--muted);
  margin-bottom: 12px;
}

.learning-list {
  display: grid;
  gap: 16px;
}

.lesson-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: clamp(18px, 3vw, 22px);
}

.lesson-item h3 {
  color: var(--primary-2);
  margin-bottom: 8px;
  line-height: 1.25;
}

.contact-card {
  background: var(--success-bg);
  border: 1px solid #a7f3d0;
  border-radius: 20px;
  padding: clamp(20px, 3vw, 26px);
}

.risk-note {
  background: var(--warning-bg);
  border: 1px solid #fed7aa;
  color: #7c2d12;
  border-radius: 18px;
  padding: 20px;
  margin: 30px 0;
}

.site-footer {
  background: var(--primary);
  color: white;
  margin-top: 56px;
}

.site-footer__inner {
  width: min(100% - 32px, var(--container));
  margin: 0 auto;
  padding: 32px 0;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
}

.site-footer a {
  color: #bbf7d0;
  text-decoration: none;
  display: inline-block;
  margin: 4px 10px 4px 0;
}

.site-footer a:hover {
  text-decoration: underline;
}

.site-footer__title {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 8px;
}

.footer-note {
  color: #d1fae5;
  font-size: 14px;
  margin-top: 10px;
}

.backend-badge {
  display: inline-block;
  background: #eef2ff;
  color: #3730a3;
  border-radius: 999px;
  padding: 6px 10px;
  font-weight: 800;
  font-size: 13px;
  margin: 6px 6px 0 0;
}

@media (max-width: 980px) {
  .site-header__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
  }

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

  .language-switcher {
    margin-left: 0;
  }

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

  .site-footer__inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 680px) {
  .container,
  .site-header__inner,
  .site-footer__inner {
    width: min(100% - 24px, var(--container));
  }

  .brand {
    align-items: flex-start;
  }

  .site-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
    gap: 10px;
  }

  .site-nav__link {
    background: rgba(255, 255, 255, .10);
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 12px;
    padding: 10px 12px;
  }

  .language-switcher {
    grid-column: 1 / -1;
  }

  .site-footer__inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .container,
  .site-header__inner,
  .site-footer__inner {
    width: min(100% - 20px, var(--container));
  }

  .site-header__inner {
    padding: 18px 0;
  }

  .brand__mark {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
    border-radius: 12px;
  }

  .brand__subtitle {
    font-size: 13px;
  }

  .site-nav {
    grid-template-columns: 1fr;
  }

  .hero {
    margin: 24px 0;
    border-radius: 18px;
  }

  .hero__title {
    line-height: 1.18;
  }

  .button {
    width: 100%;
    text-align: center;
  }
}
