    :root {
      --paper-white: #F5F3ED;
      --ink-black: #1A1A1A;
      --rust: #A65E4E;
      --faded-blue: #6B8E9E;
      --warm-grey: #4A4A44;
      --rose-gold: #D4A59A;
      --soft-lavender: #C8B8DB;
      --fade-duration: 0.6s;
    }

    * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
    }

    html, body {
      height: 100%;
      overflow: hidden;
    }

    body {
      background-color: var(--paper-white);
      color: var(--ink-black);
      font-family: 'Helvetica Neue', 'Segoe UI', system-ui, -apple-system, sans-serif;
      line-height: 1.7;
    }

    /* ── Navigation ── */

    .nav {
      position: fixed;
      top: 0;
      left: 0;
      right: 0;
      z-index: 100;
      padding: 1.5rem max(2rem, env(safe-area-inset-right, 0)) 1.5rem max(2rem, env(safe-area-inset-left, 0));
      display: flex;
      justify-content: space-between;
      align-items: center;
    }

    .nav-logo {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.85rem;
      font-weight: 400;
      letter-spacing: 0.2em;
      color: var(--ink-black);
      text-decoration: none;
      text-transform: lowercase;
      cursor: pointer;
      perspective: 600px;
    }

    .logo-letter {
      display: inline-block;
      transform-origin: center center;
    }

    .nav-logo.flipping .logo-letter {
      animation: letterFlip 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    }
    .nav-logo.flipping .logo-letter:nth-child(1) { animation-delay: 0ms; }
    .nav-logo.flipping .logo-letter:nth-child(2) { animation-delay: 60ms; }
    .nav-logo.flipping .logo-letter:nth-child(3) { animation-delay: 120ms; }
    .nav-logo.flipping .logo-letter:nth-child(4) { animation-delay: 180ms; }
    .nav-logo.flipping .logo-letter:nth-child(5) { animation-delay: 240ms; }
    .nav-logo.flipping .logo-letter:nth-child(6) { animation-delay: 300ms; }

    @keyframes letterFlip {
      0%   { transform: rotateX(0deg); opacity: 1; }
      45%  { transform: rotateX(90deg); opacity: 0; }
      55%  { transform: rotateX(-90deg); opacity: 0; }
      100% { transform: rotateX(0deg); opacity: 1; }
    }

    /* When showing "patch": last letter (d→empty) collapses */
    .nav-logo.showing-patch .logo-letter:last-child {
      width: 0;
      opacity: 0;
      overflow: hidden;
      letter-spacing: 0;
      transition: width 0.3s ease 0.35s, opacity 0.3s ease 0.35s, letter-spacing 0.3s ease 0.35s;
    }

    /* When flipping back to "conrad": last letter expands */
    .nav-logo:not(.showing-patch) .logo-letter:last-child {
      transition: width 0.3s ease, opacity 0.3s ease, letter-spacing 0.3s ease;
    }

    .nav-links {
      display: flex;
      gap: 2rem;
      list-style: none;
    }

    .nav-links a {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      color: var(--warm-grey);
      text-decoration: none;
      font-size: 0.8rem;
      letter-spacing: 0.15em;
      text-transform: lowercase;
      transition: color 0.3s ease;
      cursor: pointer;
      position: relative;
    }

    .nav-links a:hover {
      color: var(--rust);
    }

    .nav-links a.active {
      color: var(--rust);
    }

    .nav-links a.active::after {
      content: '';
      position: absolute;
      bottom: -4px;
      left: 0;
      right: 0;
      height: 1px;
      background: var(--rust);
      opacity: 0.5;
    }

    /* ── Panels ── */

    .panel {
      position: absolute;
      top: 0;
      left: 0;
      width: 100%;
      height: 100vh;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      opacity: 0;
      visibility: hidden;
      transition: opacity var(--fade-duration) ease, visibility var(--fade-duration) ease;
      pointer-events: none;
      /* Safe area: keep content away from notch/Dynamic Island */
      padding-left: env(safe-area-inset-left, 0);
      padding-right: env(safe-area-inset-right, 0);
    }

    .panel.active {
      opacity: 1;
      visibility: visible;
      pointer-events: auto;
    }

    /* ── Hero Title ── */

    .hero-title-wrap {
      position: relative;
    }

    .hero-title {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: clamp(3rem, 10vw, 7rem);
      font-weight: 300;
      letter-spacing: 0.3em;
      text-transform: lowercase;
      color: var(--ink-black);
      position: relative;
      z-index: 2;
      opacity: 0; /* hidden, canvas renders text */
    }

    /* ── Canvas Layers ── */

    .scene-canvas {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      z-index: 0;
      pointer-events: none;
      image-rendering: auto;
      background-color: #C8C0B6;
    }

    .gradient-canvas {
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      z-index: 3;
      pointer-events: none;
    }

    /* 3D depth layers */
    .hero-title-wrap::before,
    .hero-title-wrap::after {
      content: 'conrad';
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: clamp(3rem, 10vw, 7rem);
      font-weight: 300;
      letter-spacing: 0.3em;
      text-transform: lowercase;
      pointer-events: none;
      z-index: 1;
    }

    .hero-title-wrap.show-patch::before,
    .hero-title-wrap.show-patch::after {
      content: 'patch';
    }

    .hero-title-wrap::before {
      color: transparent;
      text-shadow:
        0 2px 8px rgba(200, 126, 92, 0.14),
        0 4px 20px rgba(166, 94, 78, 0.10),
        0 8px 40px rgba(107, 142, 158, 0.07);
      animation: depthFloat1 14s ease-in-out infinite;
    }

    .hero-title-wrap::after {
      color: transparent;
      text-shadow:
        0 -1px 4px rgba(200, 126, 92, 0.06),
        0 6px 30px rgba(212, 184, 150, 0.10),
        0 12px 60px rgba(58, 58, 56, 0.05);
      animation: depthFloat2 18s ease-in-out infinite;
    }

    @keyframes depthFloat1 {
      0%, 100% { transform: translate(-50%, -50%) translate3d(0, 0, 0); }
      33% { transform: translate(-50%, -50%) translate3d(1px, -1px, 0); }
      66% { transform: translate(-50%, -50%) translate3d(-1px, 1px, 0); }
    }

    @keyframes depthFloat2 {
      0%, 100% { transform: translate(-50%, -50%) translate3d(0, 0, 0); }
      50% { transform: translate(-50%, -50%) translate3d(-1.5px, 1.5px, 0); }
    }

    /* ── Content Sections ── */

    .panel-content {
      max-width: 720px;
      width: 100%;
      padding: 2rem;
    }

    .divider {
      width: 40px;
      height: 1px;
      background-color: var(--rose-gold);
      margin-bottom: 3rem;
      opacity: 0.5;
    }

    .section-title {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.8rem;
      font-weight: 400;
      letter-spacing: 0.3em;
      text-transform: lowercase;
      color: var(--rust);
      margin-bottom: 2.5rem;
    }

    .about-text {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.85rem;
      font-weight: 300;
      color: var(--warm-grey);
      max-width: 560px;
      letter-spacing: 0.02em;
      line-height: 1.9;
      text-align: center;
      margin: 0 auto;
    }

    .about-text p + p {
      margin-top: 1.5rem;
    }

    /* ── About: Bild + Text-Overlay ── */
    .about-wrap {
      position: relative;
      max-width: 800px;
      width: 90vw;
      cursor: default;
      pointer-events: none;
    }

    .about-swarm-canvas {
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      pointer-events: none;
      z-index: 0;
    }

    .about-bird {
      position: fixed;
      border-radius: 50%;
      pointer-events: none;
      z-index: 2;
      opacity: 0;
      transition: opacity 0.8s ease;
    }
    .about-bird.visible {
      opacity: 1;
    }
    .about-bird.pulsing {
      animation: particlePulse 3s ease-in-out infinite;
    }
    .about-bird-1 {
      width: 7px; height: 7px;
      background: var(--rust);
    }
    .about-bird-2 {
      width: 9px; height: 9px;
      background: var(--faded-blue);
    }

    .about-overlay {
      position: relative;
      z-index: 1;
      padding: 2.5rem 2.5rem;
      opacity: 0;
      transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .about-overlay .about-text {
      background: transparent;
      padding: 0;
      border-radius: 0;
      backdrop-filter: none;
      -webkit-backdrop-filter: none;
      box-shadow: none;
      pointer-events: auto;
    }

    .about-overlay.revealed {
      opacity: 1;
    }

    .panel-footer {
      position: absolute;
      bottom: max(1.5rem, env(safe-area-inset-bottom, 0));
      left: env(safe-area-inset-left, 0);
      right: env(safe-area-inset-right, 0);
      z-index: 10;
      text-align: center;
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.65rem;
      letter-spacing: 0.15em;
      color: var(--warm-grey);
      display: flex;
      justify-content: center;
      align-items: center;
      gap: 0.8rem;
    }

    .footer-copy {
      font-size: 11px;
      line-height: 1;
      cursor: default;
      transition: color 0.6s ease;
    }

    .footer-copy::after {
      content: '';
      display: inline;
      max-width: 0;
      overflow: hidden;
      white-space: nowrap;
      transition: max-width 0.4s ease, opacity 0.3s ease;
      opacity: 0;
      vertical-align: baseline;
    }

    .footer-copy:hover {
      color: var(--rust);
    }

    .footer-copy:hover::after {
      content: ' 2026 crz';
      max-width: 6rem;
      opacity: 1;
    }

    .footer-socials {
      display: flex;
      gap: 0.8rem;
      align-items: center;
    }

    .footer-socials a {
      text-decoration: none;
      transition: color 0.6s ease;
      display: flex;
      align-items: center;
    }

    .footer-socials a:hover {
      color: var(--rust) !important;
    }

    .footer-socials svg {
      width: 14px;
      height: 14px;
      fill: currentColor;
    }

    /* ── Audio Toggle ── */

    .audio-toggle {
      background: none;
      border: none;
      cursor: pointer;
      padding: 12px;
      outline: none;
      display: flex;
      align-items: center;
    }

    .audio-icon {
      display: block;
      width: 0;
      height: 0;
      border-style: solid;
      border-width: 4px 0 4px 7px;
      border-color: transparent transparent transparent var(--warm-grey);
      border-radius: 0;
      transition: all 0.4s ease;
    }

    .audio-toggle:hover .audio-icon {
      border-color: transparent transparent transparent var(--rust);
    }

    .audio-toggle.playing .audio-icon {
      width: 7px;
      height: 7px;
      border-width: 0;
      border-radius: 50%;
      background: var(--rust);
    }

    /* ── Patch Puzzle Game ── */

    .patch-game-wrap {
      max-width: 1100px;
      width: 100%;
      padding: 2rem;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 1.5rem;
    }

    .patch-header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      width: 100%;
      max-width: 840px;
    }

    .patch-title {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.8rem;
      letter-spacing: 0.2em;
      color: var(--rust);
      opacity: 0.7;
    }

    .patch-close {
      display: none; /* replaced by .synth-close-float (outside clip-path stacking context) */
    }

    .patch-rack-wrap {
      position: relative;
      display: inline-block;
    }

    .patch-rack {
      position: relative;
      display: flex;
      align-items: stretch;
      gap: 2px;
      /* Minimal dark rack */
      background: #111;
      border: 1px solid #2A2926;
      padding: 3px;
      border-radius: 2px;
      box-shadow:
        0 3px 12px rgba(0, 0, 0, 0.35);
      transition: border-color 0.4s ease;
      overflow-x: auto;
      max-width: 100%;
    }

    .patch-rack.error-flash {
      border-color: rgba(166, 94, 78, 0.6);
    }

    .patch-module {
      min-width: 90px;
      width: auto;
      /* Minimal bright panel, subtly tinted per module */
      background: color-mix(in srgb, var(--module-accent, #4A4A44) 5%, #E8E6E1);
      border: 1px solid #D0CEC8;
      display: flex;
      flex-direction: column;
      align-items: stretch;
      padding: 10px 6px;
      gap: 3px;
      position: relative;
      flex-shrink: 0;
      box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.15);
    }

    .patch-module::before {
      content: '';
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      height: 2px;
      background: var(--module-accent, var(--warm-grey));
      opacity: 0.6;
    }

    .patch-module::after {
      display: none;
    }

    .patch-module-name {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.9rem;
      font-weight: 700;
      letter-spacing: 0.15em;
      color: #1A1A1A;
      text-shadow: none;
    }

    .patch-module-subtitle {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.5rem;
      letter-spacing: 0.1em;
      color: #666;
      text-transform: lowercase;
    }

    /* ── Dual-column layout (VCF, SEQ) ── */
    .patch-columns {
      display: flex;
      gap: 2px;
      flex: 1;
    }

    .patch-column {
      flex: 1;
      display: flex;
      flex-direction: column;
      min-width: 0;
      border-right: 1px solid rgba(0, 0, 0, 0.06);
    }

    .patch-column:last-child {
      border-right: none;
    }

    .patch-column .patch-row {
      padding: 1px 1px 10px 1px;
      gap: 2px;
    }

    .patch-column .patch-outputs {
      margin-top: auto;
    }

    .patch-column-label {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.45rem;
      letter-spacing: 0.08em;
      color: #888;
      text-transform: uppercase;
      text-align: center;
      padding: 2px 0 4px 0;
      border-bottom: 1px solid rgba(0, 0, 0, 0.04);
    }

    .patch-row {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 4px;
      min-height: 30px;
      padding: 1px 2px 14px 2px;
    }

    .patch-row-jack {
      display: flex;
      align-items: center;
      flex: 1;
      min-width: 0;
    }

    .patch-row-knob {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      flex: 1;
      min-width: 0;
    }

    .patch-outputs {
      display: flex;
      gap: 6px;
      justify-content: center;
      align-items: center;
      flex-wrap: wrap;
      padding-top: 5px;
      border-top: 1px solid rgba(0, 0, 0, 0.08);
      min-height: 40px;
      margin-top: auto;
    }

    /* When multiple output rows, only the first gets margin-top: auto */
    .patch-outputs + .patch-outputs {
      margin-top: 0;
      border-top: none;
      padding-top: 2px;
    }

    .patch-module-header {
      text-align: center;
      padding-bottom: 2px;
    }

    .patch-jack {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 3px;
      cursor: pointer;
    }

    .patch-row .patch-jack {
      flex-direction: row;
    }

    .patch-jack-ring {
      width: 18px;
      height: 18px;
      border-radius: 50%;
      /* Minimal dark jack socket */
      border: 2px solid #1A1918;
      background: #080808;
      position: relative;
      transition: border-color 0.2s, box-shadow 0.2s;
      box-shadow:
        inset 0 2px 4px rgba(0, 0, 0, 0.8),
        0 0.5px 1px rgba(0, 0, 0, 0.2);
    }

    /* Center contact pin */
    .patch-jack-ring::after {
      content: '';
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 3px;
      height: 3px;
      border-radius: 50%;
      background: #222;
    }

    .patch-jack:hover .patch-jack-ring {
      border-color: #333;
      box-shadow:
        inset 0 2px 4px rgba(0, 0, 0, 0.8),
        0 0 4px rgba(166, 94, 78, 0.15);
    }

    .patch-jack.selected .patch-jack-ring {
      border-color: var(--rust);
      box-shadow:
        inset 0 2px 4px rgba(0, 0, 0, 0.8),
        0 0 6px rgba(166, 94, 78, 0.35);
    }

    .patch-jack.connected .patch-jack-ring {
      border-color: var(--jack-cable-color, #556670);
    }

    .patch-jack-label {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.48rem;
      font-weight: 600;
      letter-spacing: 0.08em;
      color: #333;
      text-transform: uppercase;
      white-space: nowrap;
    }

    /* ── Knobs ── */

    .patch-knobs {
      display: flex;
      gap: 6px;
      justify-content: center;
      flex-wrap: wrap;
    }

    /* ── Phase 2: Dormant State (Veil) ── */

    .phase-2 {
      opacity: 0.15;
      pointer-events: none;
      transition: opacity 0.6s ease, filter 0.6s ease, transform 0.4s ease;
      filter: grayscale(0.5);
    }

    /* Phase 2: Awakened after puzzle solve */
    .patch-module.success .phase-2 {
      opacity: 1;
      pointer-events: auto;
      filter: none;
    }

    @keyframes phaseUnlock {
      0%   { opacity: 0.15; filter: grayscale(0.5); transform: scale(0.95); }
      50%  { opacity: 0.8;  filter: grayscale(0.1); transform: scale(1.02); }
      100% { opacity: 1;    filter: none;            transform: scale(1); }
    }

    .patch-module.success .phase-2.awakening {
      animation: phaseUnlock 0.8s ease-out forwards;
    }

    /* ── Waveform Selector ── */

    .patch-selector {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 2px;
      user-select: none;
      -webkit-user-select: none;
    }

    .patch-selector-btn {
      width: 36px;
      height: 16px;
      border: 1px solid #5A5850;
      background: linear-gradient(180deg, #1A1A18 0%, #2A2A26 40%, #1A1A18 100%);
      color: var(--paper-white);
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.35rem;
      letter-spacing: 0.05em;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      transition: border-color 0.2s;
      border-radius: 2px;
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 1px 2px rgba(0, 0, 0, 0.2);
    }

    .patch-selector-btn:hover {
      border-color: var(--rust);
    }

    .patch-selector-label {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.4rem;
      letter-spacing: 0.08em;
      color: var(--warm-grey);
      text-transform: uppercase;
    }

    .patch-controls-section {
      display: flex;
      gap: 6px;
      justify-content: center;
      flex-wrap: wrap;
    }

    .patch-knob {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 2px;
      user-select: none;
      -webkit-user-select: none;
      transition: opacity 0.3s ease;
    }

    /* DLY TIME knob dimmed when SYNC or CLK overrides it */
    .patch-module .patch-knob[data-sync-active] {
      opacity: 0.3 !important;
      pointer-events: none !important;
    }

    /* In rows, knob label+value sit below the dial but don't affect vertical centering */
    .patch-row .patch-knob {
      position: relative;
    }
    .patch-row .patch-knob-label,
    .patch-row .patch-knob-value {
      position: absolute;
      top: 100%;
      left: 50%;
      transform: translateX(-50%);
      white-space: nowrap;
    }
    .patch-row .patch-knob-label {
      margin-top: -2px;
    }
    .patch-row .patch-knob-value {
      margin-top: 7px;
    }

    .patch-knob-dial {
      width: 28px;
      height: 28px;
      border-radius: 50%;
      /* Minimal dark knob — clean, flat-ish with subtle depth */
      background:
        radial-gradient(circle at 38% 35%,
          rgba(255, 255, 255, 0.10) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%,
          #2E2D2C 0%, #252423 40%, #1C1B1A 70%, #141312 100%);
      border: 1.5px solid #0A0A09;
      position: relative;
      cursor: grab;
      transition: box-shadow 0.2s;
      box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.35),
        0 0.5px 1px rgba(0, 0, 0, 0.2);
    }

    /* White indicator line */
    .patch-knob-dial::after {
      content: '';
      position: absolute;
      width: 1.5px;
      height: 8px;
      background: #FFF;
      top: 2px;
      left: 50%;
      transform: translateX(-50%);
      border-radius: 0.5px;
    }

    /* Bipolar knob: indicator line in faded-blue */
    .bipolar-knob .patch-knob-dial::after {
      background: var(--faded-blue);
    }
    /* Bipolar knob: center detent dot at 12 o'clock */
    .bipolar-knob .patch-knob-dial::before {
      content: '';
      position: absolute;
      width: 3px;
      height: 3px;
      border-radius: 50%;
      background: rgba(107, 142, 158, 0.5);
      top: -1px;
      left: 50%;
      transform: translateX(-50%);
      z-index: 1;
    }
    .bipolar-knob .patch-knob-value {
      color: var(--faded-blue);
    }

    /* ── Detent Knob (snap positions with dots) ── */
    .detent-knob {
      position: relative;
    }

    .knob-detent-ring {
      position: absolute;
      top: 0;
      left: 50%;
      transform: translateX(-50%);
      width: 28px;
      height: 28px;
      pointer-events: none;
    }

    .knob-detent-dot {
      position: absolute;
      width: 2.5px;
      height: 2.5px;
      border-radius: 50%;
      background: #bbb;
      left: calc(50% + var(--dx));
      top: calc(50% + var(--dy));
      transform: translate(-50%, -50%);
      transition: background 0.2s ease, transform 0.2s ease;
    }

    .knob-detent-dot.active {
      background: var(--rust);
      transform: translate(-50%, -50%) scale(1.3);
    }

    .patch-knob:hover .patch-knob-dial {
      box-shadow:
        0 2px 5px rgba(0, 0, 0, 0.4),
        0 0 4px rgba(166, 94, 78, 0.1);
    }

    .patch-knob:active .patch-knob-dial {
      cursor: grabbing;
      box-shadow:
        0 0.5px 2px rgba(0, 0, 0, 0.25);
    }

    .patch-knob-label {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.42rem;
      font-weight: 600;
      letter-spacing: 0.08em;
      color: #333;
      text-transform: uppercase;
    }

    .patch-knob-value {
      display: none; /* Minimalistisch: keine Werte anzeigen */
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.35rem;
      color: var(--rust);
      opacity: 0.8;
      min-height: 0.6em;
    }

    /* BPM-Knob: Wert immer sichtbar */
    [data-knob-id="seq-bpm"] .patch-knob-value {
      display: block;
    }

    /* Module-Breiten */
    .patch-module[data-module-id="seq"]     { width: 160px; }
    .patch-module[data-module-id="cxo"]     { width: 115px; }
    .patch-module[data-module-id="sou"]     { width: 100px; }
    .patch-module[data-module-id="noise"]   { display: none; } /* hidden — replaced by SOU */
    .patch-module[data-module-id="lpg"]     { width: 175px; }
    .patch-module[data-module-id="lfo"]     { display: none; } /* hidden — replaced by SOU */
    .patch-module[data-module-id="dual-ad"] { width: 130px; }
    .patch-module[data-module-id="dld"]     { width: 155px; }
    .patch-module[data-module-id="mult"]    { width: 55px; min-width: 55px; padding: 10px 3px; }
    .patch-module[data-module-id="out"]     { width: 80px; }

    /* ── Mult Module Layout (vertical jack strips) ── */
    .mult-section {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 0;
      padding: 0;
    }

    .mult-section + .mult-section {
      border-top: 1px solid rgba(0, 0, 0, 0.08);
      margin-top: 4px;
      padding-top: 2px;
    }

    .mult-section-label {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.45rem;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: var(--warm-grey);
      opacity: 0.7;
      padding: 2px 0 0 0;
    }

    .mult-jack-row {
      display: flex;
      justify-content: center;
      align-items: center;
      width: 100%;
      min-height: 30px;
      padding: 1px 0 14px 0;  /* Match patch-row vertical rhythm */
    }

    /* Hide subtitle for narrow BM module */
    .patch-module[data-module-id="mult"] .patch-module-subtitle {
      display: none;
    }

    /* ── SEQ Run Switch + Tap Tempo ── */
    .seq-run-switch {
      display: flex;
      justify-content: center;
      gap: 4px;
      margin-bottom: 2px;
    }

    .seq-run-btn, .seq-tap-btn {
      height: 16px;
      border: 1px solid #5A5850;
      background: linear-gradient(180deg, #1A1A18 0%, #2A2A26 40%, #1A1A18 100%);
      color: var(--paper-white);
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.38rem;
      letter-spacing: 0.1em;
      text-transform: uppercase;
      cursor: pointer;
      border-radius: 2px;
      padding: 0;
      line-height: 16px;
      text-align: center;
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 1px 2px rgba(0, 0, 0, 0.2);
      transition: border-color 0.15s, box-shadow 0.3s;
    }

    .seq-run-btn { width: 42px; }
    .seq-tap-btn { width: 32px; }

    .seq-run-btn:hover, .seq-tap-btn:hover {
      border-color: var(--rust);
    }

    .seq-tap-btn:active {
      border-color: var(--rust);
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 0 4px rgba(166, 94, 78, 0.4),
        0 1px 2px rgba(0, 0, 0, 0.2);
    }

    .seq-run-btn.running {
      border-color: var(--rust);
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 0 6px rgba(166, 94, 78, 0.5),
        0 1px 2px rgba(0, 0, 0, 0.2);
      color: var(--rust);
    }

    /* ── REC Button (Output module) ── */
    .rec-section {
      display: flex;
      justify-content: center;
      padding: 4px 0 2px;
    }

    .rec-btn {
      display: flex;
      align-items: center;
      gap: 3px;
      height: 16px;
      border: 1px solid #5A5850;
      background: linear-gradient(180deg, #1A1A18 0%, #2A2A26 40%, #1A1A18 100%);
      color: var(--paper-white);
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.38rem;
      letter-spacing: 0.1em;
      cursor: pointer;
      border-radius: 2px;
      padding: 0 6px;
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 1px 2px rgba(0, 0, 0, 0.2);
      transition: border-color 0.15s, box-shadow 0.3s;
    }

    .rec-btn:hover {
      border-color: var(--rust);
    }

    .rec-dot {
      width: 5px;
      height: 5px;
      border-radius: 50%;
      background: #666;
      transition: background 0.2s;
      flex-shrink: 0;
    }

    .rec-btn.recording {
      border-color: #cc3333;
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 0 6px rgba(204, 51, 51, 0.4),
        0 1px 2px rgba(0, 0, 0, 0.2);
    }

    .rec-btn.recording .rec-dot {
      background: #cc3333;
      animation: recPulse 1s ease-in-out infinite;
    }

    @keyframes recPulse {
      0%, 100% { opacity: 1; }
      50% { opacity: 0.3; }
    }

    /* ── DLD Buttons (HOLD / REV) ── */
    .dld-buttons {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 3px;
      padding: 4px 6px;
      margin: 2px 0;
    }

    .dld-btn {
      display: flex;
      align-items: center;
      justify-content: center;
      height: 18px;
      padding: 0 4px;
      border: 1.5px solid rgba(0, 0, 0, 0.15);
      border-radius: 2px;
      background: rgba(0, 0, 0, 0.03);
      color: var(--ink);
      font-family: 'JetBrains Mono', 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
      font-size: 0.4rem;
      letter-spacing: 0.03em;
      cursor: pointer;
      transition: border-color 0.15s, background 0.15s;
      user-select: none;
      -webkit-user-select: none;
    }

    .dld-btn:hover {
      border-color: rgba(0, 0, 0, 0.25);
    }

    .dld-btn:active {
      background: rgba(0, 0, 0, 0.06);
    }

    .dld-btn.active {
      border-color: var(--rust);
      background: rgba(166, 94, 78, 0.08);
      color: var(--rust);
      box-shadow: 0 0 4px rgba(166, 94, 78, 0.15);
    }
    .dld-btn.buffer-clearing {
      border-color: var(--faded-blue);
      background: rgba(107, 142, 158, 0.15);
      color: var(--faded-blue);
      animation: bufferClear 0.3s ease-out;
    }
    @keyframes bufferClear {
      0%   { transform: scale(0.95); opacity: 0.6; }
      50%  { transform: scale(1.06); opacity: 1; }
      100% { transform: scale(1); opacity: 1; }
    }

    /* ── Sequencer Step Grid ── */
    .seq-grid-section {
      display: flex;
      flex-direction: column;
      gap: 3px;
      padding: 4px 6px;
      margin: 2px 0;
    }

    .seq-step-grid {
      display: flex;
      gap: 2px;
      align-items: flex-end;
      height: 48px;
      padding: 3px 2px;
      background: rgba(0, 0, 0, 0.04);
      border: 1px solid rgba(0, 0, 0, 0.06);
      border-radius: 2px;
    }

    .seq-step-wrap {
      flex: 1;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 1px;
    }

    .seq-step-bar {
      --step-prob: 1;
      position: relative;
      width: 100%;
      min-height: 4px;
      background: var(--warm-grey, #4A4A44);
      opacity: calc(0.2 + var(--step-prob) * 0.1);
      border-radius: 1px 1px 0 0;
      cursor: ns-resize;
      transition: opacity 0.08s, background-color 0.08s;
    }

    .seq-step-bar.step-active {
      opacity: calc(0.3 + var(--step-prob) * 0.4);
      background: var(--module-accent, #6B8E9E);
    }

    .seq-step-bar.step-playing {
      opacity: calc(0.5 + var(--step-prob) * 0.5);
      background: #A65E4E;
      box-shadow: 0 0 5px rgba(166, 94, 78, 0.5);
    }

    .seq-step-bar.step-playing.step-active {
      background: #A65E4E;
      box-shadow: 0 0 6px rgba(166, 94, 78, 0.6);
    }

    /* Pitch-Lock indicator: subtle line below step */
    .seq-step-bar.step-locked::after {
      content: '';
      position: absolute;
      bottom: -3px;
      left: 20%;
      right: 20%;
      height: 1.5px;
      background: var(--rust, #A65E4E);
      opacity: 0.5;
      border-radius: 1px;
    }

    /* Probability edit mode flash */
    .seq-step-bar.step-prob-edit {
      box-shadow: 0 0 4px rgba(107, 142, 158, 0.5);
    }

    .seq-step-label {
      font-family: 'SF Mono', 'Fira Code', monospace;
      font-size: 0.3rem;
      color: var(--warm-grey, #4A4A44);
      text-align: center;
      opacity: 0.6;
      line-height: 1;
    }

    .patch-cables-canvas {
      position: absolute;
      top: 0;
      left: 0;
      pointer-events: none;
      z-index: 10;
    }

    .patch-controls {
      display: flex;
      gap: 1.5rem;
    }

    .patch-test-btn,
    .patch-reset-btn {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.72rem;
      letter-spacing: 0.1em;
      background: none;
      border: 1px solid #5A5850;
      color: #5A5850;
      padding: 0.5rem 1.2rem;
      cursor: pointer;
      transition: all 0.3s;
      text-shadow: 0 0.5px 0 rgba(255, 255, 255, 0.2);
    }

    .patch-test-btn:hover {
      border-color: var(--rust);
      color: var(--rust);
    }

    .patch-reset-btn:hover {
      border-color: var(--faded-blue);
      color: var(--faded-blue);
    }

    /* Preset Save/Load buttons (same style as reset) */
    .patch-preset-btn {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.72rem;
      letter-spacing: 0.1em;
      background: none;
      border: 1px solid #5A5850;
      color: #5A5850;
      padding: 0.5rem 1.2rem;
      cursor: pointer;
      transition: all 0.3s;
      text-shadow: 0 0.5px 0 rgba(255, 255, 255, 0.2);
    }
    .patch-preset-btn:hover {
      border-color: var(--faded-blue);
      color: var(--faded-blue);
    }

    /* ── Preset Overlay ── */
    .preset-overlay {
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      background: #1A1A18;
      border: 1px solid #5A5850;
      border-radius: 4px;
      padding: 14px 16px;
      z-index: 60;
      min-width: 220px;
      max-height: 320px;
      overflow-y: auto;
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    }

    .preset-title {
      font-size: 0.55rem;
      color: var(--faded-blue);
      margin-bottom: 10px;
      letter-spacing: 0.1em;
    }

    .preset-input {
      width: 100%;
      background: #2A2A26;
      border: 1px solid #5A5850;
      border-radius: 2px;
      color: var(--paper-white);
      font-family: inherit;
      font-size: 0.5rem;
      padding: 6px 8px;
      margin-bottom: 10px;
      outline: none;
      box-sizing: border-box;
    }
    .preset-input:focus {
      border-color: var(--faded-blue);
    }

    .preset-btn-row {
      display: flex;
      gap: 6px;
      flex-wrap: wrap;
    }

    .preset-btn {
      flex: 1;
      min-width: 60px;
      background: #2A2A26;
      border: 1px solid #5A5850;
      color: var(--paper-white);
      font-family: inherit;
      font-size: 0.42rem;
      letter-spacing: 0.08em;
      padding: 5px 8px;
      cursor: pointer;
      border-radius: 2px;
      transition: border-color 0.15s;
    }
    .preset-btn:hover {
      border-color: var(--rust);
      color: var(--rust);
    }
    .preset-btn-dim {
      opacity: 0.5;
    }
    .preset-btn-dim:hover {
      opacity: 1;
    }

    .preset-list {
      margin-bottom: 10px;
      max-height: 180px;
      overflow-y: auto;
    }

    .preset-item {
      display: flex;
      justify-content: space-between;
      align-items: center;
      padding: 5px 6px;
      border-bottom: 1px solid #2A2A26;
      transition: background 0.1s;
    }
    .preset-item:hover {
      background: #2A2A26;
    }

    .preset-item-name {
      font-size: 0.45rem;
      color: var(--paper-white);
      cursor: pointer;
      flex: 1;
      letter-spacing: 0.05em;
    }
    .preset-item-name:hover {
      color: var(--rust);
    }

    .preset-item-del {
      font-size: 0.6rem;
      color: #5A5850;
      cursor: pointer;
      padding: 0 4px;
      line-height: 1;
    }
    .preset-item-del:hover {
      color: #cc3333;
    }

    .preset-empty {
      font-size: 0.42rem;
      color: #5A5850;
      text-align: center;
      padding: 12px;
    }

    .patch-message {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.7rem;
      letter-spacing: 0.1em;
      min-height: 1.5em;
      color: var(--rust);
      opacity: 0;
      transition: opacity 0.4s;
    }

    .patch-message.visible {
      opacity: 1;
    }

    .patch-download {
      opacity: 0;
      transition: opacity 0.8s ease;
    }

    .patch-download.visible {
      opacity: 1;
    }

    .patch-download-link {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.8rem;
      letter-spacing: 0.15em;
      color: var(--rust);
      text-decoration: none;
      border-bottom: 1px solid var(--rust);
      padding-bottom: 2px;
      transition: color 0.3s, border-color 0.3s;
    }

    .patch-download-link:hover {
      color: var(--faded-blue);
      border-color: var(--faded-blue);
    }

    @keyframes moduleGlow {
      0%, 100% {
        box-shadow:
          0 1px 4px rgba(0, 0, 0, 0.22),
          0 1px 1px rgba(0, 0, 0, 0.12),
          inset 0 1px 0 rgba(255, 255, 255, 0.55);
      }
      50% {
        box-shadow:
          0 1px 4px rgba(0, 0, 0, 0.22),
          0 1px 1px rgba(0, 0, 0, 0.12),
          inset 0 1px 0 rgba(255, 255, 255, 0.55),
          0 0 15px rgba(166, 94, 78, 0.25);
      }
    }

    .patch-module.success {
      animation: moduleGlow 2s ease-in-out 3;
    }

    /* ── Bubble Expand Animation ── */
    #patchgame.bubble-expand {
      opacity: 1 !important;
      visibility: visible !important;
      pointer-events: auto !important;
      clip-path: circle(0% at var(--bubble-x, 50%) var(--bubble-y, 50%));
      background: var(--rust);
      transition: none !important;
      animation: bubbleGrow 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    }

    #patchgame.bubble-ready {
      opacity: 1 !important;
      visibility: visible !important;
      pointer-events: auto !important;
      clip-path: circle(150% at var(--bubble-x, 50%) var(--bubble-y, 50%));
      background: var(--paper-white);
      animation: none;
      transition: none !important;
    }

    @keyframes bubbleGrow {
      0% {
        clip-path: circle(0% at var(--bubble-x, 50%) var(--bubble-y, 50%));
        background: var(--rust);
      }
      40% {
        background: var(--rust);
      }
      100% {
        clip-path: circle(150% at var(--bubble-x, 50%) var(--bubble-y, 50%));
        background: var(--paper-white);
      }
    }

    /* Content fades in after bubble expands */
    #patchgame .patch-game-wrap {
      opacity: 0;
      transition: opacity 0.4s ease 0.5s;
    }

    #patchgame.bubble-ready .patch-game-wrap {
      opacity: 1;
    }

    /* Floating close button (outside patchgame stacking context) */
    .synth-close-float {
      display: none;
      position: fixed;
      right: 2rem;
      top: 4.8rem;
      z-index: 101;
      background: none;
      border: none;
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 1.1rem;
      color: var(--warm-grey);
      cursor: pointer;
      transition: color 0.3s;
      padding: 0.2rem 0.4rem;
      letter-spacing: 0.05em;
    }
    .synth-close-float:hover {
      color: var(--rust);
    }
    .synth-close-float.visible {
      display: block;
    }

    /* Fullscreen button (mobile synth) */
    .synth-fullscreen-float {
      display: none;
      position: fixed;
      left: 1rem;
      top: 1rem;
      z-index: 101;
      background: none;
      border: 1px solid var(--warm-grey);
      border-radius: 4px;
      color: var(--warm-grey);
      cursor: pointer;
      padding: 0.3rem;
      transition: color 0.3s, border-color 0.3s;
      line-height: 0;
    }
    .synth-fullscreen-float:hover {
      color: var(--rust);
      border-color: var(--rust);
    }
    .synth-fullscreen-float.visible {
      display: block;
    }

    /* Bubble shrink (closing) */
    #patchgame.bubble-shrink {
      opacity: 1 !important;
      visibility: visible !important;
      pointer-events: none !important;
      transition: none !important;
      animation: bubbleShrink 0.6s cubic-bezier(0.55, 0, 1, 0.45) forwards;
    }

    @keyframes bubbleShrink {
      0% {
        clip-path: circle(150% at var(--bubble-x, 50%) var(--bubble-y, 50%));
        background: var(--paper-white);
        opacity: 1;
      }
      60% {
        background: var(--rust);
      }
      100% {
        clip-path: circle(0% at var(--bubble-x, 50%) var(--bubble-y, 50%));
        background: var(--rust);
        opacity: 0;
      }
    }

    #patchgame.bubble-shrink .patch-game-wrap {
      opacity: 0;
      transition: opacity 0.15s ease;
    }

    /* ── Swarm Particle (sitting) ── */

    .swarm-particle {
      position: fixed;
      width: 8px;
      height: 8px;
      border-radius: 50%;
      background: var(--rust);
      pointer-events: auto;
      cursor: pointer;
      z-index: 110;
      opacity: 0;
      transition: opacity 1s ease, left 2.5s ease-in-out, top 2.5s ease-in-out;
    }

    .swarm-particle.visible {
      opacity: 1;
    }

    body[data-active-panel]:not([data-active-panel="hero"]) .swarm-particle,
    body[data-active-panel]:not([data-active-panel="hero"]) #swarmCanvas {
      visibility: hidden;
    }

    @keyframes particlePulse {
      0%, 100% { transform: scale(1); opacity: 0.8; }
      50% { transform: scale(1.5); opacity: 1; }
    }

    .swarm-particle.pulsing {
      animation: particlePulse 3s ease-in-out infinite;
    }

    /* ── Rain Mode ── */

    .rain-text {
      position: fixed;
      bottom: 20%;
      left: 50%;
      transform: translateX(-50%);
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.75rem;
      letter-spacing: 0.3em;
      color: var(--faded-blue);
      opacity: 0;
      transition: opacity 2s ease;
      pointer-events: none;
      z-index: 55;
    }

    /* ── Responsive ── */

    @media (max-width: 900px) {
      /* Synth panel: fixed overlay with own scroll context (iOS needs this) */
      #patchgame.active {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        overflow-y: auto;
        justify-content: flex-start;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
        /* Safe area insets for notch/home indicator */
        padding: env(safe-area-inset-top, 0) env(safe-area-inset-right, 0)
                 env(safe-area-inset-bottom, 0) env(safe-area-inset-left, 0);
      }
      body:has(#patchgame.bubble-ready) .nav {
        display: none;
      }
      .patch-game-wrap {
        padding: 0.5rem;
        padding-bottom: 1.5rem;
        gap: 0.5rem;
      }
      .patch-rack {
        flex-wrap: wrap;
        justify-content: center;
        max-width: 520px;
      }
      .patch-module {
        min-width: 85px;
        flex-shrink: 1;
      }
      .patch-module[data-module-id="seq"]     { width: 140px; }
      .patch-module[data-module-id="cxo"]     { width: 100px; }
      .patch-module[data-module-id="sou"]     { width: 90px; }
      .patch-module[data-module-id="lpg"]     { width: 150px; }
      .patch-module[data-module-id="dual-ad"] { width: 115px; }
      .patch-module[data-module-id="dld"]     { width: 135px; }
      .patch-module[data-module-id="mult"]    { width: 50px; min-width: 50px; }
      .patch-module[data-module-id="out"]     { width: 72px; }
      .patch-module[data-module-id="noise"] {
        min-width: 70px;
      }
      .patch-row {
        gap: 2px;
      }
      .patch-outputs {
        gap: 4px;
      }
      .synth-close-float {
        right: 1rem;
        top: 1rem;
        font-size: 1.5rem;
      }
    }

    @media (max-width: 600px) {
      .nav {
        padding: 1rem 1.2rem;
      }

      .nav-logo {
        font-size: 0.78rem;
        letter-spacing: 0.15em;
      }

      .nav-links {
        gap: 1rem;
      }

      .nav-links a {
        font-size: 0.72rem;
        letter-spacing: 0.1em;
      }

      .hero-title {
        letter-spacing: 0.2em;
      }

      .hero-title-wrap::before,
      .hero-title-wrap::after {
        letter-spacing: 0.2em;
      }

      .panel-footer {
        gap: 0.6rem;
        bottom: 1rem;
      }

      .panel-footer .audio-toggle {
        padding: 14px;
      }

      .footer-socials svg {
        width: 16px;
        height: 16px;
      }

      .panel-content {
        padding: 2rem 1.5rem;
      }

      .about-wrap {
        padding-bottom: 3.5rem;
      }

      .about-overlay {
        padding: 1rem;
      }

      .about-overlay .about-text {
        padding: 1.2rem 1.4rem;
        font-size: 0.8rem;
      }

      .patch-module {
        padding: 6px 4px;
      }

      .patch-row {
        gap: 1px;
        min-height: 26px;
      }

      .patch-jack-ring {
        width: 18px;
        height: 18px;
        border-width: 2px;
      }

      .patch-jack-ring::after {
        width: 5px;
        height: 5px;
      }

      .patch-module-name {
        font-size: 0.75rem;
      }

      .patch-knob-dial {
        width: 26px;
        height: 26px;
        border-width: 2.5px;
        box-shadow:
          inset 0 1px 1px rgba(255, 255, 255, 0.12),
          inset 0 -1px 2px rgba(0, 0, 0, 0.3),
          0 3px 5px rgba(0, 0, 0, 0.4),
          0 1px 2px rgba(0, 0, 0, 0.25);
      }

      .patch-knob-dial::after {
        height: 8px;
        width: 2px;
        top: 2px;
      }

      .patch-knob-label {
        font-size: 0.42rem;
      }

      .patch-knob-value {
        font-size: 0.38rem;
      }

      .patch-jack-label {
        font-size: 0.42rem;
      }

      .patch-outputs {
        gap: 3px;
      }

      .patch-game-wrap {
        padding: 0.5rem;
        gap: 0.5rem;
      }
      .patch-rack {
        max-width: 370px;
      }
      .patch-module {
        padding: 4px 3px;
        min-width: 70px;
      }
      .patch-module[data-module-id="seq"]     { width: 100px; min-width: 80px; }
      .patch-module[data-module-id="cxo"]     { width: 85px; min-width: 70px; }
      .patch-module[data-module-id="sou"]     { width: 75px; min-width: 60px; }
      .patch-module[data-module-id="noise"]   { min-width: 55px; }
      .patch-module[data-module-id="lpg"]     { width: 110px; min-width: 90px; }
      .patch-module[data-module-id="lfo"]     { min-width: 70px; }
      .patch-module[data-module-id="dual-ad"] { width: 95px; min-width: 80px; }
      .patch-module[data-module-id="dld"]     { width: 100px; min-width: 80px; }
      .patch-module[data-module-id="mult"]    { width: 40px; min-width: 35px; }
      .patch-module[data-module-id="out"]     { width: 65px; min-width: 55px; }

      .patch-selector-btn {
        width: 30px;
        height: 14px;
        font-size: 0.3rem;
      }

      .patch-selector-label {
        font-size: 0.3rem;
      }

      .patch-controls-section {
        gap: 4px;
      }

      .seq-step-grid {
        height: 36px;
        gap: 1px;
        padding: 2px 1px;
      }

      .seq-step-label {
        font-size: 0.22rem;
      }

      .seq-grid-section {
        padding: 2px 3px;
      }

      .seq-run-btn, .seq-tap-btn {
        height: 14px;
        font-size: 0.32rem;
      }
      .seq-run-btn { width: 34px; }
      .seq-tap-btn { width: 26px; }

      .dld-buttons {
        gap: 2px;
        padding: 2px 4px;
      }
      .dld-btn {
        height: 14px;
        font-size: 0.32rem;
      }
    }

    /* ── Small phones (iPhone Mini, SE etc.) ── */

    @media (max-width: 480px) {
      .nav {
        padding: 0.8rem 1rem;
      }

      .nav-logo {
        font-size: 0.72rem;
        letter-spacing: 0.12em;
      }

      .nav-links {
        gap: 0.7rem;
      }

      .nav-links a {
        font-size: 0.68rem;
        letter-spacing: 0.08em;
      }

      .hero-title {
        letter-spacing: 0.15em;
      }

      .hero-title-wrap::before,
      .hero-title-wrap::after {
        letter-spacing: 0.15em;
      }

      .panel-footer {
        gap: 0.5rem;
        bottom: 0.8rem;
        font-size: 0.6rem;
      }

      .about-wrap {
        width: 94vw;
      }

      .about-overlay .about-text {
        padding: 1rem 1.2rem;
        font-size: 0.78rem;
        line-height: 1.8;
      }

      .section-title {
        font-size: 0.7rem;
        letter-spacing: 0.2em;
        margin-bottom: 1.5rem;
      }
    }

    /* ── Footer hover text: always visible on touch devices ── */

    @media (hover: none) {
      .footer-copy::after {
        max-width: 6rem !important;
        opacity: 1 !important;
      }
    }

    /* ── Rotate device overlay ── */

    .rotate-overlay {
      display: none; /* shown via JS */
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      z-index: 10000;
      background: rgba(245, 243, 237, 0.95);
      backdrop-filter: blur(8px);
      -webkit-backdrop-filter: blur(8px);
      justify-content: center;
      align-items: center;
    }

    .rotate-overlay.visible {
      display: flex;
    }

    .rotate-content {
      text-align: center;
    }

    .rotate-icon {
      width: 64px;
      height: 52px;
      color: var(--warm-grey);
      margin-bottom: 1.2rem;
      animation: rotateHint 2.5s ease-in-out infinite;
    }

    @keyframes rotateHint {
      0%, 100% { transform: rotate(0deg); }
      30%, 70% { transform: rotate(90deg); }
    }

    .rotate-text {
      font-family: 'SF Mono', 'Fira Code', 'Fira Mono', 'Roboto Mono', 'Courier New', monospace;
      font-size: 0.75rem;
      letter-spacing: 0.15em;
      color: var(--warm-grey);
      text-transform: lowercase;
    }

    /* ── Reduced Motion ── */

    @media (prefers-reduced-motion: reduce) {
      .hero-title-shadow-1, .hero-title-shadow-2 { animation: none; }
      .about-bird.pulsing { animation: none; }
      .rotate-icon { animation: none; }
      .panel { transition-duration: 0.01s; }
      .about-overlay { transition-duration: 0.01s; }
    }
