/* Overlay für 1080x1920 Stream-Format */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    width: 1920px;
    height: 1080px;
    background: transparent;
    font-family: 'Arial', sans-serif;
    overflow: hidden;
}

/* Vertical Layout: 1080x1920 Hochformat */
body.layout-vertical {
    width: 1080px;
    height: 1920px;
}

#overlay-container {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 20px;
    box-sizing: border-box;
    overflow: hidden;
    align-items: center;
}

/* Vertikales Layout - Container linksbündig */
body:has(#shops-container.vertical) #overlay-container {
    align-items: flex-start;
    padding-left: 30px;
}

/* Header Timer */
.header-timer {
    font-size: 36px; /* größer */
    font-weight: 800;
    color: #ffd700;
    background: transparent; /* Rahmen & Hintergrund weg */
    padding: 0 4px;
    border: none;
    border-radius: 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.9);
    box-shadow: none;
    min-width: 70px;
    text-align: center;
    letter-spacing: 1px;
}

/* Shops Container */
#shops-container {
    display: flex;
    flex: 1;
    align-items: flex-start;
    transition: all 0.3s ease;
}

/* Horizontales Layout (Standard) */
#shops-container.horizontal {
    flex-direction: row;
    gap: 15px;
    align-items: flex-start;
    margin-left: 0;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    width: fit-content;
}



#shops-container.horizontal .shop-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
}

#shops-container.horizontal .shop-title {
    font-size: 28px;
}

#shops-container.horizontal .header-timer { font-size: 34px; padding:0 4px; }

#shops-container.horizontal .items-grid {
    gap: 10px;
}

#shops-container.horizontal .item-tile {
    padding: 10px;
    gap: 10px;
}

#shops-container.horizontal .item-image {
    width: 60px;
    height: 60px;
}

#shops-container.horizontal .item-name {
    font-size: 24px;
}

#shops-container.horizontal .item-rarity {
    font-size: 14px;
}



/* Vertikales Layout - optimiert für 1080x1920 */
#shops-container.vertical {
    flex-direction: column;
    gap: 15px;
    align-items: flex-start;
    margin-left: 0;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    width: fit-content;
}



#shops-container.vertical .shop-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
}

#shops-container.vertical .shop-title {
    font-size: 28px;
}

#shops-container.vertical .header-timer { font-size: 34px; padding:0 4px; }

#shops-container.vertical .items-grid {
    gap: 10px;
}

#shops-container.vertical .item-tile {
    padding: 10px;
    gap: 10px;
}

#shops-container.vertical .item-image {
    width: 60px;
    height: 60px;
}

#shops-container.vertical .item-name {
    font-size: 24px;
}

#shops-container.vertical .item-rarity {
    font-size: 14px;
}



#shops-container.vertical .footer-credit {
    font-size: 18px;
    margin-top: 8px;
    padding-top: 6px;
}

.shop-section {
    background: linear-gradient(145deg, #2d3748, #4a5568);
    border-radius: 20px;
    border: 3px solid #ffd700;
    padding: 12px 12px 8px 12px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.4);
    display: flex;
    flex-direction: column;
    min-height: 400px;
    width: 400px;
    flex: none;
}

.shop-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #ffd700;
}

.shop-title {
    font-size: 36px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

/* Items Grid */
.items-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
    flex: 1;
    min-height: 0;
}

/* Item Tile */
.item-tile {
    background: linear-gradient(145deg, #1a202c, #2d3748);
    border-radius: 15px;
    border: 2px solid;
    padding: 15px;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.item-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.4);
}

/* Rarity Colors */
.item-tile.epic { border-color: #8b5cf6; background: linear-gradient(145deg, #5b21b6, #8b5cf6); }
.item-tile.legendary { border-color: #f59e0b; background: linear-gradient(145deg, #d97706, #f59e0b); }
.item-tile.mythic { border-color: #ef4444; background: linear-gradient(145deg, #dc2626, #ef4444); }
.item-tile.godly { border-color: #00ffff; background: linear-gradient(145deg, #0891b2, #00ffff); }
.item-tile.secret { border-color: #ff00ff; background: linear-gradient(145deg, #a21caf, #ff00ff); }

/* Item Image */
.item-image {
    width: 80px;
    height: 80px;
    border-radius: 10px;
    object-fit: cover;
    border: 2px solid rgba(255,255,255,0.2);
}

/* Item Info */
.item-info { display: flex; flex-direction: column; gap: 1px; min-width: 0; }

.item-name {
    font-size: 42px;
    line-height: 1.01;
    font-weight: bold;
    color: #ffffff;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-rarity {
    font-size: 19px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.item-rarity.common { color: #9ca3af; }
.item-rarity.rare { color: #60a5fa; }
.item-rarity.epic { color: #a78bfa; }
.item-rarity.legendary { color: #fbbf24; }
.item-rarity.mythic { color: #f87171; }
.item-rarity.godly { color: #00ffff; }
.item-rarity.secret { color: #ff00ff; }

/* Stock Container */
.stock-container {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-width: 90px;
}

.item-stock {
    font-size: 28px;
    font-weight: 800;
    color: #ffd700;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    text-align: right;
    white-space: nowrap;
}

.item-stock.out-of-stock {
    color: #ef4444;
}



/* Scrollbar Styling */
.items-grid::-webkit-scrollbar {
    width: 8px;
}

.items-grid::-webkit-scrollbar-track {
    background: rgba(45, 55, 72, 0.3);
    border-radius: 4px;
}

.items-grid::-webkit-scrollbar-thumb {
    background: #ffd700;
    border-radius: 4px;
}

.items-grid::-webkit-scrollbar-thumb:hover {
    background: #ffed4e;
}

/* Footer Credit */
.footer-credit {
    text-align: center;
    margin-top: 10px;
    margin-bottom: 0px;
    padding-top: 8px;
    padding-bottom: 0px;
    border-top: 2px solid #ffd700;
    font-size: 22px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    opacity: 0.8;
}

/* Animation für Updates */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.item-tile.updated {
    animation: pulse 0.5s ease-in-out;
}

/* Leucht- und Pulsier-Animationen für seltene Items */
@keyframes glow-pulse {
    0%, 100% {
        box-shadow: 0 0 20px rgba(255, 215, 0, 0.8), 0 0 40px rgba(255, 215, 0, 0.6), 0 0 60px rgba(255, 215, 0, 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 30px rgba(255, 215, 0, 1), 0 0 60px rgba(255, 215, 0, 0.8), 0 0 90px rgba(255, 215, 0, 0.6);
        transform: scale(1.02);
    }
}

@keyframes legendary-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(245, 158, 11, 0.8), 0 0 40px rgba(245, 158, 11, 0.6);
        border-color: #f59e0b;
    }
    50% {
        box-shadow: 0 0 30px rgba(245, 158, 11, 1), 0 0 60px rgba(245, 158, 11, 0.8);
        border-color: #fbbf24;
    }
}

@keyframes mythic-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(239, 68, 68, 0.8), 0 0 40px rgba(239, 68, 68, 0.6);
        border-color: #ef4444;
    }
    50% {
        box-shadow: 0 0 30px rgba(239, 68, 68, 1), 0 0 60px rgba(239, 68, 68, 0.8);
        border-color: #f87171;
    }
}

@keyframes godly-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(0, 255, 255, 0.8), 0 0 40px rgba(0, 255, 255, 0.6);
        border-color: #00ffff;
    }
    50% {
        box-shadow: 0 0 30px rgba(0, 255, 255, 1), 0 0 60px rgba(0, 255, 255, 0.8);
        border-color: #67e8f9;
    }
}

@keyframes secret-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(255, 0, 255, 0.8), 0 0 40px rgba(255, 0, 255, 0.6);
        border-color: #ff00ff;
    }
    50% {
        box-shadow: 0 0 30px rgba(255, 0, 255, 1), 0 0 60px rgba(255, 0, 255, 0.8);
        border-color: #f472b6;
    }
}

@keyframes golden-glow {
    0%, 100% {
        box-shadow: 0 0 25px rgba(255, 215, 0, 0.9), 0 0 50px rgba(255, 215, 0, 0.7), 0 0 75px rgba(255, 215, 0, 0.5);
        border-color: #ffd700;
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 35px rgba(255, 215, 0, 1), 0 0 70px rgba(255, 215, 0, 0.9), 0 0 105px rgba(255, 215, 0, 0.7);
        border-color: #fff700;
        transform: scale(1.03);
    }
}

/* Anwenden der goldenen Schein-Animation nur auf höchste Seltenheiten */
.item-tile.legendary {
    animation: golden-glow 2s ease-in-out infinite;
}

.item-tile.mythic {
    animation: golden-glow 1.9s ease-in-out infinite;
}

.item-tile.godly {
    animation: golden-glow 1.8s ease-in-out infinite;
}

.item-tile.secret {
    animation: golden-glow 1.5s ease-in-out infinite;
}

/* Predictor Tiles */
.predictor-tile {
    background: linear-gradient(145deg, #1a202c, #2d3748);
    border-radius: 8px;
    border: 2px solid #ffd700;
    padding: 1px 12px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    min-height: 28px;
}

.predictor-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.4);
}

.predictor-countdown {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-width: 100px;
}

.countdown-text {
    font-size: 28px;
    font-weight: 800;
    color: #ffd700;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
    text-align: right;
    white-space: nowrap;
    line-height: 0.8;
    margin: 0;
    padding: 0;
    display: block;
}

.predictor-tile .item-name {
    font-size: 28px;
    line-height: 1.2;
    margin: 0;
    padding: 0;
    display: block;
}

.predictor-tile .item-info {
    margin: 0;
    padding: 0;
    min-height: 0;
    line-height: 1.2;
}

/* ========================================
   ALERT BANNER SYSTEM
   ======================================== */

/* Alert Container - Banner oben zentriert */
.alert-banner {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 9999;
    max-width: 90%;
    min-width: 700px;
    background: rgba(220, 38, 38, 0.93);
    border: 2px solid rgba(255, 85, 85, 0.7);
    border-radius: 20px;
    padding: 25px 40px;
    box-shadow: 
        0 25px 50px -12px rgba(0, 0, 0, 0.95),
        0 0 80px rgba(255, 68, 68, 0.4);
    animation: alertSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    backdrop-filter: blur(10px);
}

.alert-banner.show {
    opacity: 1;
}

.alert-banner.hide {
    animation: alertSlideOut 0.4s ease-in-out forwards;
}

/* Alert Items Grid */
.alert-items-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Single Alert Item */
.alert-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    background: transparent;
    border-radius: 0;
    padding: 0;
    border: none;
}

.alert-item-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

/* Alert Item Image */
.alert-item-image {
    width: 100px;
    height: 100px;
    border-radius: 0;
    object-fit: cover;
    border: none;
    box-shadow: none;
    background: none;
    image-rendering: crisp-edges;
}

/* Alert Item Info */
.alert-item-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.alert-item-title {
    font-size: 24px;
    font-weight: 900;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: 4px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
    margin-bottom: 0;
    text-align: center;
}

.alert-item-name {
    font-size: 48px;
    font-weight: 900;
    color: #ffffff;
    text-shadow: 3px 3px 8px rgba(0, 0, 0, 0.9);
    line-height: 1;
    white-space: nowrap;
    margin-bottom: 8px;
    text-align: center;
}

/* Alert Countdown */
.alert-countdown {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    width: 100%;
}

.alert-countdown-timer {
    font-size: 56px;
    font-weight: 900;
    color: #ffffff;
    text-shadow: 
        0 0 15px rgba(255, 255, 255, 0.6),
        0 4px 10px rgba(0, 0, 0, 0.7);
    font-family: 'Courier New', monospace;
    min-width: 120px;
    text-align: center;
    margin-bottom: 0;
}

.alert-countdown-timer.urgent {
    color: #ffffff;
    text-shadow: 
        0 0 30px rgba(255, 255, 255, 0.9),
        0 4px 12px rgba(0, 0, 0, 0.8);
    animation: urgentPulse 0.5s ease-in-out infinite;
}

/* Animations */
@keyframes alertSlideIn {
    0% {
        transform: translate(-50%, -50%) scale(0.5);
        opacity: 0;
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

@keyframes alertSlideOut {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(0.5);
        opacity: 0;
    }
}

@keyframes urgentPulse {
    0%, 100% {
        text-shadow: 
            0 0 10px rgba(255, 0, 0, 0.8),
            0 0 20px rgba(255, 0, 0, 0.6),
            3px 3px 6px rgba(0, 0, 0, 0.9);
        transform: scale(1);
    }
    50% {
        text-shadow: 
            0 0 20px rgba(255, 0, 0, 1),
            0 0 40px rgba(255, 0, 0, 0.8),
            3px 3px 6px rgba(0, 0, 0, 0.9);
        transform: scale(1.05);
    }
}

.alert-banner.show {
    animation: alertSlideIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}