:root {
  --bg: #ffffff;
  --bg-soft: #f5f5f7;
  --bg-muted: #fafafa;
  --fg: #1d1d1f;
  --fg-muted: #6e6e73;
  --fg-soft: #86868b;
  --border: #d2d2d7;
  --border-soft: #ececef;
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --good: #4ec96e;
  --radius: 22px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.04), 0 4px 14px rgba(0,0,0,.04);
  --shadow-md: 0 2px 6px rgba(0,0,0,.05), 0 18px 40px rgba(0,0,0,.06);
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --body: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Inter', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  letter-spacing: -.005em;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 32px);
}

/* Top nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0,0,0,.06);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 52px;
  max-width: 1120px; margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 32px);
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 600;
  font-size: 15px;
  color: var(--fg);
}
.brand-mark {
  width: 22px; height: 22px;
  background: linear-gradient(135deg, #0071e3, #5e5ce6);
  border-radius: 6px;
  display: grid; place-items: center;
  color: #fff; font-weight: 800; font-size: 12px;
}
.brand-sub { color: var(--fg-muted); font-weight: 400; font-size: 13px; }

.lang-toggle {
  display: inline-flex;
  background: var(--bg-soft);
  border-radius: 999px;
  padding: 3px;
  font-size: 13px;
}
.lang-toggle button {
  border: 0;
  background: transparent;
  color: var(--fg-muted);
  padding: 5px 12px;
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--body);
  font-weight: 500;
  letter-spacing: .02em;
  transition: all .2s ease;
}
.lang-toggle button.active {
  background: var(--fg);
  color: #fff;
}

/* Hero */
.hero {
  padding: clamp(48px, 8vw, 96px) 0 clamp(40px, 6vw, 72px);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
@media (max-width: 820px) { .hero-grid { grid-template-columns: 1fr; } }

.ceo-photo {
  width: 100%;
  aspect-ratio: 4/5;
  max-width: 420px;
  border-radius: 28px;
  object-fit: cover;
  box-shadow: var(--shadow-md);
  background: var(--bg-soft);
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 16px;
  letter-spacing: -.005em;
}
.eyebrow::before {
  content: ''; width: 8px; height: 8px;
  border-radius: 50%; background: var(--good);
  box-shadow: 0 0 8px var(--good);
}

.h1 {
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.04;
  margin: 0 0 16px;
}
.h2 {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  letter-spacing: -.022em;
  line-height: 1.1;
  margin: 0 0 12px;
}
.h3 {
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -.012em;
  margin: 0;
}
.lead {
  font-size: 21px;
  color: var(--fg-muted);
  max-width: 60ch;
  margin: 0 0 28px;
  letter-spacing: -.01em;
  line-height: 1.4;
}

/* Operator ID card */
.opcard {
  background: var(--bg-soft);
  border-radius: var(--radius);
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
}
.opcard .label {
  font-size: 12px;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: .12em;
  margin-bottom: 8px;
  font-weight: 600;
}
.opcard .opid {
  font-family: var(--mono);
  font-size: clamp(18px, 2.4vw, 24px);
  font-weight: 700;
  color: var(--fg);
  word-break: break-all;
}
.opcard .opmeta {
  color: var(--fg-muted);
  font-size: 13px;
  margin-top: 6px;
  font-family: var(--mono);
}
.opcard .opmeta .secret {
  filter: blur(5px);
  cursor: pointer;
  user-select: none;
  transition: filter .25s ease;
  color: var(--accent);
  font-weight: 600;
}
.opcard .opmeta .secret.revealed { filter: none; user-select: text; }

.qr-mini {
  width: 84px; height: 84px;
  background: #fff;
  border-radius: 14px;
  padding: 6px;
  border: 1px solid var(--border-soft);
}
.qr-mini svg { width: 100%; height: 100%; display: block; }

/* Section */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section.alt { background: var(--bg-soft); }
.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  margin-bottom: 40px;
  gap: 16px;
  flex-wrap: wrap;
}
.section-head .sub {
  color: var(--fg-muted);
  font-size: 17px;
  max-width: 50ch;
}

/* Drones grid */
.drones {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 24px;
}
.drone {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--border-soft);
  padding: 0;
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s ease;
  cursor: pointer;
}
.drone:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.section.alt .drone {
  border-color: transparent;
  box-shadow: var(--shadow-sm);
}

.drone-photo {
  background: linear-gradient(180deg, #fafafa, #f0f0f3);
  aspect-ratio: 16/10;
  display: grid; place-items: center;
  padding: 24px;
}
.drone-photo img {
  max-width: 90%;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 18px 24px rgba(0,0,0,.12));
}
.drone-body {
  padding: 28px;
  display: flex; flex-direction: column; gap: 16px;
  flex: 1;
}
.drone-name {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -.02em;
  margin: 0;
}
.drone-cat {
  display: inline-flex; align-items: center;
  font-family: var(--mono); font-size: 12px;
  padding: 4px 10px;
  background: rgba(78, 201, 110, .15);
  color: #1b8c3a;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: .02em;
  align-self: flex-start;
}
.drone-id-box {
  background: var(--bg-soft);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 700;
  color: var(--fg);
  text-align: center;
  letter-spacing: .02em;
}
.drone-fields {
  display: grid; grid-template-columns: auto 1fr;
  gap: 10px 18px;
  font-size: 14px;
  margin: 0;
}
.drone-fields dt { color: var(--fg-muted); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; padding-top: 2px; }
.drone-fields dd { margin: 0; font-family: var(--mono); font-size: 13.5px; word-break: break-all; }

.drone-link {
  margin-top: auto;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 14px;
  color: var(--accent);
  font-weight: 500;
}
.drone-link::after { content: '→'; transition: transform .2s ease; }
.drone:hover .drone-link::after { transform: translateX(4px); }

/* Focus mode (single drone view) */
.drone-focus {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 56px);
  align-items: center;
}
@media (max-width: 820px) { .drone-focus { grid-template-columns: 1fr; } }
.drone-focus .photo {
  background: var(--bg-soft);
  border-radius: 28px;
  aspect-ratio: 1;
  display: grid; place-items: center;
  padding: 40px;
}
.drone-focus .photo img {
  max-width: 100%; max-height: 100%; object-fit: contain;
  filter: drop-shadow(0 30px 40px rgba(0,0,0,.15));
}
.drone-focus .info { display: flex; flex-direction: column; gap: 22px; }
.drone-focus .big-id {
  font-family: var(--mono);
  font-size: clamp(30px, 4.5vw, 52px);
  font-weight: 700;
  letter-spacing: -.01em;
  background: linear-gradient(135deg, #1d1d1f 0%, #6e6e73 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.spec-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.spec {
  background: var(--bg-soft);
  border-radius: 16px;
  padding: 16px 18px;
}
.spec .k {
  font-size: 11px; text-transform: uppercase; letter-spacing: .1em;
  color: var(--fg-muted); font-weight: 600; margin-bottom: 4px;
}
.spec .v {
  font-family: var(--mono); font-size: 15px; font-weight: 600; word-break: break-all;
}

/* Cert grid */
.certs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}
.cert {
  background: #fff;
  border-radius: var(--radius);
  border: 1px solid var(--border-soft);
  padding: 28px;
  display: flex; flex-direction: column; gap: 12px;
}
.section.alt .cert { border-color: transparent; box-shadow: var(--shadow-sm); }
.cert-row {
  display: flex; align-items: center; justify-content: space-between;
}
.cert-badge {
  font-family: var(--mono); font-size: 11px;
  padding: 5px 10px; border-radius: 6px;
  background: var(--fg); color: #fff;
  font-weight: 700; letter-spacing: .05em;
}
.cert-status {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--good); font-size: 12px; font-weight: 600;
}
.cert-status::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--good);
}
.cert-title { font-size: 19px; font-weight: 600; margin: 0; letter-spacing: -.012em; }
.cert-meta { font-size: 14px; color: var(--fg-muted); }
.cert-meta strong { color: var(--fg); font-family: var(--mono); font-weight: 500; font-size: 13px; }

/* Footer */
.foot {
  padding: 32px 0 48px;
  border-top: 1px solid var(--border-soft);
  color: var(--fg-soft);
  font-size: 13px;
}
.foot-inner {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
}

/* Buttons */
.btn-back {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--fg);
  font-size: 13px;
  font-weight: 500;
  margin: 24px 0;
  transition: background .2s ease;
}
.btn-back:hover { background: var(--border-soft); text-decoration: none; }

.hidden { display: none !important; }

/* Animations */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
.hero, .section { animation: fadeUp .6s cubic-bezier(.2,.8,.2,1) both; }

/* Cert clickable */
.cert.has-preview { cursor: pointer; transition: transform .25s cubic-bezier(.2,.8,.2,1), box-shadow .25s ease; }
.cert.has-preview:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.cert-preview-hint {
  margin-top: auto;
  align-self: flex-start;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--accent); font-weight: 500;
}
.cert-preview-hint::after { content: '→'; transition: transform .2s ease; }
.cert.has-preview:hover .cert-preview-hint::after { transform: translateX(4px); }

/* Modal */
.modal {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center;
  padding: 24px;
  animation: modalIn .25s ease;
}
@keyframes modalIn { from { opacity: 0; } to { opacity: 1; } }
.modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(20,20,22,.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.modal-window {
  position: relative;
  background: #fff;
  border-radius: 20px;
  width: min(960px, 100%);
  height: min(92vh, 1000px);
  display: flex; flex-direction: column;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,.4);
  animation: modalUp .35s cubic-bezier(.2,.8,.2,1);
}
@keyframes modalUp { from { transform: translateY(20px) scale(.98); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-soft);
  gap: 16px;
}
.modal-eyebrow {
  font-size: 11px; text-transform: uppercase; letter-spacing: .12em;
  color: var(--fg-muted); font-weight: 600;
}
.modal-title { font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.modal-actions { display: flex; align-items: center; gap: 8px; }
.modal-btn {
  border: 1px solid var(--border);
  background: #fff;
  color: var(--fg);
  font-family: var(--body);
  font-size: 13px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: background .2s ease;
}
.modal-btn:hover { background: var(--bg-soft); text-decoration: none; }
.modal-close {
  width: 36px; height: 36px; padding: 0;
  font-size: 22px; line-height: 1;
  display: grid; place-items: center;
}
.modal-body {
  flex: 1 1 auto;
  min-height: 0;
  background: var(--bg-soft);
  position: relative;
}
.modal-body iframe {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  border: 0;
  display: block;
}
.modal-close {
  border: 1px solid var(--border);
  background: #fff;
  cursor: pointer;
}
.modal-close:hover { background: var(--bg-soft); }
body.modal-open { overflow: hidden; }
.section { animation-delay: .08s; }
