/* UAVPROG landing page. Layout follows the Figma frame "Home Page" (1440px wide, content 1232px). */

:root {
  --bg: #FCFEFE;
  --surface: #FAFCFF;
  --ink: #222223;
  --ink-2: #4F4F52;
  --mist-100: #E4E4EC;
  --blue: #2D7FFD;
  --sky: #2DA5FD;
  --blue-200: #93C5FD;
  --blue-100: #D3E5FE;

  /* theme tokens: light values here, dark values in [data-theme="dark"] below */
  --card: #FFFFFF;          /* cards and panels */
  --card-2: #F3F7FD;        /* subtle fills inside cards */
  --muted: #8C8D8D;
  --line: var(--blue-100);  /* hairlines and card borders */
  --chip: rgba(79, 79, 82, .15);
  --chip-weak: rgba(79, 79, 82, .1);
  --chip-solid: rgba(255, 255, 255, .85);
  --glow: var(--blue-200);  /* light-blue glow of the hero, steps and media frames */
  --glow-center: rgba(255, 255, 255, .18);
  --glow-light: #B5D6FE;
  --header-bg: rgba(252, 254, 254, .82);
  --menu-bg: rgba(252, 254, 254, .97);
  --shadow: rgba(7, 46, 108, .35);
  --dots: #D9D9D9;
  --btn-dark-bg: #4F4F52;
  --btn-dark-bg-hover: #222223;
  --btn-dark-fg: #FFFFFF;
  color-scheme: light;

  --font-display: "Hanken Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;

  --container: 1232px;
  --gutter: max(24px, calc((100% - var(--container)) / 2));
  /* one Figma pixel, scaled down on viewports narrower than the 1440px frame */
  --u: calc(min(100vw, 1440px) / 1440);
  --radius: 24px;
}

/* Dark theme: brand black and greys, the brand blues stay as accents. The head script sets
   data-theme from the saved choice or the system setting before the first paint. */
:root[data-theme="dark"] {
  --bg: #19191A;
  --surface: #1E1E20;
  --card: #222223;
  --card-2: #2B2B2E;
  --ink: #FCFEFE;
  --ink-2: #BDBEC3;
  --muted: #8C8D8D;
  --mist-100: #2B2B2E;
  --line: rgba(252, 254, 254, .1);
  --chip: rgba(252, 254, 254, .12);
  --chip-weak: rgba(252, 254, 254, .07);
  --chip-solid: rgba(34, 34, 35, .85);
  --glow: rgba(45, 127, 253, .24);
  --glow-center: rgba(25, 25, 26, .2);
  --glow-light: rgba(45, 165, 253, .32);
  --header-bg: rgba(25, 25, 26, .82);
  --menu-bg: rgba(34, 34, 35, .98);
  --shadow: rgba(0, 0, 0, .6);
  --dots: #3A3A3E;
  --btn-dark-bg: #FCFEFE;
  --btn-dark-bg-hover: #D3E5FE;
  --btn-dark-fg: #222223;
  color-scheme: dark;
}
/* the logo has dark letters; the dark theme uses a copy with light letters */
.logo--dark { display: none; }
:root[data-theme="dark"] .logo--light { display: none; }
:root[data-theme="dark"] .logo--dark { display: block; }

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }

.container { width: 100%; max-width: calc(var(--container) + 48px); margin: 0 auto; padding: 0 24px; }

.skip-link {
  position: absolute; inset-inline-start: 16px; top: -48px; z-index: 100;
  padding: 8px 16px; border-radius: 8px; background: var(--ink); color: var(--bg);
}
.skip-link:focus { top: 16px; }

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

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 24px; border: 0; border-radius: 999px;
  font: 500 16px/1 var(--font-body); white-space: nowrap;
  transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn--lg { height: 56px; padding: 0 28px; font-weight: 600; }
.btn--dark { background: var(--btn-dark-bg); color: var(--btn-dark-fg); }
.btn--dark:hover { background: var(--btn-dark-bg-hover); }
.btn--primary { background: linear-gradient(115deg, var(--sky) 0%, var(--blue) 100%); color: var(--bg); }
.btn--primary:hover { box-shadow: 0 10px 24px -10px rgba(45, 127, 253, .7); }
.btn__chevron { width: 24px; height: 24px; margin-inline-end: -6px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

.icon-btn {
  display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  border: 0; background: var(--chip); color: var(--ink-2); transition: background-color .2s ease, color .2s ease;
}
.icon-btn:hover { background: var(--chip); color: var(--ink); box-shadow: inset 0 0 0 48px var(--chip-weak); }
.icon-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

.round-btn {
  display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%;
  background: var(--blue-200); color: #fff; transition: background-color .2s ease, opacity .2s ease;
}
.round-btn:hover { background: var(--blue); }
.round-btn:disabled { opacity: .45; cursor: default; background: var(--blue-200); }
.round-btn svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Header ---------- */

.header {
  position: sticky; top: 0; z-index: 50;
  padding: 36px 0; transition: padding .25s ease, background-color .25s ease, box-shadow .25s ease;
}
.header.is-scrolled {
  padding: 12px 0;
  background: var(--header-bg);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line);
}
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.header__logo { flex: none; }
.header__logo .logo { width: 180px; height: auto; }
.header__actions { display: flex; align-items: center; gap: 10px; }

.nav {
  display: flex; align-items: center; height: 48px; padding: 0; border-radius: 999px;
  background: var(--chip-weak);
}
.nav__link {
  display: flex; align-items: center; height: 48px; padding: 0 22px; border-radius: 999px;
  font-weight: 500; color: var(--ink-2); transition: color .2s ease, background-color .2s ease;
}
.nav__link:hover { color: var(--ink); }
.nav__link.is-active { background: var(--chip); color: var(--ink); }
.nav__link.is-soon { cursor: default; }
.nav__link.is-soon:hover { color: var(--ink-2); }

.menu-toggle { display: none; }

/* products and language menus (main.js toggles .is-open; hover opens them on desktop) */
.nav__group { position: relative; }
.nav__link--menu { gap: 2px; border: 0; background: none; }
.nav__chevron { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s ease; }
[data-dropdown].is-open .nav__chevron { transform: rotate(180deg); }
.dropdown {
  position: absolute; top: calc(100% + 10px); inset-inline-start: 0; z-index: 60; min-width: 220px; padding: 8px;
  border-radius: 20px; background: var(--menu-bg); box-shadow: 0 24px 48px -24px var(--shadow), 0 0 0 1px var(--line);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .18s ease, transform .18s ease, visibility .18s;
}
.dropdown::before { content: ""; position: absolute; inset: -12px 0 auto; height: 12px; } /* hover bridge */
[data-dropdown].is-open > .dropdown { opacity: 1; visibility: visible; transform: none; }
@media (hover: hover) and (min-width: 1025px) {
  .nav__group:hover > .dropdown { opacity: 1; visibility: visible; transform: none; }
}
.dropdown--products { width: 360px; }
.dropdown__product { display: flex; align-items: center; gap: 14px; padding: 10px 12px; border-radius: 14px; }
.dropdown__product img { flex: none; width: 76px; height: 46px; object-fit: contain; }
.dropdown__product b, .dropdown__more b { display: block; font: 600 16px/1.2 var(--font-display); color: var(--ink); }
.dropdown__product small, .dropdown__more small { display: block; margin-top: 3px; font-size: 13px; line-height: 1.35; color: var(--ink-2); }
.dropdown__more { display: block; margin-top: 6px; padding: 12px; border-top: 1px solid var(--line); }
.dropdown__product:hover, .dropdown__more:hover, .dropdown__lang:hover { background: var(--chip-weak); }
.dropdown__product[aria-current] b { color: var(--blue); }

.lang { position: relative; }
.icon-btn.lang__btn { display: flex; gap: 6px; width: auto; padding: 0 14px 0 12px; border-radius: 999px; }
.lang__code { font: 600 13px/1 var(--font-body); letter-spacing: .04em; }
.dropdown--lang { inset-inline-start: auto; inset-inline-end: 0; }
.dropdown__lang { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 14px; border-radius: 12px; font-weight: 500; color: var(--ink); }
.dropdown__lang[aria-current] { color: var(--blue); }
.dropdown__code { font-size: 12px; font-weight: 600; color: var(--muted); }

.theme-btn__sun { display: none; }
:root[data-theme="dark"] .theme-btn__moon { display: none; }
:root[data-theme="dark"] .theme-btn__sun { display: block; }

/* ---------- Hero ---------- */

.hero {
  position: relative; margin-top: -120px; padding-top: 170px;
  height: calc(var(--u) * 980 + 0px); min-height: 640px;
  border-radius: 0 0 var(--radius) var(--radius); overflow: hidden;
  background:
    linear-gradient(180deg, transparent 81.9%, var(--bg) 99%),
    radial-gradient(95.67% 95.66% at 50% 0.9%, var(--glow-center) 89.05%, var(--glow) 100%) var(--bg);
}
.hero::after { /* bottom fade over the dashboard, as in the design */
  content: ""; position: absolute; inset: auto 0 0; z-index: 1; height: 18%; pointer-events: none;
  background: linear-gradient(180deg, transparent, var(--bg) 92%);
}
.hero__inner { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero__title {
  font: 500 clamp(38px, 4.55vw, 65.5px)/1.27 var(--font-display);
  letter-spacing: -.005em;
  background: linear-gradient(90deg, var(--muted) 0%, var(--ink) 22%, var(--ink) 78%, var(--muted) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero__title + .btn { margin-top: 39px; }
.hero__screen { width: min(1189px, 100%); margin-top: 44px; }
.hero__screen img { width: 100%; height: auto; }

.hero__stage { /* the 1440 px Figma frame, centred, so the drones keep their place on any width or zoom */
  position: absolute; top: 0; bottom: 0; left: max(0px, 50% - 720px); width: calc(var(--u) * 1440);
  pointer-events: none; z-index: 2;
}
.hero__drone { position: absolute; transform-origin: 0 0; height: auto; }
.hero__drone--left {
  left: calc(var(--u) * -1); top: calc(var(--u) * 323.8); width: calc(var(--u) * 187.7);
  transform: rotate(-28.59deg); animation: hover-a 7s ease-in-out infinite;
}
.hero__drone--right {
  left: calc(var(--u) * 1449.6); top: calc(var(--u) * 464.3); width: calc(var(--u) * 238);
  transform: matrix(-0.946365, -0.323099, -0.323099, 0.946365, 0, 0); animation: hover-b 8s ease-in-out infinite;
}
@keyframes hover-a { 50% { transform: translate(4px, -10px) rotate(-26.5deg); } }
@keyframes hover-b { 50% { transform: matrix(-0.946365, -0.323099, -0.323099, 0.946365, -6, -12); } }
@media (prefers-reduced-motion: reduce) { .hero__drone { animation: none; } }

/* ---------- Sections ---------- */

.section { padding-top: 123px; }
.section-head { margin-bottom: 64px; }
.section-head--row { display: flex; align-items: flex-start; justify-content: space-between; gap: 32px; }
.section-head--row .btn { margin-inline-end: 25px; }

.h2 { font: 500 clamp(36px, 3.9vw, 56px)/1.2 var(--font-display); color: var(--ink); }
.subtitle {
  margin-top: 14px; font: 500 clamp(20px, 2.15vw, 30px)/1.3 var(--font-display); color: var(--ink-2);
  text-transform: capitalize;
}
.subtitle--narrow { max-width: 680px; }
.h3 { font: 500 30px/1.3 var(--font-display); color: var(--ink-2); }
.lead { margin-top: 10px; font-size: 20px; line-height: 1.5; color: var(--ink-2); }

/* ---------- Lessons ---------- */

.lessons .section-head { margin-bottom: 0; } /* the zoom block below keeps the gap */

.motion {
  position: relative; aspect-ratio: 1232 / 693; border-radius: var(--radius); overflow: hidden;
  background:
    radial-gradient(80% 90% at 15% 10%, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 60%),
    var(--blue-200);
}
:root[data-theme="dark"] .motion { background: radial-gradient(80% 90% at 15% 10%, rgba(45, 165, 253, .35), transparent 60%), var(--card); }
/* media slot: blue frame that holds a video (or keeps its fallback until the file exists) */
.slot { position: relative; overflow: hidden; background-size: cover; background-position: center; }
.slot > video, .slot > iframe, .slot > img { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.slot > iframe { opacity: 0; transition: opacity .6s ease; }
.slot.has-video > iframe { opacity: 1; }
.slot__play { position: absolute; inset-inline: 0; margin-inline: auto; top: calc(50% - 22px); z-index: 2; width: 44px; height: 44px; background: var(--blue); box-shadow: 0 0 0 4px var(--card); }
.slot__play::before { content: ""; width: 14px; height: 17px; background: currentColor; clip-path: polygon(0 0, 100% 50%, 0 100%); transform: translateX(1px); }
.slot__play[hidden] { display: none; }
.motion > iframe { pointer-events: none; }
.motion.has-video .motion__collage, .motion.has-poster .motion__collage { display: none; }
.motion__yt {
  position: absolute; left: calc(var(--cl, 0px) + 20px); bottom: calc(var(--cb, 0px) + 20px); z-index: 2;
  display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 999px; font: 500 14px/1 var(--font-body);
  color: var(--bg); background: rgba(34, 34, 35, .65); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.motion__yt::before { content: ""; width: 9px; height: 10px; background: currentColor; clip-path: polygon(0 0, 100% 50%, 0 100%); }
.motion__yt:hover { background: rgba(34, 34, 35, .85); }

/* Scroll zoom: while the sticky block is pinned, the frame grows from the spot under the heading
   to the whole screen. main.js clips the frame (--ct --cr --cb --cl, --crad) and scales the video
   inside it so it always covers the visible part. */
/* the frame sits centred in the pinned screen; the negative margin keeps it 62px under the heading */
.zoom { position: relative; height: 220vh; margin-top: calc(62px - 50vh + min(100% - 48px, var(--container)) * 693 / 1232 / 2); }
.zoom__sticky {
  position: sticky; top: 0; display: flex; flex-direction: column; justify-content: center;
  height: 100vh; overflow: hidden; pointer-events: none;
}
.zoom__spot { aspect-ratio: 1232 / 693; }
.zoom__frame {
  position: absolute; inset: 0; overflow: hidden; pointer-events: auto; background: var(--glow);
  clip-path: inset(var(--ct, 0px) var(--cr, 0px) var(--cb, 0px) var(--cl, 0px) round var(--crad, 0px));
}
.zoom .motion {
  position: absolute; left: 0; top: 0; width: max(100%, 100vh * 1232 / 693); border-radius: 0;
  transform-origin: 0 0; will-change: transform;
}
@media (max-width: 720px), (prefers-reduced-motion: reduce) {
  .lessons .section-head { margin-bottom: 40px; }
  .zoom { height: auto; margin-top: 0; }
  .zoom__sticky { position: static; height: auto; overflow: visible; }
  .zoom__sticky > .container { display: none; }
  .zoom__frame {
    position: relative; width: min(100% - 48px, var(--container)); margin: 0 auto;
    aspect-ratio: 1232 / 693; border-radius: var(--radius); clip-path: none;
  }
  .zoom .motion { width: 100%; transform: none !important; }
}
@media (max-width: 720px) {
  .motion__yt, .sound-btn { height: 32px; padding: 0 12px; font-size: 13px; }
  .motion__yt { left: 12px; bottom: 12px; }
  .zoom__frame .sound-btn { right: 12px; bottom: 12px; }
}
.sound-btn {
  position: absolute; right: calc(var(--cr, 0px) + 20px); bottom: calc(var(--cb, 0px) + 20px); z-index: 2;
  height: 40px; padding: 0 18px; border: 0; border-radius: 999px;
  font: 500 14px/1 var(--font-body); color: var(--bg); background: rgba(34, 34, 35, .65);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.sound-btn:hover { background: rgba(34, 34, 35, .85); }
.motion__collage { position: absolute; inset: 0; }
.motion__shot {
  position: absolute; height: auto; border-radius: 14px; background: #fff;
  box-shadow: 0 30px 60px -24px rgba(7, 46, 108, .45);
}
.motion__shot--a { width: 46%; left: 27%; top: 14%; z-index: 2; }
.motion__shot--b { width: 33%; left: 6%; top: 42%; transform: rotate(-4deg); }
.motion__shot--c { width: 33%; right: 6%; top: 40%; transform: rotate(4deg); }

.features-head { margin-top: 70px; margin-bottom: 52px; }

.carousel { position: relative; }
.carousel__track {
  display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  padding: 0 var(--gutter) 8px; scroll-padding-inline-start: var(--gutter); scrollbar-width: none;
}
.carousel__track::-webkit-scrollbar { display: none; }
.carousel__controls { display: flex; justify-content: flex-end; gap: 24px; margin-top: 43px; }

.lesson-card {
  flex: 0 0 400px; max-width: calc(100vw - 48px); scroll-snap-align: start;
  min-height: 377px; padding-bottom: 24px; border-radius: 16px; overflow: hidden;
  background: linear-gradient(180deg, var(--glow-center) 62%, var(--mist-100) 107%);
}
.lesson-card__media { position: relative; height: 260px; overflow: hidden; }
/* a short loop of the lesson format recorded on the platform (800×520); the poster shows until it plays */
.lesson-card__media.slot { background-color: #F6FAFF; }
.lesson-card__media::after {
  content: ""; position: absolute; inset: auto 0 0; height: 30px;
  background: linear-gradient(180deg, transparent, var(--bg));
}
.lesson-card__title { margin: 25px 24px 0; font: 400 20px/1.3 var(--font-body); color: var(--ink-2); }
.lesson-card__text { margin: 10px 24px 0; font-size: 16px; line-height: 1.15; color: var(--ink-2); }

/* ---------- Animations ----------
   Elements marked [data-anim] pause while off screen (main.js adds .is-playing) and stop with reduced motion. */

[data-anim]:not(.is-playing) *, [data-anim]:not(.is-playing) *::before, [data-anim]:not(.is-playing) *::after { animation-play-state: paused !important; }
@media (prefers-reduced-motion: reduce) { [data-anim] *, [data-anim] *::before { animation: none !important; } }

/* ---------- Blocks ---------- */

.blocks { position: relative; padding-top: 0; margin-top: 110px; overflow-x: clip; }
.blocks__inner { position: relative; z-index: 0; padding-top: 57px; }
.blocks__inner::before { /* dot grid under the blocks, faded to the left by a white overlay (Figma "Rectangle 14");
  its right edge is the content edge, so the dots stay under the blocks on any width or zoom */
  content: ""; position: absolute; z-index: -1; top: 0; bottom: -26px; inset-inline-end: 24px; width: 1336px;
  background:
    linear-gradient(270deg, transparent 16%, var(--bg) 52%),
    radial-gradient(circle, var(--dots) 1.75px, transparent 2px) right 0 top 0 / 20.09px 20.09px;
  pointer-events: none;
}
.blocks .section-head { margin-bottom: 74px; }
.blocks__art { position: absolute; top: 35px; inset-inline-end: calc(24px + 101px); width: 211px; height: auto; }

.perks { display: grid; gap: 36px; }
.perk { display: flex; align-items: center; gap: 32px; }
.perk__icon {
  flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 16px;
  background: var(--sky); color: var(--bg);
}
.perk__icon img { width: 56px; height: 56px; filter: brightness(0) invert(1); }
.perk__title { font: 600 20px/1.3 var(--font-body); color: var(--blue); }
.perk__text { margin-top: 4px; font-size: 20px; line-height: 1.3; color: var(--ink); }

/* ---------- Simulation ---------- */

.simulation { padding-top: 190px; }
.simulation .section-head { margin-bottom: 64px; }
.steps { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.step {
  position: relative; min-height: 341px; padding: 18px 18px 24px; border-radius: var(--radius); overflow: hidden;
  background: radial-gradient(231% 130% at 2.8% 43%, var(--glow-center) 22.4%, var(--glow) 100%) var(--bg);
}
.steps .step:nth-child(2) { background: radial-gradient(231% 130% at 2.8% -61.7%, var(--glow-center) 22.4%, var(--glow) 100%) var(--bg); }
.steps .step:nth-child(4) { background: radial-gradient(231% 130% at 2.8% 43%, var(--glow-center) 22.4%, var(--glow) 100%) var(--bg); }
.step--media { background: var(--card); }
.step--media::before { /* full editor bleeds into the original gradient treatment */
  content: ""; position: absolute; inset-inline-start: 30%; top: 0; width: 100%; height: 100%;
  background: url("../img/sim-blocks.webp") 0 0 / 100% 100% no-repeat;
  filter: blur(.35px);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%);
  mask-image: linear-gradient(90deg, transparent, #000 12%);
}
.step--media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, var(--card) 22%, color-mix(in srgb, var(--card) 85%, transparent) 34%, transparent 52%),
    linear-gradient(180deg, color-mix(in srgb, var(--card) 90%, transparent) 0%, transparent 30%);
}
.step--media > * { position: relative; z-index: 1; }
.step__num { display: block; font: 400 75px/1 var(--font-body); color: var(--sky); letter-spacing: -.01em; }
.step__title { margin-top: 18px; font: 600 20px/1.3 var(--font-body); color: var(--ink); }
.step__text { margin-top: 6px; max-width: 360px; font-size: 16px; line-height: 1.45; color: var(--ink-2); }
.step--media .step__text { max-width: 230px; }
.step:has(.step__media) .step__text { max-width: 46%; }
.step__media {
  position: absolute; top: 18px; inset-inline-end: 18px; bottom: 18px; width: 44%;
  border-radius: 16px; background: var(--card); box-shadow: 0 20px 40px -24px var(--shadow);
}

/* ---------- Progress ---------- */

.progress { margin-top: 120px; padding: 0; }
.progress > .container { padding-top: 56px; padding-bottom: 43px; }
.progress {
  max-width: 1440px; margin-left: auto; margin-right: auto; border-radius: var(--radius);
  background: var(--surface);
}
.progress .section-head { margin-bottom: 70px; }

.viewer { display: flex; flex-direction: column; align-items: center; }
.viewer__frame {
  width: min(920px, 100%); aspect-ratio: 920 / 518; border-radius: var(--radius); overflow: hidden;
  background: var(--card); box-shadow: 0 0 0 1px var(--line), 0 40px 80px -48px var(--shadow);
}
.viewer__panel { width: 100%; height: 100%; }
.viewer__panel[hidden] { display: none; }
.viewer__panel { display: grid; place-items: center; background: var(--card-2); }
.viewer__panel img { width: 100%; height: 100%; object-fit: contain; }
#view-student img { object-fit: cover; object-position: top center; }
.viewer__tabs { display: flex; gap: 24px; margin-top: 64px; }
.tab {
  height: 48px; padding: 0 20px; border: 0; border-radius: 999px;
  font: 500 16px/1 var(--font-body); background: var(--chip-weak); color: var(--ink);
  transition: background-color .2s ease, color .2s ease;
}
.tab:hover { background: var(--chip); }
.tab[aria-selected="true"] { background: var(--ink); color: var(--bg); }

/* ---------- Real drones ---------- */

.real { padding-top: 133px; }
.real .section-head { margin-bottom: 22px; }
.real__stage { position: relative; width: min(920px, 100%); aspect-ratio: 920 / 630; margin: 0 auto; }
.real__panel { position: absolute; border-radius: var(--radius); overflow: hidden; }
.real__panel--big {
  inset-inline-start: 33.91%; top: 0; width: 66.09%; height: 90%;
  background: radial-gradient(90% 80% at 30% 20%, var(--glow-light) 0%, var(--glow) 70%);
}
.real__panel--photo { inset-inline-start: 0; top: 53.17%; width: 32.17%; height: 46.83%; object-fit: cover; }
/* placeholders keep the Figma frame sizes; captions sit away from the drone */
.real__panel.media-ph { position: absolute; aspect-ratio: auto; }
.real__panel--big .media-ph__inner { justify-content: flex-start; align-items: flex-end; text-align: end; }
.real__panel--big .media-ph__tag { align-self: flex-end; }
.real__drone { position: absolute; inset-inline-start: 30.74%; top: 20.16%; width: 70.33%; height: auto; transform: scaleX(-1); }
/* the decorative render would cover the real footage */
.real__stage:has(.real__panel--big.has-video) .real__drone { display: none; }
.real__stage .real__drone { z-index: 2; }

/* ---------- Bundles ---------- */

.bundles { padding-top: 160px; padding-bottom: 216px; }
.bundles__title { text-align: center; font: 700 clamp(38px, 4.45vw, 64px)/1.2 var(--font-display); color: var(--ink); margin-bottom: 72px; }
.bundle-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.bundle {
  display: flex; flex-direction: column; min-height: 482px; padding: 46px 22px 40px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg);
  transition: box-shadow .25s ease, transform .25s ease;
}
.bundle:hover { transform: translateY(-4px); box-shadow: 0 30px 60px -36px var(--shadow); }
.bundle__title { font: 500 30px/1.3 var(--font-display); color: var(--ink); margin-inline-start: -4px; }
.bundle__text { margin-top: 8px; font-size: 16px; line-height: 1.4; color: var(--ink-2); min-height: 45px; }
.bundle__media {
  display: grid; place-items: center; width: 116px; height: 116px; margin: 22px auto 29px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #CFE3FE, var(--blue-200));
}
.bundle__media img { width: 150%; max-width: none; height: auto; filter: drop-shadow(0 8px 10px rgba(7, 46, 108, .25)); }
.bundle__media--icon svg { width: 52px; height: 52px; fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.checklist { display: grid; gap: 21px; padding-top: 13px; border-top: 1px solid var(--ink-2); }
.checklist li {
  position: relative; padding-inline-start: 33px; font-size: 20px; line-height: 1.05; color: var(--ink-2);
}
.checklist li::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 0; width: 20px; height: 20px; border-radius: 50%;
  background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.6 10.3l2.9 2.9 5.9-6.1' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 20px no-repeat;
}

.bundle__link {
  display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 28px;
  font-weight: 600; color: var(--blue);
}
.bundle__link::after { content: "→"; transition: transform .2s ease; }
.bundle__link:hover::after { transform: translateX(3px); }

/* ---------- Reveal on scroll (classes added by main.js) ---------- */

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease var(--rd, 0ms), transform .8s cubic-bezier(.2, .7, .2, 1) var(--rd, 0ms); }
.reveal.is-revealed { opacity: 1; transform: none; }

/* ---------- Media placeholders ----------
   Blue frames for photos and videos that are not shot yet. They are .slot elements, so a file
   added at the data-video / data-img path replaces the placeholder automatically. */

.media-ph {
  position: relative; overflow: hidden; border-radius: var(--radius); aspect-ratio: 16 / 9;
  background:
    radial-gradient(110% 120% at 0% 0%, #FFFFFF 0%, rgba(255, 255, 255, .25) 40%, rgba(255, 255, 255, 0) 70%),
    linear-gradient(160deg, var(--blue-100) 0%, var(--blue-200) 100%);
  box-shadow: inset 0 0 0 1px var(--line);
}
:root[data-theme="dark"] .media-ph {
  background: radial-gradient(110% 120% at 0% 0%, rgba(45, 165, 253, .3) 0%, transparent 60%), linear-gradient(160deg, var(--card) 0%, var(--card-2) 100%);
}
:root[data-theme="dark"] .media-ph::before { opacity: .25; }
:root[data-theme="dark"] .media-ph::after { opacity: .2; }
.media-ph::before { /* dot grid */
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, .75) 1.3px, transparent 1.6px) 0 0 / 22px 22px;
  -webkit-mask-image: linear-gradient(120deg, transparent 20%, #000 90%); mask-image: linear-gradient(120deg, transparent 20%, #000 90%);
}
.media-ph::after { /* soft light sweep */
  content: ""; position: absolute; inset: -50% -80%;
  background: linear-gradient(100deg, transparent 42%, rgba(255, 255, 255, .5) 50%, transparent 58%);
  animation: ph-sweep 3.6s ease-in-out infinite;
}
@keyframes ph-sweep { from { transform: translateX(-40%); } to { transform: translateX(40%); } }
.media-ph__inner { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; justify-content: flex-end; padding: 22px 24px; }
.media-ph__play, .media-ph__icon {
  position: absolute; left: 50%; top: 46%; display: grid; place-items: center; width: 68px; height: 68px; margin: -34px 0 0 -34px;
  border-radius: 50%; background: rgba(255, 255, 255, .9); box-shadow: 0 16px 30px -12px rgba(45, 127, 253, .6);
}
.media-ph__play::before { content: ""; width: 20px; height: 22px; margin-left: 5px; background: var(--blue); clip-path: polygon(0 0, 100% 50%, 0 100%); }
.media-ph__play::after {
  content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .9);
  animation: ph-ring 2.4s ease-out infinite;
}
@keyframes ph-ring { from { transform: scale(.9); opacity: 1; } to { transform: scale(1.45); opacity: 0; } }
.media-ph__icon svg { width: 28px; height: 28px; fill: none; stroke: var(--blue); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.media-ph__tag {
  align-self: flex-start; padding: 6px 10px; border-radius: 999px; font: 600 11px/1 var(--font-body); letter-spacing: .08em; text-transform: uppercase;
  color: var(--blue); background: var(--chip-solid);
}
.media-ph__title { margin-top: 10px; font: 500 20px/1.25 var(--font-display); color: var(--ink); }
.media-ph__text { margin-top: 4px; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.media-ph.has-video::before, .media-ph.has-video::after, .media-ph.has-image::before, .media-ph.has-image::after,
.media-ph.has-video .media-ph__inner, .media-ph.has-image .media-ph__inner { display: none; }
@media (prefers-reduced-motion: reduce) { .media-ph::after, .media-ph__play::after { animation: none; } }

/* ---------- Footer ---------- */

.footer { padding: 64px 0 40px; border-top: 1px solid var(--line); color: var(--ink-2); font-size: 15px; }
.footer__grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 32px; }
.footer__brand .logo { width: 135px; height: auto; }
.footer__note { margin-top: 14px; max-width: 280px; line-height: 1.5; }
.footer__col { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.footer__title { margin-bottom: 4px; font: 600 13px/1.2 var(--font-body); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); }
.footer__col a, .footer__bottom a { transition: color .2s ease; }
.footer__col a:hover, .footer__bottom a:hover { color: var(--blue); }
.footer__bottom {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px;
  position: relative; margin-top: 48px; padding-top: 24px; font-size: 14px;
}
.footer__bottom::before { content: ""; position: absolute; top: 0; inset-inline: 24px; border-top: 1px solid var(--line); }
@media (max-width: 1024px) {
  .footer__grid { grid-template-columns: repeat(2, 1fr); }
  .footer__brand { grid-column: 1 / -1; }
}

/* ---------- Responsive ---------- */

@media (max-width: 1180px) {
  .nav__link { padding: 0 14px; }
  .blocks__art { inset-inline-end: 24px; }
}

@media (max-width: 1024px) {
  .menu-toggle {
    display: grid; place-content: center; gap: 6px; width: 48px; height: 48px; border: 0; border-radius: 50%;
    background: var(--chip-weak);
  }
  .menu-toggle span { display: block; width: 18px; height: 2px; border-radius: 2px; background: var(--ink); transition: transform .2s ease; }
  .menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

  .nav {
    position: absolute; top: calc(100% + 8px); left: 24px; right: 24px;
    flex-direction: column; align-items: stretch; height: auto; padding: 8px; border-radius: 24px;
    background: var(--card); box-shadow: 0 24px 48px -24px var(--shadow), 0 0 0 1px var(--line);
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .2s ease, transform .2s ease, visibility .2s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav__link--menu { pointer-events: none; }
  .nav__chevron { display: none; }
  .nav .dropdown {
    position: static; width: auto; min-width: 0; padding: 0 0 6px; opacity: 1; visibility: visible; transform: none;
    background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none;
  }
  .nav .dropdown::before { display: none; }
  .dropdown__product { padding: 8px 22px; }
  .dropdown__product img { width: 56px; height: 34px; }
  .dropdown__more { margin: 0; padding: 10px 22px; border: 0; }
  .header { padding: 20px 0; }
  .hero { margin-top: -88px; padding-top: 140px; }

  .steps { grid-template-columns: 1fr; }
  .bundle-grid { grid-template-columns: 1fr; max-width: 440px; margin: 0 auto; }
  .blocks__art { position: static; width: 180px; margin: -40px 0 40px auto; }
}

@media (max-width: 720px) {
  .header__actions .btn--dark, .header__account { display: none; }
  .header__logo .logo { width: 140px; }
  .hero { height: auto; min-height: 0; padding-bottom: 8px; }
  .hero__stage { display: none; }
  .hero__screen { margin-top: 32px; }
  .section { padding-top: 88px; }
  .section-head { margin-bottom: 40px; }
  .section-head--row { flex-direction: column; }
  .section-head--row .btn { margin-inline-end: 0; }
  .features-head { margin-top: 56px; margin-bottom: 32px; }
  .lead, .perk__text, .perk__title { font-size: 17px; }
  .perk { align-items: flex-start; gap: 20px; }
  .blocks { margin-top: 72px; }
  .blocks__inner { padding-top: 16px; }
  .blocks__art { margin: 0 0 32px; }
  .blocks__inner::before { left: 0; right: 0; width: auto; }
  .simulation { padding-top: 104px; }
  .step { min-height: 240px; }
  .step:has(.step__media) .step__text { max-width: none; }
  .step__media { position: relative; inset: auto; width: 100%; height: 220px; margin-top: 20px; }
  .step--media { min-height: 420px; }
  .step--media::before { inset-inline-start: 6%; top: 52%; width: 190%; height: 48%; background-size: auto 100%; }
  .step--media::after { background: linear-gradient(180deg, var(--card) 44%, transparent 64%); }
  .progress { border-radius: 0; }
  .viewer__tabs { margin-top: 32px; gap: 12px; }
  .real__panel--photo { border-radius: 16px; }
  .bundles { padding-top: 104px; padding-bottom: 120px; }
  .bundles__title { margin-bottom: 40px; }
  .checklist li { font-size: 18px; }
}

/* ---------- Right-to-left (Hebrew) ----------
   Layout mirrors through logical properties above. These rules flip what logical properties can't:
   arrows, gradients that fade towards a side, and mirrored renders. SVG drawings are not mirrored. */
[dir="rtl"] .btn__chevron, [dir="rtl"] .round-btn svg { transform: scaleX(-1); }
/* SVG labels: right-to-left reading order, but the same position as in the drawing (left edge at x) */
[dir="rtl"] svg text { direction: rtl; text-anchor: end; }
[dir="rtl"] svg text[text-anchor="middle"] { text-anchor: middle; }
[dir="rtl"] svg [dir="ltr"] text, [dir="rtl"] [dir="ltr"] svg text { direction: ltr; text-anchor: start; }
[dir="rtl"] .bundle__link::after { content: "←"; }
[dir="rtl"] .bundle__link:hover::after { transform: translateX(-3px); }
[dir="rtl"] .blocks__inner::before {
  background:
    linear-gradient(90deg, transparent 16%, var(--bg) 52%),
    radial-gradient(circle, var(--dots) 1.75px, transparent 2px) left 0 top 0 / 20.09px 20.09px;
}
[dir="rtl"] .step--media::after {
  background:
    linear-gradient(270deg, var(--card) 22%, color-mix(in srgb, var(--card) 85%, transparent) 34%, transparent 52%),
    linear-gradient(180deg, color-mix(in srgb, var(--card) 90%, transparent) 0%, transparent 30%);
}
[dir="rtl"] .step--media::before { background-image: url("../img/sim-blocks.he.webp"); -webkit-mask-image: linear-gradient(270deg, transparent, #000 12%); mask-image: linear-gradient(270deg, transparent, #000 12%); }
[dir="rtl"] .real__drone { transform: none; }
@media (max-width: 720px) {
  [dir="rtl"] .step--media::after { background: linear-gradient(180deg, var(--card) 44%, transparent 64%); }
}

/* illustrations and UI mock-ups are drawn light; they keep light tokens in the dark theme */
:root[data-theme="dark"] :is(.anim-card, .cam__hud) {
  --ink: #222223; --ink-2: #4F4F52; --muted: #8C8D8D;
  --card: #FFFFFF; --card-2: #F3F7FD; --line: #D3E5FE; --chip-solid: rgba(255, 255, 255, .85);
  color: var(--ink);
}
