/* Preserve the original visual language and the geometry of the depth scroll. */
:root { --case-ink: #f2f2f2; --case-muted: #bab6bd; --case-line: #403a43; }
.skip-link { position:fixed;top:-100px;left:20px;z-index:10000;background:#f2f2f2;color:#0a0a0a;padding:12px 20px; }
.skip-link:focus { top:12px; }
:focus-visible { outline:2px solid #fff385;outline-offset:5px; }
.services-intro h1 { font-size:clamp(32px,5.4vw,76px);font-weight:500;line-height:1.06;max-width:1000px;margin:0 0 32px;letter-spacing:-.025em; }
.services-intro .services-intro-text { margin-bottom:20px; }
.intro-secondary { max-width:72ch;line-height:1.6;color:var(--muted);font-size:clamp(18px,2vw,23px); }
.text-link { color:var(--ink);display:inline-block;text-underline-offset:6px;margin-top:16px;font-size:20px; }
.service-copy[hidden] { display:none; }
/* Text must determine its required space, including long German compounds. */
.services-left,.services-right,.service-content,.web3-left,.web3-text > *,
.capability-grid > *,.case-story { min-width:0; }
.services-intro p,.service-subtitle,.service-text,.modal-title,.modal-text,
.web3-text p,.capability-section,.case-story,.footer-link {
  overflow-wrap:anywhere;
  word-break:normal;
}
.service-text,.modal-text,.web3-text p,.capability-section p,.case-story p,.case-story li {
  -webkit-hyphens:auto;
  hyphens:auto;
}
.services-intro h1 { text-wrap:balance; }
.services-intro .intro-secondary { margin-left:auto;margin-right:auto; }
.services-grid { height:auto;max-height:none;min-height:85vh; }
.services-left,.service-content,.service-text { overflow:visible; }
.service-text { flex-shrink:0;line-height:1.6; }
.service-subtitle { line-height:1.2;text-wrap:balance; }
.web3-text { grid-template-columns:minmax(0, 1.2fr) minmax(0, 1fr);align-items:start; }
.web3-text p { margin:0;font-size:clamp(18px, 1.6vw, 22px);line-height:1.6; }
.web3-text .lead { font-size:clamp(22px, 2vw, 28px);line-height:1.3;text-wrap:balance; }
.web3-text p:not(.lead) { text-align:left; }
.case-story { text-align:left; }
.case-story .case-link { max-width:100%; }
@media(min-width:821px) {
  .services-grid { grid-template-columns:minmax(0, 3fr) minmax(0, 1fr); }
}
@media(max-width:900px) {
  .web3-text { grid-template-columns:minmax(0, 1fr);min-height:0; }
}
/* One supplied SVG, rotated into each corner. No CSS bracket geometry remains. */
.text-divider .mech-corner {
  --corner-turn:0deg;
  background:none;
  border:0;
  box-shadow:none;
  filter:none;
  transform:rotate(var(--corner-turn));
  transform-origin:center;
  isolation:isolate;
  will-change:auto;
}
.text-divider .mech-corner-tr { --corner-turn:90deg; }
.text-divider .mech-corner-br { --corner-turn:180deg; }
.text-divider .mech-corner-bl { --corner-turn:270deg; }
.text-divider .mech-corner::before,
.text-divider .mech-corner::after {
  content:"";
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  border:0;
  border-radius:0;
  clip-path:none;
  box-shadow:none;
  pointer-events:none;
}
.text-divider .mech-corner::before {
  z-index:1;
  background:url("metalcorner-surface.svg?v=matte-1") center / contain no-repeat;
  /* Only faint ambient light remains when all neon lines are off. */
  filter:brightness(.28) drop-shadow(-1px -1px 1px rgba(0,0,0,.65));
  animation:none;
}
.text-divider .mech-corner::after {
  content:none;
  animation:none;
}
.text-divider .corner-light {
  position:absolute;
  inset:0;
  pointer-events:none;
  opacity:0;
  z-index:2;
  /* A directional reflection, clipped to the supplied metal geometry. */
  /* Reveal the rusty material with the same opacity/flicker as its light source. */
  background:linear-gradient(to bottom,rgba(0,0,0,.94),transparent 23%),
    linear-gradient(to right,rgba(0,0,0,.94),transparent 23%),
    linear-gradient(135deg,transparent 0%,currentColor 160%),
    url("metalcorner-surface.svg?v=matte-1") center / contain no-repeat;
  -webkit-mask:url("metalcorner.svg") center / contain no-repeat;
  mask:url("metalcorner.svg") center / contain no-repeat;
  animation:neon-flicker 12s linear infinite;
  color:rgba(255,247,140,.65);
}
.text-divider .corner-light::after {
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(135deg,transparent 10%,currentColor 65%);
  -webkit-mask:url("metalcorner-rim.svg?v=inward-2") center / contain no-repeat;
  mask:url("metalcorner-rim.svg?v=inward-2") center / contain no-repeat;
}
.text-divider .corner-light--red {
  color:rgba(255,120,90,.65);
  animation-name:neon-flicker-red;
  animation-delay:4s;
}
.text-divider .corner-light--blue {
  color:rgba(154,200,255,.7);
  animation-name:neon-flicker-blue;
  animation-delay:8s;
}
/* In the unrotated top-left corner, light arrives from bottom-right.
   Rotating this local shadow vector makes every shadow fall away from the text. */
.text-divider .corner-shadow {
  position:absolute;
  inset:0;
  z-index:0;
  pointer-events:none;
  transform:translate(-7px,-7px);
  filter:blur(2.5px);
  opacity:0;
  animation:neon-flicker 12s linear infinite;
}
.text-divider .corner-shadow::before {
  content:"";
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.85);
  -webkit-mask:url("metalcorner.svg") center / contain no-repeat;
  mask:url("metalcorner.svg") center / contain no-repeat;
}
.text-divider .corner-shadow--red { animation-name:neon-flicker-red;animation-delay:4s; }
.text-divider .corner-shadow--blue { animation-name:neon-flicker-blue;animation-delay:8s; }
.text-divider.neon-paused .text-3d-line,
.text-divider.neon-paused .corner-light,
.text-divider.neon-paused .corner-shadow,
.text-divider.neon-paused .divider-metal-light,
.text-divider.neon-paused .mech-corner::before,
.text-divider.neon-paused .mech-corner::after { animation-play-state:paused; }
/* Scratches and dents are a light-facing height field, not a flat glowing plate. */
.divider-metal {
  position:absolute;inset:0;pointer-events:none;z-index:0;overflow:hidden;
  background:radial-gradient(ellipse at center,#111210 0%,rgba(12,12,11,.8) 52%,transparent 76%);
  -webkit-mask:radial-gradient(ellipse,black 38%,transparent 74%);
  mask:radial-gradient(ellipse,black 38%,transparent 74%);
}
.divider-metal-light {
  position:absolute;inset:0;opacity:0;
  background:radial-gradient(ellipse at center,rgba(255,247,140,.26),rgba(255,247,140,.09) 65%,transparent);
  -webkit-mask:url("metal-relief.svg?v=grooves-4") center / 100% 100% no-repeat;
  mask:url("metal-relief.svg?v=grooves-4") center / 100% 100% no-repeat;
  animation:neon-flicker 12s linear infinite;
}
.divider-metal-light--red { background:radial-gradient(ellipse,rgba(255,120,90,.26),rgba(255,120,90,.09) 65%,transparent);animation-name:neon-flicker-red;animation-delay:4s; }
.divider-metal-light--blue { background:radial-gradient(ellipse,rgba(154,200,255,.26),rgba(154,200,255,.09) 65%,transparent);animation-name:neon-flicker-blue;animation-delay:8s; }
@media(prefers-reduced-motion:reduce) {
  .divider-metal-light { opacity:0; }
  .divider-metal-light--gold { opacity:.3; }
}
.w3-slide::after {
  border-color:#fffde5;
  box-shadow:0 0 3px #fffde5,0 0 12px rgba(255,243,133,.62),0 0 34px rgba(255,243,133,.22),inset 0 0 3px rgba(255,253,229,.8),inset 0 0 18px rgba(255,243,133,.12);
}
@media(prefers-reduced-motion:reduce) {
  .text-divider .corner-light { animation:none;opacity:0; }
  .text-divider .corner-light--gold { opacity:.3; }
  .text-divider .corner-shadow { animation:none;opacity:0; }
  .text-divider .corner-shadow--gold { opacity:.3; }
  .text-divider { color:#fff385; }
  .text-divider .text-3d-line:first-child { opacity:1; }
  .text-divider .text-3d-line:nth-child(n+2) { opacity:0; }
}
/* Align navigation with the visible lab frame, not the full carousel width. */
.w3-carousel .w3-nav.prev { left:calc(50% - min(280px, 33%) + 8px); }
.w3-carousel .w3-nav.next { right:calc(50% - min(280px, 33%) + 8px); }
@media(max-width:900px) {
  .w3-carousel .w3-nav.prev { left:calc(7% + 4px); }
  .w3-carousel .w3-nav.next { right:calc(7% + 4px); }
}
.capability-section { max-width:1200px;margin:80px auto;padding:0 5vw;scroll-margin-top:90px; }
.capability-section h2 { font-size:clamp(36px,5vw,64px);line-height:1.08;font-weight:500;max-width:800px; }
.capability-lead { font-size:clamp(21px,2.4vw,28px);line-height:1.5;max-width:62ch; }
.capability-grid { display:grid;grid-template-columns:1fr 1fr;gap:24px 60px;margin:40px 0 20px; }
.capability-grid h3 { font-size:28px;font-weight:500;margin-bottom:12px; }
.capability-grid p { font-size:19px;line-height:1.65;color:var(--muted);max-width:65ch; }
.web3-tag { font-size:clamp(30px,5vw,72px); }
.web3-num { font-size:clamp(72px,12vw,170px); }
/* Desktop showcase fits within 80vh; overlay/depth geometry stays independent. */
@media (min-width:901px) {
  .work-section {
    height:80vh;
    --work-rail-h:min(12vh, 120px);
    display:grid;
    grid-template-rows:minmax(0, 1fr) auto minmax(0, 1fr);
  }
  .work-section .work-header { margin:2vh 0; }
  .work-section .work-grid {
    width:100%;
    height:100%;
    min-height:0;
    margin:0 auto;
  }
  .work-section .work-grid > .work-card { width:auto;height:100%;min-height:0; }
  .work-section .work-grid > .wc-amen,
  .work-section .work-grid > .wc-dayfox { height:75%; }
  .work-section .work-grid-top > .work-card { align-self:end; }
}
.work-more-link { background:none;border:0;font:inherit;cursor:pointer; }
/* A separate flower bed above the footer links, using the shared garden renderer. */
.site-footer:has(.footer-garden) { position:relative;padding-top:calc(clamp(190px, 23vw, 290px) + 24px); }
.footer-garden { position:absolute;top:0;left:0;width:100%;height:clamp(190px, 23vw, 290px);overflow:hidden;pointer-events:none; }
.footer-garden-canvas { display:block;width:100%;height:100%;pointer-events:none; }
.site-footer .footer-inner { position:relative;z-index:1; }
/* Curved CRT glass inside a quiet, near-black physical bezel. */
.work-section .work-card {
  box-sizing:border-box;
  background:#111210;
  border:7px solid #080908;
  border-radius:9% / 7%;
  box-shadow:0 0 0 1px #292925,0 9px 22px rgba(0,0,0,.48),inset 0 0 12px #000;
}
.work-section .wc-svg-container::before { content:none; }
.work-section .wc-svg-image { object-fit:contain;object-position:center;filter:invert(.82) sepia(.2); }
.work-section .wc-svg-container { align-items:center;padding:12%; }
.work-section .work-card::after {
  z-index:4;
  animation:none;
  background:radial-gradient(ellipse at 45% 40%,transparent 48%,rgba(0,0,0,.26) 100%);
  box-shadow:inset 0 0 0 1px rgba(218,221,203,.1),inset 0 -3px 8px rgba(0,0,0,.45);
  border-radius:inherit;
  opacity:1;
}
.wc-crt-canvas { position:absolute;inset:0;width:100%;height:100%;z-index:3;pointer-events:none;border-radius:inherit;opacity:0; }
.crt-ready .wc-crt-canvas { opacity:1; }
.crt-ready .wc-svg-container { opacity:0; }
.work-grid-bottom .wc-svg-image { object-position:bottom; }
.work-section .work-grid-bottom .wc-svg-container { align-items:flex-end;padding-bottom:0; }
@media(max-width:900px) { .work-section .work-card { border-width:5px;border-radius:7% / 14%; } }
/* Text styles only: perspective, panel heights, origins and transforms stay in the base CSS. */
.service-modal.fold-active .modal-text { color:var(--case-muted); }
.service-modal.fold-active .modal-title { font-size:clamp(38px,6vw,78px);font-weight:500;letter-spacing:-.035em;line-height:1.02; }
.case-story { max-width:100%; }
.case-story .case-subtitle { font-size:clamp(22px,3vw,32px);font-weight:400;line-height:1.25;color:var(--case-ink);margin:0 0 28px; }
.case-story .case-meta { padding:0 0 24px;margin:0 0 30px;border:0;border-bottom:1px solid var(--case-line);background:none; }
.case-meta p { margin:5px 0;font-size:16px; }
.case-story p,.case-story li { max-width:70ch;line-height:1.7; }
.case-story h5 { color:var(--case-ink);font-size:clamp(23px,3vw,32px);font-weight:500;letter-spacing:0;text-transform:none;margin:36px 0 14px; }
.case-story strong { color:var(--case-ink);font-weight:500; }
.case-story ul { padding-left:20px;list-style:disc; }
.case-story li { margin:12px 0;padding-left:0; }
.case-story li::before { content:none; }
.case-story .case-link { display:inline-block;background:none;border:0;border-bottom:1px solid var(--case-line);padding:12px 0;color:var(--case-ink);text-decoration:none; }
.case-story [class$="-media-grid"] { grid-template-columns:repeat(2,minmax(0,1fr));gap:24px; }
.case-story [class$="-media-grid"] img { border-radius:0;box-shadow:none;object-fit:contain; }
.case-story [class$="-media-grid"] img:first-child { grid-column:1/-1; }
.case-page { max-width:1060px;margin:120px auto 80px;padding:0 6vw; }
.case-page h1 { font-size:clamp(44px,8vw,90px);line-height:1.05; }
.case-page .case-story { font-size:20px;color:var(--case-muted); }
.case-page > a { color:var(--ink); }
@media(max-width:700px) {
  .capability-grid { grid-template-columns:1fr; }
  .capability-section { margin:60px auto; }
  .case-story [class$="-media-grid"] { grid-template-columns:1fr; }
  .case-story p,.case-story li { font-size:17px; }
}
@media(prefers-reduced-motion:reduce) {
  *,*::before,*::after { animation:none!important;scroll-behavior:auto!important; }
  .contact-links { transform:none!important; }
  .contact-links-wrapper { height:auto!important; }
  .contact-links .contact-link:nth-child(n+4) { display:none; }
}
