:root {
  --bg: #0b1220;
  --panel: #0f172a;
  --fg: #f1f5f9;
  --muted: #94a3b8;
  --accent: #3b82f6;
  --accent2: #60a5fa;
  --line: rgba(255, 255, 255, 0.12);
  --light: #eef2f7;
  --light2: #e8eef5;
  --ink: #0f172a;
  --ink-soft: #475569;
  --nav-bg: rgba(11, 18, 32, 0.92);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  font: 16px/1.55 system-ui, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--fg);
  overflow-x: hidden;
}

a {
  color: inherit;
}

.w {
  width: min(1180px, calc(100% - 48px));
  margin: auto;
}

/* —— Nav —— */
nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 9;
  background: var(--nav-bg);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav {
  height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-logo {
  height: 30px;
  width: auto;
  display: block;
}

.links {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.links > a {
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
  color: #cbd5e1;
}

.langs {
  display: flex;
  gap: 9px;
  align-items: center;
  margin-left: 6px;
  padding-left: 14px;
  border-left: 1px solid var(--line);
}

.langs a,
.langs b {
  font-size: 11px !important;
  letter-spacing: 0.08em;
  text-decoration: none;
  font-weight: 700;
}

.langs b {
  color: var(--accent2);
}

/* —— Hero —— */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 125px 0 65px;
  background:
    radial-gradient(circle at 82% 38%, rgba(59, 130, 246, 0.14), transparent 25%),
    linear-gradient(135deg, #070b14, #0f172a 65%, #0b1220);
}

.hg {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: 70px;
  align-items: center;
}

.iso-line {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  font-size: clamp(28px, 4vw, 54px);
  letter-spacing: -0.045em;
  margin: 0 0 30px;
}

.iso-line span {
  color: var(--fg);
  font-weight: 520;
  white-space: nowrap;
}

.iso-line i {
  display: block;
  width: 1px;
  height: 34px;
  background: var(--accent);
  opacity: 0.85;
}

.lead {
  font-size: clamp(20px, 2vw, 25px);
  max-width: 720px;
  line-height: 1.35;
  margin: 0 0 14px;
}

.sub {
  color: var(--muted);
  margin: 0;
}

.sub strong {
  color: #e2e8f0;
}

.btn {
  display: inline-block;
  margin-top: 28px;
  padding: 13px 19px;
  border-radius: 999px;
  background: var(--accent);
  color: #06101f;
  text-decoration: none;
  font-weight: 850;
}

.btn:hover {
  background: var(--accent2);
}

.visual {
  height: 430px;
  display: grid;
  place-items: center;
}

.ring {
  width: 460px;
  height: 380px;
  border: 2px solid rgba(59, 130, 246, 0.72);
  border-radius: 50%;
  display: grid;
  place-items: center;
  position: relative;
  background: transparent;
  isolation: isolate;
}

.ring::before {
  content: "";
  position: absolute;
  inset: 70px 82px;
  border: 2.5px solid rgba(148, 180, 220, 0.55);
  border-radius: 50%;
}

.core {
  text-align: center;
  font-size: 14px;
  letter-spacing: 0.035em;
  font-weight: 900;
  z-index: 3;
  color: #fff;
  width: 174px;
  height: 130px;
  border-radius: 50%;
  background: radial-gradient(circle at 45% 40%, #1e293b, #0f172a);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.core small {
  display: block;
  margin-top: 7px;
  color: var(--accent2);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
}

.iso-domain {
  position: absolute;
  z-index: 0;
  text-align: center;
  pointer-events: none;
  color: rgba(96, 165, 250, 0.28);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  line-height: 1.15;
}

.iso-domain small {
  display: block;
  margin-top: 5px;
  font-size: 9px;
  letter-spacing: 0.08em;
  color: rgba(96, 165, 250, 0.22);
}

.iso-domain.quality {
  left: 50%;
  top: -74px;
  transform: translateX(-50%);
}

.iso-domain.environment {
  left: -84px;
  bottom: -44px;
}

.iso-domain.safety {
  right: -78px;
  bottom: -44px;
}

.orbit-item {
  position: absolute;
  z-index: 5;
  min-width: 82px;
  padding: 9px 12px;
  text-align: center;
  background: #0b1220;
  font-size: 13px;
  font-weight: 850;
  white-space: nowrap;
  transform: translate(-50%, -50%);
}

.orbit-item.core-item {
  color: #cbd5e1;
  border: 1.5px solid rgba(148, 180, 220, 0.65);
  z-index: 6;
}

.orbit-item.context {
  color: var(--accent2);
  border: 1.5px solid rgba(59, 130, 246, 0.65);
}

/* —— Shared section chrome —— */
section {
  padding: 88px 0 54px;
}

.ey {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  letter-spacing: 0.19em;
  font-weight: 950;
  text-transform: uppercase;
  color: var(--accent2);
}

.ey::before {
  content: "";
  width: 28px;
  height: 2px;
  background: currentColor;
  display: block;
}

.head {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 60px;
  margin-bottom: 36px;
}

.head h2 {
  font-size: clamp(35px, 3.6vw, 50px);
  line-height: 1;
  letter-spacing: -0.045em;
  margin: 13px 0 0;
}

.head p {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 0;
}

/* —— Services —— */
#teenused {
  position: relative;
  background: var(--light);
  color: var(--ink);
  min-height: auto;
}

#teenused::before {
  content: attr(data-watermark);
  position: absolute;
  right: 4vw;
  top: 76px;
  font-size: clamp(54px, 8vw, 112px);
  font-weight: 950;
  letter-spacing: -0.06em;
  color: rgba(15, 23, 42, 0.04);
  pointer-events: none;
}

#teenused .ey {
  color: #2563eb;
}

#teenused .head p {
  color: var(--ink-soft);
}

.services {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: #c5d0de;
  border: 1px solid #c5d0de;
}

.service {
  display: block;
  position: relative;
  background: #e8eef5;
  padding: 28px 30px;
  border: 0;
}

.service:nth-child(1) {
  background: #dfe8f2;
}
.service:nth-child(2) {
  background: #e5ecf4;
}
.service:nth-child(3) {
  background: #e3eaf2;
}
.service:nth-child(4) {
  background: #dfe6ef;
}

.markline {
  width: 34px;
  height: 2px;
  background: var(--accent);
  margin: 0 0 22px;
}

.service h3 {
  font-size: 25px;
  letter-spacing: -0.025em;
  margin: 0 0 15px;
  color: #0c1624;
  font-weight: 800;
  line-height: 1.1;
}

.service p {
  margin: 0;
  color: #46566b;
  font-size: 15px;
  line-height: 1.58;
}

.service p.second {
  margin-top: 14px;
}

.iso-standards {
  display: flex;
  align-items: center;
  gap: 13px;
  flex-wrap: wrap;
  margin-top: 19px;
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.015em;
}

.iso-standards i {
  display: block;
  width: 1px;
  height: 16px;
  background: #93b4d8;
}

.section-cta {
  grid-column: 1 / -1;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 24px;
  background: #edf2f8;
  border-top: 1px solid rgba(59, 130, 246, 0.35);
}

.section-cta span {
  font-size: 14px;
  font-weight: 750;
  line-height: 1.35;
  color: #172033;
}

.section-cta a {
  font-size: 14px;
  font-weight: 900;
  color: #1d4ed8;
  text-decoration: none;
  white-space: nowrap;
}

.section-cta a::after {
  content: " →";
  margin-left: 6px;
}

/* —— Approach —— */
.approach {
  background: #0f172a;
  color: #f1f5f9;
  min-height: auto;
  padding: 88px 0 52px;
}

.approach .ey {
  color: #7db4ff;
}

.approach .head h2 {
  color: #f1f5f9;
}

.approach .head p {
  color: #b8c4d4 !important;
}

.steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.14);
  margin-top: 30px;
}

.step {
  background: #172033;
  padding: 28px 25px 26px;
  min-height: 205px;
  display: flex;
  flex-direction: column;
}

.step:nth-child(odd) {
  background: #1a2538;
}

.step small {
  display: block;
  color: #7db4ff;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.12em;
  margin-bottom: 18px;
}

.step b {
  display: block;
  color: #f5f7fa;
  font-size: 20px;
  line-height: 1.2;
  margin-bottom: 12px;
}

.step p {
  font-size: 15px;
  line-height: 1.55;
  color: #b8c4d4;
  margin: 0;
  max-width: 210px;
}

.promise {
  font-size: clamp(24px, 2.7vw, 36px);
  line-height: 1.15;
  max-width: 950px;
  margin-top: 38px;
  color: #f1f5f9;
}

.promise span {
  color: #7db4ff;
}

/* —— Training —— */
.training {
  position: relative;
  background: var(--light);
  color: var(--ink);
  overflow: hidden;
  min-height: auto;
  padding: 92px 0 52px;
}

.training::before {
  content: attr(data-watermark);
  position: absolute;
  right: 3vw;
  top: 48px;
  font-size: clamp(52px, 7vw, 102px);
  font-weight: 950;
  letter-spacing: -0.055em;
  color: rgba(15, 23, 42, 0.04);
  pointer-events: none;
}

.training .ey {
  color: #2563eb;
}

.training-head {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 70px;
  align-items: end;
  margin-bottom: 42px;
}

.training-head h2 {
  font-size: clamp(40px, 4.5vw, 60px);
  line-height: 0.98;
  letter-spacing: -0.045em;
  margin: 10px 0 0;
  color: var(--ink);
}

.training-head > p {
  max-width: 610px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 0 0 5px;
}

.training-offers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid #c5d0de;
  background: #c5d0de;
  gap: 1px;
}

.training-offer {
  min-height: 280px;
  background: #e3eaf2;
  padding: 38px 40px;
  position: relative;
}

.training-offer:first-child {
  background: #dfe8f2;
}

.offer-line {
  width: 42px;
  height: 2px;
  background: var(--accent);
  margin-bottom: 44px;
}

.training-offer h3 {
  max-width: 520px;
  font-size: 30px;
  line-height: 1.08;
  letter-spacing: -0.025em;
  margin: 0 0 22px;
  color: var(--ink);
}

.training-offer p {
  max-width: 570px;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.62;
  margin: 0;
}

#koolitused .section-cta {
  width: 100%;
  box-sizing: border-box;
  margin: 0;
  border: 1px solid #c5d0de;
  border-top: 1px solid rgba(59, 130, 246, 0.35);
}

/* —— Expert + contact —— */
.expert-contact {
  position: relative;
  overflow: hidden;
  min-height: auto;
  display: flex;
  align-items: center;
  padding: 92px 0 46px;
  color: #f1f5f9;
  background:
    radial-gradient(circle at 10% 32%, rgba(59, 130, 246, 0.22), transparent 31%),
    radial-gradient(circle at 91% 18%, rgba(37, 99, 235, 0.16), transparent 29%),
    linear-gradient(135deg, #172554 0%, #0b1220 47%, #0f1b33 100%);
}

.expert-contact-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 0.72fr 1.1fr 0.82fr;
  gap: 38px;
  align-items: stretch;
}

.expert-person {
  height: 540px;
  align-self: center;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid rgba(96, 165, 250, 0.22);
  background: #14213a;
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.18);
}

.expert-person .photo,
.expert-person .photo img {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: block;
  object-fit: cover;
  object-position: center 27%;
  background: transparent;
  overflow: hidden;
}

.expert-copy {
  padding: 14px 0;
}

.expert-copy > .ey {
  margin-bottom: 18px;
  color: #7db4ff;
}

.expert-copy h2 {
  font-size: clamp(35px, 3.7vw, 51px);
  line-height: 1;
  letter-spacing: -0.04em;
  margin: 0 0 18px;
  color: #f4f7f5;
}

.expert-copy > p {
  font-size: 15px;
  line-height: 1.55;
  color: #b8c3d0;
}

.clean-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 24px 0 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.metric {
  padding: 16px 12px 16px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.metric:nth-child(odd) {
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}

.metric:nth-child(even) {
  padding-left: 16px;
}

.metric strong {
  display: block;
  font-size: 25px;
  color: #7db4ff;
}

.metric small {
  color: #aeb8c6;
}

.iso-metric {
  grid-column: 1 / 3;
  border-right: 0 !important;
  padding: 17px 0 !important;
}

.iso-metric strong {
  font-size: 20px;
  letter-spacing: 0.01em;
}

.iso-metric small {
  display: block;
  margin-top: 7px;
  font-size: 13px;
  color: #c0cacf;
}

.degree-line {
  margin: 17px 0 7px !important;
  color: #f0f4f8 !important;
  font-size: 14px !important;
  font-weight: 700;
}

.taltech-line {
  margin: 0 !important;
  color: #aeb8c6 !important;
  font-size: 13px !important;
  line-height: 1.48 !important;
}

.sector-line {
  margin: 10px 0 0 !important;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #b8c4d0 !important;
  font-size: 13px !important;
  line-height: 1.5 !important;
}

.sector-line strong {
  color: #eef3f8;
  font-weight: 800;
}

.contact-copy {
  height: 540px;
  align-self: center;
  border: 1px solid rgba(96, 165, 250, 0.34);
  border-radius: 16px;
  padding: 34px 32px;
  background: linear-gradient(145deg, rgba(30, 64, 130, 0.66), rgba(10, 20, 40, 0.62));
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.16);
}

.contact-copy > .ey {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #7db4ff;
  margin-bottom: 0;
}

.contact-copy > .ey::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--accent);
  opacity: 0.7;
}

.contact-copy h2 {
  font-size: clamp(29px, 2.6vw, 37px);
  line-height: 1.02;
  letter-spacing: -0.04em;
  margin: 15px 0 24px;
  color: #f4f7fa;
}

.details {
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  margin-bottom: 18px;
}

.details div {
  padding: 11px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  color: #d6dee8;
  font-size: 14px;
}

.details a {
  color: #f4f7fa;
  word-break: break-word;
}

.registry-code {
  color: #b8c4d0;
  font-size: 13px;
}

.contact-mail-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding: 14px 18px;
  border-radius: 9px;
  background: var(--accent);
  color: #06101f !important;
  text-decoration: none;
  font-weight: 850;
}

.contact-mail-btn:hover {
  background: var(--accent2);
}

/* —— Footer —— */
footer {
  background: #070b14;
  color: #7e8a96;
  padding: 22px 0;
  font-size: 12px;
}

.foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

/* —— Tablet / mid —— */
@media (max-width: 1050px) and (min-width: 851px) {
  .step {
    padding: 24px 18px;
    min-height: 195px;
  }

  .step b {
    font-size: 18px;
  }

  .step p {
    font-size: 14px;
  }

  .expert-contact-grid {
    grid-template-columns: 0.65fr 1fr 0.85fr;
    gap: 28px;
  }

  .expert-person,
  .contact-copy {
    height: 500px;
  }
}

@media (max-width: 1000px) and (min-width: 851px) {
  .expert-person,
  .contact-copy {
    height: 500px;
  }

  .contact-copy {
    padding: 26px 24px;
  }
}

/* —— Tablet / mobile stack —— */
@media (max-width: 850px) {
  .nav .links > a[href^="#"]:not(.nav-contact) {
    display: none;
  }

  .hg,
  .head,
  .training-head,
  .expert-contact-grid {
    grid-template-columns: 1fr;
  }

  .visual {
    height: 350px;
    margin-top: 20px;
  }

  .ring {
    width: 320px;
    height: 260px;
  }

  .ring::before {
    inset: 50px 58px;
  }

  .core {
    width: 130px;
    height: 96px;
    font-size: 11px;
  }

  .orbit-item {
    font-size: 9px;
    padding: 5px 7px;
    min-width: 0;
    max-width: 96px;
    white-space: normal;
    line-height: 1.2;
  }

  .iso-domain {
    font-size: 8px;
  }

  .iso-domain small {
    font-size: 7px;
  }

  .iso-domain.quality {
    top: -48px;
  }

  .iso-domain.environment {
    left: -24px;
    bottom: -38px;
  }

  .iso-domain.safety {
    right: -22px;
    bottom: -38px;
  }

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

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

  .step {
    min-height: 0;
    max-width: none;
  }

  .step p {
    max-width: none;
  }

  .training-offers {
    grid-template-columns: 1fr;
  }

  .training-offer {
    min-height: 0;
    padding: 30px 26px;
  }

  .offer-line {
    margin-bottom: 28px;
  }

  .training-offer h3 {
    font-size: 25px;
    margin: 0 0 15px;
  }

  .expert-person {
    height: 420px;
  }

  .contact-copy {
    height: auto;
    border-left: 0;
  }

  section,
  .approach,
  .training,
  .expert-contact {
    padding: 72px 0;
  }

  .langs {
    padding-left: 8px;
    margin-left: 0;
  }
}

@media (max-width: 700px) {
  .section-cta {
    height: auto !important;
    min-height: 62px;
    padding: 12px 18px !important;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
  }
}

@media (max-width: 520px) {
  .w {
    width: calc(100% - 30px);
  }

  .nav {
    height: 64px;
  }

  .brand-logo {
    height: 24px;
  }

  .hero {
    padding: 100px 0 48px;
  }

  .iso-line {
    font-size: 22px;
    gap: 9px;
  }

  .iso-line i {
    height: 20px;
  }

  .visual {
    height: 300px;
  }

  .ring {
    width: 280px;
    height: 220px;
  }

  .ring::before {
    inset: 42px 50px;
  }

  .core {
    width: 110px;
    height: 82px;
    font-size: 9px;
  }

  .orbit-item {
    font-size: 7px;
    padding: 4px 5px;
    max-width: 78px;
    letter-spacing: -0.01em;
  }

  .foot {
    flex-direction: column;
  }

  .clean-metrics {
    grid-template-columns: 1fr;
  }

  .metric:nth-child(odd) {
    border-right: 0;
  }

  .metric:nth-child(even) {
    padding-left: 0;
  }

  .iso-metric {
    grid-column: 1;
  }
}
