/* Streaming Toggle Button */
#nwf-stream-toggle {
    padding: 8px 12px;
    border-radius: 4px 0 0 4px;
    border: 1px solid #ddd;
    background-color: #fff;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 5px;
    font-weight: bold;
}

#nwf-stream-toggle.active {
    background-color: #e0e0e1;
}

#nwf-stream-toggle.active .stream-text {
    color: #333;
}

.stream-text {
    position: relative;
    font-size: 16px;
}

#nwf-stream-toggle.active .stream-text::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 2px;
    background-color: #666;
    transform: rotate(-45deg);
}

#nwf-stream-toggle:hover {
    background-color: #f5f5f5;
}

#nwf-stream-toggle.active:hover {
    background-color: #555;
}

body.dark-mode #nwf-stream-toggle {
    background-color: #444;
    border-color: #444;
    color: #fff;
}

body.dark-mode #nwf-stream-toggle:hover {
    background-color: #555;
}

body.dark-mode #nwf-stream-toggle.active {
    background-color: #666;
}

body.dark-mode #nwf-stream-toggle.active .stream-text {
    color: #999;
}

body.dark-mode #nwf-stream-toggle.active .stream-text::after {
    background-color: #fff;
    height: 2.5px;
}

body.dark-mode #nwf-stream-toggle.active:hover {
    background-color: #777;
}

body.dark-mode #nwf-stream-toggle {
    background-color: #444;
    border-color: #444;
    color: #fff;
}

body.dark-mode #nwf-stream-toggle.active {
    background-color: #666;
    color: #fff;
}

body.dark-mode #nwf-stream-toggle.active .stream-text::after {
    background-color: #fff;
}

body.dark-mode #nwf-stream-toggle:hover {
    background-color: #555;
}

body.dark-mode #nwf-stream-toggle.active:hover {
    background-color: #777;
}

/* Button Layout */
.nwf-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.nwf-ai-buttons-container {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    flex: 1;
}

.nwf-control-group {
    display: flex;
    gap: 0;
    margin-left: auto;
}

.nwf-control-group button {
    margin: 0;
}

/* Container und Basis-Layout */
.nwf-container {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 20px;
    margin: 20px 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    transition: all 0.3s ease-in-out;
}

/* Input Container und Textarea */
.nwf-input-container {
    position: relative;
    width: 100%;
    margin-bottom: 15px;
}

.nwf-textarea {
    width: 100%;
    min-height: 250px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 10px;
    font-family: inherit;
    font-size: 16px;
    line-height: 1.5;
    resize: vertical;
    transition: border-color 0.2s ease;
    background-color: #fff;
    color: #333;
    transition: all 0.3s ease-in-out;
}

.nwf-textarea:focus {
    border-color: #666;
    box-shadow: 0 0 0 1px #666;
    outline: none;
}

/* Paste Button */
.nwf-paste-button {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 1;
    transition: opacity 0.2s ease;
    padding: 12px 24px;
    background-color: rgba(255, 255, 255, 0.95);
    border: 2px solid #666;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    z-index: 10;
    -webkit-font-smoothing: antialiased;
}

.nwf-paste-button:hover {
    background-color: #666;
    color: white;
    transform: translate(-50%, -50%) scale(1.05);
}

.nwf-paste-button .paste-icon {
    font-size: 20px;
}

/* Button ausblenden wenn Textarea fokussiert ist oder Text enthält */
.nwf-textarea:not(:placeholder-shown) ~ .nwf-paste-button,
.nwf-textarea:focus ~ .nwf-paste-button {
    opacity: 0;
    pointer-events: none;
}

/* Controls Layout */
.nwf-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    position: relative;
    padding: 0;
}

.nwf-left-controls {
    display: flex;
    gap: 5px;
    padding: 0;
    margin: 0;
}

.nwf-center-controls {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.nwf-right-controls {
    margin-left: auto;
    display: flex;
    gap: 5px;
    align-items: center;
}

/* Text-Kontrollbereich */
.nwf-text-controls {
    display: flex;
    gap: 5px;
    margin-bottom: 15px;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}

.nwf-left-controls {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.nwf-transcribe-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    color: #666 !important;
    background: transparent !important;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    line-height: 1.4;
    position: relative;
}

.nwf-transcribe-button.processing {
    background-color: #f0f0f0 !important;
    cursor: not-allowed;
}

.nwf-transcribe-button.processing::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    border: 2px solid #666;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: translateY(-50%) rotate(360deg);
    }
}

.nwf-transcribe-button:hover {
    background: #e0e0e1;
    border-color: #666;
    transform: translateY(-1px);
}

.nwf-transcribe-button .button-icon {
    font-size: 16px;
}

/* Theme Switch spezifische Styles mit höherer Spezifität */
.nwf-container .nwf-theme-switch,
.nwf-container .nwf-theme-switch:focus,
.nwf-container .nwf-theme-switch:active {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 8px !important;
    border-radius: 4px !important;
    border: 1px solid #ddd !important;
    background-color: #f5f5f5 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    outline: none !important;
    box-shadow: none !important;
    color: inherit !important;
    transition: all 0.3s ease-in-out;
}

/* Dark Mode Styles mit höherer Spezifität */
body.dark-mode .nwf-container .nwf-theme-switch,
body.dark-mode .nwf-container .nwf-theme-switch:focus,
body.dark-mode .nwf-container .nwf-theme-switch:active {
    background-color: #333333 !important;
    border-color: #404040 !important;
    color: #e0e0e0 !important;
}

/* Hover Styles */
.nwf-container .nwf-theme-switch:hover {
    background-color: #e8e8e8 !important;
}

body.dark-mode .nwf-container .nwf-theme-switch:hover {
    background-color: #404040 !important;
}

/* Icon Styles */
.nwf-container .nwf-theme-switch svg {
    width: 20px !important;
    height: 20px !important;
    fill: currentColor !important;
}

/* Theme Switch Icon Styles */
.nwf-theme-switch .theme-icon {
    width: 20px !important;
    height: 20px !important;
}

.nwf-theme-switch .sun-icon {
    opacity: 1;
    fill: currentColor;
}

.nwf-theme-switch .moon-icon {
    opacity: 0;
    fill: currentColor;
}

body.dark-mode .nwf-theme-switch .sun-icon {
    opacity: 0;
}

body.dark-mode .nwf-theme-switch .moon-icon {
    opacity: 1;
}

/* Animation für den Icon-Wechsel */
.nwf-theme-switch .sun-icon,
.nwf-theme-switch .moon-icon {
    transition: opacity 0.2s ease-in-out;
}

/* Entferne alle WordPress/Astra Standard-Styles */
.nwf-container .nwf-theme-switch,
.nwf-container .nwf-theme-switch:focus,
.nwf-container .nwf-theme-switch:active {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background-image: none !important;
}

/* KI-Funktionsbuttons Container */
.nwf-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin: 15px 0;
}

.nwf-ai-buttons-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* Basis-Button-Styles */
.nwf-container .nwf-button,
.nwf-container .nwf-control-button {
    padding: 6px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f0f0f1;
    color: #3c434a;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    line-height: 1.4;
    height: auto;
    white-space: nowrap;
    transition: all 0.3s ease-in-out;
}

/* Button-Zustände */
.nwf-container .nwf-button:hover,
.nwf-container .nwf-control-button:hover:not(:disabled) {
    background: #e0e0e1;
    border-color: #666;
    transform: translateY(-1px);
}

.nwf-container .nwf-button:focus,
.nwf-container .nwf-control-button:focus {
    outline: none;
    border-color: #666;
}

.nwf-container .nwf-button.active,
.nwf-container .nwf-control-button.active {
    background: #666;
    border-color: #444;
    color: #fff;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
    transform: translateY(1px);
}

.nwf-container .nwf-control-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Untere Kontroll-Buttons (Pin und Stream) */
.nwf-pin-button,
#nwf-stream-toggle {
    position: relative;
    padding: 8px;
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    background-color: #fff !important;
    color: #666 !important;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    outline: none !important;
    box-shadow: none !important;
    border-radius: 4px;
}

/* Tooltips für die Buttons */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 8px;
    background-color: rgba(0, 0, 0, 0.8);
    color: white;
    font-size: 12px;
    white-space: nowrap;
    border-radius: 4px;
    pointer-events: none;
    opacity: 0;
    z-index: 1000;
}

/* Kleiner Pfeil unter dem Tooltip */
[data-tooltip]::before {
    content: '';
    position: absolute;
    bottom: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%) translateY(100%);
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid rgba(0, 0, 0, 0.8);
    opacity: 0;
    pointer-events: none;
    z-index: 1000;
}

/* Sofortiges Einblenden beim Hover */
[data-tooltip]:hover::before,
[data-tooltip]:hover::after {
    opacity: 1;
}

/* Hover-Effekte im hellen Modus */
.nwf-pin-button:hover,
#nwf-stream-toggle:hover {
    background-color: #f5f5f5 !important;
    border-color: #ccc;
}

/* Aktiver Zustand im hellen Modus */
.nwf-pin-button.active,
#nwf-stream-toggle.active {
    background-color: #e0e0e1 !important;
    border-color: #999;
    color: #333 !important;
}

/* Dark Mode Styles */
body.dark-mode .nwf-pin-button,
body.dark-mode #nwf-stream-toggle {
    background-color: #444 !important;
    border-color: #555 !important;
    color: #fff !important;
}

/* Dark Mode Hover */
body.dark-mode .nwf-pin-button:hover,
body.dark-mode #nwf-stream-toggle:hover {
    background-color: #555 !important;
    border-color: #666 !important;
}

/* Dark Mode Active */
body.dark-mode .nwf-pin-button.active,
body.dark-mode #nwf-stream-toggle.active {
    background-color: #666 !important;
    border-color: #777 !important;
    color: #fff !important;
}

.nwf-pin-button:hover {
    background-color: #f5f5f5 !important;
    border-color: #ddd;
    color: #666 !important;
}

.nwf-pin-button:focus {
    outline: none !important;
    box-shadow: none !important;
}

.nwf-pin-button.active {
    background-color: #e0e0e1 !important;
    border-color: #999;
    color: #333 !important;
}

.nwf-pin-button.active:hover {
    background-color: #e8e8e8 !important;
    border-color: #666;
}

.nwf-pin-button.active:focus {
    background-color: #e0e0e1 !important;
    border-color: #999;
    color: #333 !important;
}

/* Indikator-Lämpchen */
.nwf-pin-button .indicator {
    content: '';
    position: absolute;
    top: 4px;
    left: 4px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: transparent;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 0 2px rgba(0,0,0,0.3);
    pointer-events: none;
}

.nwf-pin-button.active .indicator {
    background-color: #ff3b30;
    box-shadow: 0 0 4px #ff3b30;
}

/* Pin-Button im Dark Mode */
body.dark-mode .nwf-pin-button {
    background-color: #444 !important;
    border: 1px solid #444 !important;
    color: #fff !important;
}

body.dark-mode .nwf-pin-button:hover {
    background-color: #555 !important;
    border-color: #555 !important;
}

body.dark-mode .nwf-pin-button.active {
    background-color: #666 !important;
    border-color: #666 !important;
    color: #fff !important;
}

/* Output-Bereich */
.nwf-output-area {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.nwf-output,
#nwf-output,
#nwf-output.nwf-output,
textarea.nwf-output {
    width: 100% !important;
    height: 250px !important;
    min-height: 250px !important;
    padding: 15px !important;
    background-color: #ffffff !important;
    border: 1px solid #ddd !important;
    border-radius: 4px !important;
    color: #333 !important;
    font-size: inherit !important;
    line-height: 1.5 !important;
    resize: vertical !important;
    box-sizing: border-box !important;
}

body.dark-mode .nwf-output,
body.dark-mode #nwf-output,
body.dark-mode #nwf-output.nwf-output,
body.dark-mode textarea.nwf-output,
body.dark-mode .nwf-container .nwf-output,
body.dark-mode #nwf-output-area .nwf-output {
    background-color: #4A4A4A !important;
    color: #ffffff !important;
    border-color: #505050 !important;
}

/* Button Container */
.nwf-button-container {
    display: flex;
    gap: 10px;
    margin-top: 5px;
}

/* Kopieren-Button Basis */
.nwf-copy-button,
button.nwf-copy-button,
.nwf-container button.nwf-copy-button,
.nwf-copy-button:active,
button.nwf-copy-button:active,
.nwf-container button.nwf-copy-button:active {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background-color: #f0f0f0 !important;
    border: 1px solid #ddd !important;
    border-radius: 4px;
    color: #333 !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

/* Hover-Zustand */
.nwf-copy-button:hover,
button.nwf-copy-button:hover,
.nwf-container button.nwf-copy-button:hover,
.nwf-copy-button:active,
button.nwf-copy-button:active,
.nwf-container button.nwf-copy-button:active {
    background-color: #e0e0e0 !important;
    border-color: #ccc !important;
}

/* Dark Mode */
body.dark-mode .nwf-copy-button,
body.dark-mode button.nwf-copy-button,
body.dark-mode .nwf-container button.nwf-copy-button,
body.dark-mode .nwf-copy-button:active,
body.dark-mode button.nwf-copy-button:active,
body.dark-mode .nwf-container button.nwf-copy-button:active {
    background-color: #404040 !important;
    color: #ffffff !important;
    border-color: #505050 !important;
}

/* Dark Mode Hover */
body.dark-mode .nwf-copy-button:hover,
body.dark-mode button.nwf-copy-button:hover,
body.dark-mode .nwf-container button.nwf-copy-button:hover,
body.dark-mode .nwf-copy-button:active,
body.dark-mode button.nwf-copy-button:active,
body.dark-mode .nwf-container button.nwf-copy-button:active {
    background-color: #505050 !important;
    border-color: #606060 !important;
}

/* Success Zustand - beide Modi */
.nwf-copy-button.nwf-copy-success,
button.nwf-copy-button.nwf-copy-success,
.nwf-container button.nwf-copy-button.nwf-copy-success,
#nwf-copy.nwf-copy-success {
    background-color: #e0e0e0 !important;
    border-color: #ccc !important;
    color: #333 !important;
}

body.dark-mode .nwf-copy-button.nwf-copy-success,
body.dark-mode button.nwf-copy-button.nwf-copy-success,
body.dark-mode .nwf-container button.nwf-copy-button.nwf-copy-success,
body.dark-mode #nwf-copy.nwf-copy-success {
    background-color: #505050 !important;
    border-color: #606060 !important;
    color: #ffffff !important;
}

/* Copy-Buttons */
.nwf-copy-button {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 4px;
    background: transparent !important;
    border: none;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.3s ease;
    color: #666 !important;
}

.nwf-copy-button:hover {
    opacity: 1;
    transform: scale(1.1);
}

.nwf-copy-button.copied {
    opacity: 1;
    color: #2ea043 !important;
    transform: scale(1.2);
}

.nwf-copy-button svg {
    display: block;
    stroke: currentColor;
}

/* Unterer Copy-Button */
.nwf-output-controls .nwf-button {
    min-width: 120px;
    justify-content: center;
    align-items: center;
    display: inline-flex;
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .nwf-container {
        background-color: #1e1e1e;
        color: #ffffff;
        transition: background-color 0.3s ease-in-out,
                box-shadow 0.3s ease-in-out,
                transform 0.2s ease-out;
    }

    .nwf-textarea {
        background-color: #2d2d2d;
        border-color: #404040;
        color: #ffffff;
    }

    .nwf-paste-button {
        background-color: rgba(45, 45, 45, 0.95);
        border-color: #999;
        color: #999;
    }

    .nwf-paste-button:hover {
        background-color: #999;
        color: #1e1e1e;
    }

    .nwf-container .nwf-button,
    .nwf-container .nwf-control-button {
        background: #404040;
        border-color: #505050;
        color: #ffffff;
        transition: background-color 0.3s ease-in-out,
                border-color 0.3s ease-in-out,
                color 0.3s ease-in-out,
                transform 0.2s ease-out;
    }

    .nwf-container .nwf-button:hover,
    .nwf-container .nwf-control-button:hover:not(:disabled) {
        background: #505050;
        border-color: #999;
        transform: translateY(-1px);
    }

    .nwf-container .nwf-button.active,
    .nwf-container .nwf-control-button.active {
        background: #666;
        border-color: #444;
        color: #fff;
        box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
        transform: translateY(1px);
    }

    .nwf-loading {
        background: #333333;
        color: #e0e0e0;
    }

    .nwf-copy-button {
        color: #999 !important;
    }

    .nwf-copy-button.copied {
        color: #3fb950 !important;
    }

    .nwf-textarea:focus {
        border-color: #999;
        box-shadow: 0 0 0 1px #999;
    }

    .nwf-transcribe-button {
        background: #404040;
        border-color: #505050;
        color: #ffffff;
    }

    .nwf-transcribe-button:hover {
        background: #505050;
        border-color: #999;
        transform: translateY(-1px);
    }

    /* Dark Mode Status Messages */
    .nwf-status {
        background-color: rgba(45, 45, 45, 0.6);
        border: 1px solid rgba(80, 80, 80, 0.8);
        color: #d0d0d0;
    }

    .nwf-status.success {
        background-color: rgba(45, 45, 45, 0.6);
        color: #d0d0d0;
        border: 1px solid rgba(80, 80, 80, 0.8);
    }

    .nwf-status.error {
        background-color: rgba(50, 50, 50, 0.6);
        color: #d0d0d0;
        border: 1px solid rgba(90, 90, 90, 0.8);
    }

    .nwf-processing-message {
        background-color: rgba(45, 45, 45, 0.6);
        color: #d0d0d0;
        border: 1px solid rgba(80, 80, 80, 0.8);
        padding: 10px;
        margin: 10px 0;
        border-radius: 4px;
    }
}

/* Dark Mode: Grundeinstellungen */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

body.dark-mode .nwf-container {
    background-color: #1a1a1a;
    border: 1px solid #333;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Textarea im Dark Mode */
body.dark-mode .nwf-textarea {
    background-color: #4a4a4a;
    border-color: #555555;
    color: #ffffff;
}

/* Verbesserte Button-Styles im Dark Mode */
body.dark-mode .nwf-container .nwf-button,
body.dark-mode .nwf-container .nwf-control-button {
    background: #454545;
    border-color: #555555;
    color: #ffffff;
}

body.dark-mode .nwf-container .nwf-button:hover,
body.dark-mode .nwf-container .nwf-control-button:hover:not(:disabled) {
    background: #555555;
    border-color: #666666;
    color: #ffffff;
}

body.dark-mode .nwf-container .nwf-button.active,
body.dark-mode .nwf-container .nwf-control-button.active {
    background: #666666;
    border-color: #777777;
    color: #ffffff;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
    transform: translateY(1px);
}

/* Pin-Button im Dark Mode */
body.dark-mode .nwf-pin-button {
    background-color: #454545 !important;
    border-color: #555555;
    color: #ffffff !important;
}

body.dark-mode .nwf-pin-button:hover {
    background-color: #555555 !important;
    border-color: #666666;
    color: #ffffff !important;
}

body.dark-mode .nwf-pin-button.active {
    background-color: #666666 !important;
    border-color: #777777;
    color: #ffffff !important;
}

/* Loading-Bereich im Dark Mode */
body.dark-mode .nwf-loading {
    background: #4a4a4a;
    color: #ffffff;
}

body.dark-mode .nwf-spinner {
    border-color: #666;
    border-top-color: transparent;
}

/* Paste Button Styles für Dark Mode */
body.dark-mode .nwf-paste-button {
    background-color: #454545 !important;
    border: 2px solid #555555 !important;
    color: #ffffff !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2) !important;
}

body.dark-mode .nwf-paste-button:hover {
    background-color: #555555 !important;
    border-color: #666666 !important;
    color: #ffffff !important;
    outline: none !important;
}

body.dark-mode .nwf-paste-button:focus {
    outline: none !important;
    border-color: #666666 !important;
    box-shadow: 0 0 0 1px #666666 !important;
}

/* Dark Mode Status Messages */
body.dark-mode .nwf-status {
    background-color: rgba(45, 45, 45, 0.6);
    border: 1px solid rgba(80, 80, 80, 0.8);
    color: #d0d0d0;
}

body.dark-mode .nwf-status.success {
    background-color: rgba(45, 45, 45, 0.6);
    color: #d0d0d0;
    border: 1px solid rgba(80, 80, 80, 0.8);
}

body.dark-mode .nwf-status.error {
    background-color: rgba(50, 50, 50, 0.6);
    color: #d0d0d0;
    border: 1px solid rgba(90, 90, 90, 0.8);
}

body.dark-mode .nwf-processing-message {
    background-color: rgba(45, 45, 45, 0.6);
    color: #d0d0d0;
    border: 1px solid rgba(80, 80, 80, 0.8);
    padding: 10px;
    margin: 10px 0;
    border-radius: 4px;
}

/* Responsive Anpassungen */
@media (max-width: 600px) {
    .nwf-text-controls {
        justify-content: space-between;
    }
    
    .nwf-control-button {
        flex: 1;
        padding: 8px;
        min-width: 40px;
    }

    .nwf-output-controls .nwf-button {
        width: 100%;
    }

    .nwf-paste-button {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* Accessibility Verbesserungen */
.nwf-container button:focus-visible {
    outline: 2px solid #666;
    outline-offset: 2px;
}

.nwf-textarea:focus-visible {
    outline: 2px solid #666;
    outline-offset: 2px;
    box-shadow: none;
}

/* Transition Effekte */
.nwf-paste-button,
.nwf-copy-button,
.nwf-button,
.nwf-control-button {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Print Styles */
@media print {
    .nwf-container {
        box-shadow: none;
        padding: 0;
    }

    .nwf-text-controls,
    .nwf-buttons,
    .nwf-paste-button,
    .nwf-copy-button {
        display: none;
    }

    .nwf-textarea {
        border: none;
    }
}

/* Output Container */
.nwf-output-container {
    position: relative;
    width: 100%;
}

/* Copy Button */
.nwf-copy-inline {
    position: absolute;
    right: 10px;
    bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background-color: rgba(51, 51, 51, 0.9);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0;
    transform: translateY(10px);
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.nwf-output-container:hover .nwf-copy-inline {
    opacity: 1;
    transform: translateY(0);
}

.nwf-copy-inline:hover {
    background-color: rgba(68, 68, 68, 0.95);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.nwf-copy-inline svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

.nwf-copy-inline span {
    line-height: 1;
    font-weight: 500;
}

/* Copy Success Animation */
.nwf-copy-success {
    background-color: rgba(40, 167, 69, 0.9) !important;
}

/* Dark Mode Anpassungen */
body.dark-mode .nwf-copy-inline {
    background-color: rgba(85, 85, 85, 0.9);
}

body.dark-mode .nwf-copy-inline:hover {
    background-color: rgba(102, 102, 102, 0.95);
}

/* Output Area Position */
.nwf-output-area {
    position: relative;
    margin-top: 15px;
}

.nwf-output {
    min-height: 100px;
    padding: 15px;
    margin-bottom: 10px;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: inherit;
    line-height: 1.5;
}

/* Dark Mode für Output */
body.dark-mode .nwf-output {
    background-color: #4A4A4A;
    border-color: #505050;
    color: #fff;
}

/* Output Area */
.nwf-output-area {
    margin-top: 15px;
}

.nwf-output-container {
    width: 100%;
    margin-bottom: 10px;
}

.nwf-output {
    width: 100%;
    min-height: 100px;
    padding: 15px;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: inherit;
    line-height: 1.5;
}

/* Button Container */
.nwf-button-container {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

/* Copy Button */
.nwf-copy-button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background-color: #555;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nwf-copy-button:hover {
    background-color: #666;
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
}

.nwf-copy-button:active {
    transform: translateY(0);
}

.nwf-copy-icon {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* Copy Success Animation */
.nwf-copy-success {
    background-color: #28a745 !important;
}

/* Dark Mode Anpassungen */
body.dark-mode .nwf-output {
    background-color: #4A4A4A;
    border-color: #505050;
    color: #fff;
}

body.dark-mode .nwf-copy-button {
    background-color: #666;
}

body.dark-mode .nwf-copy-button:hover {
    background-color: #777;
}

/* Verarbeitung läuft - Basis */
.processing-status {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px;
    color: #333;
    background: none;
}

/* Spinner Animation */
.nwf-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #666;
    border-top-color: transparent;
    border-radius: 50%;
    animation: nwf-spin 1s linear infinite;
}

/* Dark Mode Anpassungen */
body.dark-mode .processing-status {
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 8px 16px;
    border-radius: 4px;
}

body.dark-mode .nwf-spinner {
    border-color: #fff;
    border-top-color: transparent;
}

@keyframes nwf-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Container für Verarbeitungsmeldung */
#nwf-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 10px;
    margin: 10px 0;
}

/* Verarbeitungsmeldung */
.processing-status {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    color: #333;
    background: none;
}

body.dark-mode .processing-status {
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 8px 16px;
    border-radius: 4px;
}