/* ════════════════════════════════════════════════════════════════
   DD GLOW NOTIFICATION v2.1 — DD Luxury Gold Standard
   SSOT: Gold (#d4af37) für success/confirm/info.
         Rot (#dc2626) für error (ohne Icon, ohne rotes X).
         Type-Icons global entfernt — Logo ist das Branding-Element.
   ════════════════════════════════════════════════════════════════ */

/* ────────────────────────────────────────────────────────────────────────────
   OVERLAY
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 100002;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
}

.dd-notification-overlay.dd-notification-visible {
    display: flex;
    animation: ddNotifyFadeIn 0.3s ease-out;
}

@keyframes ddNotifyFadeIn {
    from { opacity: 0; transform: scale(0.92); }
    to   { opacity: 1; transform: scale(1); }
}

/* ────────────────────────────────────────────────────────────────────────────
   GLOWBOX — Kompakt, dunkel, edel
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-glowbox {
    position: relative;
    width: auto;
    max-width: 430px;
    min-width: 300px;
    padding: 30px 28px 28px;
    border-radius: 14px;
    background: linear-gradient(145deg, rgba(30, 30, 30, 0.94), rgba(15, 15, 15, 0.96));
    border: 1px solid rgba(212, 175, 55, 0.55);
    box-shadow:
        0 8px 32px rgba(0,0,0,0.6),
        0 0 40px rgba(212,175,55,0.18),
        inset 0 1px 3px rgba(255,255,255,0.05);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 14px;
    animation: ddNotifyPop 0.28s ease-out;
}

@keyframes ddNotifyPop {
    from { transform: scale(0.90) translateY(12px); opacity: 0; }
    to   { transform: scale(1) translateY(0); opacity: 1; }
}

/* ────────────────────────────────────────────────────────────────────────────
   GLOW COLOURS PER data-type — DD LUXURY (Gold + Error-Rot)
   ──────────────────────────────────────────────────────────────────────────── */

/* Default-Border der Glowbox ist bereits Gold (oben) — gilt auch für hidden/default */

/* Success + Confirm + Info = Goldener DD-Luxury-Glow */
.dd-notification-glowbox[data-type="success"],
.dd-notification-glowbox[data-type="confirm"],
.dd-notification-glowbox[data-type="info"] {
    border-color: rgba(212, 175, 55, 0.85) !important;
    box-shadow:
        0 0 52px rgba(212, 175, 55, 0.38),
        0 18px 48px rgba(0,0,0,0.75),
        inset 0 1px 3px rgba(255,255,255,0.06) !important;
}

/* Error: Close-X ausblenden */
.dd-notification-glowbox[data-type="error"] .dd-notification-close {
    display: none !important;
}

/* Error = roter Glow (BLEIBT rot, aber OHNE Icon) */
.dd-notification-glowbox[data-type="error"] {
    border-color: rgba(220, 38, 38, 0.75);
    box-shadow:
        0 0 42px rgba(220, 38, 38, 0.35),
        0 18px 48px rgba(0,0,0,0.75),
        inset 0 1px 3px rgba(255,255,255,0.06);
}

/* Warning: Gold (früher error-Mapping) — keine eigenen Farben mehr,
   Warning wird in JS auf success gemappt → erbt Gold */

/* ────────────────────────────────────────────────────────────────────────────
   DATA-HIDDEN SYSTEM — SSOT (gescoped auf Overlay)
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-overlay [data-hidden="true"] {
    display: none !important;
}

.dd-notification-overlay [data-hidden="false"] {
    display: block;
}

/* Buttons, Links mit data-hidden="false" korrekt darstellen */
.dd-notification-overlay button[data-hidden="false"],
.dd-notification-overlay .dd-button[data-hidden="false"],
.dd-notification-overlay a[data-hidden="false"] {
    display: inline-flex;
}

/* ────────────────────────────────────────────────────────────────────────────
   ICON — GLOBAL AUSGEBLENDET
   DD-Luxury: Logo ist das einzige Branding-Element.
   Legacy-Kompatibilität: Icon bleibt im DOM, ist aber dauerhaft display:none.
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-icon {
    display: none !important;
}

/* ────────────────────────────────────────────────────────────────────────────
   CLOSE BUTTON
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 28px;
    height: 28px;
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.5);
    background: none;
    border: none;
    cursor: pointer;
    transition: all 0.18s ease;
    line-height: 1;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.dd-notification-close:hover {
    color: #d4af37;
    transform: rotate(90deg) scale(1.1);
}

/* ────────────────────────────────────────────────────────────────────────────
   LOGO — DD Luxury (größer, zentriert)
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-logo {
    max-width: 110px;
    height: auto;
    margin: 0 auto 10px;
    opacity: 0.95;
    display: block;
}

/* ────────────────────────────────────────────────────────────────────────────
   TITLE
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-title {
    margin: 0 0 6px;
    font-size: 1.28rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-ivory);
}

/* ────────────────────────────────────────────────────────────────────────────
   TEXT / MESSAGE
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-text {
    margin: 0 0 4px;
    font-size: 0.98rem;
    line-height: 1.5;
    color: rgba(245, 240, 230, 0.90);
    word-break: break-word;
    hyphens: auto;
}

/* ────────────────────────────────────────────────────────────────────────────
   LEGACY OK BUTTON — DD Luxury Gold (heller & edler)
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-ok {
    margin-top: 6px;
    padding: 8px 18px;
    border-radius: 8px;
    border: 0.5px solid rgba(212, 175, 55, 0.65);
    background: linear-gradient(145deg, #3a3422 0%, #211d14 55%, #2b2415 100%);
    color: #f5f0e6;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    align-self: center;
    min-width: 80px;
    height: 34px;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.dd-notification-ok:hover {
    border-color: rgba(212, 175, 55, 0.95);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(212, 175, 55, 0.28);
}

/* ────────────────────────────────────────────────────────────────────────────
   ACTION BUTTONS CONTAINER — horizontal, kompakt, gap 5px
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-actions {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    flex-wrap: wrap;
}

/* ────────────────────────────────────────────────────────────────────────────
   BUTTON BASE — dunkel, kompakt, Luxury (Inbox-Richtung)
   ════════════════════════════════════════════════════════════════ */

/* Shared base fuer alle Glowbox-Buttons */
.dd-notification-actions .dd-button,
.dd-notification-actions .dd-btn-cancel,
.dd-notification-actions .dd-btn-confirm,
.dd-notification-actions .dd-btn-secondary-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 18px;
    font-size: 0.78rem;
    font-weight: 600;
    min-width: 80px;
    height: 34px;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    border-radius: 6px;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.165, 0.84, 0.44, 1),
                box-shadow 0.2s cubic-bezier(0.165, 0.84, 0.44, 1),
                border-color 0.2s ease,
                color 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    flex: 0 0 auto;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}

/* ────────────────────────────────────────────────────────────────────────────
   CANCEL BUTTON — DD Luxury Gold (analog zu Confirm)
   ──────────────────────────────────────────────────────────────────────────── */

.dd-btn-cancel {
    background: linear-gradient(145deg, #3a3422 0%, #211d14 55%, #2b2415 100%);
    border: 0.5px solid rgba(212, 175, 55, 0.55);
    color: #f5f0e6;
}

.dd-btn-cancel:hover {
    background: linear-gradient(145deg, #4a4230 0%, #2b2518 55%, #3a301c 100%);
    border-color: rgba(212, 175, 55, 0.85);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(212, 175, 55, 0.25);
}

/* ────────────────────────────────────────────────────────────────────────────
   CONFIRM BUTTON — DD Luxury Gold
   ──────────────────────────────────────────────────────────────────────────── */

.dd-btn-confirm {
    background: linear-gradient(145deg, #3a3422 0%, #211d14 55%, #2b2415 100%);
    border: 0.5px solid rgba(212, 175, 55, 0.65);
    color: #f5f0e6;
    margin-top: 5px;
}

.dd-btn-confirm:hover {
    background: linear-gradient(145deg, #4a4230 0%, #2b2518 55%, #3a301c 100%);
    border-color: rgba(212, 175, 55, 0.95);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(212, 175, 55, 0.28);
}

/* ────────────────────────────────────────────────────────────────────────────
   SECONDARY LINK — DD Luxury Gold (SSOT mit Confirm)
   ──────────────────────────────────────────────────────────────────────────── */

.dd-btn-secondary-link {
    background: linear-gradient(145deg, #3a3422 0%, #211d14 55%, #2b2415 100%);
    border: 0.5px solid rgba(212, 175, 55, 0.55);
    color: #f5f0e6;
    text-decoration: none;
}

.dd-btn-secondary-link:hover {
    background: linear-gradient(145deg, #4a4230 0%, #2b2518 55%, #3a301c 100%);
    border-color: rgba(212, 175, 55, 0.85);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(212, 175, 55, 0.25);
}

/* ────────────────────────────────────────────────────────────────────────────
   SCROLL-LOCK
   ──────────────────────────────────────────────────────────────────────────── */

body.dd-notification-lock {
    overflow: hidden;
}

/* ────────────────────────────────────────────────────────────────────────────
   OVERLAY TYPE VARIANTEN — Legacy-Selektoren (bleiben für Rückwärtskompatibilität)
   Icon-Styles sind wirkungslos, da .dd-notification-icon dauerhaft display:none.
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-success .dd-notification-icon { color: var(--success-green); }
.dd-notification-error   .dd-notification-icon { color: var(--index-red); }

/* ────────────────────────────────────────────────────────────────────────────
   GLOWBOX-BUTTONS — HELL & LESBAR (Override für .dd-button color:#000)
   Höhere Spezifität + !important, damit auth.css / main.css nicht überschreiben.
   Nur innerhalb der Glowbox aktiv.
   ──────────────────────────────────────────────────────────────────────────── */

.dd-notification-overlay .dd-notification-ok,
.dd-notification-overlay .dd-notification-actions .dd-button,
.dd-notification-overlay .dd-notification-actions .dd-btn-cancel,
.dd-notification-overlay .dd-notification-actions .dd-btn-confirm,
.dd-notification-overlay .dd-notification-actions .dd-btn-secondary-link {
    color: #fff3c4 !important;
    background: linear-gradient(
        145deg,
        #8a6a24 0%,
        #5f4618 42%,
        #9b7628 100%
    ) !important;
    border: 1px solid rgba(255, 218, 105, 0.95) !important;
    box-shadow:
        0 0 18px rgba(212, 175, 55, 0.38),
        0 8px 18px rgba(0, 0, 0, 0.55),
        inset 0 1px 0 rgba(255, 255, 255, 0.35),
        inset 0 -2px 0 rgba(0, 0, 0, 0.45) !important;
    text-shadow: 0 1px 2px rgba(0,0,0,0.9) !important;
    opacity: 1 !important;
}

.dd-notification-overlay .dd-notification-ok:hover,
.dd-notification-overlay .dd-notification-actions .dd-button:hover,
.dd-notification-overlay .dd-notification-actions .dd-btn-cancel:hover,
.dd-notification-overlay .dd-notification-actions .dd-btn-confirm:hover,
.dd-notification-overlay .dd-notification-actions .dd-btn-secondary-link:hover {
    color: #ffffff !important;
    background: linear-gradient(
        145deg,
        #b88a2e 0%,
        #72531c 42%,
        #d4af37 100%
    ) !important;
    border-color: rgba(255, 235, 150, 1) !important;
    box-shadow:
        0 0 28px rgba(212, 175, 55, 0.62),
        0 12px 24px rgba(0,0,0,0.55),
        inset 0 1px 0 rgba(255,255,255,0.45),
        inset 0 -2px 0 rgba(0,0,0,0.38) !important;
    transform: translateY(-2px);
}

/* ────────────────────────────────────────────────────────────────────────────
   MOBILE ANPASSUNG — weiterhin kompakt
   ──────────────────────────────────────────────────────────────────────────── */

@media (max-width: 480px) {
    .dd-notification-glowbox {
        max-width: 360px;
        padding: 24px 24px 26px;
        min-width: 280px;
    }
    .dd-notification-logo {
        max-width: 92px;
        margin-bottom: 8px;
    }
    .dd-notification-title {
        font-size: 1.15rem;
    }
    .dd-notification-actions {
        gap: 8px;
    }
    .dd-btn-cancel,
    .dd-btn-confirm,
    .dd-btn-secondary-link {
        min-width: 70px;
        padding: 6px 12px;
        font-size: 0.72rem;
        height: 30px;
    }
    .dd-notification-ok {
        min-width: 70px;
        padding: 6px 12px;
        font-size: 0.72rem;
        height: 30px;
    }
}
