:root {
      --text-primary: #222;
      --text-secondary: #555;
      --text-muted: #777;
      --border-color: #e8eaee;
      --light-bg: #f5f5f5;
      --section-bg: #fafafa;
      --link-color: #3273dc;
    }

    html {
      scroll-behavior: smooth;
    }

    body {
      font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
      color: var(--text-primary);
      line-height: 1.6;
      background: #fff;
      -webkit-font-smoothing: antialiased;
      -moz-osx-font-smoothing: grayscale;
    }

    img,
    video {
      display: block;
      max-width: 100%;
    }

    .project-hero {
      background: #fff;
    }

    .hero-body {
      padding: 3rem 1.5rem 2rem;
    }

    .hero-copy {
      max-width: 1120px;
      margin: 0 auto;
    }

    .eyebrow,
    .section-kicker {
      display: none;
    }

    .project-title,
    .publication-title {
      font-weight: 700 !important;
      line-height: 1.15 !important;
      color: var(--text-primary) !important;
      margin-bottom: 1rem !important;
    }

    .project-title {
      font-size: clamp(1.9rem, 3vw, 2.9rem);
    }

    .project-subtitle {
      color: var(--text-secondary);
      font-size: 1.05rem;
      max-width: 760px;
      margin: 0 auto;
    }

    .hero-actions {
      margin-top: 1.5rem;
      display: flex;
      flex-wrap: wrap;
      gap: 0.75rem;
      justify-content: center;
    }

    .button {
      border-radius: 10px !important;
      font-weight: 600 !important;
      box-shadow: none !important;
      transition: none !important;
    }

    .button.is-dark {
      background: #363636 !important;
    }

    .hero-secondary {
      background: #fff !important;
      border: 1px solid var(--border-color) !important;
      color: var(--text-primary) !important;
    }

    .section-tight {
      padding: 3rem 1.5rem 0;
    }

    .section-tight + .section-tight {
      margin-top: 2.25rem;
      padding-top: 3rem;
      border-top: 1px solid #e8e8e8;
    }

    .abstract-section,
    .results-section {
      background: var(--section-bg);
    }

    .abstract-section .container,
    .project-footer .container {
      max-width: 1120px;
    }

    .section-heading {
      margin-bottom: 2rem;
    }

    .section-heading .title {
      margin-bottom: 0.5rem !important;
    }

    .section-description {
      color: var(--text-secondary);
      max-width: 760px;
      margin: 0 auto;
    }

    .abstract-copy {
      color: var(--text-primary);
      font-size: 1rem;
    }

    .figure-panel {
      margin: 0 auto;
    }

    .figure-panel img {
      width: 100%;
      border: 0;
    }

    .pipeline-section {
      padding-top: 1.5rem;
    }

    .pipeline-image {
      width: 100%;
      border: 0 !important;
    }

    .pipeline-caption {
      margin: 1.2rem auto 0;
      max-width: 980px;
      color: var(--text-secondary);
      font-size: 1rem;
      line-height: 1.65;
      text-align: center;
    }

    .video-presentation-section {
      background: #fff;
    }

    .video-presentation-player {
      width: 100%;
      height: auto;
      aspect-ratio: 16 / 9;
      object-fit: contain;
      background: #000;
      transform: translateZ(0);
      backface-visibility: hidden;
      contain: paint;
    }

    .demonstrations-overview-section {
      background: #fff;
    }

    .demonstrations-overview-grid {
      display: grid;
      grid-template-columns: repeat(5, minmax(0, 1fr));
      gap: 1rem;
      align-items: start;
    }

    .demonstration-card {
      border: 1px solid var(--border-color);
      border-radius: 12px;
      background: #fff;
      padding: 0.85rem;
      box-shadow: 0 16px 36px rgba(148, 163, 184, 0.24);
    }

    .demonstration-instruction {
      margin: 0 0 0.7rem;
      color: var(--text-primary);
      font-size: 0.94rem;
      width: 100%;
      min-height: 4.4em;
    }

    .demonstration-video {
      width: 100%;
      height: auto;
      aspect-ratio: 2 / 3;
      object-fit: contain;
      border: 0;
      border-radius: 0;
      background: #000;
      transform: translateZ(0);
      backface-visibility: hidden;
      contain: paint;
    }

    .demonstrations-more-link {
      margin-top: 1.15rem;
    }

    .demo-section {
      background: #fff;
    }

    .demo-layout {
      display: grid;
      gap: 1.25rem;
      width: 100%;
    }

    .demo-featured-stack {
      display: grid;
      gap: 1.25rem;
      width: 100%;
    }

    .demo-row {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 1.25rem;
      align-items: start;
    }

    .carousel-viewport {
      overflow: hidden;
    }

    .carousel-anim-target {
      will-change: transform;
      transform-origin: center center;
    }

    .carousel-anim-target.is-leaving-next {
      animation: carouselSlideOutNext 220ms cubic-bezier(0.35, 0, 0.2, 1) both;
    }

    .carousel-anim-target.is-entering-next {
      animation: carouselSlideInNext 260ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
    }

    .carousel-anim-target.is-leaving-prev {
      animation: carouselSlideOutPrev 220ms cubic-bezier(0.35, 0, 0.2, 1) both;
    }

    .carousel-anim-target.is-entering-prev {
      animation: carouselSlideInPrev 260ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
    }

    @keyframes carouselSlideOutNext {
      from { transform: translateX(0); }
      to { transform: translateX(-52px); }
    }

    @keyframes carouselSlideInNext {
      from { transform: translateX(52px); }
      to { transform: translateX(0); }
    }

    @keyframes carouselSlideOutPrev {
      from { transform: translateX(0); }
      to { transform: translateX(52px); }
    }

    @keyframes carouselSlideInPrev {
      from { transform: translateX(-52px); }
      to { transform: translateX(0); }
    }

    .generated-domain-section {
      background: var(--section-bg);
      padding-bottom: 0.75rem;
    }

    .domain-group-stack {
      display: grid;
      gap: 1.5rem;
    }

    .domain-group-card {
      border: 1px solid var(--border-color);
      border-radius: 12px;
      background: #fff;
      padding: 1rem;
      box-shadow: 0 16px 36px rgba(148, 163, 184, 0.24);
    }

    .domain-group-title {
      margin: 0 0 1rem;
      color: var(--text-primary);
      font-size: 1.28rem;
      font-weight: 700;
      text-transform: capitalize;
      letter-spacing: -0.01em;
      text-align: center;
    }

    .domain-single-figure,
    .domain-carousel-stage {
      border: 0;
      border-radius: 0;
      background: transparent;
      padding: 0;
    }

    .domain-carousel {
      display: grid;
      gap: 0.9rem;
      width: 100%;
    }

    .domain-single-image,
    .domain-carousel-image {
      height: auto;
      border: 0;
      border-radius: 0;
      background: #fff;
      cursor: zoom-in;
    }

    .domain-single-image {
      width: 80%;
      margin: 0 auto;
    }

    .domain-code-link {
      display: flex;
      align-items: center;
      justify-content: center;
      width: fit-content;
      margin: 0.9rem auto 0;
      padding: 0.7rem 1rem;
      border: 1px solid var(--border-color);
      border-radius: 999px;
      background: #fff;
      color: var(--text-primary);
      font-size: 0.95rem;
      font-weight: 600;
      text-align: center;
      text-decoration: none;
      transition: background-color 0.15s ease, transform 0.15s ease;
    }

    .domain-code-link:hover {
      background: #f3f4f6;
      transform: translateY(-1px);
      color: var(--text-primary);
    }

    .domain-code-link:focus-visible {
      outline: 2px solid #94a3b8;
      outline-offset: 2px;
    }

    .domain-carousel-shell {
      display: grid;
      grid-template-columns: auto minmax(0, 1fr) auto;
      gap: 0.85rem;
      align-items: center;
    }

    .domain-carousel-stage {
      display: flex;
      align-items: center;
      justify-content: center;
      margin: 0;
      width: 100%;
      aspect-ratio: var(--stage-aspect-ratio, auto);
      min-height: 180px;
    }

    .domain-carousel-image {
      width: 100%;
      object-fit: contain;
      object-position: center;
      max-height: 100%;
      margin: 0 auto;
    }

    .domain-carousel-button {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 3.4rem;
      height: 3.4rem;
      border: 1px solid var(--border-color);
      border-radius: 999px;
      background: #fff;
      color: var(--text-primary);
      font-size: 1.7rem;
      font-weight: 700;
      cursor: pointer;
      transition: background-color 0.15s ease, transform 0.15s ease;
    }

    .domain-carousel-button:hover {
      background: #f3f4f6;
      transform: translateY(-1px);
    }

    .domain-carousel-button:focus-visible {
      outline: 2px solid #94a3b8;
      outline-offset: 2px;
    }

    .domain-carousel-indicator {
      margin-top: 0.65rem;
      text-align: center;
      color: var(--text-muted);
      font-size: 0.9rem;
    }

    .image-lightbox {
      position: fixed;
      inset: 0;
      display: none;
      align-items: center;
      justify-content: center;
      padding: 2rem;
      background: rgba(17, 24, 39, 0.82);
      z-index: 1000;
    }

    .image-lightbox.is-open {
      display: flex;
    }

    .image-lightbox-dialog {
      position: relative;
      max-width: min(92vw, 1600px);
      max-height: 92vh;
      width: fit-content;
    }

    .image-lightbox-image {
      display: block;
      max-width: 100%;
      max-height: 92vh;
      width: auto;
      height: auto;
      border-radius: 12px;
      background: #fff;
      box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
    }

    .image-lightbox-close {
      position: absolute;
      top: -0.9rem;
      right: -0.9rem;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 2.4rem;
      height: 2.4rem;
      border: 0;
      border-radius: 999px;
      background: #fff;
      color: var(--text-primary);
      font-size: 1.5rem;
      line-height: 1;
      cursor: pointer;
      box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    }

    .demo-card {
      width: 100%;
      border: 1px solid var(--border-color);
      padding: 0.9rem;
      background: #fff;
      border-radius: 8px;
      box-shadow: 0 16px 36px rgba(148, 163, 184, 0.24);
    }

    .demo-card-featured {
      max-width: 100%;
    }

    .demo-card-grid {
      max-width: 100%;
    }

    .demo-video {
      width: 100%;
      height: auto;
      object-fit: contain;
      background: #000;
      border: 0;
      border-radius: 0;
      transform: translateZ(0);
      backface-visibility: hidden;
      contain: paint;
    }

    .demo-instruction {
      margin-top: 0.8rem;
      color: var(--text-secondary);
      font-size: 0.97rem;
    }

    .demo-instruction-top {
      margin-top: 0;
      margin-bottom: 0.75rem;
      color: var(--text-primary);
      font-size: 1.12rem;
    }

    .demo-instruction-top.is-centered {
      text-align: center;
    }

    .demo-card-featured .demo-instruction-top {
      min-height: 2.4em;
    }

    .demo-card-grid .demo-instruction-top {
      min-height: 4.8em;
    }

    .results-section {
      padding-bottom: 2.75rem;
    }

    .project-footer {
      background: #fff;
      padding: 2rem 1.5rem 2.5rem;
      border-top: 1px solid var(--border-color);
    }

    .project-footer a,
    a {
      color: var(--link-color);
    }

@media screen and (max-width: 900px) {
  .domain-carousel-shell {
    grid-template-columns: 1fr;
  }

  .domain-carousel-button {
    justify-self: center;
  }

  .demo-row {
    grid-template-columns: 1fr;
  }

  .image-lightbox {
    padding: 1rem;
  }

      .image-lightbox-close {
        top: 0.5rem;
        right: 0.5rem;
      }

  .demo-instruction-top {
    min-height: 0;
  }
}

    @media screen and (max-width: 768px) {
      .hero-body {
        padding: 2.25rem 1rem 1.5rem;
      }

      .section-tight {
        padding: 2.5rem 1rem 0;
      }

      .section-tight + .section-tight {
        margin-top: 1.75rem;
        padding-top: 2.5rem;
      }
    }

    .is-disabled {
      opacity: 0.7;
      cursor: default;
      pointer-events: none;
    }
