/* IZZI ID — The Sovereign Engineering Workshop Core Stylesheet */

/* Shared demo shell and dialog: these classes are used by all demo pages. */
:root { --font-head: "Chakra Petch", sans-serif; --font-body: "Space Grotesk", sans-serif; --font-mono: monospace; }
.release-note, .contact-unavailable { display: block; line-height: 1.6; color: var(--paper); margin: 12px 0; }
.release-note { border-left: 3px solid var(--brass); padding: 12px; background: var(--panel); }
.eng-nav { border-bottom: 2px solid var(--brass); padding: 18px 5vw; }
.eng-nav-inner, .eng-nav-links { display: flex; align-items: center; flex-wrap: wrap; gap: 16px; }
.eng-nav-inner { justify-content: space-between; }
.brass-brand { display: flex; gap: 12px; color: var(--brass-hi); text-decoration: none; }
.brand-titles span { display: block; }
.brand-title-sub { font-size: 11px; }
.eng-nav-item { color: var(--paper); font-size: 12px; padding: 8px; }
.eng-nav-item.active { color: var(--brass-hi); }
.modal-overlay { display: none; position: fixed; inset: 0; z-index: 100; background: #000b; padding: 16px; overflow-y: auto; }
.modal-overlay.active { display: grid; place-items: center; }
.modal-container { width: min(100%, 560px); max-height: calc(100dvh - 32px); overflow-y: auto; }
.menu-toggle { display: none !important; }
button:disabled { cursor: not-allowed; opacity: .65; }
:focus-visible { outline: 3px solid var(--brass-hi); outline-offset: 4px; }
.eng-panel, .spec-item, .terminal-screen { min-width: 0; overflow-wrap: anywhere; }
canvas { max-width: 100%; height: auto; }
@media (max-width: 900px) {
  .menu-toggle { display: inline-flex !important; }
  .eng-nav-links, .topbar nav { display: none !important; }
  .eng-nav-links.menu-open, .topbar nav.menu-open { display: flex !important; flex-wrap: wrap; width: 100%; }
  .topbar { height: auto !important; min-height: 76px; flex-wrap: wrap; gap: 12px; padding-top: 12px !important; padding-bottom: 12px !important; }
}
@media (max-width: 600px) {
  .spec-grid { grid-template-columns: minmax(0, 1fr) !important; }
  .eng-panel { padding: 16px !important; }
  .terminal-header { flex-wrap: wrap; gap: 8px; overflow-wrap: anywhere; }
  .eng-table { font-size: 11px !important; }
  .eng-table th, .eng-table td { padding: 6px !important; overflow-wrap: anywhere; }
  h1 { overflow-wrap: anywhere; }
}

:root {
        --stone: #272624;
        --stone-2: #353330;
        --panel: #1e2d31;
        --panel-2: #243b40;
        --brass: #d99a3d;
        --brass-hi: #f3c56c;
        --copper: #b96847;
        --green: #84b94a;
        --paper: #d8d0b8;
        --muted: #9b9b8d;
        --line: rgba(243, 197, 108, 0.3);
      }
      * {
        box-sizing: border-box;
      }
      html,
      body {
        overflow-x: hidden;
      }
      body {
        margin: 0;
        min-height: 100vh;
        color: var(--paper);
        background:
          radial-gradient(circle at 72% 20%, #3c3324 0, transparent 34%),
          linear-gradient(135deg, #1c1b19, #37332d 55%, #181817);
        font-family: "Space Grotesk", sans-serif;
      }
      body:before {
        content: "";
        position: fixed;
        inset: 0;
        opacity: 0.12;
        pointer-events: none;
        background-image:
          linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
          linear-gradient(90deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px);
        background-size: 32px 32px;
        mask-image: linear-gradient(90deg, #000, transparent 80%);
      }
      .topbar {
        height: 76px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0 5vw;
        border-bottom: 2px solid #151515;
        background: rgba(25, 24, 22, 0.88);
        box-shadow: 0 4px 0 rgba(0, 0, 0, 0.2);
        position: relative;
        z-index: 2;
      }
      .brand {
        display: flex;
        align-items: center;
        gap: 12px;
      }
      .badge {
        width: 42px;
        height: 42px;
        display: grid;
        place-items: center;
        color: #151515;
        background: linear-gradient(145deg, var(--brass-hi), var(--brass));
        border: 3px solid #624a29;
        box-shadow:
          inset 0 0 0 2px #f0b958,
          3px 3px 0 #121212;
        font: bold 18px "Chakra Petch";
      }
      .brand strong {
        display: block;
        color: var(--brass-hi);
        font: 700 21px "Chakra Petch";
        letter-spacing: 0.08em;
      }
      .brand small {
        color: var(--muted);
        font-size: 10px;
        letter-spacing: 0.18em;
      }
      nav {
        display: flex;
        gap: 4px;
        padding: 5px;
        border: 1px solid #4a4841;
        background: #292824;
      }
      nav a {
        padding: 9px 16px;
        color: var(--muted);
        text-decoration: none;
        font: 600 12px "Chakra Petch";
        letter-spacing: 0.08em;
        text-transform: uppercase;
      }
      nav a.active,
      nav a:hover {
        color: #151515;
        background: var(--brass);
      }
      main {
        max-width: 1380px;
        margin: auto;
        padding: 55px 5vw 70px;
      }
      .hero {
        display: grid;
        grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.35fr);
        gap: 40px;
        align-items: center;
        min-height: 330px;
      }
      .eyebrow {
        color: var(--green);
        font: 600 12px "Chakra Petch";
        letter-spacing: 0.16em;
        text-transform: uppercase;
      }
      h1 {
        max-width: 660px;
        margin: 12px 0 17px;
        color: #eee6cf;
        font: 700 clamp(42px, 6vw, 78px)/0.95 "Chakra Petch";
        letter-spacing: 0.02em;
        text-transform: uppercase;
        text-shadow: 5px 5px 0 #151515;
      }
      h1 em {
        color: var(--brass-hi);
        font-style: normal;
      }
      .intro {
        max-width: 500px;
        color: #bbb8a9;
        font-size: 16px;
        line-height: 1.65;
      }
      .stamp {
        display: inline-flex;
        gap: 10px;
        align-items: center;
        margin-top: 18px;
        color: #151515;
        background: var(--brass);
        padding: 10px 14px;
        border: 2px solid #6e512b;
        box-shadow: 3px 3px 0 #111;
        font: 700 12px "Chakra Petch";
        letter-spacing: 0.08em;
      }
      .schematic {
        position: relative;
        min-height: 300px;
        border: 2px solid #6e6a5a;
        background-image:
          linear-gradient(
            135deg,
            rgba(18, 37, 42, 0.38),
            rgba(18, 37, 42, 0.72)
          ),
          url("../assets/backgrounds/workshop_blueprint_bg.webp");
        background-position: center;
        background-size: cover;
        box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.25);
        overflow: hidden;
      }
      .schematic:before {
        content: "SCHEMATIC // 001";
        position: absolute;
        top: 14px;
        left: 18px;
        color: rgba(235, 229, 205, 0.55);
        font: 11px "Chakra Petch";
        letter-spacing: 0.14em;
      }
      .schematic:after {
        content: "";
        position: absolute;
        inset: 45px 18px 18px;
        border: 1px dashed rgba(220, 210, 175, 0.35);
        background-image:
          linear-gradient(rgba(190, 210, 200, 0.11) 1px, transparent 1px),
          linear-gradient(90deg, rgba(190, 210, 200, 0.11) 1px, transparent 1px);
        background-size: 28px 28px;
      }
      .gear {
        position: absolute;
        z-index: 1;
        width: 172px;
        height: 172px;
        right: 28px;
        top: 70px;
        background: url("../assets/create-mod/gears/gear_large_brass.webp")
          center/contain no-repeat;
        animation: spin 26s linear infinite;
        filter: drop-shadow(0 8px 10px rgba(0, 0, 0, 0.45));
      }
      .gear:before {
        display: none;
      }
      .gear:after {
        display: none;
      }
      .gear.medium {
        width: 120px;
        height: 120px;
        right: 175px;
        top: 104px;
        background-image: url("../assets/create-mod/gears/gear_medium_brass.webp");
        animation-duration: 18s;
        animation-direction: reverse;
      }
      .gear.small {
        width: 84px;
        height: 84px;
        right: 272px;
        top: 138px;
        background-image: url("../assets/create-mod/gears/gear_small_copper.webp");
        animation-duration: 11s;
      }
      .axle {
        position: absolute;
        z-index: 0;
        width: 360px;
        height: 68px;
        left: 110px;
        top: 138px;
        background: url("../assets/create-mod/gears/axle_brass.webp")
          center/contain no-repeat;
        opacity: 0.7;
        filter: drop-shadow(0 5px 8px rgba(0, 0, 0, 0.42));
      }
      .bearing {
        position: absolute;
        z-index: 2;
        width: 48px;
        height: 48px;
        right: 88px;
        top: 132px;
        background: url("../assets/create-mod/gears/bearing_steel.webp")
          center/contain no-repeat;
        filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.5));
      }
      .steam {
        position: absolute;
        z-index: 2;
        width: 86px;
        height: 86px;
        background: url("../assets/create-mod/particles/steam_puff_01.webp")
          center/contain no-repeat;
        filter: blur(0.4px);
        animation: steam-rise 4.5s ease-out infinite;
      }
      .steam.one {
        left: 115px;
        bottom: 32px;
      }
      .steam.two {
        left: 165px;
        bottom: 36px;
        animation-delay: 1.7s;
        transform: scale(0.7);
        background-image: url("../assets/create-mod/particles/steam_puff_02.webp");
      }
      .spark {
        position: absolute;
        z-index: 3;
        width: 34px;
        height: 34px;
        background: url("../assets/create-mod/particles/spark_burst.webp")
          center/contain no-repeat;
        filter: drop-shadow(0 0 7px rgba(243, 197, 108, 0.65));
        transform: rotate(45deg);
        opacity: 0;
      }
      .schematic.is-active .spark {
        animation: spark-pop 650ms ease-out both;
      }
      .spark.one {
        left: 51.5%;
        top: 52%;
      }
      .spark.two {
        left: 56%;
        top: 48%;
        animation-delay: 140ms;
      }
      .spark.three {
        left: 47%;
        top: 58%;
        animation-delay: 260ms;
      }
      .pipe-body {
        position: absolute;
        z-index: 2;
        left: 24px;
        top: 130px;
        width: 104px;
        height: 104px;
        background: url("../assets/create-mod/ui/pipe_t.webp") center/contain no-repeat;
        filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.55));
        pointer-events: none;
      }
      .gauge {
        position: absolute;
        z-index: 3;
        left: 47px;
        top: 91px;
        width: 64px;
        height: 64px;
        background: url("../assets/create-mod/ui/pressure_gauge.webp") center/contain
          no-repeat;
        filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.45));
        transition: filter 280ms ease, transform 280ms ease;
        pointer-events: none;
      }
      .schematic.is-active .gauge {
        filter: drop-shadow(0 0 12px rgba(243, 197, 108, 0.55))
          drop-shadow(0 4px 8px rgba(0, 0, 0, 0.45));
        transform: scale(1.03);
      }
      .pipe {
        position: absolute;
        z-index: 4;
        left: 44px;
        top: 150px;
        width: 64px;
        height: 64px;
        background: url("../assets/create-mod/ui/valve_wheel.webp") center/contain
          no-repeat;
        border: none;
        background-color: transparent;
        padding: 0;
        filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.45));
        transform: rotate(-8deg);
        transition: transform 380ms cubic-bezier(0.34, 1.56, 0.64, 1), filter 280ms ease;
        cursor: pointer;
      }
      .schematic.is-active .pipe,
      .pipe:hover,
      .pipe[aria-pressed="true"] {
        transform: rotate(52deg);
        filter: drop-shadow(0 0 12px rgba(243, 197, 108, 0.65))
          drop-shadow(0 6px 8px rgba(0, 0, 0, 0.45));
      }
      .pipe:focus-visible {
        outline: 2px solid var(--brass-hi);
        outline-offset: 4px;
        border-radius: 50%;
      }
      .schematic.is-active .gear {
        animation-duration: 14s;
      }
      .schematic.is-active .gear.medium {
        animation-duration: 10s;
      }
      .schematic.is-active .gear.small {
        animation-duration: 6s;
      }
      .readout {
        position: absolute;
        z-index: 1;
        right: 18px;
        bottom: 14px;
        color: var(--green);
        font: 11px "Chakra Petch";
        letter-spacing: 0.1em;
        transition: color 250ms ease;
      }
      .schematic.is-active .readout {
        color: var(--brass-hi);
      }
      .section-head {
        display: flex;
        justify-content: space-between;
        align-items: end;
        margin: 52px 0 18px;
        border-bottom: 2px solid #696354;
        padding-bottom: 12px;
      }
      .section-head h2 {
        margin: 0;
        font: 700 25px "Chakra Petch";
        letter-spacing: 0.08em;
        text-transform: uppercase;
      }
      .section-head span {
        color: var(--muted);
        font: 11px "Chakra Petch";
        letter-spacing: 0.12em;
      }
      .filters {
        display: flex;
        flex-wrap: wrap;
        gap: 7px;
        margin: 0 0 16px;
      }
      .filter-group {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 7px;
        margin-bottom: 8px;
      }
      .filter-group-label {
        color: var(--muted);
        font: 700 10px "Chakra Petch";
        letter-spacing: 0.1em;
        margin-right: 4px;
      }
      .filter {
        border: 1px solid #5b584f;
        background: #292824;
        color: var(--muted);
        padding: 7px 11px;
        cursor: pointer;
        font: 700 10px "Chakra Petch";
        letter-spacing: 0.1em;
      }
      .filter:hover,
      .filter.active {
        color: #161616;
        background: var(--brass);
        border-color: var(--brass-hi);
      }
      .projects {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 16px;
      }
      .project {
        min-width: 0;
        position: relative;
        border: 2px solid #5b584f;
        background: linear-gradient(180deg, #303a3a, #202525);
        box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.25);
        transition:
          transform 0.2s,
          border-color 0.2s;
      }
      .project:hover {
        transform: translateY(-5px);
        border-color: var(--brass);
      }
      .project::after {
        content: "BLUEPRINT // INSPECT MODULE";
        position: absolute;
        inset: 10px;
        display: grid;
        place-items: center;
        border: 1px dashed rgba(216, 208, 184, 0.45);
        color: var(--brass-hi);
        background: rgba(23, 48, 52, 0.72);
        font: 700 10px "Chakra Petch";
        letter-spacing: 0.12em;
        opacity: 0;
        pointer-events: none;
        transition: opacity 180ms ease;
        z-index: 4;
      }
      .project:hover::after,
      .project:focus-within::after {
        opacity: 1;
      }
      .project[hidden] {
        display: none;
      }
      .thumb {
        height: 150px;
        position: relative;
        overflow: hidden;
        border-bottom: 2px solid #5b584f;
        background: #121a1b;
      }
      .thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        filter: saturate(0.8) contrast(1.06);
      }
      .project:first-child .thumb img {
        filter: saturate(0.55) sepia(0.18) contrast(1.1);
      }
      .status {
        position: absolute;
        top: 10px;
        left: 10px;
        padding: 5px 8px;
        color: #111;
        background: var(--green);
        font: 700 10px "Chakra Petch";
        letter-spacing: 0.1em;
      }
      .status.mock {
        background: var(--brass);
      }
      .status.dev {
        background: var(--copper);
        color: #fff0df;
      }
      .project-body {
        padding: 15px;
      }
      .project h3 {
        margin: 0 0 7px;
        color: #efe7ce;
        font: 700 19px "Chakra Petch";
        text-transform: uppercase;
      }
      .project p {
        min-height: 44px;
        margin: 0 0 14px;
        color: #aaa99b;
        font-size: 12px;
        line-height: 1.5;
      }
      .meta {
        display: flex;
        justify-content: space-between;
        gap: 8px;
        align-items: center;
        color: var(--brass-hi);
        font: 11px "Chakra Petch";
        letter-spacing: 0.08em;
        flex-wrap: wrap;
      }
      .view {
        color: #161616;
        background: var(--brass);
        padding: 7px 9px;
        text-decoration: none;
        font-weight: 700;
        text-transform: uppercase;
        font-size: 10px;
        letter-spacing: 0.08em;
      }
      .view.disabled {
        color: var(--muted);
        background: #45453f;
        pointer-events: none;
      }
      .access-text {
        color: var(--muted);
        font: 700 10px "Chakra Petch";
        letter-spacing: 0.08em;
        text-transform: uppercase;
      }
      a:focus-visible,
      button:focus-visible {
        outline: 2px solid var(--brass-hi);
        outline-offset: 2px;
      }
      .meta-labels {
        display: flex;
        gap: 12px;
        font-size: 10px;
      }
      .meta-label strong {
        color: var(--paper);
        font-weight: 700;
        display: block;
      }
      .meta-label span {
        color: var(--muted);
        font-weight: 500;
        display: block;
        margin-top: 1px;
      }
      .project[aria-hidden="true"] {
        display: none;
      }
      @keyframes spin {
        to {
          transform: rotate(360deg);
        }
      }
      @keyframes steam-rise {
        0% {
          opacity: 0;
          transform: translate(0, 18px) scale(0.55);
        }
        25% {
          opacity: 0.42;
        }
        100% {
          opacity: 0;
          transform: translate(28px, -135px) scale(1.45);
        }
      }
      @keyframes spark-pop {
        0%,
        100% {
          opacity: 0;
          transform: translate(0, 0) rotate(45deg) scale(0.5);
        }
        18% {
          opacity: 1;
        }
        70% {
          opacity: 0;
          transform: translate(26px, -22px) rotate(45deg) scale(1);
        }
      }
      .empty-state {
        grid-column: 1 / -1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 42px 20px;
        border: 2px dashed #5b584f;
        background: rgba(32, 37, 37, 0.6);
        text-align: center;
      }
      .empty-state[hidden] {
        display: none;
      }
      .empty-icon {
        font-size: 28px;
        color: var(--brass);
        margin-bottom: 8px;
      }
      .empty-state strong {
        color: var(--brass-hi);
        font: 700 15px "Chakra Petch";
        letter-spacing: 0.1em;
        margin-bottom: 6px;
      }
      .empty-state p {
        color: var(--muted);
        font-size: 13px;
        margin: 0 0 16px;
      }
      .reset-filter-btn {
        border: 1px solid var(--brass-hi);
        background: var(--brass);
        color: #161616;
        padding: 8px 14px;
        cursor: pointer;
        font: 700 11px "Chakra Petch";
        letter-spacing: 0.1em;
        text-transform: uppercase;
      }
      .reset-filter-btn:hover {
        background: var(--brass-hi);
      }

      @media (prefers-reduced-motion: reduce) {
        *,
        *::before,
        *::after {
          animation-duration: 0.01ms !important;
          animation-iteration-count: 1 !important;
          transition-duration: 0.01ms !important;
          scroll-behavior: auto !important;
        }
        .schematic .gear,
        .schematic .steam,
        .schematic .spark {
          animation: none !important;
        }
        .schematic .spark {
          display: none !important;
        }
        .schematic.is-active .pipe,
        .pipe[aria-pressed="true"] {
          transform: rotate(42deg) !important;
        }
      }
      @media (max-width: 1180px) {
        .hero {
          grid-template-columns: 1fr;
          gap: 32px;
        }
        .schematic {
          max-width: 680px;
          margin: 0 auto;
          width: 100%;
        }
      }
      @media (max-width: 900px) {
        .hero {
          grid-template-columns: 1fr;
          gap: 25px;
        }
        .projects {
          grid-template-columns: repeat(2, 1fr);
        }
        nav {
          display: none;
        }
      }
      @media (max-width: 560px) {
        main {
          padding-top: 34px;
        }
        .projects {
          grid-template-columns: 1fr;
        }
        .topbar {
          padding: 0 20px;
        }
        .hero {
          min-height: 0;
        }
        .schematic {
          min-height: 240px;
          background-image:
            linear-gradient(
              135deg,
              rgba(18, 37, 42, 0.42),
              rgba(18, 37, 42, 0.78)
            ),
            url("../assets/backgrounds/workshop_blueprint_mobile.webp");
        }
        .gear {
          width: 112px;
          height: 112px;
          right: 10px;
          top: 58px;
        }
        .gear.medium {
          width: 78px;
          height: 78px;
          right: 104px;
          top: 102px;
        }
        .gear.small {
          width: 54px;
          height: 54px;
          right: 168px;
          top: 128px;
        }
        .axle {
          width: 220px;
          height: 48px;
          left: 70px;
          top: 130px;
        }
        .bearing {
          width: 30px;
          height: 30px;
          right: 48px;
          top: 98px;
        }
        .pipe-body {
          width: 78px;
          height: 78px;
          left: 10px;
          top: 124px;
        }
        .gauge {
          width: 48px;
          height: 48px;
          left: 26px;
          top: 91px;
        }
        .pipe {
          width: 48px;
          height: 48px;
          left: 25px;
          top: 139px;
        }
        .steam {
          width: 54px;
          height: 54px;
        }
        .steam.one {
          left: 12%;
          bottom: 28px;
        }
        .steam.two {
          left: 20%;
          bottom: 34px;
        }
        .spark {
          width: 24px;
          height: 24px;
        }
        .readout {
          right: 12px;
          bottom: 10px;
          font-size: 9px;
        }
      }

      /* Workshop Inspection Modal */
      html.modal-open,
      body.modal-open {
        overflow: hidden !important;
      }
      .workshop-modal-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1000;
        background: rgba(10, 14, 15, 0.85);
        backdrop-filter: blur(6px);
        -webkit-backdrop-filter: blur(6px);
        display: none;
        align-items: center;
        justify-content: center;
        padding: 16px;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.25s ease-out;
        overscroll-behavior: contain;
      }
      .workshop-modal-backdrop.active,
      .workshop-modal-backdrop.is-open {
        display: flex;
        opacity: 1;
        pointer-events: auto;
      }
      .workshop-modal {
        position: relative;
        width: 100%;
        max-width: 680px;
        max-height: min(88vh, 640px);
        background: var(--panel);
        border: 2px solid var(--brass);
        box-shadow: 0 16px 40px rgba(0, 0, 0, 0.75), 0 0 25px rgba(200, 158, 86, 0.2);
        display: flex;
        flex-direction: column;
        overflow: hidden;
        pointer-events: auto;
      }
      .modal-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 12px 20px;
        background: #171d1d;
        border-bottom: 1px solid var(--line);
        flex-shrink: 0;
      }
      .modal-tag {
        font: 700 12px "Chakra Petch", sans-serif;
        color: var(--brass-hi);
        letter-spacing: 0.12em;
        text-transform: uppercase;
      }
      .modal-close {
        background: transparent;
        border: 1px solid var(--line);
        color: var(--muted);
        font-size: 20px;
        line-height: 1;
        width: 32px;
        height: 32px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.2s ease;
      }
      .modal-close:hover {
        border-color: var(--brass-hi);
        color: var(--text);
        background: rgba(200, 158, 86, 0.15);
      }
      .modal-scroll-body {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
        pointer-events: auto;
        scrollbar-width: thin;
        scrollbar-color: var(--brass) rgba(20, 25, 26, 0.95);
      }
      .modal-scroll-body::-webkit-scrollbar {
        width: 8px;
      }
      .modal-scroll-body::-webkit-scrollbar-track {
        background: rgba(16, 22, 23, 0.95);
        border-left: 1px solid rgba(243, 197, 108, 0.15);
      }
      .modal-scroll-body::-webkit-scrollbar-thumb {
        background: var(--brass);
        border-radius: 2px;
      }
      .modal-scroll-body::-webkit-scrollbar-thumb:hover {
        background: var(--brass-hi);
      }
      .modal-hero {
        position: relative;
        width: 100%;
        height: 200px;
        background: #0f1516;
        overflow: hidden;
        flex-shrink: 0;
      }
      .modal-hero img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        opacity: 0.9;
        display: block;
      }
      .modal-hero-badges {
        position: absolute;
        top: 14px;
        right: 14px;
      }
      .modal-content {
        padding: 22px;
        display: flex;
        flex-direction: column;
        gap: 16px;
      }
      .modal-content h2 {
        font: 700 24px "Chakra Petch", sans-serif;
        color: var(--text);
        margin: 0;
        letter-spacing: 0.04em;
      }
      .modal-desc {
        margin: 0;
        color: var(--muted);
        font-size: 15px;
        line-height: 1.5;
      }
      .modal-spec-block {
        display: flex;
        flex-direction: column;
        gap: 10px;
        padding: 14px;
        background: rgba(16, 22, 23, 0.65);
        border: 1px solid var(--line);
      }
      .modal-spec-block h4 {
        margin: 0;
        font: 700 12px "Chakra Petch", sans-serif;
        color: var(--brass-hi);
        letter-spacing: 0.1em;
      }
      .modal-highlights {
        margin: 0;
        padding-left: 20px;
        color: var(--text);
        font-size: 13.5px;
        line-height: 1.6;
      }
      .modal-highlights li {
        margin-bottom: 6px;
      }
      .modal-highlights li:last-child {
        margin-bottom: 0;
      }
      .modal-stack-tags {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
      }
      .modal-stack-tag {
        font: 600 11.5px "Chakra Petch", monospace;
        letter-spacing: 0.05em;
        background: rgba(30, 42, 44, 0.8);
        border: 1px solid var(--brass);
        color: var(--brass-hi);
        padding: 4px 10px;
      }
      .modal-footer {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 14px 20px;
        background: #171d1d;
        border-top: 1px solid var(--line);
        flex-shrink: 0;
        flex-wrap: wrap;
        gap: 12px;
        z-index: 2;
      }
      .modal-footer-status {
        font: 600 12px "Chakra Petch", monospace;
        color: var(--muted);
        letter-spacing: 0.08em;
      }
      .modal-action-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid var(--brass-hi);
        background: var(--brass);
        color: #121718;
        font: 700 12px "Chakra Petch", sans-serif;
        letter-spacing: 0.1em;
        text-decoration: none;
        padding: 10px 18px;
        cursor: pointer;
        transition: all 0.2s ease;
      }
      .modal-action-btn:hover {
        background: var(--brass-hi);
        box-shadow: 0 0 12px rgba(230, 185, 107, 0.4);
      }
      @media (max-height: 620px) {
        .modal-hero {
          height: 140px;
        }
        .modal-content {
          padding: 16px;
          gap: 12px;
        }
      }


/* ==========================================================================
   ENGINEERING WORKSHOP EXTENSIONS FOR PRODUCTS & DEMOS
   ========================================================================== */

.page-header {
  margin-bottom: 40px;
  border-bottom: 2px solid #1f2525;
  padding-bottom: 24px;
}

.system-badge-tag {
  display: inline-block;
  padding: 4px 10px;
  background: var(--stone);
  border: 1px solid var(--line);
  color: var(--brass-hi);
  font: 700 11px "Chakra Petch";
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.eng-panel {
  background: var(--panel);
  border: 2px solid #4a4841;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.35);
  padding: 28px;
  margin-bottom: 32px;
  position: relative;
}

.eng-panel.highlight {
  border-color: var(--brass);
}

.eng-panel-title {
  color: var(--brass-hi);
  font: 700 20px "Chakra Petch";
  letter-spacing: 0.05em;
  margin-top: 0;
  margin-bottom: 16px;
  text-transform: uppercase;
}

.spec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.spec-item {
  background: #171d1d;
  border: 1px solid #363d3d;
  padding: 18px;
}

.spec-item h4 {
  margin: 0 0 8px 0;
  color: var(--brass-hi);
  font: 700 14px "Chakra Petch";
  letter-spacing: 0.08em;
}

.spec-item p {
  margin: 0;
  color: var(--paper);
  font-size: 13px;
  line-height: 1.5;
}

.eng-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
  background: #171d1d;
  font-size: 13px;
}

.eng-table th, .eng-table td {
  padding: 12px 16px;
  text-align: left;
  border: 1px solid #2f3838;
}

.eng-table th {
  background: #202727;
  color: var(--brass-hi);
  font: 700 12px "Chakra Petch";
  letter-spacing: 0.08em;
}

.eng-table td strong {
  color: var(--paper);
}

/* Simulation & Terminal Screens */
.terminal-screen {
  background: #0d1213;
  border: 2px solid #3a4545;
  box-shadow: inset 0 0 20px rgba(0,0,0,0.8);
  padding: 24px;
  font-family: "Space Grotesk", sans-serif;
  margin-bottom: 30px;
}

.terminal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #263333;
  padding-bottom: 12px;
  margin-bottom: 18px;
  color: var(--muted);
  font: 700 11px "Chakra Petch";
  letter-spacing: 0.1em;
}

.stat-counter {
  font: 700 32px "Chakra Petch";
  color: var(--brass-hi);
  line-height: 1;
  margin: 6px 0;
}

.btn-eng {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--brass-hi);
  background: var(--brass);
  color: #121718;
  font: 700 12px "Chakra Petch", sans-serif;
  letter-spacing: 0.1em;
  text-decoration: none;
  padding: 10px 18px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 3px 3px 0 #111;
}

.btn-eng:hover {
  background: var(--brass-hi);
  box-shadow: 0 0 12px rgba(230, 185, 107, 0.4);
  transform: translateY(-1px);
}

.btn-eng.secondary {
  background: #353330;
  border-color: #55524b;
  color: var(--paper);
}

.btn-eng.secondary:hover {
  background: #45433e;
  border-color: var(--brass);
  color: #FFF;
}

.btn-eng.danger {
  background: #7f1d1d;
  border-color: #ef4444;
  color: #fee2e2;
}

.btn-eng.danger:hover {
  background: #991b1b;
}

.log-stream {
  background: #070a0a;
  border: 1px solid #202b2b;
  padding: 14px;
  font-family: monospace;
  font-size: 11px;
  color: #8db580;
  max-height: 180px;
  overflow-y: auto;
  line-height: 1.6;
}

/* Keep footer links reachable on narrow screens. */
.workshop-footer .container { padding: 0 5vw; }
.workshop-footer .container > div { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.workshop-footer .container > div:last-child { flex-wrap: wrap; }

.eng-panel > .stamp { position: static !important; align-self: flex-start; margin-bottom: 12px; }
