      * {
        box-sizing: border-box;
        margin: 0;
        padding: 0;
      }
      @font-face {
        font-family: "Inter";
        font-style: normal;
        font-weight: 400 800;
        font-display: swap;
        src: url("../fonts/inter-var.woff2") format("woff2");
      }
      :root {
        --dl-red: #e63946;
        /* Barrierefreie Varianten (WCAG AA ≥ 4,5:1): Rot als Schrift auf
           dunklem Grund etwas heller, als Fläche unter weißer Schrift etwas dunkler */
        --dl-red-text: #ee4b57;
        --dl-red-strong: #d9303e;
        --dl-red-dark: #c92837;
        --dl-black: #1a1a1a;
        --dl-bg: #0f0f10;
        --dl-card: #161618;
        --dl-border: #26262a;
        --dl-text: #f5f5f7;
        --dl-muted: rgba(255, 255, 255, 0.55);
        --dl-cta: linear-gradient(
          180deg,
          #ff6f3e 0%,
          #ff5a1f 45%,
          #df311d 100%
        );
        color-scheme: dark;
      }
      body {
        font-family: "Inter", system-ui, sans-serif;
        background: var(--dl-bg);
        overflow-x: hidden;
      }
      input,
      button,
      select,
      textarea {
        font-family: inherit;
      }
      input[type="range"] {
        accent-color: var(--dl-red);
      }
      .app {
        max-width: 480px;
        margin: 0 auto;
        background: var(--dl-bg);
        min-height: 100vh;
      }

      .header {
        background: var(--dl-black);
        color: white;
        padding: calc(16px + env(safe-area-inset-top)) 20px 12px;
        position: sticky;
        top: 0;
        z-index: 10;
      }
      .header-top {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 4px;
      }
      .logo {
        font-size: 12px;
        font-weight: 600;
        color: var(--dl-red-text);
        letter-spacing: 0.06em;
        text-transform: uppercase;
      }
      .phase-badge {
        font-size: 11px;
        background: var(--dl-red-strong);
        color: white;
        padding: 2px 10px;
        border-radius: 20px;
      }
      .header h1 {
        font-size: 18px;
        font-weight: 500;
        color: white;
      }
      .header-sub {
        font-size: 12px;
        color: rgba(255, 255, 255, 0.55);
        margin-top: 2px;
      }

      .section {
        background: var(--dl-card);
        border-bottom: 1px solid var(--dl-border);
        padding: 14px 20px;
      }
      .section-title {
        font-size: 11px;
        color: #888;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 10px;
      }

      .e1rm-grid {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 8px;
      }
      .e1rm-item label {
        font-size: 11px;
        color: #888;
        display: block;
        margin-bottom: 4px;
      }
      .e1rm-item input {
        width: 100%;
        padding: 8px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        font-size: 15px;
        font-weight: 600;
        background: #1e1e20;
        color: var(--dl-text);
        text-align: center;
      }
      .e1rm-item input:focus {
        outline: none;
        border-color: var(--dl-red);
      }

      .settings-toggle {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 12px;
        color: var(--dl-muted);
        cursor: pointer;
        padding: 10px 20px;
        background: var(--dl-card);
        border: none;
        border-bottom: 1px solid var(--dl-border);
        width: 100%;
        text-align: left;
      }
      .settings-panel {
        display: none;
        position: relative;
        z-index: 50;
        background: var(--dl-card);
      }
      .settings-panel.open {
        display: block;
      }
      .rund-grid {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 8px;
      }
      .rund-item label {
        font-size: 11px;
        color: #888;
        display: block;
        margin-bottom: 4px;
      }
      .rund-sel {
        width: 100%;
        padding: 7px 8px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        font-size: 13px;
        font-weight: 500;
        background: #1e1e20;
        color: var(--dl-text);
        cursor: pointer;
        position: relative;
        z-index: 21;
      }

      .week-nav {
        display: flex;
        background: #141416;
        border-bottom: 1px solid var(--dl-border);
        position: relative;
        z-index: 1;
      }
      .einheit-nav {
        display: flex;
        padding: 8px 20px;
        gap: 8px;
        background: #1a1a1a;
      }
      .einheit-btn {
        flex: 1;
        padding: 8px;
        border: 1px solid rgba(255, 255, 255, 0.2);
        border-radius: 8px;
        background: none;
        color: rgba(255, 255, 255, 0.6);
        font-size: 12px;
        cursor: pointer;
        font-weight: 500;
      }
      .einheit-btn.active {
        background: var(--dl-red-strong);
        color: white;
        border-color: var(--dl-red-strong);
      }
      .week-btn {
        flex: 1;
        padding: 10px 4px;
        font-size: 12px;
        border: none;
        background: none;
        color: rgba(255, 255, 255, 0.55);
        cursor: pointer;
        border-bottom: 2px solid transparent;
      }
      .week-btn.active {
        color: var(--dl-red-text);
        border-bottom-color: var(--dl-red);
        font-weight: 600;
      }

      .tag-nav {
        display: flex;
        padding: 12px 20px;
        gap: 8px;
      }
      .tag-btn {
        flex: 1;
        padding: 8px 4px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        background: #1c1c1f;
        color: rgba(255, 255, 255, 0.55);
        font-size: 11px;
        cursor: pointer;
      }
      .tag-btn.active {
        background: var(--dl-red-strong);
        color: white;
        border-color: var(--dl-red-strong);
        font-weight: 500;
      }

      .rpe-bar {
        margin: 0 20px 12px;
        background: var(--dl-card);
        border: 1px solid var(--dl-border);
        border-radius: 8px;
        padding: 10px 14px;
      }
      .rpe-bar-row {
        display: flex;
        align-items: center;
        gap: 10px;
      }
      .rpe-bar label {
        font-size: 12px;
        color: var(--dl-muted);
        white-space: nowrap;
        min-width: 130px;
      }
      .rpe-bar input[type="range"] {
        flex: 1;
      }
      .rpe-val {
        font-size: 14px;
        font-weight: 600;
        color: var(--dl-text);
        min-width: 20px;
        text-align: right;
      }

      .uebungen {
        padding: 0 0 calc(100px + env(safe-area-inset-bottom));
        display: flex;
        flex-direction: column;
        gap: 0;
      }

      /* ─── Einheitsübersicht: Übungsliste ─── */
      .ue-list-item {
        display: flex;
        align-items: center;
        gap: 0;
        background: var(--dl-black);
        border-bottom: 1px solid #2a2a2a;
        cursor: pointer;
        padding: 0;
        overflow: hidden;
        transition: background 0.15s;
        position: relative;
      }
      .ue-list-item:active {
        background: #222;
      }
      .ue-progress-bar {
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        background: rgba(230, 57, 70, 0.16);
        width: 0%;
        transition: width 0.3s ease;
        pointer-events: none;
      }
      .ue-progress-bar.done {
        background: rgba(39, 80, 10, 0.25);
        width: 100%;
      }
      .ue-left {
        width: 4px;
        align-self: stretch;
        flex-shrink: 0;
        background: #333;
      }
      .ue-left.haupt {
        background: var(--dl-red-strong);
      }
      .ue-left.neben {
        background: #3b6d11;
      }
      .ue-left.sprung {
        background: #185fa5;
      }
      .ue-left.core {
        background: #854f0b;
      }
      .ue-body {
        flex: 1;
        padding: 14px 16px;
        min-width: 0;
        position: relative;
        z-index: 1;
      }
      .ue-name {
        font-size: 15px;
        font-weight: 700;
        color: white;
        letter-spacing: -0.01em;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
      }
      .ue-selected {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        margin-top: 1px;
        margin-bottom: 1px;
        font-style: italic;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
      }
      .ue-meta {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        margin-top: 3px;
      }
      .ue-satz-dots {
        display: flex;
        gap: 4px;
        margin-top: 6px;
      }
      .ue-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        border: 1.5px solid rgba(255, 255, 255, 0.25);
        background: transparent;
        transition: all 0.2s;
      }
      .ue-dot.done {
        background: #27500a;
        border-color: #27500a;
      }
      .ue-dot.active {
        border-color: var(--dl-red-strong);
        background: var(--dl-red-strong);
      }
      .ue-arrow {
        padding: 14px 16px;
        color: rgba(255, 255, 255, 0.25);
        font-size: 18px;
        flex-shrink: 0;
        position: relative;
        z-index: 1;
      }

      /* ─── Übungsdetail Slide-up ─── */
      #ue-detail-overlay {
        display: none;
        position: fixed;
        inset: 0;
        z-index: 200;
        background: rgba(0, 0, 0, 0.7);
        align-items: flex-end;
        justify-content: center;
      }
      #ue-detail-overlay.open {
        display: flex;
      }
      #ue-detail-panel {
        background: #111;
        border-radius: 20px 20px 0 0;
        width: 100%;
        max-width: 480px;
        max-height: 92vh;
        overflow-y: auto;
        padding-bottom: calc(32px + env(safe-area-inset-bottom));
      }
      .ued-handle {
        width: 36px;
        height: 4px;
        background: #333;
        border-radius: 2px;
        margin: 12px auto 0;
      }
      .ued-header {
        padding: 16px 20px 12px;
        border-bottom: 1px solid #1e1e1e;
        display: flex;
        align-items: center;
        justify-content: space-between;
      }
      .ued-title {
        font-size: 17px;
        font-weight: 700;
        color: white;
        letter-spacing: -0.02em;
      }
      .ued-subtitle {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.6);
        margin-top: 2px;
      }
      .ued-close {
        width: 30px;
        height: 30px;
        border-radius: 50%;
        background: #222;
        border: none;
        color: rgba(255, 255, 255, 0.5);
        font-size: 16px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
      }
      .ued-nav {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 8px 20px;
        border-bottom: 1px solid #1a1a1a;
      }
      .ued-nav-btn {
        background: #1e1e1e;
        border: none;
        color: rgba(255, 255, 255, 0.5);
        padding: 6px 14px;
        border-radius: 6px;
        font-size: 12px;
        cursor: pointer;
      }
      .ued-nav-btn:disabled {
        opacity: 0.3;
        cursor: default;
      }
      .ued-nav-pos {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.3);
      }

      /* Dropdown in Detail */
      .ued-dropdown {
        margin: 10px 20px 0;
      }
      .ued-dropdown select {
        width: 100%;
        padding: 8px 12px;
        background: #1a1a1a;
        border: 1px solid #2a2a2a;
        border-radius: 8px;
        color: rgba(255, 255, 255, 0.7);
        font-size: 13px;
      }

      /* Satz-Zeilen */
      .ued-saetze {
        padding: 4px 0;
      }
      .ued-satz {
        display: grid;
        grid-template-columns: 32px 1fr 1fr 1fr 44px;
        align-items: center;
        gap: 8px;
        padding: 12px 20px;
        border-bottom: 1px solid #242424;
        transition: background 0.2s;
      }
      .ued-satz.done {
        background: rgba(39, 80, 10, 0.22);
      }
      .ued-satz-num {
        font-size: 12px;
        font-weight: 700;
        color: rgba(255, 255, 255, 0.72);
        text-align: center;
      }
      .ued-field {
        display: flex;
        flex-direction: column;
        align-items: center;
      }
      .ued-soll {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.66);
        margin-bottom: 4px;
        letter-spacing: 0.02em;
        font-weight: 500;
      }
      .ued-input {
        width: 100%;
        padding: 8px 4px;
        background: #2a2a2a;
        border: 1px solid #3a3a3a;
        border-radius: 8px;
        font-size: 15px;
        font-weight: 700;
        color: white;
        text-align: center;
        -moz-appearance: textfield;
      }
      .ued-input:focus {
        outline: none;
        border-color: var(--dl-red);
        background: #333;
      }
      .ued-input::-webkit-inner-spin-button,
      .ued-input::-webkit-outer-spin-button {
        -webkit-appearance: none;
      }
      .ued-rir-input {
        width: 100%;
        padding: 8px 4px;
        background: #2a2010;
        border: 1px solid #5a4010;
        border-radius: 8px;
        font-size: 15px;
        font-weight: 700;
        color: #fac775;
        text-align: center;
        -moz-appearance: textfield;
      }
      .ued-rir-input:focus {
        outline: none;
        border-color: #fac775;
      }
      .ued-rir-input::-webkit-inner-spin-button,
      .ued-rir-input::-webkit-outer-spin-button {
        -webkit-appearance: none;
      }
      .ued-check {
        width: 36px;
        height: 36px;
        border-radius: 50%;
        border: 2px solid #333;
        background: none;
        color: #333;
        font-size: 16px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s;
      }
      .ued-check.done {
        background: var(--dl-red-strong);
        border-color: var(--dl-red-strong);
        color: white;
      }

      /* Spaltenköpfe Detail */
      .ued-col-headers {
        display: grid;
        grid-template-columns: 32px 1fr 1fr 1fr 44px;
        gap: 8px;
        padding: 8px 20px 4px;
        border-bottom: 1px solid #1a1a1a;
      }
      .ued-col-label {
        font-size: 10px;
        color: rgba(255, 255, 255, 0.55);
        text-transform: uppercase;
        letter-spacing: 0.06em;
        text-align: center;
        font-weight: 600;
      }

      /* Pause Timer im Detail */
      .ued-timer-bar {
        margin: 0 20px 8px;
        padding: 10px 16px;
        background: #1a1a1a;
        border-radius: 10px;
        display: none;
        align-items: center;
        justify-content: space-between;
      }
      .ued-timer-bar.visible {
        display: flex;
      }
      .ued-timer-val {
        font-size: 22px;
        font-weight: 700;
        color: var(--dl-red-text);
        font-variant-numeric: tabular-nums;
        letter-spacing: 0.05em;
      }
      .ued-timer-label {
        font-size: 10px;
        color: rgba(255, 255, 255, 0.3);
        text-transform: uppercase;
        letter-spacing: 0.08em;
      }
      .ued-timer-skip {
        background: none;
        border: 1px solid #2a2a2a;
        color: rgba(255, 255, 255, 0.55);
        border-radius: 6px;
        padding: 4px 10px;
        font-size: 11px;
        cursor: pointer;
      }

      /* e1RM + Verlauf im Detail */
      .ued-e1rm-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 6px 20px;
      }
      .ued-e1rm-val {
        font-size: 11px;
        color: #6fbf3a;
        font-weight: 600;
      }
      .ued-verlauf {
        margin: 0 20px;
        border-top: 1px solid #1e1e1e;
      }
      .ued-verlauf-btn {
        width: 100%;
        padding: 10px 0;
        background: none;
        border: none;
        color: rgba(255, 255, 255, 0.3);
        font-size: 12px;
        cursor: pointer;
        text-align: left;
        letter-spacing: 0.04em;
      }
      .ued-verlauf-content {
        padding-bottom: 8px;
      }
      .ued-verlauf-week {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        padding: 4px 0 8px;
      }
      .ued-verlauf-satz {
        background: #1a1a1a;
        border-radius: 8px;
        padding: 8px 10px;
        min-width: 70px;
        text-align: center;
      }
      .ued-verlauf-satz-num {
        font-size: 9px;
        color: rgba(255, 255, 255, 0.3);
        margin-bottom: 4px;
      }
      .ued-verlauf-satz-val {
        font-size: 13px;
        font-weight: 700;
        color: white;
      }
      .ued-verlauf-satz-sub {
        font-size: 10px;
        color: rgba(255, 255, 255, 0.55);
        margin-top: 2px;
      }

      /* Aufwärm-Rechner im Übungsdetail */
      .ued-warmup-row {
        display: flex;
        align-items: center;
        background: #1a1a1a;
        border-radius: 8px;
        padding: 7px 12px;
        margin-bottom: 5px;
      }
      .ued-warmup-row.primer {
        border: 0.5px solid rgba(230, 57, 70, 0.5);
      }
      .ued-warmup-row.optional {
        border: 0.5px dashed rgba(255, 255, 255, 0.2);
        background: #161616;
      }
      .ued-warmup-row.work {
        background: rgba(230, 57, 70, 0.14);
        border: 1px solid var(--dl-red);
      }
      .ued-warmup-pct {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        width: 68px;
      }
      .ued-warmup-opt {
        display: block;
        font-size: 9px;
        color: rgba(255, 255, 255, 0.3);
      }
      .ued-warmup-kg {
        flex: 1;
        text-align: center;
        font-size: 15px;
        font-weight: 700;
        color: #fff;
      }
      .ued-warmup-unit {
        font-size: 11px;
        font-weight: 400;
        color: rgba(255, 255, 255, 0.5);
      }
      .ued-warmup-wdh {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        width: 54px;
        text-align: right;
      }
      .ued-warmup-row.work .ued-warmup-pct,
      .ued-warmup-row.work .ued-warmup-wdh {
        color: rgba(255, 255, 255, 0.85);
      }
      .ued-warmup-note {
        font-size: 10px;
        color: rgba(255, 255, 255, 0.55);
        line-height: 1.5;
        padding: 4px 2px 2px;
      }
      .ued-warmup-foot {
        font-size: 10px;
        color: rgba(255, 255, 255, 0.25);
        padding: 2px 2px 0;
      }
      /* Melden: „Leiter passt gar nicht?" */
      .ued-warmup-report {
        margin-top: 8px;
        padding-top: 8px;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
      }
      .ued-report-link {
        background: none;
        border: none;
        padding: 0;
        color: rgba(255, 255, 255, 0.85);
        font: inherit;
        text-decoration: underline;
        text-underline-offset: 3px;
        cursor: pointer;
      }
      .ued-report-label textarea {
        display: block;
        width: 100%;
        box-sizing: border-box;
        margin: 6px 0 4px;
        min-height: 56px;
        padding: 7px 9px;
        border-radius: 8px;
        border: 1px solid rgba(255, 255, 255, 0.12);
        background: rgba(0, 0, 0, 0.3);
        color: #f5f5f7;
        font: inherit;
        font-size: 13px;
        resize: vertical;
      }
      .ued-report-hint {
        font-size: 10px;
        line-height: 1.5;
      }
      .ued-report-actions {
        display: flex;
        justify-content: flex-end;
        gap: 8px;
        margin-top: 6px;
      }
      .ued-report-actions button {
        padding: 6px 12px;
        border-radius: 999px;
        border: 1px solid rgba(255, 255, 255, 0.12);
        background: transparent;
        color: #f5f5f7;
        font: inherit;
        cursor: pointer;
      }
      .ued-report-actions .send {
        background: var(--dl-red-strong);
        border-color: var(--dl-red-strong);
        font-weight: 600;
      }
      .ued-report-actions button:disabled {
        opacity: 0.6;
      }
      /* Eigenes Aufwärmen: editierbare Zeilen (Nicht-Hauptübungen) */
      .ued-warmup-row.custom {
        gap: 8px;
      }
      .cw-input {
        flex: 1;
        min-width: 0;
        background: #0e0e0e;
        border: 0.5px solid rgba(255, 255, 255, 0.15);
        border-radius: 6px;
        color: #fff;
        font-size: 14px;
        font-weight: 700;
        text-align: center;
        padding: 7px 4px;
      }
      .cw-input::placeholder {
        font-weight: 400;
        font-size: 11px;
        color: rgba(255, 255, 255, 0.3);
      }
      .cw-input:focus {
        outline: none;
        border-color: var(--dl-red);
      }
      .cw-x {
        font-size: 12px;
        color: rgba(255, 255, 255, 0.55);
      }
      .cw-del {
        margin-left: auto;
        background: transparent;
        border: none;
        color: rgba(255, 255, 255, 0.55);
        font-size: 18px;
        line-height: 1;
        padding: 0 4px;
        cursor: pointer;
      }
      .cw-del:hover {
        color: var(--dl-red-text);
      }
      .cw-add {
        display: block;
        width: 100%;
        margin: 4px 0 2px;
        background: #1a1a1a;
        border: 0.5px dashed rgba(255, 255, 255, 0.2);
        border-radius: 8px;
        color: rgba(255, 255, 255, 0.6);
        font-size: 13px;
        font-weight: 600;
        padding: 8px;
        cursor: pointer;
      }
      .cw-add:hover {
        border-color: var(--dl-red);
        color: #fff;
      }

      /* Notiz im Detail */
      .ued-notiz {
        margin: 8px 20px 0;
      }
      .ued-notiz textarea {
        width: 100%;
        background: #1a1a1a;
        border: 1px solid #2a2a2a;
        border-radius: 8px;
        color: rgba(255, 255, 255, 0.7);
        font-size: 12px;
        padding: 10px 12px;
        resize: none;
      }
      .ued-notiz textarea:focus {
        outline: none;
        border-color: var(--dl-red);
      }

      .save-bar {
        position: fixed;
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 100%;
        max-width: 480px;
        background: #111;
        border-top: 1px solid #222;
        padding: 12px 20px calc(12px + env(safe-area-inset-bottom));
        display: flex;
        gap: 10px;
        z-index: 10;
      }
      .btn-save {
        flex: 1;
        padding: 12px;
        background: var(--dl-cta);
        color: white;
        border: none;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
      }
      .btn-save:active {
        filter: brightness(0.9);
      }
      .btn-reset {
        padding: 12px 16px;
        background: none;
        border: 1px solid #333;
        border-radius: 8px;
        font-size: 14px;
        color: rgba(255, 255, 255, 0.55);
        cursor: pointer;
      }

      /* Dialogs */
      .overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 100;
        align-items: flex-end;
        justify-content: center;
      }
      .overlay.open {
        display: flex;
      }
      .dialog {
        background: var(--dl-card);
        border-radius: 16px 16px 0 0;
        padding: 24px 20px calc(32px + env(safe-area-inset-bottom));
        width: 100%;
        max-width: 480px;
      }
      .dialog h2 {
        font-size: 17px;
        font-weight: 600;
        color: var(--dl-text);
        margin-bottom: 6px;
      }
      .dialog p {
        font-size: 13px;
        color: var(--dl-muted);
        margin-bottom: 16px;
      }
      .dialog-rpe {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 20px;
      }
      .dialog-rpe label {
        font-size: 13px;
        color: var(--dl-muted);
        white-space: nowrap;
      }
      .dialog-rpe input[type="range"] {
        flex: 1;
      }
      .dialog-rpe-val {
        font-size: 20px;
        font-weight: 700;
        color: var(--dl-red-text);
        min-width: 28px;
        text-align: right;
      }
      .dialog-notiz {
        width: 100%;
        padding: 10px 12px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        font-size: 13px;
        background: #1e1e20;
        color: var(--dl-text);
        resize: none;
        margin-bottom: 16px;
      }
      .dialog-notiz:focus {
        outline: none;
        border-color: var(--dl-red);
      }
      .disclaimer-text {
        max-height: 52vh;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 18px;
      }
      .disclaimer-text p {
        font-size: 13px;
        color: var(--dl-text);
        line-height: 1.5;
        margin-bottom: 12px;
      }
      .disclaimer-text ul {
        margin: 0 0 12px;
        padding-left: 18px;
      }
      .disclaimer-text li {
        font-size: 13px;
        color: var(--dl-muted);
        line-height: 1.5;
        margin-bottom: 8px;
      }
      .disclaimer-confirm-note {
        font-size: 12px !important;
        color: var(--dl-muted) !important;
        font-style: italic;
      }
      .btn-confirm {
        width: 100%;
        padding: 14px;
        background: var(--dl-cta);
        color: white;
        border: none;
        border-radius: 8px;
        font-size: 15px;
        font-weight: 600;
        cursor: pointer;
        margin-bottom: 8px;
      }
      .btn-confirm:active {
        filter: brightness(0.9);
      }
      .variant-opt {
        display: flex;
        flex-direction: column;
        gap: 4px;
        width: 100%;
        text-align: left;
        padding: 14px 16px;
        margin-bottom: 12px;
        background: var(--dl-bg);
        border: 1px solid var(--dl-border, #333);
        border-radius: 12px;
        cursor: pointer;
      }
      .variant-opt:active {
        border-color: var(--dl-cta);
      }
      .variant-opt-title {
        font-size: 16px;
        font-weight: 700;
        color: var(--dl-text);
      }
      .variant-opt-desc {
        font-size: 12.5px;
        line-height: 1.4;
        color: var(--dl-muted);
      }
      .btn-cancel {
        width: 100%;
        padding: 10px;
        background: none;
        border: none;
        font-size: 14px;
        color: rgba(255, 255, 255, 0.5);
        cursor: pointer;
      }

      /* Block-Ende Dialog */
      .e1rm-block-grid {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 10px;
        margin-bottom: 20px;
      }
      .e1rm-block-item label {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.5);
        display: block;
        margin-bottom: 4px;
      }
      .e1rm-block-item .best-val {
        font-size: 13px;
        color: #79b743;
        font-weight: 600;
        margin-bottom: 4px;
      }
      .e1rm-block-item .avg-val {
        font-size: 13px;
        color: #5aa9e6;
        font-weight: 600;
        margin-bottom: 6px;
      }
      .e1rm-choice {
        display: flex;
        gap: 8px;
        margin-bottom: 14px;
      }
      .e1rm-choice-btn {
        flex: 1;
        padding: 9px 8px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        background: #1e1e20;
        color: var(--dl-text);
        font-size: 13px;
        font-weight: 600;
        cursor: pointer;
      }
      .e1rm-choice-btn.selected {
        border-color: var(--dl-red);
        box-shadow: 0 0 0 1px var(--dl-red);
      }
      .lg-max {
        color: #79b743;
      }
      .lg-avg {
        color: #5aa9e6;
      }
      .e1rm-block-item input {
        width: 100%;
        padding: 8px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
        text-align: center;
        background: #1e1e20;
        color: var(--dl-text);
      }
      .e1rm-block-item input:focus {
        outline: none;
        border-color: var(--dl-red);
      }
      .hint-text {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        margin-bottom: 16px;
      }
      .block-opt {
        display: block;
        width: 100%;
        padding: 8px 12px;
        border: none;
        background: none;
        text-align: left;
        font-size: 13px;
        color: var(--dl-text);
        cursor: pointer;
      }
      .block-opt:hover {
        background: #232326;
      }
      .block-opt.active {
        color: var(--dl-red-text);
        font-weight: 600;
      }

      /* ─── Block-Setup Popup ─── */
      #block-setup-overlay {
        display: none;
        position: fixed;
        inset: 0;
        z-index: 500;
        background: rgba(0, 0, 0, 0.85);
        align-items: flex-end;
        justify-content: center;
      }
      #block-setup-overlay.open {
        display: flex;
      }
      #block-setup-panel {
        background: #111;
        border-radius: 20px 20px 0 0;
        width: 100%;
        max-width: 480px;
        max-height: 88vh;
        overflow-y: auto;
        padding-bottom: calc(32px + env(safe-area-inset-bottom));
      }
      .bsp-handle {
        width: 36px;
        height: 4px;
        background: #333;
        border-radius: 2px;
        margin: 12px auto 0;
      }
      .bsp-header {
        padding: 16px 20px 10px;
        border-bottom: 1px solid #1e1e1e;
      }
      .bsp-title {
        font-size: 18px;
        font-weight: 700;
        color: white;
        letter-spacing: -0.02em;
      }
      .bsp-subtitle {
        font-size: 12px;
        color: rgba(255, 255, 255, 0.55);
        margin-top: 3px;
      }
      .bsp-tag {
        padding: 10px 20px 4px;
        font-size: 10px;
        font-weight: 700;
        color: var(--dl-red-text);
        text-transform: uppercase;
        letter-spacing: 0.08em;
        margin-top: 8px;
      }
      .bsp-row {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 8px 20px;
        border-bottom: 1px solid #1a1a1a;
      }
      .bsp-label {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.6);
        min-width: 110px;
        flex-shrink: 0;
        line-height: 1.3;
      }
      .bsp-select {
        flex: 1;
        min-width: 0;
        max-width: 100%;
        padding: 8px 10px;
        background: #1e1e1e;
        border: 1px solid #2a2a2a;
        border-radius: 8px;
        color: white;
        font-size: 12px;
      }
      .bsp-select:focus {
        outline: none;
        border-color: var(--dl-red);
      }
      .bsp-btn {
        margin: 16px 20px 0;
        width: calc(100% - 40px);
        padding: 14px;
        background: var(--dl-cta);
        color: white;
        border: none;
        border-radius: 10px;
        font-size: 15px;
        font-weight: 700;
        cursor: pointer;
      }
      .bsp-btn:active {
        filter: brightness(0.9);
      }
      .bsp-skip {
        display: block;
        width: 100%;
        padding: 10px;
        background: none;
        border: none;
        color: rgba(255, 255, 255, 0.3);
        font-size: 13px;
        cursor: pointer;
        margin-top: 4px;
      }
      .bsp-hint {
        margin: 12px 20px 4px;
        padding: 10px 12px;
        background: rgba(230, 57, 70, 0.12);
        border: 1px solid rgba(230, 57, 70, 0.35);
        border-radius: 8px;
        font-size: 12px;
        color: rgba(255, 255, 255, 0.7);
        line-height: 1.4;
      }
      .ov-ue-block {
        margin-bottom: 16px;
      }
      .ov-ue-block-title {
        font-size: 11px;
        font-weight: 700;
        color: #888;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        margin-bottom: 8px;
        padding-bottom: 6px;
        border-bottom: 1px solid #f0f0f0;
      }
      .ov-ue-row {
        display: flex;
        align-items: center;
        gap: 8px;
        margin-bottom: 8px;
      }
      .ov-ue-label {
        font-size: 11px;
        color: #555;
        min-width: 120px;
        flex-shrink: 0;
        line-height: 1.3;
      }
      .ov-ue-select {
        flex: 1;
        padding: 7px 8px;
        border: 1px solid #e0e0e0;
        border-radius: 8px;
        font-size: 12px;
        background: #f8f8f8;
        color: #1a1a1a;
        cursor: pointer;
      }
      .ov-ue-select:focus {
        outline: none;
        border-color: var(--dl-red);
      }

      /* ─── Speichern-Button im Detail ─── */
      .ued-save-btn {
        margin: 12px 20px 0;
        width: calc(100% - 40px);
        padding: 14px;
        background: var(--dl-cta);
        color: white;
        border: none;
        border-radius: 10px;
        font-size: 15px;
        font-weight: 700;
        cursor: pointer;
        letter-spacing: 0.02em;
      }
      .ued-save-btn:active {
        filter: brightness(0.9);
      }
      #overview-page {
        display: block;
      }
      #training-page {
        display: none;
      }
      .ov-header {
        background: var(--dl-black);
        color: white;
        padding: calc(20px + env(safe-area-inset-top)) 20px 16px;
      }
      .ov-logo {
        font-size: 11px;
        font-weight: 700;
        color: var(--dl-red-text);
        letter-spacing: 0.08em;
        text-transform: uppercase;
        margin-bottom: 4px;
      }
      .ov-title {
        font-size: 22px;
        font-weight: 700;
      }
      .ov-subtitle {
        font-size: 13px;
        color: rgba(255, 255, 255, 0.6);
        margin-top: 2px;
      }
      .ov-section {
        background: var(--dl-card);
        margin: 12px 16px;
        border-radius: 12px;
        padding: 16px;
        border: 1px solid var(--dl-border);
      }
      .ov-section-title {
        font-size: 11px;
        font-weight: 700;
        color: var(--dl-red-text);
        text-transform: uppercase;
        letter-spacing: 0.08em;
        margin-bottom: 12px;
      }
      .ov-date-row {
        display: flex;
        align-items: center;
        gap: 12px;
      }
      .ov-date-row label {
        font-size: 13px;
        color: var(--dl-muted);
        white-space: nowrap;
      }
      .ov-date-input {
        flex: 1;
        padding: 10px 12px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
        color: var(--dl-text);
        background: #1e1e20;
      }
      .ov-date-input:focus {
        outline: none;
        border-color: var(--dl-red);
      }
      .ov-e1rm-grid {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 10px;
        margin-bottom: 4px;
      }
      .ov-e1rm-item label {
        display: block;
        font-size: 11px;
        color: rgba(255, 255, 255, 0.5);
        margin-bottom: 4px;
      }
      .ov-e1rm-item input {
        width: 100%;
        padding: 8px;
        border: 1px solid #2e2e32;
        border-radius: 8px;
        font-size: 15px;
        font-weight: 700;
        text-align: center;
        background: #1e1e20;
        color: var(--dl-text);
        box-sizing: border-box;
      }
      .ov-e1rm-item input:focus {
        outline: none;
        border-color: var(--dl-red);
      }
      .ov-rund-grid {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 10px;
      }
      .ov-rund-item label {
        display: block;
        font-size: 11px;
        color: rgba(255, 255, 255, 0.5);
        margin-bottom: 4px;
      }
      .ov-timeline {
        margin-top: 4px;
      }
      .ov-phase {
        display: flex;
        align-items: flex-start;
        gap: 12px;
        padding: 10px 0;
        border-bottom: 1px solid var(--dl-border);
      }
      .ov-phase:last-child {
        border-bottom: none;
      }
      .ov-phase:hover {
        background: rgba(230, 57, 70, 0.07);
        border-radius: 8px;
      }
      .ov-phase-dot {
        width: 10px;
        height: 10px;
        border-radius: 50%;
        background: #3a3a3e;
        margin-top: 4px;
        flex-shrink: 0;
      }
      .ov-phase-dot.red {
        background: var(--dl-red-strong);
      }
      .ov-phase-dot.current {
        background: var(--dl-red-strong);
        box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.25);
      }
      .ov-phase-info {
        flex: 1;
      }
      .ov-phase-name {
        font-size: 13px;
        font-weight: 600;
        color: var(--dl-text);
      }
      .ov-phase-dates {
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        margin-top: 2px;
      }
      .ov-phase-badge {
        font-size: 10px;
        padding: 2px 8px;
        border-radius: 10px;
        background: #232326;
        color: rgba(255, 255, 255, 0.6);
        align-self: flex-start;
        margin-top: 2px;
        white-space: nowrap;
      }
      .ov-phase-badge.wk {
        background: rgba(230, 57, 70, 0.15);
        color: #f26670; /* auf rot getöntem Grund heller für ≥ 4,5:1 */
      }
      .ov-start-info {
        font-size: 12px;
        color: rgba(255, 255, 255, 0.5);
        text-align: center;
        margin-top: 8px;
      }
      .ov-start-btn {
        display: block;
        width: calc(100% - 32px);
        margin: 16px 16px calc(32px + env(safe-area-inset-bottom));
        padding: 16px;
        background: var(--dl-cta);
        color: white;
        border: none;
        border-radius: 12px;
        font-size: 16px;
        font-weight: 700;
        cursor: pointer;
        letter-spacing: 0.02em;
      }
      .ov-start-btn:active {
        filter: brightness(0.9);
      }
      .ov-back-btn {
        background: none;
        border: none;
        color: rgba(255, 255, 255, 0.8);
        font-size: 13px;
        cursor: pointer;
        padding: 0;
        display: flex;
        align-items: center;
        gap: 4px;
      }
      .ov-backup-row {
        display: flex;
        gap: 10px;
      }
      .ov-backup-btn {
        flex: 1;
        padding: 12px;
        background: #232326;
        color: #e8e8ea;
        border: 1px solid #2e2e32;
        border-radius: 10px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
      }
      .ov-backup-btn:active {
        background: #2c2c30;
      }
      .ov-feedback-btn {
        display: block;
        width: 100%;
      }
      .ov-footer {
        text-align: center;
        font-size: 12px;
        color: rgba(255, 255, 255, 0.55);
        padding: 0 16px calc(24px + env(safe-area-inset-bottom));
        margin-top: -16px;
      }
      .ov-footer a {
        color: rgba(255, 255, 255, 0.55);
        text-decoration: none;
      }
      .ov-footer a:active {
        color: var(--dl-red-text);
      }
      /* Coaching-Hinweis liegt über dem Block-Setup-Panel (z-index 500) */
      #overlay-coaching {
        z-index: 600;
      }
      .coaching-gains {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        margin: 4px 0 14px;
      }
      .coaching-gain {
        padding: 5px 10px;
        border-radius: 999px;
        background: rgba(230, 57, 70, 0.14);
        color: var(--dl-text);
        font-size: 12.5px;
        font-weight: 600;
      }
      .ov-backup-status {
        margin-top: 10px;
        font-size: 12px;
        color: rgba(255, 255, 255, 0.6);
        text-align: center;
      }
      .ov-backup-status.is-due {
        color: var(--dl-red-text);
      }
      /* Hinweis „Zum Home-Bildschirm" (nur Handy-Browser) */
      .ov-install {
        border-color: rgba(230, 57, 70, 0.45);
      }
      .ov-install-title {
        font-size: 15px;
        font-weight: 700;
        color: var(--dl-text);
        margin-bottom: 6px;
      }
      .ov-install-text {
        font-size: 13px;
        line-height: 1.45;
        color: var(--dl-muted);
      }
      .ov-install-steps {
        margin: 10px 0 0 18px;
        font-size: 13px;
        line-height: 1.6;
        color: var(--dl-text);
      }
      .ov-install-steps:empty {
        display: none;
      }
      .ov-install-btn {
        margin: 12px 0 0;
      }
      .ov-install-later {
        display: block;
        margin: 8px 0 0 auto;
        padding: 6px 4px;
        background: none;
        border: none;
        font-size: 13px;
        color: rgba(255, 255, 255, 0.5);
        cursor: pointer;
      }
      .ov-backup-hint {
        margin-top: 10px;
        font-size: 11px;
        color: rgba(255, 255, 255, 0.55);
        text-align: center;
      }
      .ov-reset-btn {
        display: block;
        width: 100%;
        margin-top: 14px;
        padding: 12px;
        background: transparent;
        color: var(--dl-red-text);
        border: 1px solid var(--dl-red);
        border-radius: 10px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
      }
      .ov-reset-btn:active {
        background: rgba(230, 57, 70, 0.12);
      }
