/* Shared styles for the 6 service detail pages */

.svc-hero {
  position: relative;
  padding: 90px 0 60px;
  border-bottom: 1px solid var(--ivory-3);
  overflow: hidden;
}
.svc-hero .inner {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 40px;
  align-items: end;
  position: relative;
  z-index: 2;
}
.svc-hero .num-eyebrow {
  display: flex; align-items: baseline; gap: 20px;
  margin-bottom: 12px;
}
.svc-hero .num-eyebrow .n {
  font-family: var(--mono);
  font-size: 56px;
  color: var(--slate);
  line-height: 1;
  letter-spacing: -0.02em;
  font-weight: 400;
}
.svc-hero .num-eyebrow .cat {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--slate);
}
.svc-hero h1 {
  font-family: var(--serif);
  font-size: clamp(56px, 8vw, 120px);
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin: 8px 0 0;
  text-wrap: balance;
}
.svc-hero h1 em { font-style: italic; color: var(--slate); }
.svc-hero h1 .accent {
  color: var(--ink);
  font-style: italic;
  position: relative;
  display: inline-block;
}
.svc-hero h1 .accent::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  bottom: 4px; height: 14px;
  background: var(--lime);
  z-index: -1;
  opacity: 0.85;
  border-radius: 2px;
}
.svc-hero .side { color: var(--slate); font-size: 15px; line-height: 1.6; }
.svc-hero .side p { margin: 0 0 16px; }
.svc-hero .stack {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink);
  letter-spacing: 0.06em;
  padding: 8px 0;
  border-top: 1px dashed var(--ivory-3);
  border-bottom: 1px dashed var(--ivory-3);
  margin: 20px 0 24px;
}

/* the big 3D artifact in the hero */
.svc-viz {
  position: absolute;
  right: -100px;
  top: 40px;
  width: 480px;
  height: 480px;
  z-index: 1;
  opacity: 0.9;
}

/* Deep dive section */
.deep-dive {
  padding: 100px 0;
  border-bottom: 1px solid var(--ivory-3);
}
.deep-dive .inner {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 80px;
  align-items: start;
}
.deep-dive .h2 { margin-bottom: 20px; }
.deep-dive .h2 em { color: var(--slate); font-style: italic; }
.deep-dive .side p { color: var(--slate); font-size: 15px; line-height: 1.6; max-width: 40ch; }

.checks {
  list-style: none; margin: 0; padding: 0;
  display: grid;
  gap: 0;
  border-top: 1px solid var(--ivory-3);
}
.checks li {
  padding: 24px 0;
  border-bottom: 1px solid var(--ivory-3);
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 20px;
  align-items: baseline;
}
.checks .ck {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--lime-ink);
}
.checks .txt {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-wrap: balance;
}

/* Approach steps */
.approach {
  background: var(--ink);
  color: var(--ivory);
  padding: 100px 0;
  background-image:
    linear-gradient(to right, oklch(0.97 0.005 90 / 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, oklch(0.97 0.005 90 / 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
}
.approach .head {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: end;
  margin-bottom: 60px;
}
.approach .h2 { color: var(--ivory); }
.approach .h2 em { color: var(--lime); font-style: italic; }
.approach .head .side { color: oklch(0.72 0.01 250); font-size: 15px; max-width: 40ch; }
.approach-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-top: 1px solid var(--ink-3);
  border-left: 1px solid var(--ink-3);
}
.approach-grid .cell {
  padding: 32px;
  border-right: 1px solid var(--ink-3);
  border-bottom: 1px solid var(--ink-3);
  min-height: 260px;
  display: flex; flex-direction: column;
  gap: 16px;
}
.approach-grid .n {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--lime);
  letter-spacing: 0.14em;
}
.approach-grid .t {
  font-family: var(--serif);
  font-size: 28px;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ivory);
  margin: 0;
}
.approach-grid .d {
  font-size: 14px;
  color: oklch(0.72 0.01 250);
  line-height: 1.55;
  margin: 0;
}

/* Pricing */
.pricing {
  padding: 100px 0;
  border-bottom: 1px solid var(--ivory-3);
}
.pricing .head {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: end;
  margin-bottom: 60px;
}
.pricing .head .side { color: var(--slate); font-size: 15px; max-width: 40ch; }
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  border-top: 1px solid var(--ivory-3);
  border-left: 1px solid var(--ivory-3);
}
.tier {
  padding: 32px 28px;
  border-right: 1px solid var(--ivory-3);
  border-bottom: 1px solid var(--ivory-3);
  display: flex; flex-direction: column; gap: 14px;
  background: var(--ivory);
  position: relative;
  min-height: 480px;
}
.tier.popular { background: var(--ink); color: var(--ivory); }
.tier.popular .price { color: var(--ivory); }
.tier.popular .tier-mono, .tier.popular .desc { color: oklch(0.72 0.01 250); }
.tier.popular .badge {
  position: absolute; top: 0; right: 0;
  padding: 4px 12px;
  background: var(--lime);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
}
.tier-mono {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--slate);
}
.tier-name {
  font-family: var(--serif);
  font-size: 32px;
  letter-spacing: -0.02em;
  line-height: 1;
  margin: 0;
  color: inherit;
}
.tier.popular .tier-name { color: var(--ivory); }
.price {
  font-family: var(--serif);
  font-size: 52px;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.price .u {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--slate);
  margin-left: 6px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.tier.popular .price .u { color: oklch(0.72 0.01 250); }
.desc {
  font-size: 13px;
  line-height: 1.5;
  color: var(--slate);
  margin: 0;
}
.tier ul { list-style: none; padding: 0; margin: 12px 0 0; }
.tier ul li {
  padding: 10px 0;
  font-size: 13px;
  color: var(--ink);
  border-top: 1px dashed var(--ivory-3);
  display: flex; align-items: baseline; gap: 8px;
}
.tier.popular ul li { color: var(--ivory); border-color: oklch(0.30 0.015 250); }
.tier ul li::before { content: "→"; color: var(--lime-ink); font-family: var(--mono); flex-shrink: 0; }
.tier.popular ul li::before { color: var(--lime); }

.tier-cta {
  margin-top: auto;
  padding-top: 20px;
  display: flex; align-items: center; gap: 8px;
  font-family: var(--display);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
}
.tier.popular .tier-cta { color: var(--lime); }
.tier-cta .arr {
  width: 28px; height: 28px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--ivory);
  display: grid; place-items: center;
  transition: background 200ms var(--ease);
}
.tier:hover .tier-cta .arr { background: var(--lime); color: var(--ink); }
.tier.popular .tier-cta .arr { background: var(--lime); color: var(--ink); }

/* CTA */
.svc-cta {
  padding: 120px 0;
  background: var(--ink);
  color: var(--ivory);
  background-image:
    linear-gradient(to right, oklch(0.97 0.005 90 / 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, oklch(0.97 0.005 90 / 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
}
.svc-cta .wrap { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; }
.svc-cta .display { color: var(--ivory); font-size: clamp(44px, 5.5vw, 76px); }
.svc-cta .display em { color: var(--lime); font-style: italic; }
.svc-cta .actions { display: flex; flex-direction: column; gap: 12px; align-items: flex-end; }
.svc-cta .actions .lede { color: oklch(0.72 0.01 250); text-align: right; }

/* Related services */
.related {
  padding: 80px 0;
  border-bottom: 1px solid var(--ivory-3);
}
.related h3 {
  font-family: var(--serif);
  font-size: 28px;
  letter-spacing: -0.01em;
  margin: 0 0 32px;
}
.related-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.related-grid a {
  padding: 20px;
  border: 1px solid var(--ivory-3);
  border-radius: 12px;
  background: var(--ivory);
  transition: border-color 200ms var(--ease), transform 200ms var(--ease);
  display: flex; flex-direction: column; gap: 8px;
}
.related-grid a:hover { border-color: var(--ink); transform: translateY(-2px); }
.related-grid a .n { font-family: var(--mono); font-size: 11px; color: var(--slate); letter-spacing: 0.1em; }
.related-grid a .t {
  font-family: var(--serif);
  font-size: 22px;
  letter-spacing: -0.01em;
  line-height: 1.05;
  color: var(--ink);
}

/* Big 3D visualization pods (unique to each service page) */
.viz-pod {
  aspect-ratio: 1;
  width: 100%;
  max-width: 480px;
  position: relative;
  display: grid;
  place-items: center;
}

/* WEB: exploded stack + parallax layers */
.viz-web {
  perspective: 1000px;
  perspective-origin: 50% 30%;
}
.viz-web .layer {
  position: absolute;
  width: 60%; height: 60%;
  border-radius: 12px;
  border: 1px solid var(--ink-3);
  background: var(--ivory);
  box-shadow: 0 20px 40px -20px oklch(0.14 0.02 250 / 0.15);
}
.viz-web .layer:nth-child(1) {
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(-80px);
  opacity: 0.4;
}
.viz-web .layer:nth-child(2) {
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(-20px);
  opacity: 0.7;
}
.viz-web .layer:nth-child(3) {
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(40px);
  border-color: var(--lime);
}
.viz-web .layer:nth-child(3)::after {
  content: "";
  position: absolute; inset: 12px;
  background:
    linear-gradient(to bottom, var(--lime) 3px, transparent 3px) 0 0/100% 18px,
    linear-gradient(to bottom, var(--ink-3) 1px, transparent 1px) 0 9px/100% 18px;
  opacity: 0.5;
  border-radius: 6px;
}
.viz-web .layer:nth-child(4) {
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(100px);
  width: 20%; height: 20%;
  background: var(--lime);
  border-color: var(--lime);
  box-shadow: 0 0 40px oklch(0.88 0.20 130 / 0.6);
}

/* MARKETING: animated bars + arrow */
.viz-marketing {
  padding: 40px;
}
.viz-marketing .bars {
  position: absolute;
  bottom: 20%;
  left: 20%;
  right: 20%;
  height: 60%;
  display: flex;
  align-items: flex-end;
  gap: 8px;
}
.viz-marketing .bar {
  flex: 1;
  background: oklch(0.88 0.20 130 / 0.7);
  border-radius: 6px 6px 0 0;
  animation: mk-bar 4s ease-in-out infinite;
}
.viz-marketing .bar:nth-child(1) { height: 30%; animation-delay: 0s; }
.viz-marketing .bar:nth-child(2) { height: 45%; animation-delay: 0.2s; }
.viz-marketing .bar:nth-child(3) { height: 55%; animation-delay: 0.4s; }
.viz-marketing .bar:nth-child(4) { height: 70%; animation-delay: 0.6s; background: var(--lime); box-shadow: 0 0 24px var(--lime); }
.viz-marketing .bar:nth-child(5) { height: 85%; animation-delay: 0.8s; background: var(--lime); box-shadow: 0 0 30px var(--lime); }
.viz-marketing .bar:nth-child(6) { height: 100%; animation-delay: 1.0s; background: var(--lime); box-shadow: 0 0 40px var(--lime); }
@keyframes mk-bar { 0%, 100% { transform: scaleY(1); } 50% { transform: scaleY(0.9); } }
.viz-marketing .arrow {
  position: absolute;
  top: 20%; left: 15%; right: 15%;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--ink), var(--ink));
  transform-origin: left center;
  transform: rotate(-25deg);
}
.viz-marketing .arrow::after {
  content: "";
  position: absolute; right: -1px; top: -6px;
  border-left: 12px solid var(--ink);
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
}

/* SECURITY: layered hexagons */
.viz-security {
  perspective: 900px;
  perspective-origin: center;
}
.viz-security .hex {
  position: absolute;
  width: 200px; height: 220px;
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  border: 2px solid oklch(0.88 0.20 130 / 0.6);
  background:
    repeating-linear-gradient(45deg, transparent 0 10px, oklch(0.88 0.20 130 / 0.12) 10px 11px),
    repeating-linear-gradient(-45deg, transparent 0 10px, oklch(0.88 0.20 130 / 0.12) 10px 11px);
  animation: sec-spin 20s linear infinite;
}
.viz-security .hex:nth-child(1) { transform: rotateX(60deg) translateZ(-40px); opacity: 0.4; }
.viz-security .hex:nth-child(2) { transform: rotateX(60deg) translateZ(20px); }
.viz-security .hex:nth-child(3) {
  width: 80px; height: 90px;
  background: var(--lime);
  border-color: var(--lime);
  box-shadow: 0 0 40px oklch(0.88 0.20 130 / 0.8);
}
@keyframes sec-spin { to { transform: rotateX(60deg) rotateZ(360deg); } }

/* CLOUD: floating volumes */
.viz-cloud { perspective: 900px; perspective-origin: 50% 30%; }
.viz-cloud .vol {
  position: absolute;
  border-radius: 20px;
  border: 1px solid var(--ink-3);
  background: oklch(0.97 0.005 90 / 0.85);
  backdrop-filter: blur(4px);
  animation: cloud-drift 8s ease-in-out infinite;
  box-shadow: 0 20px 40px -20px oklch(0.14 0.02 250 / 0.2);
}
.viz-cloud .vol:nth-child(1) {
  width: 45%; height: 30%; top: 20%; left: 15%;
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(-40px);
  animation-delay: 0s;
}
.viz-cloud .vol:nth-child(2) {
  width: 40%; height: 40%; top: 35%; left: 45%;
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(20px);
  border-color: var(--lime);
  animation-delay: 0.5s;
}
.viz-cloud .vol:nth-child(3) {
  width: 35%; height: 25%; top: 55%; left: 25%;
  transform: rotateX(55deg) rotateZ(-30deg) translateZ(60px);
  animation-delay: 1s;
}
@keyframes cloud-drift {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -8px; }
}
.viz-cloud .link {
  position: absolute;
  height: 1px;
  background: repeating-linear-gradient(to right, var(--lime) 0 3px, transparent 3px 6px);
  transform-origin: left center;
  z-index: 2;
}
.viz-cloud .link.l1 { top: 45%; left: 35%; width: 30%; transform: rotate(15deg); }
.viz-cloud .link.l2 { top: 60%; left: 40%; width: 25%; transform: rotate(-20deg); }

/* MOBILE: floating phone */
.viz-mobile { perspective: 900px; perspective-origin: 50% 30%; }
.viz-mobile .device {
  width: 200px; height: 400px;
  border: 2px solid var(--ink);
  border-radius: 32px;
  padding: 12px;
  background: var(--ivory);
  transform: rotateX(15deg) rotateY(-25deg);
  box-shadow: 40px 40px 80px -30px oklch(0.14 0.02 250 / 0.3);
  animation: phone-tilt 6s ease-in-out infinite;
  position: relative;
}
@keyframes phone-tilt {
  0%, 100% { transform: rotateX(15deg) rotateY(-25deg); }
  50%      { transform: rotateX(12deg) rotateY(-22deg); }
}
.viz-mobile .device::before {
  content: "";
  display: block;
  width: 60px; height: 6px;
  margin: 6px auto 12px;
  background: var(--ink-3);
  border-radius: 3px;
}
.viz-mobile .device .screen {
  height: calc(100% - 30px);
  background: var(--ink);
  border-radius: 20px;
  position: relative;
  overflow: hidden;
}
.viz-mobile .device .screen::before {
  content: "";
  position: absolute;
  top: 20%; left: 15%; right: 15%; height: 30%;
  background: var(--lime);
  border-radius: 8px;
  box-shadow: 0 0 40px oklch(0.88 0.20 130 / 0.7);
}
.viz-mobile .device .screen::after {
  content: "";
  position: absolute;
  bottom: 15%; left: 15%; right: 15%; height: 3px;
  background:
    repeating-linear-gradient(to bottom, oklch(0.35 0.015 250) 0 3px, transparent 3px 9px);
  height: 40%;
}

/* AI: pulsing neural network */
.viz-ai svg { width: 100%; height: 100%; overflow: visible; }
.viz-ai .node {
  fill: var(--ivory);
  stroke: var(--ink-3);
  stroke-width: 1.5;
}
.viz-ai .node.on {
  fill: var(--lime);
  stroke: var(--lime);
  filter: drop-shadow(0 0 8px var(--lime));
  animation: node-pulse 2.5s ease-in-out infinite;
}
@keyframes node-pulse {
  0%, 100% { r: 8; opacity: 1; }
  50%      { r: 10; opacity: 0.7; }
}
.viz-ai .edge { stroke: var(--ink-3); stroke-width: 1; fill: none; }
.viz-ai .edge.on {
  stroke: var(--lime);
  stroke-width: 1.4;
  stroke-dasharray: 4 3;
  animation: edge-flow 1s linear infinite;
}
@keyframes edge-flow { to { stroke-dashoffset: -14; } }

@media (max-width: 900px) {
  .svc-hero .inner, .deep-dive .inner, .approach .head,
  .pricing .head, .svc-cta .wrap { grid-template-columns: 1fr; }
  .approach-grid, .pricing-grid { grid-template-columns: 1fr; }
  .svc-viz { display: none; }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .svc-cta .actions { align-items: flex-start; }
  .svc-cta .actions .lede { text-align: left; }
}
