*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #f5f5f7;
    color: #222;
}

header {
    padding: 10px 20px;
    border-bottom: 1px solid #ddd;
    background: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

header .right {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    color: #555;
}

button.primary {
    padding: 6px 14px;
    border-radius: 6px;
    border: none;
    background: #2563eb;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    font-size: 13px;
}

button.primary:disabled {
    opacity: 0.5;
    cursor: default;
}

.status {
    font-size: 12px;
    color: #555;
}

.container {
    max-width: 1180px;
    margin: 14px auto 40px;
    padding: 0 16px;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 12px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #ddd;
    margin-bottom: 12px;
    align-items: center;
}

.filter-group {
    display: flex;
    flex-direction: column;
    font-size: 12px;
    color: #555;
}

.filter-group input,
.filter-group textarea {
    margin-top: 2px;
    padding: 4px 6px;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-size: 13px;
    min-width: 180px;
}

.filter-group textarea {
    min-width: 260px;
    resize: vertical;
}

.filter-actions {
    display: flex;
    gap: 6px;
    margin-left: auto;
    align-items: center;
}

.filter-actions button {
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    background: #f8f8f8;
    cursor: pointer;
    font-size: 13px;
}

.filter-actions button.primary {
    border: none;
    background: #2563eb;
    color: #fff;
}

.card {
    border-radius: 10px;
    border: 1px solid #e3e3e3;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    margin-bottom: 10px;
}

.card.missing-required {
    border-color: #ef4444;
    box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.25);
}

/* --- Kopfzeile (kompakte Listenansicht) --- */
.card-header-row {
    display: grid;
    grid-template-columns: 80px minmax(0, 1fr) auto;
    column-gap: 12px;
    padding: 8px 12px;
    align-items: center;
    cursor: pointer;
}

.card-header-row:hover {
    background: #f9fafb;
}

.card-thumb {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-thumb img {
    max-width: 64px;
    max-height: 64px;
    border-radius: 6px;
    border: 1px solid #eee;
    object-fit: contain;
    background: #fafafa;
}

.card-thumb .placeholder {
    width: 64px;
    height: 64px;
    border-radius: 6px;
    border: 1px dashed #bbb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #aaa;
    background: #fafafa;
}

.card-header-main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ebay-title-input {
    width: 100%;
    padding: 5px 7px;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 13px;
}

.ebay-title-input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.25);
}

.card-meta-line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #6b7280;
}

.asin-link {
    font-weight: 600;
    color: #2563eb;
    text-decoration: none;
}

.asin-link:hover {
    text-decoration: underline;
}

.meta-pill {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 999px;
    background: #f1f5f9;
    font-size: 11px;
    color: #374151;
}

.meta-pill.brand-missing {
    border-color: #dc2626;
    color: #b91c1c;
    background: #fef2f2;
}

.note-btn {
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    font-size: 11px;
    padding: 2px 8px;
    cursor: pointer;
}

.note-btn.has-notes {
    border-color: #34d399;
    background: #ecfdf3;
    color: #065f46;
}

.brand-edit-btn {
    width: 22px;
    height: 22px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* kleines, neutrales Icon (schwarz/monochrom) */
.brand-edit-btn::before {
    content: "↗";
    /* alternativ z.B. "B" oder "◆" */
    font-size: 12px;
}


/* --- Notiz-Popup direkt am Button --- */
.note-popup {
    position: absolute;
    z-index: 9999;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    padding: 10px;
    width: 220px;
    border: 1px solid #e0e0e0;
    animation: fadeInScale 0.1s ease-out;
}

.note-popup textarea {
    width: 100%;
    height: 60px;
    font-size: 13px;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 6px;
    outline: none;
    resize: none;
}

.note-popup .note-save-btn {
    margin-top: 8px;
    width: 100%;
    padding: 6px 0;
    background: #4caf50;
    border: none;
    border-radius: 6px;
    color: white;
    cursor: pointer;
    font-size: 13px;
}

.note-popup:after {
    content: "";
    position: absolute;
    top: -8px;
    left: 14px;
    border-width: 0 8px 8px 8px;
    border-style: solid;
    border-color: transparent transparent #ffffff transparent;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}


.card-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    font-size: 11px;
}

.char-counter {
    font-size: 11px;
    color: #666;
    white-space: nowrap;
}

.cat-pill {
    padding: 2px 8px;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    font-size: 11px;
    color: #374151;
}

.delete-btn {
    padding: 2px 8px;
    font-size: 11px;
    border-radius: 999px;
    border: 1px solid #dc2626;
    background: #fef2f2;
    color: #b91c1c;
    cursor: pointer;
}

/* --- Detailbereich (Tabs + Inhalt) --- */
.card-details {
    border-top: 1px solid #e5e7eb;
    padding: 8px 12px 10px;
    display: none;
}

.tabs {
    display: flex;
    gap: 6px;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 8px;
}

.tab-btn {
    padding: 4px 10px;
    font-size: 12px;
    border-radius: 999px 999px 0 0;
    border: 1px solid transparent;
    border-bottom: none;
    background: transparent;
    cursor: pointer;
    color: #6b7280;
}

.tab-btn.active {
    border-color: #e5e7eb;
    border-bottom-color: #fff;
    background: #fff;
    color: #111827;
    font-weight: 500;
}

.tab-content {
    display: none;
    padding-top: 4px;
    font-size: 13px;
}

.tab-content.active {
    display: block;
}

.field-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #9ca3af;
    margin-bottom: 2px;
}

.amazon-title {
    font-size: 13px;
    color: #4b5563;
    background: #f9fafb;
    padding: 6px 8px;
    border-radius: 6px;
    margin-bottom: 8px;
    max-height: 80px;
    overflow-y: auto;
}

.field-row {
    margin-bottom: 6px;
}

.field-row.small {
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr);
    column-gap: 8px;
    align-items: center;
}

.field-row.small input {
    width: 100%;
}

.field-row input[type="text"] {
    padding: 5px 7px;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 13px;
    width: 100%;
}

.field-row input[type="text"]:focus {
    outline: none;
    border-color: #ff8c00;
    box-shadow: 0 0 0 1px rgba(255, 140, 0, 0.25);
}

.category-path {
    padding: 6px 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 13px;
    white-space: nowrap;
    overflow-x: auto;
    width: 100%;
}

.cat-non-leaf {
    border-color: #ff4d4f !important;
    background-color: #ffecec !important;
}

.cat-non-leaf-hint {
    color: #c00000;
    font-size: 12px;
    margin-top: 4px;
}

.cat-suggestions {
    margin-top: 3px;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    max-height: 130px;
    overflow-y: auto;
    background: #ffffff;
    font-size: 12px;
    display: none;
}

.cat-item {
    padding: 4px 7px;
    cursor: pointer;
}

.cat-item:hover {
    background: #eff6ff;
}

.cat-item .cat-id {
    font-weight: 600;
    margin-right: 6px;
}

/* --- Item-Specifics --- */
.item-specifics-container {
    margin-top: 4px;
    font-size: 12px;
    color: #374151;
}

.spec-group {
    margin-top: 4px;
}

.spec-row {
    display: grid;
    grid-template-columns: 140px minmax(0, 1fr) 24px 24px;
    column-gap: 6px;
    align-items: center;
    margin-top: 3px;
}

.spec-row.spec-new-row {
    grid-template-columns: 140px minmax(0, 1fr) minmax(0, 1fr) 24px 24px;
}

.spec-name {
    font-size: 12px;
    color: #374151;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.spec-input {
    padding: 4px 6px;
    border-radius: 5px;
    border: 1px solid #d1d5db;
    font-size: 12px;
    width: 100%;
}

.spec-input:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.25);
}

.spec-btn {
    width: 22px;
    height: 22px;
    border-radius: 4px;
    border: 1px solid #d1d5db;
    background: #f9fafb;
    cursor: pointer;
    padding: 0;
    position: relative;
}

.spec-btn::before {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -55%);
    font-size: 13px;
}

.spec-btn.spec-save::before {
    content: "💾";
}

.spec-btn.spec-delete::before {
    content: "🗑";
}

.spec-missing .spec-input {
    border-color: #f97316;
    background: #fff7ed;
}

.images-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.image-thumb {
    position: relative;
    width: 210px;
    height: 210px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fafafa;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: move;
}

.image-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.image-thumb .img-delete-btn {
    position: absolute;
    top: 3px;
    right: 3px;
    width: 18px;
    height: 18px;
    border: none;
    border-radius: 999px;
    background: #ef4444;
    color: #fff;
    font-size: 11px;
    cursor: pointer;
}

/* „Add Image“-Kachel */
.image-thumb.image-add {
    cursor: pointer;
    border-style: dashed;
    color: #6b7280;
    flex-direction: column;
    gap: 4px;
}

.image-thumb.image-add span.plus {
    font-size: 20px;
    line-height: 1;
}

.image-thumb.image-add span.add-text {
    font-size: 11px;
}

.image-thumb.drag-over {
    outline: 2px dashed #2563eb;
}

.img-popup {
    position: fixed;
    z-index: 9999;
    background: #fff;
    padding: 10px;
    width: 240px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.img-popup.hidden {
    display: none;
}

#imageUrlInput {
    width: 100%;
    min-height: 70px;
    font-size: 13px;
    padding: 5px;
    resize: vertical;
}

.img-popup-buttons {
    display: flex;
    justify-content: space-between;
    gap: 6px;
}

.img-popup-cancel,
.img-popup-save {
    flex: 1;
    border: none;
    padding: 6px;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
}

.img-popup-cancel {
    background: #e5e7eb;
    color: #374151;
}

.img-popup-save {
    background: #22c55e;
    color: white;
}

/* Beschreibung / Editor */
.desc-toolbar {
    display: flex;
    gap: 4px;
    margin-bottom: 4px;
}

.desc-btn {
    font-size: 12px;
    padding: 2px 6px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    background: #f9fafb;
    cursor: pointer;
}

.desc-btn:hover {
    background: #f3f4f6;
}

.desc-view-switch {
    display: inline-flex;
    gap: 4px;
    margin: 4px 0 6px;
}

.desc-view-btn {
    font-size: 11px;
    padding: 2px 8px;
    border: 1px solid #d1d5db;
    border-radius: 9999px;
    background: #f9fafb;
    cursor: pointer;
}

.desc-view-btn.active {
    background: #111827;
    color: #fff;
    border-color: #111827;
}

.desc-editor {
    border-radius: 6px;
    padding: 6px;
    background: #f9fafb;
}

.desc-visual,
.desc-html {
    width: 100%;
    min-height: 200px;
    box-sizing: border-box;
    font-size: 13px;
    font-family: Arial, sans-serif;
}


.desc-visual {
    outline: none;
}

.desc-html {
    resize: vertical;
    font-family: Consolas, Menlo, Monaco, "Courier New", monospace;
}

.hidden {
    display: none !important;
}

/* ⬇️ CKEditor Warnung ausblenden */
.cke_notification,
.cke_notifications_area {
    display: none !important;
}

/* Gesamt-Layout: Sidebar links, Inhalt rechts */
.layout-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

/* Linke Spalte */
.settings-sidebar {
    width: 260px;
    background: #ffffff;
    border-radius: 16px;
    padding: 16px 14px;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
    position: sticky;
    top: 16px;
    /* bleibt beim Scrollen „kleben“ */
    align-self: flex-start;
}

/* Header in der Sidebar */
.settings-header {
    display: flex;
    flex-direction: column;
    margin-bottom: 12px;
}

.settings-title {
    font-weight: 600;
    font-size: 15px;
}

.settings-subtitle {
    font-size: 11px;
    color: #9ca3af;
}

/* Navigation in der Sidebar */
.settings-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
}

.settings-nav-item {
    border: none;
    background: transparent;
    padding: 6px 10px;
    border-radius: 10px;
    text-align: left;
    font-size: 13px;
    cursor: pointer;
    color: #4b5563;
    transition: background 0.15s ease, color 0.15s ease, transform 0.05s;
}

.settings-nav-item:hover {
    background: #f3f4f6;
    color: #111827;
}

.settings-nav-item--active {
    background: #2563eb0d;
    /* leichtes Blau, sehr dezent */
    color: #1d4ed8;
}

/* Box für den gewählten Bereich (z.B. Drafts) */
.settings-panel {
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    padding: 10px 12px;
    background: #f9fafb;
}

.settings-panel-title {
    font-size: 13px;
    font-weight: 600;
    margin: 0 0 4px;
}

.settings-panel-text {
    font-size: 12px;
    color: #6b7280;
    margin: 0;
}

/* Rechte Spalte: dein bisheriger Inhalt */
.content-area {
    flex: 1;
    min-width: 0;
    /* wichtig bei flex, damit nichts „überläuft“ */
}

.token-status-connected {
    font-weight: 600;
    margin-right: 8px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin: 16px 0 24px;
}

.settings-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
}

.settings-field select {
    min-width: 220px;
    padding: 4px 6px;
}

.token-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 999px;
    margin-right: 6px;
}

.token-dot-green {
    background-color: #28a745;
    /* grün */
}

.token-dot-red {
    background-color: #dc3545;
    /* rot */
}

.settings-shop-select {
    margin: 12px 0 20px;
}

.settings-shop-select label {
    margin-right: 8px;
    font-weight: 600;
}

.field-hint {
    font-size: 0.85rem;
    color: #666;
    margin-top: 4px;
}

.settings-actions {
    margin-top: 50px;
    text-align: right;
    padding-right: 300px;  
}

.settings-row {
    display: flex;
    gap: 16px;
    margin-bottom: 12px;
}

.settings-field {
    flex: 1;
    min-width: 0;
}

.settings-field input[type="text"],
.settings-field input[type="number"],
.settings-field select {
    width: 100%;
    max-width: 260px;
    box-sizing: border-box;
}

/* Toggle-Switch simpel & klar */

.toggle-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.toggle {
    position: relative;
    display: inline-block;
    width: 32px;
    height: 16px;
}

.toggle input {
    display: none;
}

.toggle-slider {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    background-color: #ddd;
    /* AUS: grau */
    border-radius: 999px;
    transition: background-color 0.2s ease;
}

/* der weiße Kreis */
.toggle-slider::before {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 0 2px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease;
}

/* AN: orange Spur + Kreis nach rechts */
.toggle input:checked+.toggle-slider {
    background-color: #f0a63a;
    /* AN: orange */
}

.toggle input:checked+.toggle-slider::before {
    transform: translateX(16px);
}

.toggle-text {
    font-weight: 600;
}

.product-settings-row {
    display: flex;
    gap: 20px;
    margin: 10px 0 15px;
}

.product-settings-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 4px;
}

.product-settings-field input,
.product-settings-field select {
    width: 150px;
    padding: 4px 6px;
    font-size: 13px;
}

.meta-pill{
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px;
  
    height: 20px;
    padding: 0 8px;
    box-sizing: border-box;
  }
  
  .meta-pill img{
    height: 14px;
    display: block;
  }
  
  .meta-pill .pill-code{
    display: inline-flex;
    align-items: center;
    justify-content: center;
  
    height: 20px;     /* = pill height */
    line-height: 20px;
    font-size: 12px;
  }
  
.toast-container{ position:fixed; top:18px; right:18px; z-index:9999; display:flex; flex-direction:column; gap:10px; }
.toast{ min-width:320px; max-width:520px; padding:12px 14px; border-radius:8px; background:#fff; box-shadow:0 8px 20px rgba(0,0,0,.12);
  display:grid; grid-template-columns:26px 1fr 26px; gap:10px; align-items:start; border:1px solid #e5e7eb; }
.toast-success{ border-left:4px solid #22c55e; }
.toast-error{ border-left:4px solid #ef4444; }
.toast-info{ border-left:4px solid #3b82f6; }
.toast-icon{ width:22px; height:22px; border-radius:999px; display:inline-flex; align-items:center; justify-content:center; font-weight:700; margin-top:1px; }
.toast-success .toast-icon{ background:#dcfce7; color:#166534; }
.toast-error .toast-icon{ background:#fee2e2; color:#991b1b; }
.toast-info .toast-icon{ background:#dbeafe; color:#1e40af; }
.toast-text{ font-size:13px; line-height:1.35; color:#111827; white-space:pre-wrap; word-break:break-word; }
.toast-close{ border:none; background:transparent; font-size:18px; line-height:18px; cursor:pointer; color:#6b7280; padding:0; }
.toast-close:hover{ color:#111827; }


/* --- Image Popup (wie Brandstore: Box + Pfeil) --- */
.img-popup{
    position: absolute;
    z-index: 9999;
    min-width: 260px;
    max-width: 420px;
    padding: 10px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.12);
    box-shadow: 0 10px 30px rgba(0,0,0,0.18);
  }
  
  /* Pfeil */
  .img-popup::before{
    content:"";
    position:absolute;
    width: 12px;
    height: 12px;
    background:#fff;
    border-left: 1px solid rgba(0,0,0,0.12);
    border-top: 1px solid rgba(0,0,0,0.12);
    transform: rotate(45deg);
  }
  
  /* Standard: Pfeil oben links (Popup unterhalb der Kachel) */
  .img-popup.arrow-top::before{
    top: -7px;
    left: 18px;
  }
  
  /* Alternative: Pfeil unten links (Popup oberhalb der Kachel) */
  .img-popup.arrow-bottom::before{
    bottom: -7px;
    left: 18px;
    transform: rotate(225deg);
  }
  
  .img-popup textarea{
    width: 100%;
    min-height: 70px;
    border-radius: 10px;
    border: 1px solid rgba(0,0,0,0.12);
    padding: 8px;
    resize: vertical;
  }
  
  .img-popup-buttons{
    display:flex;
    gap:10px;
    justify-content:flex-end;
    margin-top: 10px;
  }
  
  .img-popup-buttons button{
    border-radius: 10px;
    padding: 8px 12px;
  }
  
/* Einheitliche Titelleiste (Drafts + Products) */
.title-row{
    display:flex;
    align-items:center;
    gap:8px;
    width:100%;
  }
  
  .title-row .ebay-title-input{
    flex:1 1 auto;
    min-width:0;            /* wichtig für Flex, damit nichts rausdrückt */
  }
  
  .title-row .js-title-counter{
    min-width:64px;
    text-align:right;
    opacity:0.75;
    font-size:12px;
    white-space:nowrap;
  }
  
  /* AI Button kompakt + gleiches Verhalten überall */
  .ai-title-btn{
    border:none;
    background:transparent;
    width:34px;
    height:34px;
    padding:0;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    cursor:pointer;
  }
  
  .ai-title-btn img{
    width:18px;
    height:18px;
    display:block;
  }
  
  /* Header-Grid: Titel + Meta sollen immer über die ganze Textbreite laufen */
.card-header-row .title-row {
    grid-column: 2 / 4;   /* Text-Spalte + rechte Spalte */
  }
  
  .card-header-row .card-meta-line {
    grid-column: 2 / 4;   /* Meta-Zeile immer unter Titel, volle Breite */
  }
  
  .card-header-row .card-footer-line {
    grid-column: 3;       /* CatID/Löschen rechts belassen (falls vorhanden) */
  }
  

  /* CKEditor Fullscreen in Modals/Containers korrekt darstellen */
.cke {
    max-width: 980px; /* optional: wie bisher */
  }
  
  .cke_inner {
    background: #fff;
  }
  
  .cke_screen_reader_only { /* optional, verhindert komische Offsets in manchen Layouts */
    position: absolute !important;
  }
  
  /* Wichtig: Fullscreen muss über allem liegen */
  .cke.cke_reset.cke_chrome.cke_focus.cke_fullscreen,
  .cke.cke_fullscreen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 2147483647 !important;
  }
  
  /* Falls ein Parent den Editor clippt (overflow hidden/auto), neutralisieren */
  .tab-content,
  .card,
  .modal,
  .modal-content {
    overflow: visible;
  }
  
  /* ============================================================
   CKEditor4 Fullscreen: global robust (Drafts + Produkte + überall)
   Problem: Parent mit transform/overflow kann Fullscreen clippen.
   Lösung: Fullscreen immer fixed + oberstes z-index + Body scroll aus.
   ============================================================ */

/* Wenn CKEditor Fullscreen aktiv ist, keine Scrollbars im Hintergrund */
body.cke_editable.cke_editable_themed,
body.cke_ltr,
body.cke_rtl {
  overflow: hidden !important;
}

/* Fullscreen Container immer über allem, unabhängig vom Layout */
.cke.cke_fullscreen,
.cke.cke_reset.cke_chrome.cke_focus.cke_fullscreen {
  position: fixed !important;
  inset: 0 !important;            /* top/left/right/bottom = 0 */
  width: 100vw !important;
  height: 100vh !important;
  z-index: 2147483647 !important;
}

/* Editor-Inhalte und Toolbar sauber skalieren */
.cke.cke_fullscreen .cke_inner,
.cke.cke_fullscreen .cke_contents {
  height: calc(100vh - 40px) !important;  /* Toolbar-Puffer */
}

/* Verhindert Clipping durch "moderne UI" Wrapper (falls transform/overflow gesetzt) */
html, body {
  transform: none !important;
}
