/* ==========================================================================
   Home — sections below the intro, in the intro's visual language
   (markup: app/View/home/index.php · motion: assets/js/modules/dx-home.js)
   ========================================================================== */

.dxh { position: relative; overflow-x: clip; background: #04080A; }
.dxh::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(60vmax 40vmax at 0% 18%, rgba(32, 220, 203, 0.07), transparent 70%),
    radial-gradient(55vmax 40vmax at 100% 52%, rgba(61, 123, 255, 0.07), transparent 70%),
    radial-gradient(50vmax 40vmax at 10% 88%, rgba(8, 127, 121, 0.09), transparent 70%);
}

/* ---------- reveal (uses the global data-reveal observer) ---------- */
/* reveal moves with `translate` so cards keep `transform` free for the tilt */
.js .dxh [data-reveal] {
  opacity: 0;
  translate: 0 34px;
  transition: opacity 900ms ease var(--d, 0ms), translate 1100ms var(--dx-ease) var(--d, 0ms);
}
.js .dxh [data-reveal].is-visible { opacity: 1; translate: none; }

/* ---------- shared headings ---------- */
.dxh-section { position: relative; padding: clamp(5rem, 10vw, 8.5rem) 0; }
.dxh-head { max-width: 46rem; margin-bottom: clamp(2.5rem, 5vw, 3.75rem); }
.dxh-head--center { margin-inline: auto; text-align: center; }
.dxh-head--center .dxh-kicker { justify-content: center; }
.dxh-head--row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.5rem; max-width: none; }
.dxh-head--row > div { max-width: 46rem; }
.dxh-kicker { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 1.1rem; font-size: 0.74rem; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase; color: var(--dx-mint); }
.dxh-kicker span { width: 1.8rem; height: 2px; border-radius: 2px; background: linear-gradient(90deg, var(--dx-turq), transparent); }
.dxh-h2 { font-size: clamp(2.2rem, 4.6vw, 4.2rem); font-weight: 800; line-height: 1.02; letter-spacing: -0.045em; color: #fff; }
.dxh-grad {
  background: linear-gradient(100deg, var(--dx-turq), var(--dx-mint) 40%, #8FB2FF 75%, var(--dx-turq));
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: dx-pan 9s linear infinite;
}
.dxh-lead { margin-top: 1.2rem; max-width: 38rem; font-size: clamp(1rem, 0.5vw + 0.85rem, 1.12rem); line-height: 1.7; color: rgba(244, 247, 246, 0.64); }
.dxh-link {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.75rem 1.25rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
  transition: border-color 300ms ease, background 300ms ease;
}
.dxh-link svg { width: 1rem; height: 1rem; transition: transform 400ms var(--dx-ease); }
.dxh-link:hover { border-color: var(--dx-turq); background: rgba(32, 220, 203, 0.1); }
.dxh-link:hover svg { transform: translateX(4px); }

/* ==========================================================================
   MARQUEE
   ========================================================================== */
.dxh-marquee { position: relative; z-index: 1; display: grid; gap: 1.1rem; padding: 2.4rem 0; overflow: hidden; border-block: 1px solid rgba(255, 255, 255, 0.06); background: rgba(6, 14, 16, 0.6); }
.dxh-marquee__row { display: flex; align-items: center; gap: 0.9rem; width: max-content; will-change: transform; }
.dxh-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 1.4rem 0.7rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  font-size: clamp(1.05rem, 1.8vw, 1.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  white-space: nowrap;
  color: #fff;
}
.dxh-pill i { display: grid; place-items: center; width: 2.2rem; height: 2.2rem; padding: 0.5rem; border-radius: 50%; background: linear-gradient(135deg, var(--tone), var(--tone-2)); color: var(--dx-ink); }
.dxh-word { font-size: clamp(2.2rem, 5.6vw, 5rem); font-weight: 800; letter-spacing: -0.05em; white-space: nowrap; color: transparent; -webkit-text-stroke: 1.2px rgba(244, 247, 246, 0.35); transition: color 300ms ease, -webkit-text-stroke-color 300ms ease; }
.dxh-word:hover { color: var(--dx-turq); -webkit-text-stroke-color: var(--dx-turq); }
.dxh-star { font-size: 1.6rem; color: var(--dx-turq); }

/* ==========================================================================
   SERVICES — bento of glass cards
   ========================================================================== */
.dxh-bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 1.1rem; }
.dxh-card {
  --mx: 50%;
  --my: 50%;
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  grid-column: span var(--span, 6);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2.4rem;
  min-height: 19rem;
  padding: 1.8rem;
  border-radius: 1.6rem;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015));
  color: #fff;
  transform: perspective(1100px) rotateX(var(--rx)) rotateY(var(--ry));
}
.js .dxh .dxh-card[data-reveal] { transition: opacity 900ms ease var(--d, 0ms), translate 1100ms var(--dx-ease) var(--d, 0ms), transform 500ms var(--dx-ease), border-color 400ms ease; }
.dxh-card:hover { border-color: color-mix(in srgb, var(--tone) 55%, transparent); }
.dxh-card:focus-visible { outline: 2px solid var(--tone); outline-offset: 3px; }
.dxh-card__media { position: absolute; inset: 0; z-index: -2; opacity: 0.16; transition: opacity 600ms ease; }
.dxh-card__media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); filter: saturate(0.6); transition: transform 900ms var(--dx-ease), filter 600ms ease; }
.dxh-card__media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(4, 8, 10, 0.2), rgba(4, 8, 10, 0.92) 80%); }
.dxh-card:hover .dxh-card__media { opacity: 0.42; }
.dxh-card:hover .dxh-card__media img { transform: scale(1.12); filter: saturate(1); }
.dxh-card__glow { position: absolute; inset: 0; z-index: -1; background: radial-gradient(420px circle at var(--mx) var(--my), color-mix(in srgb, var(--tone) 22%, transparent), transparent 60%); opacity: 0; transition: opacity 400ms ease; }
.dxh-card:hover .dxh-card__glow { opacity: 1; }
.dxh-card__top { display: flex; align-items: flex-start; justify-content: space-between; }
.dxh-card__icon { display: grid; place-items: center; width: 3.2rem; height: 3.2rem; padding: 0.8rem; border-radius: 1rem; background: linear-gradient(135deg, var(--tone), var(--tone-2)); color: var(--dx-ink); box-shadow: 0 14px 30px -14px var(--tone); transition: transform 500ms var(--dx-spring); }
.dxh-card:hover .dxh-card__icon { transform: rotate(-8deg) scale(1.08); }
.dxh-card__num { font-size: 3.4rem; font-weight: 800; line-height: 0.8; letter-spacing: -0.06em; color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, 0.18); }
.dxh-card__body { display: grid; gap: 0.6rem; }
.dxh-card__title { font-size: clamp(1.35rem, 1.8vw, 1.75rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; }
.dxh-card__text { max-width: 30rem; font-size: 0.98rem; line-height: 1.6; color: rgba(244, 247, 246, 0.66); }
.dxh-card__more { display: inline-flex; align-items: center; gap: 0.45rem; margin-top: 0.5rem; font-size: 0.86rem; font-weight: 700; color: var(--tone); }
.dxh-card__more svg { width: 1rem; height: 1rem; transition: transform 400ms var(--dx-ease); }
.dxh-card:hover .dxh-card__more svg { transform: translateX(5px); }

/* ==========================================================================
   PROCESS — five steps on a line that fills while scrolling
   ========================================================================== */
.dxh-steps { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.1rem; padding-top: 2.4rem; }
.dxh-steps__line { position: absolute; left: 1.4rem; right: 1.4rem; top: 1.3rem; height: 2px; border-radius: 2px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.dxh-steps__line i { display: block; height: 100%; background: linear-gradient(90deg, var(--dx-turq), var(--dx-mint), #8FB2FF); transform-origin: left; transform: scaleX(0); box-shadow: 0 0 14px rgba(32, 220, 203, 0.8); }
.dxh-step {
  position: relative;
  display: grid;
  align-content: start;
  gap: 0.7rem;
  padding: 1.5rem 1.3rem 1.6rem;
  border-radius: 1.3rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01));
  transition: border-color 400ms ease, background 400ms ease;
}
.dxh-step__dot { position: absolute; top: -2.45rem; left: 1.3rem; display: grid; place-items: center; width: 2.3rem; height: 2.3rem; border-radius: 50%; background: #0a1517; border: 1px solid rgba(255, 255, 255, 0.16); font-size: 0.85rem; font-weight: 800; color: rgba(255, 255, 255, 0.7); transition: background 400ms ease, color 400ms ease, border-color 400ms ease, box-shadow 400ms ease; }
.dxh-step__icon { display: grid; place-items: center; width: 2.6rem; height: 2.6rem; padding: 0.65rem; border-radius: 0.8rem; background: rgba(32, 220, 203, 0.1); color: var(--dx-turq); }
.dxh-step h3 { font-size: 1.15rem; font-weight: 800; letter-spacing: -0.02em; }
.dxh-step p { font-size: 0.9rem; line-height: 1.6; color: rgba(244, 247, 246, 0.6); }
.dxh-step.is-lit { border-color: rgba(32, 220, 203, 0.35); background: linear-gradient(180deg, rgba(32, 220, 203, 0.09), rgba(255, 255, 255, 0.01)); }
.dxh-step.is-lit .dxh-step__dot { background: var(--dx-turq); color: var(--dx-ink); border-color: var(--dx-turq); box-shadow: 0 0 0 6px rgba(32, 220, 203, 0.15), 0 0 24px rgba(32, 220, 203, 0.6); }

/* ==========================================================================
   PROJECTS (cards/filters come from main.css; layout tuned here)
   ========================================================================== */
.home-projects::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 55%;
  width: min(1100px, 90vw);
  height: 60%;
  translate: -50% -50%;
  pointer-events: none;
  background: radial-gradient(closest-side, rgba(32, 220, 203, 0.09), transparent);
}
.dxh-work-side { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; }
.dxh-work-stats { display: flex; gap: 0.5rem; }
.dxh-work-stats div {
  display: grid;
  gap: 0.15rem;
  min-width: 6.5rem;
  padding: 0.7rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}
.dxh-work-stats dt { order: 2; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.04em; color: rgba(244, 247, 246, 0.55); }
.dxh-work-stats dd { order: 1; font-size: 1.6rem; font-weight: 800; line-height: 1; letter-spacing: -0.04em; color: #fff; }
.dxh .home-filter { margin-bottom: 0.5rem; }
.dxh .dxh-projects { align-items: stretch; }
@media (min-width: 1024px) {
  .dxh .dxh-projects { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
/* card polish on the home page */
.dxh .project-card__link { background: linear-gradient(170deg, rgba(14, 26, 29, 0.95), rgba(8, 14, 16, 0.75)); }
.dxh .project-card__media::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(260px circle at var(--cx, 50%) var(--cy, 50%), rgba(32, 220, 203, 0.22), transparent 70%);
  opacity: 0;
  transition: opacity 400ms ease;
}
.dxh .project-card__link:hover .project-card__media::after { opacity: 1; }
.dxh .project-card__title { font-size: 1.25rem; letter-spacing: -0.02em; }

/* invitation card that completes the row */
.dxh-next {
  --mx: 50%;
  --my: 50%;
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
  min-height: 100%;
  padding: 1.6rem;
  border-radius: 1.5rem;
  overflow: hidden;
  isolation: isolate;
  border: 1.5px dashed rgba(32, 220, 203, 0.4);
  background:
    radial-gradient(120% 70% at 100% 0%, rgba(32, 220, 203, 0.14), transparent 60%),
    radial-gradient(90% 60% at 0% 100%, rgba(61, 123, 255, 0.12), transparent 60%),
    rgba(6, 14, 16, 0.6);
  color: #fff;
  transform: perspective(1000px) rotateX(var(--rx)) rotateY(var(--ry));
  transition: transform 500ms var(--dx-ease), border-color 400ms ease, box-shadow 450ms ease;
}
.dxh-next::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  -webkit-mask-image: radial-gradient(circle at 70% 30%, #000, transparent 75%);
  mask-image: radial-gradient(circle at 70% 30%, #000, transparent 75%);
}
.dxh-next:hover { border-style: solid; border-color: var(--dx-turq); box-shadow: 0 30px 70px -30px rgba(32, 220, 203, 0.45); }
.dxh-next:focus-visible { outline: 2px solid var(--dx-turq); outline-offset: 3px; }
.dxh-next__glow { position: absolute; inset: 0; z-index: -1; background: radial-gradient(320px circle at var(--mx) var(--my), rgba(32, 220, 203, 0.2), transparent 65%); opacity: 0; transition: opacity 400ms ease; }
.dxh-next:hover .dxh-next__glow { opacity: 1; }
.dxh-next__chip { align-self: flex-start; padding: 0.35rem 0.8rem; border-radius: 999px; border: 1px solid rgba(32, 220, 203, 0.35); background: rgba(5, 9, 11, 0.6); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dx-turq); }
.dxh-next__orb { position: relative; display: grid; place-items: center; width: 6.5rem; height: 6.5rem; margin: 0 auto; border-radius: 50%; background: radial-gradient(circle at 50% 40%, rgba(32, 220, 203, 0.25), rgba(5, 9, 11, 0.9) 70%); box-shadow: 0 0 60px rgba(32, 220, 203, 0.35); color: var(--dx-turq); transition: transform 600ms var(--dx-spring); }
.dxh-next__orb svg { width: 2.2rem; height: 2.2rem; }
.dxh-next__ring { position: absolute; inset: -0.6rem; border-radius: 50%; border: 1.5px dashed rgba(32, 220, 203, 0.5); animation: dx-spin 18s linear infinite; }
.dxh-next:hover .dxh-next__orb { transform: scale(1.08) rotate(90deg); }
.dxh-next__body { display: grid; gap: 0.7rem; }
.dxh-next__title { font-size: 1.5rem; font-weight: 800; line-height: 1.15; letter-spacing: -0.03em; }
.dxh-next__title em { font-style: normal; background: linear-gradient(90deg, var(--dx-turq), var(--dx-lime)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.dxh-next__text { font-size: 0.92rem; line-height: 1.6; color: rgba(244, 247, 246, 0.65); }
.dxh-next__cta { display: inline-flex; align-items: center; gap: 0.5rem; margin-top: 0.4rem; font-size: 0.9rem; font-weight: 700; color: var(--dx-turq); }
.dxh-next__cta svg { width: 1rem; height: 1rem; transition: transform 400ms var(--dx-ease); }
.dxh-next:hover .dxh-next__cta svg { transform: translateX(5px); }

/* ==========================================================================
   PROMISES — count-ups
   ========================================================================== */
.dxh-promises__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.1rem; }
.dxh-promise {
  position: relative;
  padding: 2rem 1.6rem;
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}
.dxh-promise::before { content: ''; position: absolute; left: 1.6rem; right: 1.6rem; top: 0; height: 2px; background: linear-gradient(90deg, var(--tone), transparent); }
.dxh-promise__value { font-size: clamp(2.8rem, 5vw, 4.4rem); font-weight: 800; line-height: 1; letter-spacing: -0.05em; color: #fff; font-variant-numeric: tabular-nums; }
.dxh-promise__value span { background: linear-gradient(120deg, #fff, var(--tone-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.dxh-promise__label { margin-top: 0.8rem; font-size: 0.95rem; color: rgba(244, 247, 246, 0.62); }

/* ==========================================================================
   TESTIMONIALS
   ========================================================================== */
.dxh-quotes { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 1.1rem; }
.dxh-quote { padding: 1.8rem; border-radius: 1.5rem; border: 1px solid rgba(255, 255, 255, 0.08); background: rgba(255, 255, 255, 0.03); }
.dxh-quote p { font-size: 1.05rem; line-height: 1.7; color: rgba(244, 247, 246, 0.85); }
.dxh-quote footer { margin-top: 1.2rem; font-size: 0.9rem; color: rgba(244, 247, 246, 0.6); }
.dxh-quote footer b { color: #fff; }

/* ==========================================================================
   CTA
   ========================================================================== */
.dxh-cta-wrap { padding-top: 2rem; }
.dxh-cta {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: clamp(3rem, 7vw, 6rem) clamp(1.5rem, 6vw, 5rem);
  border-radius: 2rem;
  border: 1px solid rgba(32, 220, 203, 0.22);
  background: linear-gradient(140deg, #072124 0%, #04090B 55%, #081631 100%);
  box-shadow: 0 40px 100px -50px rgba(32, 220, 203, 0.45);
}
.dxh-cta__blob { position: absolute; left: 0; top: 0; z-index: -1; width: 34rem; height: 34rem; margin: -17rem 0 0 -17rem; border-radius: 50%; background: radial-gradient(circle, rgba(32, 220, 203, 0.42), transparent 65%); filter: blur(30px); will-change: transform; }
.dxh-cta__grid { position: absolute; inset: 0; z-index: -1; background-image: linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px); background-size: 64px 64px; -webkit-mask-image: radial-gradient(circle at 70% 40%, #000, transparent 70%); mask-image: radial-gradient(circle at 70% 40%, #000, transparent 70%); }
.dxh-cta__content { max-width: 44rem; }
.dxh-cta__title { font-size: clamp(2.4rem, 5.4vw, 5rem); font-weight: 800; line-height: 1; letter-spacing: -0.05em; color: #fff; }
.dxh-cta__text { margin-top: 1.2rem; max-width: 34rem; font-size: 1.05rem; line-height: 1.7; color: rgba(244, 247, 246, 0.68); }
.dxh-cta__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
.dxh-cta__chips { display: flex; flex-wrap: wrap; gap: 0.6rem 1.2rem; margin-top: 2rem; }
.dxh-cta__chips li { display: inline-flex; align-items: center; gap: 0.45rem; font-size: 0.86rem; font-weight: 600; color: rgba(244, 247, 246, 0.75); }
.dxh-cta__chips svg { color: var(--dx-turq); }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1100px) {
  .dxh-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 3.4rem; }
  .dxh-steps__line { display: none; }
  .dxh-promises__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .dxh-work-stats div { min-width: 0; padding: 0.6rem 0.8rem; }
  .dxh-work-stats dd { font-size: 1.3rem; }
  .dxh-bento { grid-template-columns: 1fr; }
  .dxh-card { grid-column: auto; min-height: 15rem; padding: 1.5rem; }
  .dxh-steps { grid-template-columns: 1fr; row-gap: 1rem; padding-top: 0; padding-left: 3.2rem; }
  .dxh-steps__line { display: block; left: 1.15rem; right: auto; top: 0.5rem; bottom: 0.5rem; width: 2px; height: auto; }
  .dxh-steps__line i { width: 100%; height: 100%; transform-origin: top; transform: scaleY(0); }
  .dxh-step__dot { top: 1.4rem; left: -3.2rem; }
  .dxh-marquee { padding: 1.6rem 0; }
}
@media (max-width: 520px) {
  .dxh-promises__grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .dxh-grad { animation: none; }
  .js .dxh [data-reveal] { opacity: 1; translate: none; transition: none; }
  .dxh-steps__line i { transform: none; }
}
