:root {
    --lavender: #eeeeffff;
    --lavender-grey: #7f7cafff;
    --powder-blue: #9fb4c7ff;
    --baltic-blue: #28587bff;
    --muted-teal: #9fb798ff;
    
    --bg-color: var(--lavender);
    --text-color: #333;
    --card-bg: white;
    --primary-color: var(--baltic-blue);
    --secondary-color: var(--lavender-grey);
    --accent-color: var(--muted-teal);
    --danger-color: #e76f51;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    justify-content: center;
    min-height: 100vh;
}

.app-container {
    width: 100%;
    max-width: 500px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    height: 100vh;
    position: relative;
    overflow: hidden;
}

header {
    text-align: center;
    margin-bottom: 20px;
}

h1.logo {
    color: var(--baltic-blue);
    font-size: 2rem;
}

.screen {
    display: none;
    flex-direction: column;
    align-items: center;
    flex: 1;
    animation: fadeIn 0.3s ease-in-out;
}

.screen.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* CARDS */
.card {
    background: var(--card-bg);
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    padding: 20px;
    width: 100%;
    margin-bottom: 20px;
}

/* INPUTS & BUTTONS */
.input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

input[type="text"] {
    flex: 1;
    padding: 12px;
    border: 2px solid var(--powder-blue);
    border-radius: 12px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

input[type="text"]:focus {
    border-color: var(--baltic-blue);
}

.btn {
    border: none;
    border-radius: 12px;
    padding: 12px 20px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s, opacity 0.2s;
}

.btn:active {
    transform: scale(0.98);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary {
    background-color: var(--baltic-blue);
    color: white;
}

.btn-secondary {
    background-color: var(--lavender-grey);
    color: white;
}

.btn-baltic {
    background-color: var(--muted-teal);
    color: white; /* Darker text for contrast on teal */
}

.btn-lg {
    width: 100%;
    padding: 16px;
    font-size: 1.2rem;
    margin-top: 10px;
}

/* PLAYER LIST */
.player-list {
    list-style: none;
    max-height: 300px;
    overflow-y: auto;
}

.player-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid #eee;
    animation: slideIn 0.2s;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

.player-name {
    font-weight: 500;
}

.remove-btn {
    background: none;
    border: none;
    color: var(--danger-color);
    font-size: 1.2rem;
    cursor: pointer;
}

.player-count {
    text-align: right;
    font-size: 0.8rem;
    color: #888;
    margin-top: 10px;
}

/* REVEAL SCREEN */
.highlight-name {
    color: var(--baltic-blue);
    font-size: 2.5rem;
    margin: 20px 0;
    text-align: center;
}

.role-card {
    height: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    cursor: pointer;
    background: linear-gradient(135deg, white, #f8f9fa);
    border: 2px solid var(--powder-blue);
    position: relative;
    overflow: hidden;
}

.lock-icon {
    font-size: 4rem;
    margin-bottom: 10px;
    color: var(--lavender-grey);
}

.secret-word {
    font-size: 2.2rem;
    color: var(--baltic-blue);
    margin: 15px 0;
}

.impostor-text {
    color: var(--danger-color);
}

.hidden {
    display: none !important;
}

/* GAME SCREEN */
.timer {
    font-size: 3rem;
    font-weight: 800;
    color: var(--baltic-blue);
    margin: 20px 0;
    font-variant-numeric: tabular-nums;
}

.info-card {
    text-align: center;
}

.actions.column {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

/* MODAL */
.modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    animation: zoomIn 0.3s;
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.result-info {
    margin: 20px 0;
}

.divider {
    height: 1px;
    background: #eee;
    margin: 15px 0;
}
