/* ============================================================
   vadxdesign.ru/d/ — Portfolio page
   ============================================================ */

:root {
  --bg: #060910;
  --bg-elevated: #0a0e14;
  --card: #0d1117;
  --card-hover: #121820;
  --card-bg: #0b0e17;
  --inset: rgba(255, 255, 255, 0.025);
  --inset-2: rgba(255, 255, 255, 0.045);
  --ink: #e8eef7;
  --ink-2: #c8d1dc;
  --muted: #8b95a5;
  --muted-2: #6b7a8e;
  --blue: #4a92f3;
  --blue-2: #2b6de6;
  --border: rgba(255, 255, 255, 0.07);
  --border-subtle: rgba(255, 255, 255, 0.045);
  --radius: 12px;
  --radius-lg: 16px;
  --max: 1200px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --subnav-h: 55px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: "Golos Text", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

::selection { color: #fff; background: var(--blue-2); }

a {
  color: inherit;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

img, svg { display: block; max-width: 100%; }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

.container {
  width: min(calc(100% - 48px), var(--max));
  margin-inline: auto;
}

[data-lucide] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  stroke-width: 1.8;
  color: currentColor;
  vertical-align: middle;
}

h1, h2, h3, h4, p { margin-top: 0; text-wrap: pretty; hyphens: none; }
h1, h2, h3 { text-wrap: balance; }
h2 em { color: var(--blue); font-style: normal; }

.section { padding: 96px 0; }
.dark-section { background: var(--bg-elevated); }

/* ===== SUB-NAV ===== */
.sub-nav {
  position: sticky;
  top: 0;
  z-index: 9;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: rgba(6, 9, 16, 0.72);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.32);
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transition: opacity 0.25s ease;
}

.sub-nav-inner {
  display: flex;
  align-items: center;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.sub-nav-inner::-webkit-scrollbar { display: none; }

@media (min-width: 851px) {
  .sub-nav-inner > :first-child { margin-left: auto; }
  .sub-nav-inner > :last-child { margin-right: auto; }
}

.sub-nav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 16px 16px;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: -0.01em;
  white-space: nowrap;
  transition: color 0.25s ease;
}

.sub-nav-link [data-lucide] {
  opacity: 0.7;
  transition: opacity 0.25s ease, color 0.25s ease;
}

.sub-nav-link::after {
  position: absolute;
  right: 16px;
  bottom: -1px;
  left: 16px;
  height: 2px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.35s var(--ease);
  content: "";
}

.sub-nav-link:hover { color: var(--ink); }
.sub-nav-link:hover [data-lucide] { opacity: 1; color: var(--blue); }
.sub-nav-link.is-active { color: var(--ink); }
.sub-nav-link.is-active [data-lucide] { opacity: 1; color: var(--blue); }
.sub-nav-link.is-active::after { transform: scaleX(1); }

#overview, #projects, #structure, #process, #clients, #faq, #services, #contact {
  scroll-margin-top: var(--subnav-h);
}

/* ===== BUTTONS ===== */
.button {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 22px;
  border: 1px solid var(--blue);
  border-radius: 100px;
  color: var(--ink);
  background: var(--blue-2);
  font-size: 14.5px;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s var(--ease), border-color 0.25s ease;
}

.button:hover { background: var(--blue); transform: translateY(-3px); }
.button [data-lucide] { width: 18px; height: 18px; stroke-width: 2; }

.button--outline {
  color: var(--ink);
  background: transparent;
  border-color: var(--border);
}

.button--outline:hover {
  border-color: var(--blue);
  background: rgba(74, 146, 243, 0.08);
  transform: translateY(-3px);
}

.button--outline [data-lucide] { color: var(--blue); }

.button--small {
  padding: 10px 18px;
  font-size: 13.5px;
  gap: 10px;
}

.button--small [data-lucide] { width: 15px; height: 15px; }
.button.is-disabled { pointer-events: none; opacity: 0.5; }

kbd {
  padding: 2px 7px;
  background: var(--inset-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--muted);
  font-family: inherit;
  font-size: 12px;
}

/* ===== TOOLTIP ===== */
.has-tip { position: relative; }

.tip {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  z-index: 20;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  width: max-content;
  max-width: 250px;
  padding: 12px 14px;
  background: #131a24;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.4;
  text-align: left;
  font-weight: 400;
  white-space: normal;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 4px);
  transition: opacity 0.15s ease, transform 0.15s var(--ease), visibility 0.15s;
  pointer-events: none;
}

.tip::after {
  position: absolute;
  top: 100%;
  left: 50%;
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  background: #131a24;
  border-right: 1px solid rgba(255, 255, 255, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  transform: rotate(45deg);
  content: "";
}

.tip-ico {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  background: var(--inset-2);
  border-radius: 8px;
  color: var(--blue);
  font-size: 16px;
}

.tip b { display: block; margin-bottom: 2px; font-weight: 600; color: #fff; }
.tip span { color: var(--muted); }

.has-tip:hover > .tip,
.has-tip:focus-visible > .tip,
.has-tip.is-open > .tip {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

/* ===== HERO ===== */
.hero {
  display: flex;
  flex-direction: column;
  padding: 100px 0 0;
}

.hero__main {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(32px, 4vw, 64px);
  align-items: center;
  min-height: 480px;
}

.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(40px, 6.4vw, 88px);
  font-weight: 500;
  letter-spacing: -0.07em;
  line-height: 0.98;
}

.hero-description {
  max-width: 560px;
  margin: 0 0 22px;
  color: #c4cdd8;
  font-size: clamp(15px, 1.2vw, 17px);
  line-height: 1.5;
}

.hero-cta {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-tools {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
  color: var(--muted-2);
  font-size: 13px;
  flex-wrap: wrap;
}

.hero-tools__label { color: var(--muted-2); }

.hero-tool {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 9px;
  color: var(--ink-2);
  font-size: 15px;
  cursor: default;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.hero-tool:hover { background: var(--card-hover); color: #fff; }

.hero__status {
  position: relative;
  padding: 26px 28px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.hero__status-head {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  margin-bottom: 16px;
  border: 1px solid rgba(127, 213, 141, 0.28);
  border-radius: 999px;
  color: #b8e6c1;
  background: rgba(127, 213, 141, 0.08);
  font-size: 11.5px;
  letter-spacing: 0.02em;
}

.hero-status-dot {
  position: relative;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7fd58d;
  flex-shrink: 0;
}

.hero-status-dot::before {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #7fd58d;
  content: "";
  animation: heroStatusPing 2.2s cubic-bezier(0, 0, 0.2, 1) infinite;
}

@keyframes heroStatusPing {
  0% { opacity: 0.6; transform: scale(1); }
  75% { opacity: 0; transform: scale(2.4); }
  100% { opacity: 0; transform: scale(2.4); }
}

.hero__status-head .hero-status-dot {
  box-shadow: 0 0 0 4px rgba(127, 213, 141, 0.18);
}

.hero__status-head .hero-status-dot::before { animation: none; }

.hero__status-title {
  margin: 0 0 20px;
  font-size: clamp(20px, 1.8vw, 26px);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 1.1;
}

.hero__status-title em { color: var(--blue); font-style: normal; }

.hero__facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px 20px;
  padding-top: 18px;
  margin: 0;
  border-top: 1px solid var(--border);
}

.hero__fact { min-width: 0; }

.hero__fact dt {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero__fact dt [data-lucide] {
  width: 11px;
  height: 11px;
  color: var(--blue);
  opacity: 0.85;
  stroke-width: 2;
}

.hero__fact dd {
  margin: 0;
  color: var(--ink);
  font-size: 13.5px;
  letter-spacing: -0.01em;
}

.hero__marquee {
  position: relative;
  width: 100%;
  margin-top: 56px;
  padding: 18px 0 20px;
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
}

.hero__marquee .tags-track {
  display: flex;
  width: max-content;
  gap: 10px;
  animation: tagsMarquee 32s linear infinite;
  will-change: transform;
}

.hero__marquee .tags-track:hover { animation-play-state: paused; }

@keyframes tagsMarquee {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}

.hero__marquee .currently-tag {
  flex: 0 0 auto;
  padding: 10px 20px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(17, 22, 29, 0.6);
  font-size: 13.5px;
  letter-spacing: -0.01em;
  white-space: nowrap;
  transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.hero__marquee .currently-tag:hover {
  border-color: rgba(74, 146, 243, 0.5);
  color: var(--ink);
  background: rgba(74, 146, 243, 0.08);
}

/* ===== SECTION HEAD ===== */
.section-head {
  display: grid;
  grid-template-columns: 0.55fr 1fr;
  gap: 64px;
  align-items: end;
  margin-bottom: 40px;
}

.section-title {
  margin: 0;
  font-size: clamp(34px, 4vw, 54px);
  font-weight: 500;
  letter-spacing: -0.06em;
  line-height: 1.02;
}

.section-intro {
  max-width: 460px;
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.55;
}

/* ===== TABS ===== */
.tabs {
  display: flex;
  gap: 4px;
  padding: 5px;
  margin: 0 auto 40px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  width: fit-content;
}

.tab {
  background: transparent;
  border: none;
  color: var(--muted);
  padding: 10px 24px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
  font-family: inherit;
  white-space: nowrap;
}

.tab:hover { color: var(--ink); background: var(--inset-2); }

.tab.active {
  background: rgba(74, 146, 243, 0.15);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(74, 146, 243, 0.4);
}

/* ===== NESTED BLOCKS ===== */
.card-blocks {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 2px;
}

.card-block {
  padding: 11px 12px;
  background: var(--inset);
  border-radius: 10px;
}

.card-block__label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted-2);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.card-block__value {
  display: block;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  line-height: 1.35;
}

.card-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.tool-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--inset-2);
  border-radius: 7px;
  color: var(--ink-2);
  font-size: 13px;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.tool-icon:hover { background: var(--inset); color: #fff; }

/* ===== PROJECT CARDS ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

.project-card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: background-color 0.25s ease, border-color 0.2s ease;
  height: 100%;
}

.project-card:hover {
  background: var(--card-hover);
  border-color: rgba(255, 255, 255, 0.11);
}

.project-card__cover {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0a0d12;
  border-bottom: 1px solid var(--border-subtle);
  display: block;
  flex-shrink: 0;
}

.project-card__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease);
}

.project-card:hover .project-card__cover img { transform: scale(1.03); }

.project-card__duration {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px 5px 11px;
  background: rgba(6, 9, 16, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: -0.005em;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.85);
}

.project-card__duration .dur {
  color: var(--blue);
  font-weight: 600;
  text-shadow: 0 0 8px rgba(74, 146, 243, 0.3);
}

.project-card__duration .year {
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 11px;
  line-height: 1.2;
}

.project-card__duration .cat { color: rgba(255, 255, 255, 0.6); }

.project-card__status {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 4px 10px;
  background: rgba(6, 9, 16, 0.85);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--ink-2);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.project-card__status--nda {
  background: rgba(74, 146, 243, 0.18);
  border-color: rgba(74, 146, 243, 0.5);
  color: #b8d3ff;
}

.project-card__body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px 22px 22px;
  flex: 1;
}

.project-card__title {
  margin: 0;
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.2;
}

.project-card__title a { color: var(--ink); transition: color 0.2s ease; }
.project-card__title a:hover { color: #fff; }

.project-card__desc {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(1.55em * 4);
}

.project-card__desc.is-expanded {
  -webkit-line-clamp: unset;
  display: block;
  overflow: visible;
  min-height: 0;
}

.project-card__more-wrap {
  display: flex;
  min-height: 18px;
  align-items: center;
}

.project-card__more {
  display: none;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--blue);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  cursor: pointer;
  transition: color 0.2s ease;
}

.project-card__more:hover { color: #fff; }
.project-card__more.is-visible { display: inline-block; }

.project-card__footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  min-height: 55px;
}

.project-card__nda-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px dashed rgba(74, 146, 243, 0.45);
  border-radius: 100px;
  color: rgba(184, 211, 255, 0.95);
  background: rgba(74, 146, 243, 0.08);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: not-allowed;
  user-select: none;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.project-card__nda-label::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 3px rgba(74, 146, 243, 0.2);
}

.project-card__nda-label:hover {
  border-color: rgba(74, 146, 243, 0.7);
  background: rgba(74, 146, 243, 0.14);
}

/* ===== STRUCTURE ===== */
.structure-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.structure-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 26px 24px 28px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: background-color 0.25s ease, border-color 0.2s ease;
}

.structure-card:hover {
  background: var(--card-hover);
  border-color: rgba(255, 255, 255, 0.11);
}

.structure-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--inset);
  border-radius: 11px;
  color: var(--blue);
  transition: background-color 0.25s ease;
}

.structure-card:hover .structure-card__icon { background: var(--inset-2); }

.structure-card__icon [data-lucide] {
  width: 22px;
  height: 22px;
  stroke-width: 1.6;
  transition: transform 0.4s var(--ease);
}

.structure-card:hover .structure-card__icon [data-lucide] {
  animation: iconPop 0.6s var(--ease);
}

@keyframes iconPop {
  0% { transform: scale(1); }
  40% { transform: scale(1.18); }
  100% { transform: scale(1); }
}

.structure-card__title {
  margin: 0;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.structure-card__desc {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
}

/* ===== PROCESS ===== */
.process-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.process-card {
  padding: 28px 26px 32px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: background-color 0.25s ease, border-color 0.2s ease;
}

.process-card:hover {
  background: var(--card-hover);
  border-color: rgba(255, 255, 255, 0.11);
}

.process-card__num {
  display: block;
  margin-bottom: 32px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
}

.process-card h3 {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.2;
}

.process-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.55;
}

/* ===== TILES ===== */
.tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.tile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  cursor: default;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.tile:hover, .tile:focus-visible {
  background: var(--card-hover);
  border-color: rgba(255, 255, 255, 0.11);
}

.tile [data-lucide] {
  color: var(--blue);
  width: 18px;
  height: 18px;
}

.tile--cta {
  border-color: rgba(74, 146, 243, 0.35);
  background: linear-gradient(160deg, rgba(74, 146, 243, 0.1), rgba(74, 146, 243, 0.02));
  color: var(--ink);
}

.tile--cta:hover, .tile--cta:focus-visible {
  background: linear-gradient(160deg, rgba(74, 146, 243, 0.18), rgba(74, 146, 243, 0.06));
  border-color: rgba(74, 146, 243, 0.55);
}

.tile--cta [data-lucide] { color: #b8d3ff; }

/* ===== FAQ ===== */
.faq-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--border);
  max-width: 900px;
  margin: 0 auto;
}

.faq-item { border-bottom: 1px solid var(--border); }

.faq-item summary {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 4px;
  cursor: pointer;
  list-style: none;
  color: var(--ink);
  font-size: clamp(17px, 1.6vw, 21px);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.3;
  transition: padding 0.3s var(--ease), color 0.25s ease;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary:hover {
  padding-left: 12px;
  padding-right: 12px;
  color: #fff;
}

.faq-item summary [data-lucide] {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: var(--blue);
  transition: transform 0.35s var(--ease);
}

.faq-item[open] summary [data-lucide] { transform: rotate(45deg); }

.faq-item p {
  max-width: 780px;
  margin: 0;
  padding: 0 4px 26px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

/* ===== RELATED NICHES ===== */
.related-niches {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

.niche-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 320px;
  padding: 24px 22px 22px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  transition: border-color 0.35s var(--ease), transform 0.35s var(--ease), box-shadow 0.5s var(--ease);
}

.niche-card:hover {
  border-color: rgba(74, 146, 243, 0.5);
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(74, 146, 243, 0.12);
}

.niche-card--image {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.niche-card__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  opacity: 0.55;
  filter: saturate(0.9) contrast(1.02);
  transition: opacity 0.5s var(--ease), transform 0.8s var(--ease), filter 0.5s var(--ease);
  pointer-events: none;
}

.niche-card--image::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(6, 9, 16, 0.55) 0%, rgba(6, 9, 16, 0.75) 45%, rgba(6, 9, 16, 0.94) 100%);
  transition: background 0.5s var(--ease);
  pointer-events: none;
}

.niche-card--image:hover .niche-card__image {
  opacity: 0.75;
  transform: scale(1.06);
  filter: saturate(1) contrast(1.05);
}

.niche-card--image:hover::before {
  background: linear-gradient(180deg, rgba(6, 9, 16, 0.45) 0%, rgba(6, 9, 16, 0.7) 45%, rgba(6, 9, 16, 0.92) 100%);
}

.niche-card__top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 24px;
}

.niche-card__tag {
  display: inline-flex;
  padding: 5px 12px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  color: rgba(232, 238, 247, 0.9);
  background: rgba(6, 9, 16, 0.5);
  font-size: 11.5px;
  letter-spacing: 0.02em;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: border-color 0.3s ease, color 0.3s ease;
}

.niche-card:hover .niche-card__tag {
  border-color: rgba(74, 146, 243, 0.45);
  color: #fff;
}

.niche-card__icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  color: var(--blue);
  background: rgba(6, 9, 16, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: border-color 0.3s ease, background 0.3s ease, transform 0.3s var(--ease);
}

.niche-card:hover .niche-card__icon {
  border-color: rgba(74, 146, 243, 0.7);
  background: rgba(74, 146, 243, 0.35);
  transform: translateY(-2px);
}

.niche-card__icon [data-lucide] { width: 18px; height: 18px; }

.niche-card__title {
  position: relative;
  z-index: 1;
  margin: 0 0 10px;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.15;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}

.niche-card__desc {
  position: relative;
  z-index: 1;
  margin: 0 0 22px;
  color: rgba(232, 238, 247, 0.78);
  font-size: 13.5px;
  line-height: 1.55;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.4);
}

.niche-card__arrow {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: auto;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  transition: gap 0.3s var(--ease);
  line-height: 1.35;
}

.niche-card__arrow [data-lucide] { width: 15px; height: 15px; flex-shrink: 0; }
.niche-card:hover .niche-card__arrow { gap: 11px; }
.niche-card__image[data-error="true"] { display: none; }

/* ===== FINALE ===== */
.finale {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-top: 1px solid var(--border);
  background: var(--bg-elevated);
}

.finale::before {
  position: absolute;
  top: 0;
  right: 8%;
  width: 42%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--blue));
  pointer-events: none;
  content: "";
}

.finale-main {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(48px, 6vw, 96px);
  align-items: center;
  padding: 88px 0 72px;
}

.finale-title {
  margin: 0 0 24px;
  font-size: clamp(42px, 6.2vw, 88px);
  font-weight: 500;
  letter-spacing: -0.085em;
  line-height: 0.92;
}

.finale-title span { color: var(--blue); }

.finale-sub {
  max-width: 460px;
  margin: 0 0 40px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.55;
}

.finale-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.cta-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 14px;
  transition: color 0.25s ease;
}

.cta-link:hover { color: var(--ink); }
.cta-link [data-lucide] { width: 14px; height: 14px; }

.finale-status {
  position: relative;
  padding: 34px 36px 30px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card-bg);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.finale-status-head {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  margin-bottom: 22px;
  border: 1px solid rgba(127, 213, 141, 0.28);
  border-radius: 999px;
  color: #b8e6c1;
  background: rgba(127, 213, 141, 0.08);
  font-size: 12px;
  letter-spacing: 0.02em;
}

.finale-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7fd58d;
  box-shadow: 0 0 0 4px rgba(127, 213, 141, 0.18);
}

.finale-status-title {
  margin: 0 0 14px;
  font-size: clamp(22px, 2.2vw, 30px);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 1.08;
}

.finale-status-title em { color: var(--blue); font-style: normal; }

.finale-status-desc {
  margin: 0 0 26px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.finale-facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  padding-top: 22px;
  margin: 0;
  border-top: 1px solid var(--border);
}

.finale-fact { min-width: 0; }

.finale-fact dt {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.finale-fact dt [data-lucide] {
  width: 12px;
  height: 12px;
  color: var(--blue);
  opacity: 0.85;
  stroke-width: 2;
}

.finale-fact dd {
  margin: 0;
  color: var(--ink);
  font-size: 14px;
  letter-spacing: -0.01em;
}

/* ===== SEO / LEGAL / CHIP ===== */
.seo-content { padding: 80px 0 60px; }

.seo-content__inner {
  max-width: 900px;
  margin: 0 auto;
}

.seo-content__title {
  margin: 0 0 28px;
  color: var(--ink);
  font-size: clamp(22px, 2.4vw, 30px);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.15;
}

.seo-content__text p {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.seo-content__text strong { color: var(--ink); font-weight: 500; }

.seo-content__link {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.seo-content__link:hover { color: #fff; }

.legal-note { padding: 0 0 40px; }

.legal-note__card {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 20px;
  align-items: flex-start;
  max-width: 880px;
  margin: 0 auto;
  padding: 22px 26px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.legal-note__icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  background: var(--inset);
  border-radius: 10px;
  color: var(--blue);
  flex-shrink: 0;
}

.legal-note__icon [data-lucide] { width: 18px; height: 18px; }

.legal-note__title {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.35;
}

.legal-note__text {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.hub-chip-section {
  padding: 40px 0 60px;
  border-top: 1px solid var(--border);
}

.hub-chip-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.hub-chip {
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: var(--card-bg);
  font-size: 13px;
  font-weight: 500;
  transition: all 0.25s var(--ease);
}

.hub-chip:hover {
  border-color: rgba(74, 146, 243, 0.5);
  color: var(--ink);
  background: rgba(74, 146, 243, 0.08);
  transform: translateY(-2px);
}

.hub-chip.active {
  border-color: rgba(74, 146, 243, 0.55);
  color: var(--ink);
  background: rgba(74, 146, 243, 0.14);
  pointer-events: none;
}

/* ===== COMMAND PALETTE ===== */
.pal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 14vh 16px 16px;
  background: rgba(4, 6, 10, 0.72);
}

.pal.on { display: flex; }

.pal-box {
  width: min(560px, 100%);
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
}

.pal-in {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--muted-2);
}

.pal-in input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 16px;
}

.pal-list {
  max-height: 340px;
  margin: 0;
  padding: 6px;
  overflow-y: auto;
  list-style: none;
}

.pal-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 8px;
  font-size: 14.5px;
}

.pal-list a.on {
  background: var(--inset-2);
  box-shadow: inset 2px 0 0 var(--blue);
}

.pal-list img {
  width: 40px;
  height: 28px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border);
}

.pal-list em {
  margin-left: auto;
  color: var(--muted-2);
  font-style: normal;
  font-size: 12px;
}

.pal-foot {
  display: flex;
  gap: 16px;
  padding: 10px 16px;
  border-top: 1px solid var(--border);
  color: var(--muted-2);
  font-size: 12px;
}

.pal-empty {
  padding: 24px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

/* ===== FOOTER ===== */
.footer {
  position: relative;
  padding: 60px 20px;
  background: #060910;
  overflow: hidden;
  font-size: 15px;
  color: var(--muted);
}

.footer::after {
  content: "";
  position: absolute;
  bottom: -80px;
  right: -100px;
  width: 800px;
  height: 600px;
  background: radial-gradient(70% 60% at 90% 100%, rgba(59, 91, 140, 0.35) 0%, rgba(59, 91, 140, 0.15) 40%, rgba(59, 91, 140, 0.1) 70%, transparent 100%);
  pointer-events: none;
  z-index: 0;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 40px;
}

.footer-logo img {
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: #fff;
  padding: 6px;
}

.footer-menu {
  display: flex;
  gap: 32px;
  font-size: 16px;
  flex-wrap: wrap;
}

.footer-menu a { color: #b0b8c2; transition: 0.3s; }
.footer-menu a:hover { font-weight: 600; color: #fff; }

.footer-links-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  margin: 50px 0 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 40px;
}

.footer-col h4 {
  color: #fff;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: -0.3px;
}

.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }

.footer-col a {
  color: #b0b8c2;
  font-size: 14px;
  transition: 0.2s;
  display: inline-block;
}

.footer-col a:hover { color: #fff; transform: translateX(3px); }

.footer-cta h2 {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 20px;
  color: #fff;
}

.footer-buttons { display: flex; flex-wrap: wrap; gap: 16px; }

.footer .button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 10px;
  background: #11141a;
  border: 1px solid #2a2b2e;
  color: #fff;
  font-size: 15px;
  transition: 0.2s;
  width: auto;
}

.footer .button:hover { background: #2b2c31; transform: none; }
.footer .button img { width: 20px; height: 20px; object-fit: contain; }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 60px;
  border-top: 1px solid #2a2a2d;
  padding-top: 20px;
  font-size: 14px;
  color: #b0b8c2;
}

.crafted { display: flex; align-items: center; gap: 10px; }
.crafted img { height: 40px; }

.scroll-top {
  position: absolute;
  right: 0;
  bottom: 125px;
  color: #fff;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 12px 24px;
  border-radius: 9999px;
  transition: background 0.3s;
  font-size: 15px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.scroll-top:hover { background: #2a2b30; }

/* ===== REVEAL ===== */
[data-reveal] {
  opacity: 0;
  translate: 0 20px;
}

[data-reveal].is-visible {
  animation: revealIn 0.7s var(--ease) both;
  animation-delay: calc(var(--stagger-i, 0) * 0.07s);
}

@keyframes revealIn {
  from { opacity: 0; translate: 0 20px; }
  to { opacity: 1; translate: 0 0; }
}

/* ===== ADAPTIVE ===== */
@media (max-width: 1100px) {
  .projects-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .process-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .related-niches { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .structure-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tiles { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 900px) {
  .section { padding: 80px 0; }
  .section-head { grid-template-columns: 1fr; gap: 24px; }
  .section-intro { max-width: 100%; }
  .hero { padding: 80px 0 0; }
  .hero__main { grid-template-columns: 1fr; gap: 32px; min-height: 0; }
  .hero__marquee { margin-top: 40px; }
  .finale-main { grid-template-columns: 1fr; gap: 40px; padding: 64px 0 56px; }
  .footer-links-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 850px) {
  :root { --subnav-h: 47px; }

  .sub-nav-link {
    padding: 13px 11px;
    font-size: 13px;
    gap: 6px;
  }

  .sub-nav-link [data-lucide] { width: 14px; height: 14px; }
  .sub-nav-link::after { right: 12px; left: 12px; }
}

@media (max-width: 700px) {
  .container { width: min(calc(100% - 32px), var(--max)); }
  .section-title { font-size: clamp(30px, 8.5vw, 42px); }

    .hero { padding: calc(var(--subnav-h) + 64px) 0 72px; }
  .hero__main { min-height: 0; gap: 32px; padding-bottom: 0; }
  .hero h1 { font-size: clamp(46px, 14vw, 72px); margin-bottom: 24px; letter-spacing: -0.08em; line-height: 0.92; }
  .hero-description { font-size: 16px; margin-top: 20px; margin-bottom: 0; max-width: 440px; line-height: 1.45; }
  .hero-cta { flex-direction: column; align-items: stretch; gap: 12px; margin-top: 32px; }
  .hero-cta .button { justify-content: center; width: 100%; padding: 15px 20px; }
  .hero-tools { margin-top: 24px; }
  .hero__status { padding: 22px 22px; }
  .hero__status-head { margin-bottom: 14px; font-size: 11.5px; padding: 6px 12px; }
  .hero__status-title { font-size: 20px; margin-bottom: 16px; }
  .hero__facts { gap: 12px 18px; padding-top: 16px; }
  .hero__fact dd { font-size: 13.5px; }
  .hero__marquee { margin-top: 40px; padding: 16px 0 18px; }
  .hero__marquee .currently-tag { padding: 9px 16px; font-size: 13px; }

  .section { padding: 64px 0; }
  .section-head { margin-bottom: 32px; }

  .tabs { overflow-x: auto; width: 100%; scrollbar-width: none; margin-bottom: 28px; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab { padding: 9px 18px; font-size: 13px; }

  .projects-grid { grid-template-columns: 1fr; gap: 14px; }
  .structure-grid { grid-template-columns: 1fr; }
  .process-grid { grid-template-columns: 1fr; }
  .tiles { grid-template-columns: repeat(2, 1fr); }

  .finale-title { font-size: clamp(36px, 12vw, 56px); margin-bottom: 20px; }
  .finale-sub { margin-bottom: 30px; font-size: 15px; }
  .finale-actions { flex-direction: column; align-items: stretch; gap: 14px; }
  .finale-actions .button { justify-content: center; width: 100%; }
  .finale-actions .cta-link { justify-content: center; }
  .finale-status { padding: 24px 22px; }
  .finale-facts { grid-template-columns: 1fr; gap: 12px; }

  .seo-content { padding: 48px 0 40px; }
  .seo-content__title { font-size: 20px; margin-bottom: 20px; }
  .seo-content__text p { font-size: 14.5px; line-height: 1.65; }

  .legal-note__card { grid-template-columns: 1fr; gap: 14px; padding: 20px 20px; }

  .related-niches {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 14px;
    margin-inline: -16px;
    padding-inline: 16px;
    padding-bottom: 8px;
    margin-bottom: 8px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .related-niches::-webkit-scrollbar { display: none; }

  .niche-card {
    flex: 0 0 80%;
    max-width: 80%;
    scroll-snap-align: start;
    min-height: 300px;
  }

  .niche-card:hover { transform: none; }

  .footer { padding: 40px 16px; text-align: center; }
  .footer-top { flex-direction: column; align-items: center; }
  .footer-menu { flex-direction: column; gap: 12px; }
  .footer-cta h2 { font-size: 20px; }
  .footer-buttons { flex-direction: column; align-items: center; gap: 12px; }
  .footer .button { width: 100%; max-width: 280px; justify-content: center; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .scroll-top { position: static; margin: 24px auto 0; width: 100%; max-width: 200px; display: block; }
}

@media (max-width: 550px) {
  .footer-links-grid { grid-template-columns: 1fr; gap: 25px; }
  .footer-col { border-bottom: 1px solid rgba(255, 255, 255, 0.05); padding-bottom: 15px; }
  .footer-col:last-child { border-bottom: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  [data-reveal] { opacity: 1; translate: 0; }
  [data-reveal].is-visible { animation: none !important; }
  .hero__marquee .tags-track { animation: none !important; }
  .structure-card:hover .structure-card__icon [data-lucide] { animation: none; }
  .hero-status-dot::before { animation: none; }
}