:root {
  --black: #000000;
  --white: #ffffff;
  --grey: #8a8a8a;
  --panel: rgba(0, 0, 0, 0.72);
  --panel-border: rgba(255, 255, 255, 0.12);
  --font: system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --pad: clamp(1rem, 3vw, 2rem);
}

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

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  font-family: var(--font);
  color: var(--white);
  background: var(--black);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html:has(body.route-detail),
body.route-detail {
  overflow: hidden;
  height: 100%;
}

html:has(body.route-portal),
html:has(body.route-key),
body.route-portal,
body.route-key {
  overflow: auto;
  height: auto;
  min-height: 100dvh;
}

body.route-portal .site-header,
body.route-key .site-header {
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.82), transparent);
}

.site-header a.is-current {
  opacity: 1;
}

.hidden {
  display: none !important;
}

.portal-page,
.key-page {
  position: relative;
  z-index: 1;
  max-width: 40rem;
  margin: 0 auto;
  padding: calc(5.5rem + env(safe-area-inset-top, 0px)) var(--pad) calc(3rem + env(safe-area-inset-bottom, 0px));
}

.portal-page .catalog-kicker,
.key-page .catalog-kicker {
  font-family: "Share Tech Mono", var(--mono);
}

.portal-page h1,
.key-page h1 {
  margin: 0.35rem 0 0.85rem;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 650;
  letter-spacing: -0.04em;
}

.portal-lead {
  margin: 0 0 1rem;
  max-width: 32rem;
  color: var(--grey);
  font-size: clamp(0.95rem, 1.4vw, 1.05rem);
  line-height: 1.55;
}

.portal-meta {
  margin: 0 0 1.35rem;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.cm-crit {
  margin: 0 0 1.45rem;
  max-width: 40rem;
  padding: 1.05rem 1.15rem 1.15rem;
  border: 1px solid rgba(232, 64, 56, 0.55);
  border-radius: 12px;
  background: rgba(232, 64, 56, 0.1);
}

.cm-crit-kicker {
  margin: 0 0 0.35rem;
  font-family: "Share Tech Mono", var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #e84038;
}

.cm-crit h2 {
  margin: 0 0 0.45rem;
  font-size: 1.15rem;
  font-weight: 650;
  letter-spacing: -0.03em;
  color: #fff;
}

.cm-crit p:last-child {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.5;
  font-size: 0.95rem;
}

.cm-demo {
  margin: 0 0 1.45rem;
  max-width: 40rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  overflow: hidden;
  background: #0a0a0c;
}

.cm-demo video {
  display: block;
  width: 100%;
  height: auto;
}

.portal-cta {
  width: 100%;
  max-width: 22rem;
  min-height: 3rem;
  margin: 0;
}

.portal-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.7rem;
  max-width: 22rem;
}

.home-cta.portal-cta-alt,
.portal-cta-alt {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: none;
}

.home-cta.portal-cta-alt:hover {
  background: rgba(255, 255, 255, 0.06);
  opacity: 1;
}

.portal-status {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0 0 0.9rem;
  padding: 0.28rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
}

.portal-status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.7);
}

.portal-dl-link {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  margin-top: 0.15rem;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  padding-bottom: 1px;
}

.portal-dl-link:hover {
  color: #fff;
  border-bottom-color: #fff;
}

.gk-dls {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.45rem;
}

.portal-actions .gk-dls {
  margin-top: 0.15rem;
}

.portal-cta[aria-disabled="true"] {
  opacity: 0.45;
  pointer-events: none;
}

.portal-hint {
  margin: 0.9rem 0 2.25rem;
  color: var(--grey);
  font-size: 0.9rem;
  line-height: 1.5;
}

.portal-faq {
  margin-top: 0.5rem;
}

.portal-redeem {
  margin: 0 0 2rem;
  max-width: 22rem;
}

.portal-redeem-label {
  display: block;
  margin: 0 0 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grey);
}

.portal-redeem-row {
  display: flex;
  gap: 0.5rem;
  align-items: stretch;
}

.portal-redeem-row input {
  flex: 1;
  min-width: 0;
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  font: inherit;
  font-size: 0.88rem;
}

.portal-redeem-row input:focus {
  outline: 1px solid rgba(255, 255, 255, 0.4);
}

.portal-redeem-row button {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: transparent;
  color: #fff;
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.portal-redeem-row button:hover {
  background: rgba(255, 255, 255, 0.06);
}

/* ——— Header ——— */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(20px, 3.5vw, 48px);
  padding: clamp(16px, 2.4vh, 28px) clamp(20px, 3.5vw, 48px);
  pointer-events: none;
}

.site-header a,
.site-header button {
  pointer-events: auto;
  color: var(--white);
  text-decoration: none;
  transition: opacity 0.15s ease;
}

.site-header a:hover {
  opacity: 0.72;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 1.85rem;
  margin-left: 0.55rem;
}

.lang-btn {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--grey);
  cursor: pointer;
}

.lang-btn:hover,
.lang-btn.is-active {
  color: var(--white);
  opacity: 1;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: clamp(0.88rem, 1.1vw, 1.02rem);
  font-weight: 600;
  letter-spacing: 0.08em;
}

.brand-mark {
  display: none;
}

.brand-tag {
  margin-left: 0.38em;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.8vw, 40px);
  font-size: clamp(0.82rem, 1vw, 0.96rem);
  font-weight: 500;
  letter-spacing: 0.03em;
}

.top-nav a {
  display: inline-flex;
  align-items: baseline;
  gap: 0.38em;
  white-space: nowrap;
}

.nav-chip {
  color: var(--grey);
  font-size: 0.72em;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.free-banner {
  margin: 0.55rem 0 0;
  color: var(--white);
  font-size: clamp(0.92rem, 1.35vw, 1.08rem);
  font-weight: 600;
  letter-spacing: 0.04em;
}

.nav-toggle {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.nav-toggle span,
.nav-toggle::before,
.nav-toggle::after {
  content: "";
  display: block;
  position: absolute;
  left: 13px;
  width: 18px;
  height: 1.5px;
  background: #fff;
  transition: transform 0.2s ease, opacity 0.2s ease, top 0.2s ease;
}

.nav-toggle span {
  top: 21px;
}

.nav-toggle::before {
  top: 15px;
}

.nav-toggle::after {
  top: 27px;
}

body.nav-open .nav-toggle span {
  opacity: 0;
}

body.nav-open .nav-toggle::before {
  top: 21px;
  transform: rotate(45deg);
}

body.nav-open .nav-toggle::after {
  top: 21px;
  transform: rotate(-45deg);
}

.nav-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 35;
  background: rgba(0, 0, 0, 0.55);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}

body.nav-open .nav-backdrop {
  display: block;
}

/* ——— Home (Spline plein écran, centré) ——— */
.home {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: var(--black);
}

.home-stage {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
}

.home-globe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: auto;
}

.home-globe spline-viewer {
  display: block;
  width: 100%;
  height: 100%;
  background: transparent;
}

.home-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 7.5rem;
  padding: 0.62rem 1.65rem;
  border: 0;
  border-radius: 999px;
  background: var(--white);
  color: var(--black);
  font-family: inherit;
  font-size: clamp(0.88rem, 1vw, 0.96rem);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.35);
  transition: transform 0.15s ease, opacity 0.15s ease;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  box-sizing: border-box;
}

.home-cta:hover {
  transform: translateY(-1px);
  opacity: 0.92;
}

body.route-scripts #home,
body.route-detail #home,
body.route-executors #home,
body.route-faq #home {
  display: none;
}

body.route-scripts .view,
body.route-detail .view,
body.route-executors .view,
body.route-faq .view {
  padding-top: clamp(4.5rem, 8vh, 5.75rem);
}

body.route-detail #view-detail {
  padding: clamp(4.5rem, 8vh, 5.75rem) 0 0;
  overflow: auto;
  background: #000;
}

body.route-detail .pages {
  overflow: auto;
}

body.route-scripts .site-header,
body.route-detail .site-header,
body.route-executors .site-header {
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.82), transparent);
}

.pages {
  position: fixed;
  inset: 0;
  z-index: 10;
  pointer-events: none;
  overflow: hidden;
}

.view {
  display: none;
  height: 100%;
  overflow: auto;
  padding: 5.5rem var(--pad) 2rem;
  pointer-events: none;
}

.view.is-active {
  display: block;
  pointer-events: auto;
}

body.route-home .pages {
  pointer-events: none;
}

body.route-home .view {
  display: none !important;
}

.panel,
.catalog {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 0 2.5rem;
}

.panel {
  max-width: 920px;
  padding: 1.25rem 1.5rem 1.5rem;
  border: 1px solid var(--panel-border);
  border-radius: 18px;
  background: var(--panel);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.panel-head,
.catalog-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.15rem;
}

.panel-kicker,
.catalog-kicker {
  margin: 0;
  font-size: clamp(1.05rem, 1.6vw, 1.35rem);
  font-weight: 700;
  letter-spacing: 0.14em;
}

.panel-head h2,
.catalog-head h2 {
  margin: 0.25rem 0 0;
  font-size: clamp(1.55rem, 2.6vw, 2.15rem);
  font-weight: 600;
  letter-spacing: 0.01em;
}

.panel-sub,
.catalog-sub,
.catalog-empty {
  margin: 0.35rem 0 0;
  color: var(--grey);
  font-size: 0.95rem;
}

.pill {
  border: 1px solid var(--panel-border);
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  font-size: 0.85rem;
  background: rgba(255, 255, 255, 0.06);
}

.search-wrap {
  display: block;
  margin-bottom: 1.25rem;
}

.search {
  width: 100%;
  padding: 0.85rem 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 0;
  background: transparent;
  color: var(--white);
  font: inherit;
  outline: none;
}

.search:focus {
  border-bottom-color: rgba(255, 255, 255, 0.55);
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.exec-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 980px;
  gap: 1rem;
}

.exec-panel {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1.15rem 1.15rem 1.2rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: #101114;
  color: #fff;
}

.exec-panel-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.exec-panel-top h3 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
}

.exec-edition {
  margin: 0 0 0.2rem;
  color: rgba(255, 255, 255, 0.48);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.exec-legacy-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.62rem;
  border-radius: 999px;
  background: #2a2a2e;
  color: #c8c8cc;
  font-size: 0.72rem;
  font-weight: 700;
}

.exec-panel.is-legacy {
  background: #0c0c0e;
}

.exec-working {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.62rem;
  border-radius: 999px;
  background: #16351f;
  color: #3ee07a;
  font-size: 0.72rem;
  font-weight: 700;
}

.exec-meta {
  margin: 0;
}

.exec-meta > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.38rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.86rem;
}

.exec-meta dt {
  margin: 0;
  color: rgba(255, 255, 255, 0.55);
  font-weight: 500;
}

.exec-meta dd {
  margin: 0;
  font-weight: 600;
}

.exec-free {
  display: inline-block;
  padding: 0.08rem 0.42rem;
  border: 1px solid #3ee07a;
  border-radius: 6px;
  color: #3ee07a;
  font-size: 0.74rem;
}

.exec-unc { color: #7ec8ff; }
.exec-sunc { color: #c9a6ff; }

.exec-bypass {
  margin: 0;
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(62, 224, 122, 0.35);
  border-radius: 10px;
  background: rgba(22, 53, 31, 0.7);
  color: #7dffb0;
  font-size: 0.82rem;
}

.exec-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.exec-tags span {
  padding: 0.28rem 0.55rem;
  border-radius: 8px;
  background: #1b2744;
  color: #d7e4ff;
  font-size: 0.7rem;
  font-weight: 600;
}

.exec-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 2.55rem;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
}

.exec-btn-dl {
  background: #5aa7ff;
  color: #06101c;
}

.exec-btn-dc {
  background: #5865f2;
  color: #fff;
}

.exec-legacy {
  align-self: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.78rem;
  text-decoration: none;
}

.exec-legacy:hover { color: #fff; }

.script-card {
  position: relative;
  z-index: 0;
  isolation: isolate;
  display: block;
  aspect-ratio: 16 / 10;
  min-height: 168px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  overflow: hidden;
  color: inherit;
  text-decoration: none;
  background: #0a0a0a;
  transition: border-color 0.18s ease, transform 0.18s ease;
}

.card-media,
.card-media img,
.card-fallback {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-fallback {
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.12), transparent 42%),
    linear-gradient(160deg, #141414, #050505);
}

.sheet-exec .sheet-copy {
  max-width: 36rem;
}

.card-shade {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0.85rem 0.95rem 0.9rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.2) 55%, transparent 78%);
}

.script-card h3 {
  margin: 0.12rem 0 0;
  font-size: 1.02rem;
  font-weight: 600;
  line-height: 1.25;
}

.script-card .card-game {
  margin: 0.35rem 0 0;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
}

.exec-card.is-recommended {
  border-color: rgba(255, 255, 255, 0.38);
}

.exec-badge {
  width: fit-content;
  margin-bottom: 0.55rem;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: var(--white);
  color: var(--black);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.exec-dl {
  margin-top: 0.35rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: #fff;
}

.card-badge {
  display: inline-block;
  width: fit-content;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.badge-ok {
  background: #22c55e;
  border: 0;
  color: #04150a;
  font-weight: 800;
  padding: 0.22rem 0.62rem;
  border-radius: 6px;
  letter-spacing: 0.08em;
  box-shadow: 0 2px 0 #15803d, 0 0 10px rgba(34, 197, 94, 0.4);
}

.badge-dev {
  background: #f59e0b;
  border: 0;
  color: #1a0e00;
  font-weight: 800;
  padding: 0.22rem 0.62rem;
  border-radius: 6px;
  letter-spacing: 0.08em;
  box-shadow: 0 2px 0 #b45309, 0 0 10px rgba(245, 158, 11, 0.4);
}

.badge-rip {
  background: #ef4444;
  border: 0;
  color: #140404;
  font-weight: 800;
  padding: 0.22rem 0.62rem;
  border-radius: 6px;
  letter-spacing: 0.08em;
  box-shadow: 0 2px 0 #b91c1c, 0 0 10px rgba(239, 68, 68, 0.4);
}

.script-card:hover {
  border-color: rgba(255, 255, 255, 0.36);
  transform: translateY(-2px);
}

.script-card:hover .card-media img.is-on {
  transform: scale(1.04);
}

.card-media img {
  opacity: 0;
  transition: opacity 0.65s ease, transform 0.35s ease;
}

.card-media img.is-on {
  opacity: 1;
}

/* ——— Script detail sheet ——— */
#view-detail,
#view-detail #detail-root {
  position: relative;
  width: 100%;
  min-height: 100%;
  background: #000;
}

.sheet {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(16px, 3vw, 36px) 3rem;
}

.sheet-back {
  display: inline-block;
  margin-bottom: 1.1rem;
  color: rgba(255, 255, 255, 0.62);
  text-decoration: none;
  font-size: 0.88rem;
}

.sheet-back:hover { color: #fff; }

.sheet-empty {
  color: var(--grey);
}

.sheet-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: clamp(20px, 4vw, 56px);
  align-items: center;
}

.sheet-gallery {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 18px;
  overflow: hidden;
  background: #0a0a0a;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.sheet-gallery img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sheet-nav {
  position: absolute;
  top: 50%;
  z-index: 2;
  width: 2.1rem;
  height: 2.1rem;
  margin-top: -1.05rem;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.88);
  color: #111;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}

.sheet-nav.prev { left: 0.7rem; }
.sheet-nav.next { right: 0.7rem; }

.sheet-count {
  position: absolute;
  right: 0.8rem;
  top: 0.7rem;
  margin: 0;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
}

.sheet-film {
  position: absolute;
  left: 0.7rem;
  right: 0.7rem;
  bottom: 0.65rem;
  display: flex;
  gap: 0.35rem;
  z-index: 2;
}

.sheet-dot {
  flex: 1;
  height: 2.4rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 6px;
  background-size: cover;
  background-position: center;
  opacity: 0.45;
  cursor: pointer;
}

.sheet-dot.is-on {
  opacity: 1;
  border-color: #fff;
}

.sheet-copy {
  max-width: 28rem;
}

.sheet-kicker {
  margin: 0 0 0.55rem;
  font-size: clamp(1.15rem, 1.8vw, 1.55rem);
  font-weight: 700;
  letter-spacing: 0.14em;
}

.sheet-title {
  margin: 0 0 0.75rem;
  font-size: clamp(1.55rem, 2.5vw, 2.2rem);
  font-weight: 600;
  line-height: 1.18;
}

.sheet-meta {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0 0 0.85rem;
  color: var(--grey);
  font-size: 0.92rem;
}

.sheet-lead {
  margin: 0 0 0.85rem;
  color: var(--grey);
  font-size: 0.98rem;
  line-height: 1.5;
}

.sheet-features {
  margin: 2rem 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sheet-features h2 {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.sheet-feat {
  margin: 0 0 1.15rem;
}

.sheet-feat h3 {
  margin: 0 0 0.4rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: #fff;
}

.sheet-feat ul {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--grey);
  font-size: 0.88rem;
  line-height: 1.55;
  columns: 2;
  column-gap: 2rem;
}

.sheet-feat li {
  break-inside: avoid;
  margin: 0.12rem 0;
}

.sheet-anti {
  margin: 0 0 1.25rem;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.sheet-load {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.9rem;
  width: 100%;
}

.sheet-load-input {
  width: 100%;
  padding: 0.35rem 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: rgba(255, 255, 255, 0.42);
  font-family: var(--mono);
  font-size: 0.72rem;
  outline: none;
}

.sheet-cta {
  border: 0;
  cursor: pointer;
}

.feature-block {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--panel-border);
}

.feature-block h4 {
  margin: 0 0 0.4rem;
  font-size: 0.92rem;
}

.feature-block ul {
  margin: 0;
  padding-left: 1rem;
  color: var(--grey);
  font-size: 0.85rem;
  line-height: 1.55;
}

.faq-list {
  display: flex;
  flex-direction: column;
  max-width: 36rem;
}

.faq-item {
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0;
  background: none;
  padding: 1.05rem 0;
}

.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 1.05rem;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item p {
  margin: 0.55rem 0 0;
  color: var(--grey);
  font-size: 0.95rem;
  line-height: 1.55;
}

.faq-item a {
  color: #fff;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.25rem;
  transform: translateX(-50%);
  z-index: 100;
  padding: 0.6rem 1rem;
  border-radius: 999px;
  background: var(--white);
  color: var(--black);
  font-size: 0.85rem;
  font-weight: 600;
}

.toast[hidden] {
  display: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 900px) {
  html,
  body {
    overflow-x: clip;
  }

  .site-header {
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    padding: calc(10px + env(safe-area-inset-top, 0px)) 14px 10px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.78), transparent);
  }

  .brand-mark {
    display: none;
  }

  .brand {
    font-size: 0.92rem;
  }

  .nav-toggle {
    display: block;
  }

  .top-nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 36;
    width: min(18.5rem, 84vw);
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: calc(4.75rem + env(safe-area-inset-top, 0px)) 1.15rem calc(1.4rem + env(safe-area-inset-bottom, 0px));
    background: #050505;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 1.05rem;
    transform: translateX(110%);
    transition: transform 0.22s ease;
    pointer-events: auto;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  body.nav-open .top-nav {
    transform: translateX(0);
  }

  .top-nav a {
    display: flex;
    align-items: center;
    min-height: 48px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .lang-switch {
    margin: 1rem 0 0;
    gap: 1.4rem;
    min-height: 48px;
  }

  .lang-btn {
    min-height: 44px;
    min-width: 44px;
  }

  .home-stage,
  .home-globe {
    inset: 0;
    width: 100%;
    height: 100%;
  }

  .portal-page,
  .key-page {
    padding-top: calc(4.4rem + env(safe-area-inset-top, 0px));
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
  }

  .view,
  body.route-scripts .view,
  body.route-detail .view,
  body.route-executors .view,
  body.route-faq .view {
    padding-top: calc(4.4rem + env(safe-area-inset-top, 0px));
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
    padding-bottom: calc(2rem + env(safe-area-inset-bottom, 0px));
  }

  body.route-detail #view-detail {
    padding: calc(4.4rem + env(safe-area-inset-top, 0px)) 0 0;
  }

  .catalog-head,
  .panel-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .search {
    font-size: 16px;
    min-height: 44px;
  }

  .sheet {
    padding: 0 4px 2.5rem;
  }

  .sheet-stage {
    grid-template-columns: 1fr;
    gap: 1.25rem;
    align-items: start;
  }

  .sheet-copy {
    max-width: none;
  }

  .sheet-feat ul {
    columns: 1;
  }

  .sheet-gallery {
    aspect-ratio: 16 / 9;
  }

  .sheet-nav {
    width: 44px;
    height: 44px;
    margin-top: -22px;
    font-size: 1.35rem;
  }

  .sheet-load-input {
    font-size: 16px;
    min-height: 44px;
  }

  .home-cta,
  .sheet-cta,
  .exec-btn,
  .portal-cta {
    width: 100%;
    max-width: 22rem;
    min-height: 44px;
  }

  .cards-grid,
  .exec-grid {
    grid-template-columns: 1fr;
    max-width: none;
    gap: 0.85rem;
  }

  .script-card {
    min-height: 180px;
  }

  .faq-item summary {
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .toast {
    left: 12px;
    right: 12px;
    bottom: calc(14px + env(safe-area-inset-bottom, 0px));
    transform: none;
    text-align: center;
  }
}

@media (hover: none) and (pointer: coarse) {
  .script-card:hover {
    transform: none;
  }

  .home-cta:hover {
    transform: none;
  }

  a,
  button,
  .script-card,
  .lang-btn,
  .nav-toggle {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }
}
