/* 🏛️ ATLAS-CIV-CLICKER | UI: BUTTONS ELITE (Nova v4.0) */
/* @ui-buttons @interaction @nova-v4-elite */

/* Mapping auf echte HTML-Klassen */
.btn-imperial-primary, .upgrade-btn {
    width: 100%;
    background: linear-gradient(135deg, #f59e0b, #d97706) !important;
    color: #000 !important;
    font-family: 'Cinzel', serif !important;
    font-weight: 900 !important;
    font-size: 1rem !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    padding: 14px 20px !important;
    border-radius: 14px !important;
    border: none !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    box-shadow: 0 8px 25px rgba(217, 119, 6, 0.4) !important;
    transition: var(--transition-elite) !important;
}

.btn-imperial-primary:hover, .upgrade-btn:hover {
    transform: translateY(-3px) scale(1.02) !important;
    box-shadow: 0 12px 35px rgba(217, 119, 6, 0.5) !important;
    filter: brightness(1.1);
}

.btn-imperial-ghost {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #fff !important;
    padding: 10px 18px !important;
    border-radius: 12px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    cursor: pointer !important;
    transition: var(--transition-elite) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
}

.btn-imperial-ghost:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

/* Navigations-Buttons */
.nav-btn {
    background: transparent !important;
    border: 1px solid transparent !important;
    color: var(--text-secondary) !important;
    padding: 8px 16px !important;
    border-radius: 10px !important;
    font-weight: 700 !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    transition: var(--transition-elite) !important;
}

.nav-btn.active, .nav-btn:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #fff !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

/* --- 4. ACTION BUTTONS (Sammeln, Abbauen) --- */
.btn-gather-primary {
    flex-grow: 1;
    background: linear-gradient(135deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03)) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #fff !important;
    padding: 14px !important;
    border-radius: 14px !important;
    font-family: 'Outfit', sans-serif !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    transition: var(--transition-elite) !important;
}

.btn-gather-primary:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: var(--color-gold-elite) !important;
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.15) !important;
}

.btn-boost-v5 {
    width: 54px !important;
    height: 54px !important;
    background: rgba(217, 70, 239, 0.1) !important;
    border: 1px solid rgba(217, 70, 239, 0.3) !important;
    color: var(--color-rubine) !important;
    border-radius: 14px !important;
    cursor: pointer !important;
    transition: var(--transition-elite) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.btn-boost-v5:hover {
    background: rgba(217, 70, 239, 0.2) !important;
    transform: scale(1.1) rotate(5deg) !important;
    box-shadow: 0 0 15px rgba(217, 70, 239, 0.3) !important;
}

/* Container für Sammel-Gruppe & Action Stack */
.gather-group-v5, .action-stack-v6 {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    padding: 0 1.5rem 1.5rem !important;
    width: 100% !important;
}

.action-stack-v6 button {
    width: 100% !important;
    margin: 0 !important;
}

/* --- 5. OVERLAY UPGRADE BUTTONS (Ressourcen-Karten) --- */

/* MENSCH: Dieser Button sitzt direkt auf dem Gebäude-Banner der Minen. */
/* v4.0: Veraltete Overlay-Logik deaktiviert (Migration zu .btn-upgrade-elite in ui_core.css) */
.btn-upgrade-overlay {
    display: none !important;
}

.btn-upgrade-overlay:hover {
    background: rgba(245, 158, 11, 0.2) !important;
    border-color: var(--color-gold-elite) !important;
    box-shadow: 0 0 30px rgba(245, 158, 11, 0.3) !important;
    color: #fff !important;
}

.btn-upgrade-overlay .material-symbols-outlined {
    font-size: 1.8rem !important;
    margin-bottom: -2px !important;
}

/* Kosten-Label innerhalb des Overlay-Buttons */
.cost-label {
    font-size: 0.65rem !important;
    font-weight: 900 !important;
    font-family: 'Cinzel', serif !important;
    letter-spacing: 0.5px !important;
    text-shadow: 0 0 5px #000;
}

/* Mobile-Sichtbarkeit: Auf Touch-Geräten sollte der Button immer leicht sichtbar sein */
@media (pointer: coarse) {
    .btn-upgrade-overlay {
        opacity: 0.8 !important;
        transform: translate(-50%, -50%) scale(1) !important;
        background: rgba(15, 23, 42, 0.8) !important;
    }
}

/* --- 6. INTELLIGENT BUTTON STATES (Bezahlbarkeit) --- */

/* MENSCH: Diese Zustände werden von der JS-Engine gesteuert. */

/* Zustand: Ausbau möglich (Gold-Glow) */
.can-afford {
    border-color: var(--color-gold-elite) !important;
    box-shadow: 0 0 25px rgba(245, 158, 11, 0.4) !important;
}

/* Redesign: Ressourcen fehlen (Premium Frosted Red) */
.insufficient-cost {
    background: rgba(239, 68, 68, 0.05) !important;
    border: 1px solid rgba(239, 68, 68, 0.3) !important;
    color: rgba(239, 68, 68, 0.6) !important;
    filter: grayscale(0.5) !important;
    box-shadow: none !important;
    cursor: not-allowed !important;
    position: relative;
    overflow: hidden;
}

.insufficient-cost::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(45deg, transparent, rgba(239, 68, 68, 0.05), transparent);
    animation: alertShimmer 3s infinite linear;
}

@keyframes alertShimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* --- 7. ELITE DEKRET BUTTON --- */

.btn-decree-elite {
    background: linear-gradient(135deg, #a855f7, #d946ef) !important;
    color: #fff !important;
    box-shadow: 0 0 30px rgba(217, 70, 239, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    padding: 18px !important;
    border-radius: 14px !important;
    font-size: 1.1rem !important;
    font-family: 'Cinzel', serif !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    letter-spacing: 2px !important;
    text-shadow: 0 0 10px rgba(0,0,0,0.5);
    animation: rubyPulse 3s infinite alternate ease-in-out;
    cursor: pointer !important;
}

@keyframes rubyPulse {
    0% { box-shadow: 0 0 20px rgba(217, 70, 239, 0.3); }
    100% { box-shadow: 0 0 40px rgba(217, 70, 239, 0.6), inset 0 0 15px rgba(255,255,255,0.2); }
}

@keyframes buttonPulseElite {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.15); opacity: 0; }
}
