/* ============================================================
   Blackjack – style.css  (überarbeitet)
   Neu: .bet-area, .quick-bets, .hand-section, .hand-value,
        .action-buttons, .logout-link, .error-msg,
        .new-player-banner, #doubleBtn
   ============================================================ */

/* ── Grundlayout ── */
body {
    background: url('bg.jpg') no-repeat center center fixed;
    background-size: cover;
    color: #fff;
    font-family: Arial, sans-serif;
    text-align: center;
}

h1 {
    margin-top: 20px;
    font-size: 2.5em;
}

/* ── Container ── */
.game-container, footer {
    max-width: 1000px;
    margin: 20px auto;
    background: rgba(0,0,0,0.82);
    padding: 24px 28px;
    border-radius: 12px;
    box-shadow: 0 0 18px rgba(227,194,4,0.85);
}

/* ── Status-Leiste ── */
.status {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 26px;
    font-size: 1.2rem;
    align-items: center;
}
.status p {
    margin: 0;
    padding: 8px 14px;
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
}

/* ── Logout-Link ── */
.logout-link {
    color: #ffaa00;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    padding: 8px 14px;
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
    transition: background 0.2s;
}
.logout-link:hover {
    background: rgba(255,170,0,0.25);
}

/* ── Fehlermeldung & Banner ── */
.error-msg {
    color: #ff5555;
    font-size: 1.1rem;
    margin: 10px 0;
    padding: 10px;
    background: rgba(255,0,0,0.15);
    border-radius: 8px;
}
.new-player-banner {
    color: #00ff99;
    font-size: 1.1rem;
    margin-bottom: 14px;
    padding: 10px;
    background: rgba(0,200,100,0.15);
    border-radius: 8px;
}

/* ── Formular-Elemente ── */
input[type="text"],
input[type="password"],
input[type="number"] {
    font-size: 1.2rem;
    padding: 12px 18px;
    border-radius: 10px;
    border: none;
    width: 250px;
    margin: 10px 0;
    outline: none;
    color: #000;
}
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ── Einsatz-Bereich ── */
.bet-area {
    margin: 10px 0 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.bet-area label {
    font-size: 1.2rem;
}
.bet-area input {
    width: 110px;
    margin: 0;
}

/* ── Schnellwahl-Buttons ── */
.quick-bets {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin: 8px 0 18px;
}
.quick-bet {
    font-size: 1.1rem !important;
    padding: 9px 20px !important;
    margin: 4px !important;
    background: linear-gradient(45deg, #1a6ab5, #1250a0) !important;
    border-radius: 10px !important;
}
.quick-bet:hover:not(:disabled) {
    background: linear-gradient(45deg, #1250a0, #1a6ab5) !important;
}

/* ── Allgemeine Buttons ── */
button {
    font-size: 1.5rem;
    margin: 12px;
    padding: 13px 32px;
    border-radius: 14px;
    border: none;
    background: linear-gradient(45deg, #28a745, #1e7e34);
    color: white;
    cursor: pointer;
    transition: all 0.25s ease;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
}
button:disabled {
    background: #555 !important;
    cursor: not-allowed;
    box-shadow: none;
    transform: none !important;
}
button:hover:not(:disabled) {
    background: linear-gradient(45deg, #1e7e34, #28a745);
    transform: translateY(-2px);
}

/* ── Verdoppeln-Button ── */
#doubleBtn {
    background: linear-gradient(45deg, #c0700a, #a05808);
}
#doubleBtn:hover:not(:disabled) {
    background: linear-gradient(45deg, #a05808, #c0700a);
}

/* ── Aktions-Buttons Gruppe ── */
.action-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin: 10px 0;
}

/* ── Hand-Bereich ── */
.hand-section {
    margin: 10px 0;
}
.hand-section h3 {
    margin-bottom: 4px;
    font-size: 1.3rem;
    color: #ffd700;
}

/* ── Handwert-Anzeige ── */
.hand-value {
    font-size: 1rem;
    font-weight: 400;
    color: #aaffcc;
    margin-left: 8px;
}

/* ── Kartenbereich ── */
#dealerCards, #playerCards {
    min-height: 180px;
    margin: 10px 0 28px;
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 12px;
}
.card {
    width: 120px;
    height: 175px;
    margin: 8px 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.35);
    background: white;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    flex-shrink: 0;
}
.card img.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.card:hover {
    transform: scale(1.06) rotateY(3deg);
    z-index: 10;
    box-shadow: 0 6px 20px rgba(0,0,0,0.45);
}

/* ── Statusmeldungen ── */
#status {
    font-size: 1.8rem;
    margin: 10px 0 20px;
    min-height: 2.5rem;
    font-weight: 600;
    text-shadow: 0 0 6px black;
}

/* ── Chips ── */
#chipsDisplay {
    font-weight: 700;
    font-size: 1.6rem;
    color: #00ff00;
    text-shadow: 0 0 6px #00ff00;
}

/* ── Highscore ── */
#highscores {
    background: rgba(0,0,0,0.82);
    border-radius: 14px;
    padding: 20px;
    margin: 40px auto;
    box-shadow: 0 0 18px rgba(227,194,4,0.85);
    max-width: 1000px;
}
#highscoreTable {
    width: 100%;
    border-collapse: collapse;
    margin: 0 auto;
}
#highscoreTable th,
#highscoreTable td {
    padding: 10px 14px;
    text-align: center;
    border: 1px solid #ffd700;
    color: white;
}
#highscoreTable th {
    background: rgba(227,194,4,0.3);
    font-size: 1.05em;
}
#highscoreTable tr.rank-1 { background: rgba(255,215,0,0.2); }
#highscoreTable tr.rank-2 { background: rgba(192,192,192,0.2); }
#highscoreTable tr.rank-3 { background: rgba(205,127,50,0.2); }
#highscoreTable tr.rank-bust {
    background: rgba(180,0,0,0.15);
    color: #ff7777;
    opacity: 0.75;
}
.bust-label {
    color: #ff6666;
    font-style: italic;
}
#highscoreTable tr:nth-child(even):not(.rank-1):not(.rank-2):not(.rank-3) {
    background: rgba(255,255,255,0.05);
}

/* ── Warnhinweise ── */
.warning {
    color: #ffcc00;
    font-size: 1rem;
    margin: 10px 0;
}

/* ── Footer ── */
footer {
    margin-top: 20px;
    font-size: 0.9rem;
    color: #aaa;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    .game-container, #highscores { padding: 16px; }
    button { font-size: 1.2rem; padding: 10px 22px; }
    .card  { width: 80px; height: 120px; }
    #highscoreTable { font-size: 0.88rem; }
    .status { font-size: 1rem; }
}
