@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700&family=Righteous&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    background: #000;
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 10;
}

/* Role Selection Tabs */
.role-selection-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 20px;
    background: rgba(255,255,255,0.12);
    padding: 5px;
    border-radius: 8px;
}

.tab-btn {
    flex: 1;
    padding: 10px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: bold;
    color: rgba(255,255,255,0.7);
    border-radius: 6px;
    transition: all 0.2s;
}

.tab-btn.active {
    background: rgba(255,255,255,0.25);
    color: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* Card Styles */
.card {
    background: rgba(255, 255, 255, 0.10);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    color: #fff;
}

h1 {
    font-family: 'Righteous', sans-serif;
    font-size: 2.5em;
    margin-bottom: 10px;
    text-align: center;
    color: #fff;
    letter-spacing: 0.02em;
}

.app-title {
    font-family: 'Righteous', sans-serif;
    font-size: 2.5em;
    letter-spacing: 0.08em;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}
.app-title strong {
    font-weight: normal;
    letter-spacing: 0.12em;
}
.vapour-byline-wrapper {
    width: 100%;
    min-height: 24px;
    height: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.vapour-byline-wrapper canvas {
    display: block;
    max-width: 100%;
}
.app-byline {
    display: block;
    font-family: 'Outfit', sans-serif;
    font-size: 0.45em;
    font-weight: 500;
    color: #d4af37;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

h2, h3 {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
}
h2 {
    font-size: 1.5em;
    margin-bottom: 20px;
    color: #444;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.subtitle {
    text-align: center;
    font-size: 1.2em;
    color: rgba(255,255,255,0.7);
    margin-bottom: 30px;
}

/* Game Selection */
.game-selection {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 30px 0;
}

.game-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 40px 60px;
    font-size: 1.5em;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    min-width: 200px;
}

.game-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.game-icon {
    font-size: 3em;
}

.game-name {
    font-weight: bold;
}

/* Role Selection */
.role-selection {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 30px 0;
}

.role-btn {
    background: white;
    border: 3px solid #667eea;
    border-radius: 12px;
    padding: 30px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.role-btn:hover {
    background: #f0f0ff;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.role-icon {
    font-size: 3em;
}

.role-name {
    font-size: 1.5em;
    font-weight: bold;
    color: #667eea;
}

.role-desc {
    color: #666;
    font-size: 0.9em;
}

.back-link {
    display: block;
    text-align: center;
    margin-top: 20px;
    color: #667eea;
    text-decoration: none;
    font-weight: bold;
}

.back-link:hover {
    text-decoration: underline;
}

/* Table Layout */
.table-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    aspect-ratio: 1 / 1;
    max-height: 80vh;
    margin: 40px auto 100px;
    background: radial-gradient(circle, #2d5a27 0%, #1e3c1a 100%);
    border: 15px solid #5d4037;
    border-radius: 50%;
    box-shadow: 0 40px 60px rgba(0,0,0,0.6), inset 0 -20px 40px rgba(0,0,0,0.5);
    overflow: visible;
    display: flex;
    justify-content: center;
    align-items: center;
    /* 3D Transform Properties */
    transform-style: preserve-3d;
    transform: perspective(1200px) rotateX(25deg);
}

/* Player Slots around table */
.player-slot {
    position: absolute;
    width: 80px;
    height: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    transition: all 0.5s ease;
    z-index: 10;
    /* Counter-rotate players to stand up on tilted table */
    transform-style: preserve-3d;
    transform: rotateX(-25deg) translateZ(40px);
}

/* Central Pool Box */
.pool-box {
    position: absolute;
    top: 50%;
    left: 50%;
    background: linear-gradient(135deg, #1a1a1a 0%, #333 100%);
    border: 4px solid #ffd700;
    padding: 20px 40px;
    border-radius: 20px;
    text-align: center;
    color: white;
    box-shadow: 
        0 15px 30px rgba(0,0,0,0.6),
        inset 0 0 15px rgba(255, 215, 0, 0.2);
    z-index: 5;
    min-width: 180px;
    border-image: linear-gradient(to bottom, #ffd700, #b8860b) 1;
    border: 4px solid;
    animation: pool-glow 2s infinite alternate;
    /* Counter-rotate pool box to stand upright */
    transform-style: preserve-3d;
    transform: translate(-50%, -50%) rotateX(-25deg) translateZ(30px);
}

@keyframes pool-glow {
    from { box-shadow: 0 0 20px rgba(255, 215, 0, 0.4); }
    to { box-shadow: 0 0 40px rgba(255, 215, 0, 0.7), 0 0 60px rgba(255, 215, 0, 0.2); }
}

.pool-label {
    font-size: 0.9em;
    color: #ffd700;
    font-weight: 900;
    margin-bottom: 8px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.pool-value {
    font-size: 2.5em;
    font-weight: 900;
    color: #fff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5), 0 0 20px rgba(255,255,255,0.4);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Player Slots around table */
.player-slot {
    position: absolute;
    width: 80px;
    text-align: center;
    transition: all 0.5s ease;
    z-index: 10;
}

.player-info-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    background: rgba(0,0,0,0.7);
    padding: 2px 8px;
    border-radius: 12px;
    margin-top: 2px;
    white-space: nowrap;
}

.player-wallet-label {
    color: #4cd137;
    font-size: 0.85em;
    font-weight: bold;
}

.player-name-label {
    color: white;
    font-size: 0.85em;
    font-weight: 500;
}

.player-bid-container {
    height: 60px; /* Increased height for two labels */
    position: relative;
    margin-bottom: 5px;
    width: 100%;
}

.player-total-bid,
.player-last-bid {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    padding: 2px 10px;
    border-radius: 6px;
    font-size: 0.7em;
    font-weight: 900;
    white-space: nowrap;
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
    display: none;
    z-index: 20;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    border: 1px solid rgba(255,255,255,0.3);
}

.total-bid {
    top: 0;
    background: #764ba2 !important; /* Purple/Blue for total */
}

.latest-bid {
    top: 25px; /* Offset from total bid */
    background: #ff4d4d !important; /* Bright Red for latest */
}

.player-total-bid.active,
.player-last-bid.active {
    display: block !important;
}

.player-icon {
    width: 50px;
    height: 50px;
    background: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5em;
    margin: 0 auto;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    border: 3px solid #667eea;
}

.player-slot.winner-glow {
    animation: winner-pulse 1s infinite;
}

@keyframes winner-pulse {
    0% { transform: scale(1); box-shadow: 0 0 0px #ffd700; }
    50% { transform: scale(1.1); box-shadow: 0 0 30px #ffd700; }
    100% { transform: scale(1); box-shadow: 0 0 0px #ffd700; }
}

/* Coin Animation */
.coin {
    position: fixed;
    width: 40px;
    height: 40px;
    background: #ffd700;
    border: 2px solid #b8860b;
    border-radius: 50%;
    color: #3e2723;
    font-size: 0.7em;
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    pointer-events: none;
    transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.8s ease;
}

/* Admin Winner Selection Boxes */
.winner-selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.winner-box {
    background: white;
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    text-align: center;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s;
    user-select: none;
    color: #333;
    font-size: 0.9em;
    word-break: break-all;
}

.winner-box:hover {
    border-color: #667eea;
    transform: translateY(-2px);
}

.winner-box.selected {
    background: #ff4d4d !important;
    color: white !important;
    border-color: #cc0000 !important;
    animation: pulse-red 1s infinite;
}

.winner-box.winner {
    background: #ffd700 !important;
    color: #333 !important;
    border-color: #b8860b !important;
    transform: scale(1.1);
    box-shadow: 0 0 20px #ffd700;
    z-index: 10;
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0px rgba(255, 77, 77, 0.4); }
    50% { box-shadow: 0 0 10px rgba(255, 77, 77, 0.7); }
    100% { box-shadow: 0 0 0px rgba(255, 77, 77, 0.4); }
}

/* Moderator Controls */
.mod-controls {
    display: none;
}

.mod-controls.active {
    display: block;
}

.mod-section {
    margin: 15px 0;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.mod-section label {
    display: block;
    font-weight: bold;
    margin-bottom: 8px;
    font-size: 0.9em;
    color: #444;
}

.input-group {
    display: flex;
    gap: 10px;
}

.input-group select {
    flex: 2;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.input-group input {
    flex: 1;
    margin-bottom: 0;
    padding: 8px;
}

.input-group .btn-primary,
.input-group .btn-success {
    flex: 1;
    padding: 8px;
    font-size: 0.9em;
}

.btn-danger {
    background: #ff4444;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 15px;
    cursor: pointer;
    font-weight: bold;
}

.btn-success {
    background: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 15px;
    cursor: pointer;
    font-weight: bold;
}

.btn-danger:hover { background: #cc0000; }
.btn-success:hover { background: #218838; }

/* Quick Bet Buttons */
.quick-bets-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin: 20px auto;
    max-width: 600px;
    padding: 10px;
}

.btn-quick-bet {
    width: 60px;
    height: 60px;
    background: white;
    border: 2px solid #ffd700;
    border-radius: 8px;
    color: #333;
    font-weight: bold;
    font-size: 0.9em;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.btn-quick-bet:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.2);
    background: #fdf2f2;
}

.btn-quick-bet:active {
    transform: translateY(1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.interaction-panel {
    max-width: 500px;
    margin: 20px auto;
}

.bet-input-section {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

#player-info-bar {
    text-align: center;
    font-weight: bold;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

/* Dealer Dashboard */
.dealer-header {
    text-align: center;
    margin-bottom: 20px;
}

.dealer-name {
    font-size: 1.3em;
    color: #667eea;
    font-weight: bold;
    margin-top: 10px;
}

.game-type-selector {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.btn-game-type {
    flex: 1;
    padding: 15px;
    border: 2px solid #667eea;
    background: white;
    border-radius: 8px;
    font-size: 1.1em;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-game-type:hover {
    background: #f0f0ff;
}

.btn-game-type.active {
    background: #667eea;
    color: white;
}

.current-game-type {
    text-align: center;
    font-weight: bold;
    color: #667eea;
    font-size: 1.1em;
}

/* Players List */
.players-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.player-item {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.player-info {
    flex: 1;
}

.player-name {
    font-weight: bold;
    font-size: 1.1em;
    color: #333;
}

.player-wallet {
    color: #666;
    margin-top: 5px;
}

.player-bet {
    color: #667eea;
    font-weight: bold;
    margin-top: 5px;
}

.player-actions {
    display: flex;
    gap: 10px;
    flex-direction: column;
}

.btn-small {
    padding: 8px 15px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9em;
    transition: all 0.2s;
}

.btn-adjust {
    background: #667eea;
    color: white;
}

.btn-kick {
    background: #dc3545;
    color: white;
}

.btn-small:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

/* Round Info */
.round-info {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.round-stat {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 6px;
}

.stat-label {
    font-weight: bold;
    color: #666;
}

.stat-value {
    font-weight: bold;
    color: #667eea;
    font-size: 1.1em;
}

/* Controls */
.controls-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
}

.btn-control {
    padding: 15px;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-warning {
    background: #ffc107;
    color: #333;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-control:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Winner Selection */
.winner-selection {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.winner-item {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-select-winner {
    background: #28a745;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 20px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s;
}

.btn-select-winner:hover {
    background: #218838;
    transform: translateY(-2px);
}

/* Player Dashboard */
.player-header {
    text-align: center;
    margin-bottom: 20px;
}

.wallet-display {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 12px;
    margin-top: 15px;
    font-size: 1.5em;
}

.wallet-label {
    display: block;
    font-size: 0.7em;
    opacity: 0.9;
    margin-bottom: 5px;
}

.wallet-amount {
    font-size: 2em;
    font-weight: bold;
}

.wallet-unit {
    font-size: 0.6em;
    opacity: 0.9;
}

/* Game Status */
.game-status {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.status-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 6px;
}

.status-label {
    color: #666;
}

.status-value {
    font-weight: bold;
    color: #667eea;
}

/* Betting Section */
.bet-input-section {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.bet-input-section input {
    flex: 1;
    margin-bottom: 0;
}

.bet-input-section button {
    width: auto;
    min-width: 120px;
}

.quick-bet-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .game-view {
        display: flex;
        flex-direction: column;
        height: 100vh;
        padding: 10px;
        gap: 10px;
    }

    .table-container {
        max-height: 45vh;
        max-width: 95vw;
        border-width: 8px;
        border-radius: 50%;
        margin: 10px auto;
        transform: perspective(800px) rotateX(20deg);
    }

    .pool-box {
        min-width: 120px;
        padding: 12px 20px;
    }

    .pool-value {
        font-size: 1.8em;
    }

    .player-info-row {
        font-size: 0.7em;
    }

    .interaction-panel {
        height: 40vh;
        overflow: hidden;
    }

    .admin-controls-container {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        margin-left: 0 !important;
        gap: 10px !important;
        height: 100%;
    }

    .card {
        padding: 10px !important;
        margin: 0;
    }

    #player-bets-card {
        flex: 1;
        display: flex !important;
        flex-direction: column;
        width: 95% !important;
        max-width: 500px !important;
    }

    #player-bets-card h3 {
        font-size: 16px !important;
        margin: 0 0 10px 0 !important;
    }

    #player-bets-card > div:first-child {
        display: grid !important;
        grid-template-columns: repeat(4, 1fr) !important;
        gap: 10px !important;
        margin-bottom: 15px !important;
    }

    #player-bets-card button {
        padding: 18px 8px !important;
        font-size: 16px !important;
        min-height: 50px !important;
        font-weight: bold !important;
    }

    #player-stats {
        background: rgba(255, 255, 255, 0.95) !important;
        border-radius: 12px !important;
        padding: 15px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
        margin-top: 10px !important;
    }

    /* Hide player betting buttons and stats for admin on mobile */
    .admin-controls-container:has(.mod-controls.active) ~ #player-bets-card,
    .admin-controls-container:has(.mod-controls.active) ~ #player-bets-card > div:first-child,
    .admin-controls-container:has(.mod-controls.active) ~ #player-bets-card #player-stats {
        display: none !important;
    }

    /* Fallback for browsers that don't support :has */
    .mod-controls.active ~ #player-bets-card {
        display: none !important;
    }

    /* Additional targeting - when admin controls are visible, hide player bets */
    #admin-controls-card[style*="block"] ~ #player-controls-card ~ #player-bets-card {
        display: none !important;
    }

    /* When moderator controls are active, hide player betting card */
    .mod-controls.active ~ #player-bets-card {
        display: none !important;
    }
}

.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.status-indicator.connected {
    background: #28a745;
    box-shadow: 0 0 10px #28a745;
}

.status-indicator.disconnected {
    background: #dc3545;
    box-shadow: 0 0 10px #dc3545;
}

/* Error Messages */
.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #f5c6cb;
}

/* Badge */
.badge {
    background: #667eea;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8em;
    margin-left: 10px;
}

/* Empty State */
.empty-state {
    text-align: center;
    color: #999;
    padding: 20px;
    font-style: italic;
}

/* Adjust Wallet Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal {
    background: white;
    border-radius: 12px;
    padding: 30px;
    max-width: 400px;
    width: 90%;
}

.modal h3 {
    margin-bottom: 20px;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.modal-actions button {
    flex: 1;
}

/* Responsive */
@media (max-width: 768px) {
    h1 {
        font-size: 2em;
    }

    .game-btn {
        padding: 30px 40px;
        min-width: 150px;
    }

    .controls-grid {
        grid-template-columns: 1fr;
    }

    .quick-bet-buttons {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ═══════════════════════════════════════════════════════════════════════════
   LOGIN PAGE  –  full-screen particle bg + floating compact card
   ═══════════════════════════════════════════════════════════════════════════ */

/* Lock the login page to one screen, no scroll */
body.login-page {
    margin: 0;
    padding: 0;
    overflow: hidden;
    height: 100vh;
    background: #000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 18px;
}

/* Canvas fills the entire viewport behind everything */
body.login-page #particle-canvas {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    display: block;
}

/* Compact card – wide, short, pinned to top */
.login-card {
    position: relative;
    z-index: 10;
    width: min(860px, 94vw);
    background: rgba(10, 10, 18, 0.78);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 16px;
    padding: 14px 28px 16px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.55);
    color: #fff;
}

/* Title + form in one row */
.login-card-inner {
    display: flex;
    align-items: center;
    gap: 24px;
}

/* Left: branding block */
.login-brand {
    flex-shrink: 0;
    text-align: center;
    min-width: 150px;
}

/* Right: form block */
.login-form-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Vertical divider between brand and form */
.login-divider {
    width: 1px;
    align-self: stretch;
    background: rgba(255, 255, 255, 0.12);
    flex-shrink: 0;
    margin: 0 4px;
}

/* Title area */
.login-card .app-title {
    font-family: 'Righteous', sans-serif;
    font-size: 1.9em;
    letter-spacing: 0.12em;
    color: #fff;
    text-align: center;
    margin-bottom: 2px;
    margin-top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
}

        .login-card .vapour-byline-wrapper {
    min-height: 18px;
    height: 18px;
}

.login-card .subtitle {
    text-align: center;
    font-size: 0.78em;
    color: rgba(255, 255, 255, 0.50);
    margin-bottom: 0;
    margin-top: 2px;
}

/* Tabs */
.login-card .role-selection-tabs {
    display: flex;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 3px;
    margin-bottom: 8px;
}

.login-card .tab-btn {
    flex: 1;
    padding: 6px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.55);
    font-weight: 600;
    font-size: 0.82em;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Outfit', sans-serif;
}

.login-card .tab-btn.active {
    background: rgba(102, 126, 234, 0.55);
    color: #fff;
}

/* Inputs */
.login-card input[type="text"],
.login-card input[type="password"] {
    width: 100%;
    padding: 7px 11px;
    margin-bottom: 8px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-size: 0.86em;
    font-family: 'Outfit', sans-serif;
    outline: none;
    box-sizing: border-box;
    transition: border 0.2s, background 0.2s;
}

.login-card input::placeholder {
    color: rgba(255, 255, 255, 0.38);
}

.login-card input:focus {
    border-color: rgba(102, 126, 234, 0.7);
    background: rgba(255, 255, 255, 0.12);
}

/* Room details row */
.login-card .room-details {
    display: flex;
    gap: 8px;
}

.login-card .room-details input {
    flex: 1;
}

/* Admin password label */
.login-card label {
    display: block;
    font-size: 0.8em;
    color: rgba(255,255,255,0.6);
    margin-bottom: 4px;
}

/* Join button */
.login-card .btn-join {
    width: 100%;
    padding: 9px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 0.95em;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    letter-spacing: 0.04em;
    margin-top: 2px;
    transition: transform 0.15s, box-shadow 0.15s;
}

.login-card .btn-join:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.5);
}

.particle-bg-canvas {
    display: block;
    width: 100%;
    height: calc(100vh - 360px);
    min-height: 260px;
    border-radius: 16px;
    margin-top: 16px;
    background: #000;
}

/* ── Join card glass form overrides ──────────────────────────────────────── */
.join-container {
    max-width: 480px;
    margin: 40px auto;
}

.join-container input[type="text"],
.join-container input[type="password"] {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 12px;
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 8px;
    background: rgba(255,255,255,0.12);
    color: #fff;
    font-size: 1em;
    font-family: 'Outfit', sans-serif;
    outline: none;
    transition: border 0.2s, background 0.2s;
    box-sizing: border-box;
}

.join-container input::placeholder {
    color: rgba(255,255,255,0.45);
}

.join-container input:focus {
    border-color: rgba(255,255,255,0.55);
    background: rgba(255,255,255,0.18);
}

.room-details {
    display: flex;
    gap: 10px;
}

.room-details input {
    flex: 1;
}

.btn-join, .join-container button[id="join-btn"] {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 1.1em;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    letter-spacing: 0.04em;
    transition: transform 0.15s, box-shadow 0.15s;
    margin-top: 6px;
}

.btn-join:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(102,126,234,0.5);
}

.form-group label {
    color: rgba(255,255,255,0.75);
    font-size: 0.9em;
    font-weight: 500;
    margin-bottom: 4px;
    display: block;
}

@media (max-width: 768px) {
    .login-card {
        width: 92vw;
        padding: 18px 20px;
    }
    .login-card-inner {
        flex-direction: column;
        gap: 16px;
    }
    .login-divider {
        display: none;
    }
    .login-form-area {
        width: 100%;
    }
    .login-card .room-details {
        flex-direction: column;
        gap: 0;
    }
    .login-card input[type="text"],
    .login-card input[type="password"] {
        font-size: 16px;
        padding: 12px 14px;
    }
    .login-card .btn-join {
        padding: 14px;
        font-size: 1.1em;
    }
}
