:root {
  --color-bg: oklch(0.505 0.026 107.3);
  --color-surface: oklch(0.257 0.09 281.3);
  --color-text: oklch(0.98 0 0);
  --color-text-dark: #000000;
  --color-muted: oklch(0.373 0.031 259.7);
  --color-accent-yellow: oklch(0.861 0.16 91.9);
  --color-accent-green: oklch(0.627 0.16 149.2);
  --color-accent-red: oklch(0.505 0.16 27.5);
  --color-accent-teal: oklch(0.773 0.16 163.2);
  --color-accent-blue: oklch(0.714 0.16 254.6);
  --color-accent-indigo: oklch(0.511 0.16 277);
  --color-accent-orange: oklch(0.705 0.16 47.6);
  --color-egg-orange: oklch(0.751 0.16 58.3);
  --color-egg-brown: oklch(0.484 0.06 38.3);
  --color-egg-green: oklch(0.427 0.09 143.7);
  --color-egg-cyan: oklch(0.633 0.09 195.3);
  --color-egg-red: oklch(0.639 0.09 20);
  --color-egg-blue: oklch(0.35 0.12 223.1);
  --color-egg-indigo: oklch(0.424 0.16 265.6);
  --color-egg-rust: oklch(0.598 0.11 52.2);
  --color-soft-stone: oklch(0.886 0.018 113.9);
  --color-egg-sand: oklch(0.786 0.064 74.6);
  /* Darker tan for Duplicate Note Mode background */
  --color-dark-tan: oklch(0.5412 0.06 74.6);
  /* Midnight Blue for text accents in Duplicate Note Mode */
  --color-midnight-blue: #191970;
}

body { font-family: 'Poppins', sans-serif; background-color: var(--color-bg); touch-action: manipulation; color: var(--color-text); overflow-y: auto; -webkit-user-select: none; -ms-user-select: none; user-select: none; }
      .text-yellow-300 { color: var(--color-accent-yellow); }
      .knob-border { border: 2px solid var(--color-surface); box-shadow: 0 0 0 2px var(--color-surface); }
      .main-knob { cursor: grab; aspect-ratio: 1 / 1; transition: background-color 0.05s linear; width: 100%; }
      #knob-indicator-1, #knob-indicator-2 {
      background-color: var(--color-text);
      mix-blend-mode: difference;
      }
      .osc-sub-knob > .osc-sub-indicator {
        top: 50%;
        left: 50%;
        width: 0.25rem;
        height: 42%;
        border-radius: 9999px;
        transform-origin: 50% 100%;
      }
      .main-knob:active { cursor: grabbing; }
      .fx-knob-container { cursor: ns-resize; aspect-ratio: 1 / 1; transition: background-color 0.1s linear; will-change: transform; }
      .fx-knob-container.osc-sub-knob.duo-volume-active { background: var(--color-egg-orange); box-shadow: 0 0 0 2px var(--color-surface), 0 0 10px var(--color-egg-orange); }
      .retro-select { 
        -webkit-appearance: none;
        -moz-appearance: none;
        appearance: none;
        background-color: transparent;
        border: 2px solid var(--color-text); 
        border-radius: 0; 
        padding: 0.5rem 1rem; 
        color: var(--color-text); 
        font-weight: 700; 
        text-align: center;
        text-align-last: center;
        -moz-text-align-last: center;
        transition: all 0.2s;
      }

      #midi-clock-toggle {
        appearance: none;
        width: 16px;
        height: 16px;
        background-color: var(--color-text);
        border: 2px solid var(--color-text);
        border-radius: 0;
        cursor: pointer;
        transition: background-color 0.15s ease, border-color 0.15s ease;
      }

      #midi-clock-toggle:checked {
        background-color: var(--color-accent-green);
        border-color: var(--color-accent-green);
      }
.midi-routing-table {
  border-collapse: collapse;
}
.midi-routing-table th,
.midi-routing-table td {
  padding: 0.35rem 0.25rem;
}
.midi-routing-table th {
  text-transform: uppercase;
}
.midi-routing-row td {
  font-weight: 700;
  letter-spacing: 0.08em;
}
.midi-routing-row:not(:last-child) td {
  border-bottom: 1px solid var(--color-surface);
}
.midi-routing-select {
  width: 100%;
  min-width: 8rem;
}
.midi-routing-label {
  text-transform: uppercase;
}
/* Update your MIDI Learn classes in style.css */

.blinking-midi-learn {
    animation: midi-white-blink 1.2s infinite !important;
    cursor: cell !important;
    /* Ensure the glow isn't clipped */
    z-index: 10;
}

.blinking-midi-learn.learning-focus {
    outline: 2px solid #ffffff !important;
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.8), inset 0 0 10px rgba(255, 255, 255, 0.4) !important;
    animation: none !important;
    background-color: rgba(255, 255, 255, 0.3) !important;
    filter: brightness(1.2);
}

@keyframes midi-white-blink {
    0% { 
        box-shadow: 0 0 2px rgba(255, 255, 255, 0.3); 
    }
    50% { 
        box-shadow: 0 0 15px rgba(255, 255, 255, 0.9), inset 0 0 5px rgba(255, 255, 255, 0.2);
        filter: brightness(1.1);
    }
    100% { 
        box-shadow: 0 0 2px rgba(255, 255, 255, 0.3); 
    }
}

      .preset-display {
        display: block;
        word-break: break-word;
        white-space: normal;
        cursor: pointer;
      }
      .preset-nav-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 2.25rem;
        height: 2.25rem;
        padding: 0;
        color: var(--color-text);
        font-family: 'Poppins', 'Helvetica Neue', Arial, 'Noto Sans', sans-serif;
        line-height: 1;
        letter-spacing: 0;
        -webkit-font-smoothing: antialiased;
        text-rendering: optimizeLegibility;
      }
.preset-nav-button:hover {
        color: var(--color-accent-yellow);
      }
.preset-nav-icon {
        width: 0.9rem;
        height: 0.9rem;
        stroke: currentColor;
        stroke-width: 1.6;
      }
  .retro-select:disabled { opacity: 0.5; cursor: not-allowed; background-color: var(--color-muted); }
      .retro-select option { background-color: var(--color-text-dark, #000000); }
      .retro-select:focus { outline: 2px solid var(--color-text); }
      .power-switch { width: 60px; height: 30px; border: 2px solid var(--color-text); cursor: pointer; position: relative; transition: background-color 0.2s ease-in-out; background-color: var(--color-accent-red); }
      .power-switch.small { width: 40px; height: 20px; border-width: 1px; }
      .power-switch.on { background-color: var(--color-accent-green); }
      .power-switch-handle { width: 24px; height: 24px; background-color: var(--color-accent-yellow); position: absolute; top: 1px; left: 1px; transition: transform 0.2s ease-in-out; }
      .power-switch.small .power-switch-handle { width: 16px; height: 16px; top: 1px; left: 1px; }
      .power-switch.on .power-switch-handle { transform: translateX(28px); }
      .power-switch.small.on .power-switch-handle { transform: translateX(18px); }
        .is-off > div:not(.power-container):not(.main-header) {
        filter: grayscale(1);
        opacity: 0.2;
        pointer-events: none;
      }
      .is-off #main-header-buttons > *:not(#how-to-button-header-container) {
        filter: grayscale(1);
        opacity: 0.2;
        pointer-events: none;
      }
      .is-off .main-header h1 {
        filter: grayscale(1);
        opacity: 0.2;
        pointer-events: none;
      }

    #synth-container.is-off + #lfo-switch-container {
  filter: grayscale(1);
  opacity: 0.2;
  pointer-events: none;
}
      #how-to-modal-overlay { transition: opacity 0.3s ease-in-out; }
      .how-to-guide { border: 2px solid var(--color-text); background-color: var(--color-text-dark, #000000); max-height: 80vh; overflow-y: auto; }
      .how-to-guide li {
        list-style-type: none;
      }
      .retro-button { transition: color 0.2s; }
      .retro-button:hover { color: var(--color-accent-yellow); }
      .retro-button.active { color: var(--color-accent-yellow); text-decoration: underline; }
      .preset-save-button { color: var(--color-accent-blue); }
      .preset-load-button { color: var(--color-accent-teal); }
      .preset-category-button {
        border: none;
        background: transparent;
      }
      #presets-toggle-button.active,
      .preset-category-button.active {
        text-decoration: none;
      }
      #presets-submenu-container {
        position: absolute;
        z-index: 10;
        background: rgba(0, 0, 0, 0.85);
        border: 2px solid rgba(255, 255, 255, 0.7);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
        color: var(--color-text);
        backdrop-filter: blur(2px);
      }
      .preset-category-button:focus { outline: none; }
       #preset-list-selector {
         position: absolute;
         left: -9999px;
         top: -9999px;
         width: 1px;
         height: 1px;
         opacity: 0;
         margin: 0;
         padding: 0;
         border: 2px solid rgba(255, 255, 255, 0.7);
         background: rgba(0, 0, 0, 0.9);
         color: var(--color-text);
         box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
       }
.arp-rate-button {
        min-width: 1.75rem;
        padding: 0.1rem 0.4rem;
        border: none;
        background-color: transparent;
        color: inherit;
        font-size: 0.65rem;
        font-weight: 700;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
        letter-spacing: 0.08em;
        transition: color 0.2s, opacity 0.2s, transform 0.1s;
      }

      /* Step Sequencer */
      #steps-mode-bar {
        gap: 0.25rem;
      }

      #step-sequencers {
        align-items: start;
      }

      .step-sequencer-header {
        gap: 0.5rem;
      }

      .step-sequencer {
        background: transparent;
        border: none;
        border-radius: 0.75rem;
        padding: 0.1rem 0.5rem 0.25rem;
      }

      .step-header-controls {
        gap: 0.75rem;
      }

      .step-volume-control {
        gap: 0.25rem;
      }

      .step-length-control,
      .step-base-control,
      .step-range-control {
        gap: 0.25rem;
      }

      .step-volume-knob,
      .step-length-knob,
      .step-base-knob,
      .step-range-knob {
        width: 36px;
        height: 36px;
        border-radius: 9999px;
        background: var(--color-egg-orange);
        position: relative;
        cursor: pointer;
        box-shadow: 0 0 0 2px var(--color-surface);
        touch-action: none;
      }

      .step-volume-indicator,
      .step-length-indicator,
      .step-base-indicator,
      .step-range-indicator {
        position: absolute;
        width: 4px;
        height: 11px;
        background: var(--color-text);
        left: 50%;
        top: 4px;
        transform-origin: 50% 14px;
        border-radius: 9999px;
        transition: transform 0.12s ease-out;
      }

      .step-volume-label,
      .step-length-label,
      .step-base-label,
      .step-range-label {
        text-align: center;
        letter-spacing: 0.18em;
      }

      .step-volume-value,
      .step-length-value,
      .step-base-value,
      .step-range-value {
        letter-spacing: 0.12em;
      }

      .step-knob {
        width: 38px;
        height: 38px;
        border-radius: 50%;
        background: var(--color-egg-orange);
        position: relative;
        cursor: pointer;
        transition: box-shadow 0.1s, opacity 0.1s, transform 0.1s;
        box-shadow: 0 0 0 2px var(--color-surface);
        touch-action: none;
      }

      .step-knob .step-indicator {
        position: absolute;
        width: 4px;
        height: 12px;
        background: var(--color-text);
        left: 50%;
        top: 3px;
        transform-origin: 50% 15px;
        border-radius: 9999px;
      }

      .step-knob.inactive {
        opacity: 0.3;
        filter: grayscale(0.6);
      }

      .step-knob.active-step {
        box-shadow: 0 0 12px var(--color-accent-blue);
      }

      .step-knob-grid {
        margin-bottom: 0.35rem;
        justify-items: center;
      }

      .step-knob.step-out-of-range {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
      }

      .chain-section {
        margin-top: 0.45rem;
        padding: 0.5rem 0.2rem 0.5rem;
      }

      .chain-section.chain-enabled {
        border-top: 1px solid var(--color-surface-light, #dbeafe);
      }

      .chain-header {
        font-size: 10px;
        letter-spacing: 0.12em;
        font-weight: 700;
        text-align: center;
        margin-bottom: 0.25rem;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-direction: column;
        gap: 0.35rem;
      }

      .chain-header-label {
        display: inline-block;
      }

      .chain-footer .chain-header-label {
        font-size: 10px;
        letter-spacing: 0.12em;
        font-weight: 700;
        text-transform: uppercase;
      }

      .chain-section:not(.chain-enabled) .chain-grid {
        display: none;
      }

      .chain-grid {
        display: grid;
        grid-template-columns: repeat(8, minmax(0, 1fr));
        gap: 0.35rem;
        justify-items: center;
      }

      .chain-slot {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.3rem;
        opacity: 0.4;
        transition: opacity 0.12s ease-out, filter 0.12s ease-out;
      }

      .chain-slot.active {
        opacity: 1;
        filter: none;
      }

      .chain-slot.playing .chain-knob {
        box-shadow: 0 0 12px var(--color-accent-blue);
      }

      .chain-grid.chain-disabled {
        opacity: 0.5;
      }

      .chain-knob {
        width: 34px;
        height: 34px;
        border-radius: 50%;
        background: var(--color-egg-orange);
        position: relative;
        cursor: pointer;
        box-shadow: 0 0 0 2px var(--color-surface);
        touch-action: none;
      }
.chain-slot.chain-locked {
    opacity: 0.3; 
    pointer-events: none; /* This prevents the knob from reacting to clicks */
}

      .chain-indicator {
        position: absolute;
        width: 3px;
        height: 10px;
        background: var(--color-text);
        left: 50%;
        top: 4px;
        transform-origin: 50% 12px;
        border-radius: 9999px;
      }

      .chain-value {
        font-size: 10px;
        font-weight: 700;
        letter-spacing: 0.08em;
        text-align: center;
        min-width: 32px;
      }
      .rate-display-row {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 1rem;
        text-transform: uppercase;
        color: inherit;
        width: 100%;
      }
      .rate-bpm-display {
        font-weight: 700;
        letter-spacing: 0.12em;
        white-space: nowrap;
        color: inherit;
        display: block;
        text-align: center;
        line-height: 1.1;
        margin-top: 0.25rem;
      }
      .arp-rate-button:hover {
        color: var(--color-accent-yellow);
        transform: translateY(-1px);
      }

      body.easter-egg-mode .arp-rate-button:hover {
        color: var(--color-accent-orange);
      }
      #custom-scale-builder { display: none; }
      .piano { display: flex; position: relative; background-color: var(--color-surface); padding: 0.5rem; border: 2px solid var(--color-text); }
      .key { border: 2px solid var(--color-surface); cursor: pointer; transition: background-color 0.1s ease-in-out; }
      .white-key { width: 30px; height: 90px; background-color: var(--color-accent-yellow); }
      .white-key.selected { background-color: var(--color-accent-green); }
      .black-key { position: absolute; width: 22px; height: 60px; background-color: var(--color-surface); border: 2px solid var(--color-accent-yellow); }
      .black-key.selected { background-color: var(--color-accent-indigo); }
      .black-key[data-note="1"] { left: 27px; }
      .black-key[data-note="3"] { left: 58px; }
      .black-key[data-note="6"] { left: 117px; }
      .black-key[data-note="8"] { left: 148px; }
      .black-key[data-note="10"] { left: 178px; }
      .arp-controls { grid-template-rows: repeat(2, minmax(0, 1fr)); }
      .arp-controls, #master-arp-controls > div { transition: opacity 0.2s ease-in-out; }
      .arp-disabled { opacity: 0.5 !important; pointer-events: none !important; }
      .arp-hidden { display: none !important; }
      .arp-note-indicator { min-width: 2.5rem; text-align: center; color: var(--color-accent-yellow); display: block; font-weight: bold; }
      .main-knob.knob-active {
      box-shadow: 0 0 0 2px var(--color-surface), inset 0 0 0 2px var(--color-text); background-color: var(--color-text);
      mix-blend-mode: difference;}
      body.easter-egg-mode {
      background-color: var(--color-dark-tan);
      color: var(--color-text-dark, #000000);
      }
.main-knob.lfo-target {
  animation: pulse-lfo 1s infinite;
}

@keyframes pulse-lfo {
  0%, 100% {
    box-shadow: 0 0 0 2px var(--color-surface), 0 0 10px 2px rgba(255, 153, 0, 0.5);
  }
  50% {
    box-shadow: 0 0 0 2px var(--color-surface), 0 0 20px 4px rgba(255, 153, 0, 0.8);
  }
}
      body.easter-egg-mode .retro-select,
      body.easter-egg-mode .power-switch,
      body.easter-egg-mode .piano {
      border-color: var(--color-text-dark, #000000);
      }
      body.easter-egg-mode #voice-0-wave-display,
      body.easter-egg-mode #voice-1-wave-display {
        color: var(--color-midnight-blue);
      }
      body.easter-egg-mode .retro-select {
      color: var(--color-text-dark, #000000);
      }
      body.easter-egg-mode .retro-select:focus {
      outline-color: var(--color-text-dark, #000000);
      }
body.easter-egg-mode #note-display-1,
body.easter-egg-mode #note-display-2,
body.easter-egg-mode .arp-note-indicator {
  color: var(--color-midnight-blue) !important;
}
      body.easter-egg-mode .how-to-guide {
        color: var(--color-text);
      }
      body.easter-egg-mode .retro-button:hover {
        color: var(--color-egg-blue);
      }
      body.easter-egg-mode .retro-button.active {
        color: var(--color-egg-blue);
        text-decoration-color: var(--color-egg-blue);
      }
      body.easter-egg-mode .preset-nav-button,
      body.easter-egg-mode .preset-nav-button:hover {
        color: var(--color-text-dark, #000000);
      }
      /* --- LFO MODE STYLES --- */
      #lfo-patch-bay {
        position: absolute;
        overflow: visible !important;
        top: 0; left: 0;
        width: 100%; height: 100%;
        pointer-events: none;
        z-index: 10;
        display: none; /* Hidden by default */
      }
      body.lfo-mode #lfo-patch-bay {
        display: block; /* Shown only in LFO mode */
      }
      .lfo-cable-group {
        pointer-events: none;
      }
      .lfo-cable {
        stroke-width: 3;
        fill: none;
        transition: d 0.1s ease-out;
        pointer-events: none;
      }
      body.lfo-mode {
        background-color: var(--color-bg);
        color: var(--color-text);
      }
      body.easter-egg-mode.lfo-mode {
  background-color: var(--color-dark-tan);
  color: var(--color-text-dark, #000000);
    }
   body.easter-egg-mode.lfo-mode #note-display-1,
body.easter-egg-mode.lfo-mode #note-display-2,
   body.easter-egg-mode.lfo-mode .arp-note-indicator {
  color: var(--color-midnight-blue) !important;
}

/* Ensure pattern dots also use midnight blue in Duplicate Note Mode */
body.easter-egg-mode .feel-pattern-step.on {
  background: var(--color-midnight-blue) !important;
}

#lfo-lock-container {
  display: none;
}

body.lfo-mode #lfo-lock-container {
  display: flex;
}

        body.easter-egg-mode.lfo-mode .retro-select {
  color: var(--color-text-dark, #000000);
  border-color: var(--color-text-dark, #000000);
  background-color: var(--color-dark-tan); /* Match the background */
}

	body.easter-egg-mode.lfo-mode .retro-select option {
  background-color: var(--color-dark-tan);
  color: var(--color-text-dark, #000000);
}
      #lfo-grid-container {
        display: none;
        /* REMOVED TOP BORDER TO FIX WHITE LINE ISSUE */
        border-top: none; 
        margin-top: 1rem;
        padding-top: 1rem;
      }

      /* Keep the LFO mode switch tappable without floating during scroll */
      #lfo-switch-container {
        position: static;
        z-index: 20;
        pointer-events: auto;
        background: inherit;
      }

      .lfo-column-box {
        border: 1px solid currentColor;
        border-radius: 0;
        padding: 14px 10px 10px 10px;
      }

      .fx-delay-knob {
        background-color: var(--color-egg-cyan);
      }

      .fx-delay-indicator {
        background-color: var(--color-egg-indigo);
      }

      .fx-reverb-knob {
        background-color: var(--color-egg-red);
      }

      .fx-reverb-indicator {
        background-color: var(--color-egg-indigo);
      }
      .lfo-display {
        color: var(--color-accent-yellow); /* Bright yellow for contrast */
        font-size: 10px;
        margin-top: 2px;
        min-height: 12px;
        font-weight: bold;
        text-align: center;
        white-space: normal;
        line-height: 1.2;
      }

      .lfo-rate-display {
        text-transform: uppercase;
        letter-spacing: 0.05em;
      }

      .lfo-tempo-switch-wrapper {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2px;
        margin-top: 2px;
      }

      .switch-disabled {
        opacity: 0.35;
        filter: grayscale(1);
        pointer-events: none;
      }
       @keyframes blink-green {
        50% {
          background-color: var(--color-accent-orange);
        }
      }
      .blinking-lfo-source {
        animation: blink-green 1s infinite;
        cursor: pointer !important;
      }
       .blinking-lfo-target {
        animation: blink-green 1s infinite;
        cursor: pointer !important;
      }
      /* --- END LFO MODE STYLES --- */
     .sequence-note-block {
  display: inline-block;
  width: calc(25% - 6px);
  height: 40px;
  border-radius: 0px; /* 4px looks better at this size */
  margin: 3px;
  cursor: pointer;
  opacity: 0.7;

  transition: opacity 0.1s;
}


.sequence-note-block.playhead,
.sequence-note-block.playhead-skipped {
                                 
  transition: none !important; 
}

.sequence-note-block:hover {
  opacity: 1;
}
      .sequence-display-container {
        display: flex;
        justify-content: center;
        width: 100%;
        max-width: 240px;
        margin-left: auto;
        margin-right: auto;
        padding: 4px 0;
        box-sizing: content-box;
      }

.feel-pattern-preview {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex-wrap: nowrap;
  width: auto;
  /* 8px dots need about 158px. 165px gives a tiny safety buffer. */
  max-width: 165px; 
  margin: 2px auto 1px;
  padding: 0;
  box-sizing: border-box;
  --feel-preview-color: rgba(255, 255, 255, 0.85);
}

.feel-pattern-step {
  width: 8px;
  height: 8px;
  
  /* Soft square corners */
  border-radius: 0px; 
  
  /* CHANGE: Set border to 'none' so empty steps are invisible */
  border: none; 
  
  background: transparent;
  
  /* This keeps them aligned even without borders */
  display: inline-block; 
}

.feel-pattern-step.on {
  background: var(--feel-preview-color);
  opacity: 1;
}
     .sequence-note-block.muted {
     opacity: 0.4;
     transform: scale(0.8);
     }
      .knob-flash {
        animation: flash-white 1s ease-in-out;
      }
      @keyframes flash-white {
        50% {
        box-shadow: 0 0 500px 14px rgba(255, 255, 255, 0.8), 0 0 0 2px var(--color-surface);
        }
      }
@keyframes note-retrigger {
  0% { opacity: 0.6; transform: scale(0.95); } /* Subtle dip to make it visible */
  100% { opacity: 1; transform: scale(1); }
}
    .sequence-note-block.playhead {
  opacity: 1 !important;
animation: note-retrigger 0.08s ease-out;
  box-shadow: 
    0 0 10px var(--color-accent-yellow); /* Outer glow */
    
  /* 4. Brighten the color itself */
  filter: brightness(1.2);
  
  /* Ensure it sits on top */
  z-index: 5;
}

.sequence-note-block.playhead-skipped {
  background: transparent !important;
  background-image: none !important;
  border-color: rgba(255, 255, 255, 0.6);
  border-width: 2px;
  border-style: solid;
  opacity: 0.2;
  transition: none !important;
}
      .mobile-spin-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        color: white;
        mix-blend-mode: difference;
        width: 36px;
        height: 36px;
        font-size: 20px;
        font-weight: bold;
        line-height: 1;
        cursor: pointer;
        -webkit-user-select: none;
        user-select: none;
      }

     @media (max-width: 1024px) {
  .fx-knob-container {
    transition: none;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    isolation: isolate;
  }
  
  .fx-knob-container > .indicator {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    will-change: transform;
    /* Remove these lines: */
    /* transform: translateZ(0); */
    /* -webkit-transform: translateZ(0); */
  }
  
  
  #octave-display-1, #octave-display-2 {
    height: 36px;
  }
  
}
@media (min-width: 768px) {
  .feel-pattern-preview {
    /* More room on desktop, let them expand */
    max-width: 220px;
  }

  .feel-pattern-step {
    /* Big, clear 10px dots for mouse users */
    width: 10px;
    height: 10px;
  }
}

.feel-pattern-step.playhead {
  /* Force visibility and make it bright white */
  background-color: #ffffff !important;
  border: 1px solid #ffffff !important;
  opacity: 1 !important;
  
  /* Make it pop out slightly */
  transform: scale(1.15);
  box-shadow: 0 0 5px rgba(255, 255, 255, 0.9);
  z-index: 10;
}

.break-grid {
  margin: 10px auto 0;
  max-width: 680px;
  background: transparent;
  border-radius: 0;
  padding: 12px;
}

.break-grid.hidden {
  display: none;
}

.break-grid.visible {
  display: block;
}

.break-grid-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.break-knob-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.break-waveform-shell {
  position: relative;
  margin: 0;
  padding: 0;
  background: transparent;
}

.break-waveform {
  width: 100%;
  height: 82px;
  display: block;
  background: transparent;
  border: none;
}

.fx-knob-container {
  touch-action: none;
}


.break-play-btn {
  background: transparent;
  border: none;
  box-shadow: none;
  color: var(--color-text);
  padding: 6px 10px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.break-play-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.soundfont-disabled {
  opacity: 0.3;
  pointer-events: none;
}

#soundfont-upload-container {
  border: none;
}

#soundfont-list-container {
  display: none;
  border: 1px solid #fff;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.soundfont-locked {
  display: none !important;
}

.soundfont-unlock-blur {
  filter: blur(6px);
  transition: filter 200ms ease;
}

.soundfont-panel {
  border: none;
  background: transparent;
  box-shadow: none;
}

#soundfont-list,
#soundfont-sample-list {
  max-height: 200px;
  overflow-y: auto;
  padding-right: 4px;
}

.soundfont-item {
  border: 1px solid #fff;
  background: transparent;
  justify-content: flex-start;
}

.soundfont-item.active {
  border-color: #fbbf24;
  box-shadow: none;
}

.soundfont-badge {
  padding: 2px 6px;
  border: 1px solid var(--color-text);
  background: transparent;
  letter-spacing: 0.12em;
}

.soundfont-subheading {
  color: var(--color-accent-yellow);
  letter-spacing: 0.18em;
  font-weight: 700;
}

.soundfont-scroll {
  border: 1px solid #fff;
  background: transparent;
  padding: 2px 6px;
  font-weight: 700;
  font-size: 10px;
  line-height: 1;
}

.controller-mode #fx-grid-container,
.controller-mode .oscillator-subgrid,
.controller-mode #drums-switch-container,
.controller-mode #break-grid-container,
.controller-mode #break-grid-default-slot,
.controller-mode #break-grid-arp-slot {
  display: none !important;
}



