:root {
  --navy: #0b1f3a;
  --navy-deep: #071528;
  --blue: #1e4b8c;
  --accent: #3b82c4;
  --sky: #e8f1fa;
  --mist: #f4f8fc;
  --white: #ffffff;
  --ink: #142338;
  --muted: #4a5d78;
  --line: #d0e2f4;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Manrope", "Segoe UI", system-ui, sans-serif;
  --radius: 12px;
  --header-h: 76px;
}

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

html {
  scroll-behavior: smooth;
  background: #daeaf7;
}

body {
  margin: 0;
  padding-left: 4.5%;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.625;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: url("../images/scenes/bg-page.jpg") left top / 100% 100% no-repeat;
}

img { max-width: 100%; }

a { color: var(--blue); }

a:hover { color: var(--navy); }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

::selection {
  background: var(--sky);
  color: var(--navy);
}

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  background: var(--white);
  color: var(--navy);
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 50;
}

.skip:focus { top: 12px; }

.container {
  width: min(1080px, calc(100% - 40px));
  margin-inline: auto;
}

.top {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.top__in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  min-height: var(--header-h);
  padding: 12px 0;
}

.brand {
  display: flex;
  align-items: center;
  line-height: 0;
}

.brand img { height: 52px; width: auto; }

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
}

.nav a:not(.btn) {
  color: var(--blue);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
}

.nav a:not(.btn):hover { text-decoration: underline; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--blue);
  color: var(--white);
  border: 0;
  border-radius: 10px;
  padding: 12px 22px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.4;
  text-decoration: none;
}

.btn:hover { background: var(--navy); color: var(--white); }

.btn--ghost {
  background: var(--white);
  color: var(--blue);
  border: 2px solid var(--blue);
  padding: 10px 18px;
}

.btn--ghost:hover { background: var(--sky); color: var(--navy); }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(280px, 0.92fr);
  gap: 28px 36px;
  align-items: center;
  padding: 40px 0 8px;
}

.hero h1 { grid-column: 1 / -1; margin-bottom: 18px; }

.claim {
  grid-column: 1 / -1;
  justify-self: start;
  margin: 0 0 22px;
  padding: 8px 0;
  border-top: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 26px;
  line-height: 1.3;
  color: var(--navy);
}

h1 {
  margin: 0 0 16px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 48px;
  line-height: 1.17;
  color: var(--navy);
}

.lead { margin: 0; max-width: 40rem; }

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.aside {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
  max-width: 40rem;
}

.intro {
  margin: 36px 0 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 28px;
  line-height: 1.3;
  color: var(--navy);
}

.hint {
  margin: 0 0 18px;
  color: var(--muted);
}

.accs {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 56px;
}

.acc {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  scroll-margin-top: 92px;
}

.acc:hover,
.acc.is-open { border-color: var(--blue); }

.acc__h { margin: 0; font-size: inherit; font-weight: inherit; }

.acc__btn {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  width: 100%;
  padding: 12px;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
  border-radius: var(--radius);
}

.acc__btn:hover { background: var(--mist); }

.acc__num {
  display: block;
  margin-bottom: 4px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 28px;
  line-height: 1;
  color: var(--blue);
}

.acc__title {
  display: block;
  font-weight: 700;
  font-size: 20px;
  line-height: 1.35;
  color: var(--navy);
}

.chev {
  width: 28px;
  height: 28px;
  color: var(--blue);
  transition: transform 0.35s ease;
}

.acc.is-open .chev { transform: rotate(180deg); }

.acc__panel {
  display: grid;
  grid-template-rows: 1fr;
}

.js .acc__panel {
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s ease;
}

.js .acc.is-open .acc__panel { grid-template-rows: 1fr; }

.acc__inner { min-height: 0; overflow: hidden; }

.js .acc:not(.is-open) .acc__inner { visibility: hidden; }

.acc__body {
  padding: 4px 18px 22px;
  border-top: 1px solid var(--line);
}

.problem { margin: 16px 0 18px; }

.tag {
  font-weight: 700;
  color: var(--blue);
}

.cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.card {
  background: var(--mist);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.card .frame { border-radius: 0; }

.card__body { padding: 14px 16px 18px; }

.card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.35;
  color: var(--navy);
}

.card p { margin: 0 0 10px; }

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

.example {
  margin: 12px 0 0;
  padding: 12px 14px;
  background: var(--white);
  border-left: 3px solid var(--blue);
  border-radius: 0 10px 10px 0;
}

.note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}

.frame {
  position: relative;
  background: var(--sky);
  overflow: hidden;
}

.frame[data-ratio="16/9"] { aspect-ratio: 16 / 9; }
.frame[data-ratio="3/2"] { aspect-ratio: 3 / 2; }
.frame[data-ratio="4/3"] { aspect-ratio: 4 / 3; }
.frame[data-ratio="1/1"] { aspect-ratio: 1 / 1; }
.frame[data-ratio="2/1"] { aspect-ratio: 2 / 1; }

.frame__ph { position: absolute; inset: 0; }

.frame__ph svg {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 50%;
  width: 46%;
  height: 46%;
  transform: translate(-50%, -50%);
}

.frame--full .frame__ph svg {
  inset: 0;
  width: 100%;
  height: 100%;
  transform: none;
  left: 0;
  top: 0;
}

.frame__ph::before,
.frame__ph::after {
  content: "";
  position: absolute;
  border-radius: 10px;
}

.frame--full .frame__ph::before,
.frame--full .frame__ph::after { content: none; }

.frame[data-v="0"] .frame__ph::before { width: 36%; height: 48%; left: 7%; top: 16%; background: var(--white); }
.frame[data-v="0"] .frame__ph::after { width: 24%; height: 20%; right: 8%; bottom: 12%; background: var(--blue); }
.frame[data-v="1"] .frame__ph::before { width: 28%; height: 36%; right: 8%; top: 12%; background: var(--white); }
.frame[data-v="1"] .frame__ph::after { width: 18%; height: 42%; left: 10%; bottom: 12%; background: var(--navy); }
.frame[data-v="2"] .frame__ph::before { width: 42%; height: 22%; left: 8%; bottom: 12%; background: var(--white); }
.frame[data-v="2"] .frame__ph::after { width: 20%; height: 20%; right: 12%; top: 14%; background: var(--accent); border-radius: 50%; }
.frame[data-v="3"] .frame__ph::before { width: 22%; height: 55%; left: 10%; top: 14%; background: var(--blue); }
.frame[data-v="3"] .frame__ph::after { width: 30%; height: 24%; right: 8%; bottom: 14%; background: var(--white); }
.frame[data-v="4"] .frame__ph::before { width: 34%; height: 34%; right: 10%; bottom: 12%; background: var(--navy); }
.frame[data-v="4"] .frame__ph::after { width: 26%; height: 16%; left: 8%; top: 14%; background: var(--white); }
.frame[data-v="5"] .frame__ph::before { width: 46%; height: 18%; left: 8%; top: 14%; background: var(--white); }
.frame[data-v="5"] .frame__ph::after { width: 16%; height: 28%; right: 10%; bottom: 14%; background: var(--accent); }

.frame__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
}

.close, .fit, .contact { margin-bottom: 48px; }

h2 {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 32px;
  line-height: 1.25;
  color: var(--navy);
}

.close-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 18px;
}

.tile {
  margin: 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.tile figcaption {
  padding: 12px 12px 14px;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.35;
}

.fit {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}

.facts {
  margin: 0;
  padding: 0;
  list-style: none;
}

.facts li {
  margin: 0 0 10px;
  padding-left: 16px;
  border-left: 3px solid var(--blue);
}

.contact {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 22px 32px;
}

.contact .split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 28px;
  align-items: center;
}

.mail-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  margin: 12px 0 0;
  font-weight: 700;
  color: var(--navy);
}

.mail {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  vertical-align: middle;
}

.mail img { height: 28px; width: auto; display: block; }
.mail--lg img { height: 36px; }
.mail img + img { margin-left: -1px; }

.foot {
  background: var(--navy);
  color: var(--white);
  border-top: 4px solid var(--accent);
}

.foot__in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 28px;
  padding: 28px 0;
}

.foot__logo { height: 48px; width: auto; }

.foot p { margin: 0; font-weight: 700; }

.foot .mail img { height: 26px; }

@media (max-width: 900px) {
  h1 { font-size: 32px; line-height: 1.25; }
  .claim { font-size: 20px; }
  .hero, .fit, .contact .split, .cards, .close-grid {
    grid-template-columns: 1fr;
  }
  .close-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .container { width: min(1080px, calc(100% - 28px)); }
  .hero { padding-top: 28px; }
  h1 { font-size: 32px; line-height: 1.25; }
  h2, .intro { font-size: 26px; }
  .acc__btn {
    grid-template-columns: 1fr auto;
  }
  .acc__media { grid-column: 1 / -1; }
  .acc__title { font-size: 18px; }
  .close-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .acc__panel,
  .chev { transition: none; }
}
