/* Промо СДО «Мир профессий» — палитра от логотипа */
@font-face {
  font-family: "Manrope";
  src: url("../fonts/Manrope-wght.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --brand: #025682;
  --brand-dark: #173b52;
  --accent: #0b6e9f;
  --ink: #464f58;
  --ink-strong: #1f2a33;
  --bg: #ffffff;
  --bg-soft: #eef4f7;
  --line: #d6e2ea;
  --r-btn: 10px;
  --r-field: 8px;
  --r-card: 14px;
  --wrap: 1180px;
  --shadow: 0 6px 24px rgba(23, 59, 82, .08);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font: 400 17px/1.6 "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a[href^="tel:"] { white-space: nowrap; }
a:hover { color: var(--brand); }
h1, h2, h3 { color: var(--ink-strong); line-height: 1.2; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: clamp(30px, 4.2vw, 50px); letter-spacing: -.02em; }
h2 { font-size: clamp(24px, 2.8vw, 36px); letter-spacing: -.01em; }
h3 { font-size: 20px; }
p { margin: 0 0 1em; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: 24px; }
.muted { color: #6b7782; }
.section { padding-block: clamp(48px, 7vw, 96px); }
.section-soft { background: var(--bg-soft); }
.lead { font-size: clamp(18px, 1.6vw, 21px); }
.eyebrow { font-size: 14px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }

/* кнопки */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border-radius: var(--r-btn); border: 2px solid var(--brand);
  background: var(--brand); color: #fff; font: inherit; font-weight: 700; font-size: 16px;
  text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s, color .15s;
}
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn-ghost { background: transparent; color: var(--brand); }
.btn-ghost:hover { background: var(--brand); color: #fff; }
.btn-light { background: #fff; border-color: #fff; color: var(--brand-dark); }
.btn-light:hover { background: var(--bg-soft); border-color: var(--bg-soft); color: var(--brand-dark); }
.btn-outline-light { background: transparent; border-color: rgba(255,255,255,.7); color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,.12); color: #fff; border-color: #fff; }
.btn-sm { padding: 9px 18px; font-size: 15px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }

/* шапка */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.header-row { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.logo img { width: auto; height: 72px; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav-item { position: relative; }
.nav-item > a { display: block; padding: 10px 14px; color: var(--ink-strong); font-weight: 600; font-size: 15px; text-decoration: none; border-radius: var(--r-field); }
.nav-item > a:hover, .nav-item > a[aria-current] { color: var(--brand); background: var(--bg-soft); }
.has-sub > a::after { content: ""; display: inline-block; width: 7px; height: 7px; margin-left: 8px; border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-3px) rotate(45deg); }
.sub {
  position: absolute; top: 100%; left: 0; min-width: 260px; padding: 8px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s;
}
.sub a { display: block; padding: 10px 12px; border-radius: var(--r-field); color: var(--ink-strong); text-decoration: none; font-size: 15px; }
.sub a:hover { background: var(--bg-soft); color: var(--brand); }
.has-sub:hover .sub, .has-sub:focus-within .sub { opacity: 1; visibility: visible; transform: none; }
.nav-cta { margin-left: 10px; }
.nav-toggle, .burger { display: none; }

/* герой */
.hero { position: relative; color: #fff; background: var(--brand-dark); overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: var(--hero-img) center/cover no-repeat; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(23,59,82,.94) 0%, rgba(23,59,82,.82) 42%, rgba(2,86,130,.25) 100%); }
.hero .wrap { position: relative; z-index: 1; padding-block: clamp(72px, 11vw, 150px); }
.hero h1 { color: #fff; max-width: 15em; }
.hero .lead { max-width: 34em; color: rgba(255,255,255,.88); margin-bottom: 32px; }
.hero-sm .wrap { padding-block: clamp(56px, 7vw, 96px); }

/* сетки и карточки */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.split { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.split img { border-radius: var(--r-card); box-shadow: var(--shadow); }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); padding: 28px; }
.section-soft .card { border-color: transparent; box-shadow: var(--shadow); }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.icon { width: 52px; height: 52px; border-radius: 12px; background: var(--bg-soft); color: var(--brand); display: grid; place-items: center; margin-bottom: 18px; }
.section-soft .icon { background: #fff; }
.icon svg { width: 26px; height: 26px; }

.photo-card { position: relative; display: block; border-radius: var(--r-card); overflow: hidden; color: #fff; text-decoration: none; min-height: 340px; background: var(--brand-dark); }
.photo-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.photo-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(23,59,82,0) 30%, rgba(23,59,82,.9) 100%); }
.photo-card:hover img { transform: scale(1.04); }
.photo-card .pc-body { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 28px; }
.photo-card h3 { color: #fff; font-size: 26px; margin-bottom: 6px; }
.photo-card span { font-weight: 600; color: rgba(255,255,255,.9); }
.photo-card:hover { color: #fff; }

.check { list-style: none; padding: 0; margin: 0 0 1em; }
.check li { position: relative; padding-left: 32px; margin-bottom: 10px; }
.check li::before { content: ""; position: absolute; left: 0; top: 4px; width: 20px; height: 20px; border-radius: 50%; background: var(--bg-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%23025682' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/20px no-repeat; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.steps > li { counter-increment: step; position: relative; padding: 22px 24px 22px 76px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); }
.steps > li::before { content: counter(step); position: absolute; left: 22px; top: 20px; width: 38px; height: 38px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 700; display: grid; place-items: center; }

.stat { font-size: clamp(32px, 4vw, 46px); font-weight: 800; color: var(--brand); line-height: 1; margin-bottom: 8px; }

/* призыв и форма */
.cta { background: linear-gradient(120deg, var(--brand-dark), var(--brand)); color: #fff; border-radius: var(--r-card); padding: clamp(32px, 5vw, 56px); display: grid; grid-template-columns: 1.1fr 1fr; gap: 32px; align-items: center; }
.cta h2 { color: #fff; }
.cta p { color: rgba(255,255,255,.88); }
.form { display: grid; gap: 12px; }
.form input, .form select, .form textarea { width: 100%; font: inherit; font-size: 16px; padding: 13px 16px; border-radius: var(--r-field); border: 1px solid var(--line); background: #fff; color: var(--ink-strong); }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.form .note { font-size: 13px; color: rgba(255,255,255,.75); margin: 0; }
.form-ok { display: none; background: rgba(255,255,255,.14); border-radius: var(--r-field); padding: 14px 16px; font-weight: 600; }
.form.sent .form-ok { display: block; }

/* курсы */
.course-meta { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 18px; padding: 0; list-style: none; }
.course-meta li { background: var(--bg-soft); color: var(--brand-dark); border-radius: 999px; padding: 6px 14px; font-size: 14px; font-weight: 600; }
.price { font-size: 28px; font-weight: 800; color: var(--brand-dark); }
.list-cards { display: grid; gap: 16px; }
.list-card { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 22px 26px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); text-decoration: none; color: var(--ink-strong); font-weight: 600; }
.list-card:hover { border-color: var(--accent); color: var(--brand); }
.list-card small { display: block; font-weight: 400; color: #6b7782; margin-top: 4px; }

/* хлебные крошки и справка */
.crumbs { font-size: 14px; margin-bottom: 18px; color: rgba(255,255,255,.75); }
.crumbs a { color: rgba(255,255,255,.9); }
.help-layout { display: grid; grid-template-columns: 280px 1fr; gap: 40px; align-items: start; }
.help-nav { position: sticky; top: 96px; background: var(--bg-soft); border-radius: var(--r-card); padding: 18px; font-size: 15px; }
.help-nav h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: #6b7782; margin: 14px 8px 6px; }
.help-nav h2:first-child { margin-top: 0; }
.help-nav a { display: block; padding: 8px 10px; border-radius: var(--r-field); color: var(--ink-strong); text-decoration: none; }
.help-nav a:hover, .help-nav a[aria-current] { background: #fff; color: var(--brand); }
.article h2 { font-size: 24px; margin-top: 1.6em; }
.article figure { margin: 22px 0 30px; }
.article figure img { border: 1px solid var(--line); border-radius: var(--r-field); }
.article figcaption { font-size: 14px; color: #6b7782; margin-top: 8px; }
.tip { background: var(--bg-soft); border-left: 4px solid var(--accent); border-radius: var(--r-field); padding: 16px 20px; margin: 20px 0; }

/* новости */
.timeline { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 32px 28px; }
.timeline li::before { content: ""; position: absolute; left: -8px; top: 6px; width: 14px; height: 14px; border-radius: 50%; background: var(--brand); border: 3px solid #fff; box-shadow: 0 0 0 2px var(--brand); }
.timeline time { font-size: 14px; font-weight: 700; color: var(--accent); }

/* подвал */
.site-footer { background: var(--brand-dark); color: rgba(255,255,255,.82); padding-top: 56px; margin-top: 0; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; }
.footer-logo { width: auto; height: 100px; margin-bottom: 16px; }
.footer-h { color: #fff; font-size: 16px; margin-bottom: 12px; }
.site-footer .muted { color: rgba(255,255,255,.65); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.14); margin-top: 32px; padding-block: 20px; font-size: 14px; color: rgba(255,255,255,.6); }

/* адаптив */
@media (max-width: 1080px) {
  .nav-toggle { display: block; position: absolute; opacity: 0; width: 1px; height: 1px; }
  .burger { display: grid; place-items: center; width: 44px; height: 44px; margin-left: auto; cursor: pointer; border-radius: var(--r-field); }
  .burger span, .burger span::before, .burger span::after { display: block; width: 22px; height: 2px; background: var(--ink-strong); position: relative; transition: .2s; }
  .burger span::before, .burger span::after { content: ""; position: absolute; left: 0; }
  .burger span::before { top: -7px; } .burger span::after { top: 7px; }
  .nav-toggle:checked + .burger span { background: transparent; }
  .nav-toggle:checked + .burger span::before { top: 0; transform: rotate(45deg); }
  .nav-toggle:checked + .burger span::after { top: 0; transform: rotate(-45deg); }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 16px 18px; box-shadow: var(--shadow); max-height: calc(100vh - 76px); overflow-y: auto; }
  .nav-toggle:checked ~ .nav { display: flex; }
  .sub { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 6px 14px; min-width: 0; }
  .has-sub > a::after { display: none; }
  .nav-cta { margin: 10px 0 0; }
  .header-row { position: relative; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .help-layout { grid-template-columns: 1fr; }
  .help-nav { position: static; }
}
@media (max-width: 820px) {
  .grid-2, .grid-3, .split, .cta, .footer-grid { grid-template-columns: 1fr; }
  .hero::after { background: linear-gradient(180deg, rgba(23,59,82,.9), rgba(23,59,82,.8)); }
  .photo-card { min-height: 260px; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .wrap { padding-inline: 16px; }
  .grid-4 { grid-template-columns: 1fr; }
  .btn-row .btn { width: 100%; }
  .steps > li { padding: 70px 18px 18px; }
  .steps > li::before { top: 18px; left: 18px; }
  .list-card { flex-direction: column; align-items: flex-start; }
}

/* таблица программы курса, страницы курсов */
.table-wrap { overflow-x: auto; margin-top: 24px; border: 1px solid var(--line); border-radius: var(--r-card); background: #fff; }
.program { width: 100%; border-collapse: collapse; font-size: 15px; }
.program th, .program td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.program th { background: var(--bg-soft); color: var(--brand-dark); font-weight: 700; white-space: nowrap; }
.program tr:last-child td { border-bottom: 0; }
.program td:first-child, .program td:last-child { white-space: nowrap; }
.card .price { margin: 0 0 14px; }
.steps h3 { margin-bottom: 6px; }
@media (max-width: 640px) { .program { font-size: 14px; min-width: 520px; } }

/* появление блоков при прокрутке вниз (task/208): один раз, обратно не прячется */
.js-reveal .reveal { opacity: 0; transform: translateY(24px); transition: opacity .4s ease-out, transform .4s ease-out; }
.js-reveal .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js-reveal .reveal { opacity: 1; transform: none; transition: none; } }
