body {
    background: #0f172a;
    font-family: 'Poppins',sans-serif;
    color: white;
}

.main-card {
    width: 60%;
    margin: 120px auto 80px auto;
    background: #1e293b;
    padding: 40px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0px 10px 30px rgba(0,0,0,0.4);
}

.scenario-list {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}


.scenario-card {
    display: inline-block;
    width: 260px;
    background: #0f172a;
    border: 1px solid rgba(255,255,255,0.06);
    padding: 18px 22px;
    border-radius: 12px;
    text-decoration: none;
    color: #fff;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.scenario-card.clickable { cursor: pointer; }

.scenario-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.45);
}

/* Ensure link states do not show default blue/underline */
.scenario-card:link,
.scenario-card:visited,
.scenario-card:active,
.scenario-card:hover {
    color: #fff !important;
    text-decoration: none !important;
}

/* Make the whole card a block for consistent padding/click area */
.scenario-card {
    display: block;
}

@media (max-width: 700px) {
    .main-card { width: 90%; padding: 20px; }
    .scenario-list { flex-direction: column; gap: 12px; }
    .scenario-card { width: 100%; }
}

.scenario-name {
    font-weight: 600;
    font-size: 18px;
    margin-bottom: 8px;
}

.scenario-subtext {
    font-size: 14px;
    color: #94a3b8;
}

.title {
    font-size: 40px;
    font-weight: 600;
    margin-bottom: 20px;
}

.subtitle {
    font-size: 18px;
    color: #94a3b8;
}

.subtext {
    font-size: 16px;
    color: #cbd5e1;
    line-height: 1.6;
}

.sim-btn {
    background: #6366f1;
    border: none;
    padding: 18px 35px;
    border-radius: 10px;
    font-size: 18px;
    color: white;
    transition: 0.3s;
}

    .sim-btn:hover {
        /* keep the same color on hover to avoid default blue link color */
        background: #6366f1;
        transform: scale(1.05);
    }

/* Ensure all link/button states keep the same background and text color */
.sim-btn:link,
.sim-btn:visited,
.sim-btn:active,
.sim-btn:hover,
.sim-btn:focus {
    color: #ffffff !important;
    text-decoration: none !important;
    background: #6366f1 !important;
    outline: none !important;
    box-shadow: none !important;
}

/* Decision buttons styling (left column) */
.decision-btn {
    display: block;
    width: 100%;
    max-width: 560px;
    text-align: left;
    margin: 12px 0;
    white-space: normal;
    word-wrap: break-word;
    line-height: 1.4;
    padding: 18px 24px;
    font-size: 18px;
}

/* Scenario list buttons (use same style as home buttons but block-level) */
.scenario-btn {
    display: block;
    width: 320px;
    margin: 10px auto;
    padding: 12px 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: none;
}

.scenario-btn .scenario-name { font-size: 18px; font-weight: 600; }
.scenario-btn .scenario-subtext { font-size: 14px; color: #e6e6ff; margin-top: 6px; }

/* Scenario select page layout cleanup */
.scenario-select-card {
    max-width: 1100px;
    width: 95%;
}

.scenario-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    align-items: stretch;
    justify-items: stretch;
}

.scenario-grid .scenario-btn {
    width: 100%;
    margin: 0;
    min-height: 210px;
    padding: 18px 14px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
}

.scenario-grid .scenario-name {
    font-size: 18px;
    line-height: 1.25;
    margin-bottom: 10px;
}

.scenario-grid .scenario-subtext {
    font-size: 15px;
    line-height: 1.35;
    color: #e6e6ff;
}
/* Registration form improvements */
.register-card {
    width: 420px;
    margin: 100px auto;
    background: #232946;
    padding: 36px 32px;
    border-radius: 18px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    text-align: center;
}
.register-card .title {
    font-size: 2.4rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: #fff;
}
.register-card .subtitle {
    font-size: 1.2rem;
    color: #b8c1ec;
    margin-bottom: 24px;
}
.register-card .form-group {
    margin-bottom: 18px;
    text-align: left;
}
.register-card .input {
    width: 100%;
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid #b8c1ec;
    font-size: 1rem;
    margin-top: 4px;
    background: #fff;
    color: #232946;
    box-sizing: border-box;
}
.register-card .validator {
    color: #ff4d4d;
    font-size: 0.95rem;
    margin-left: 4px;
}
.register-card .sim-btn {
    width: 100%;
    padding: 12px;
    background: #6d6ee7;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    margin-top: 8px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: background 0.2s;
}
.register-card .sim-btn:hover {
    background: #4f4fcf;
}
.register-card .login-link {
    margin-top: 16px;
    color: #b8c1ec;
    font-size: 1rem;
}
.register-card .login-link a {
    color: #6d6ee7;
    text-decoration: underline;
}
.register-card .subtext {
    color: #ff4d4d;
    margin-bottom: 10px;
    display: block;
    font-size: 1rem;
}

/* Shared auth (login/register) layout */
.auth-wrapper {
    max-width: 420px;
    margin: 120px auto 70px auto;
}

.auth-card {
    width: 100%;
    background: #1e293b;
    padding: 32px 30px 28px;
    border-radius: 18px;
    box-shadow: 0 14px 40px rgba(15, 23, 42, 0.85);
    text-align: center;
}

.auth-title {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 8px;
}

.auth-subtitle {
    font-size: 15px;
    color: #94a3b8;
    margin-bottom: 22px;
}

.auth-error {
    display: block;
    min-height: 20px;
    margin-bottom: 6px;
    font-size: 13px;
    color: #f97373;
}

.auth-form {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.auth-field {
    margin-bottom: 16px;
    text-align: left;
}

.auth-label {
    display: block;
    font-size: 13px;
    color: #e5e7eb;
    margin-bottom: 4px;
}

.auth-input {
    width: 100%;
    padding: 10px 12px;
    border-radius: 999px;
    border: 1px solid #4b5563;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
    box-sizing: border-box;
}

.auth-input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 1px #6366f1;
}

.auth-password-wrap {
    position: relative;
}

.auth-input-password {
    padding-right: 44px;
}

.auth-eye-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: #94a3b8;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
}

.auth-eye-btn:hover {
    color: #e5e7eb;
}

.auth-validator {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: #f97373;
}

.auth-btn {
    width: 100%;
    margin-top: 4px;
    padding: 11px 14px;
    border-radius: 10px;
    border: none;
    background: #6366f1;
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.auth-btn:hover {
    background: #4f46e5;
    transform: translateY(-1px);
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.45);
}

.auth-footer {
    margin-top: 18px;
    font-size: 13px;
    color: #9ca3af;
    text-align: center;
}

.auth-footer a {
    color: #a5b4fc;
    text-decoration: underline;
}

/* Leaderboard styling */
.leaderboard-card {
    max-width: 900px;
}

.leaderboard-grid {
    width: 100%;
    margin-top: 24px;
    border-collapse: separate;
    border-spacing: 0 8px;
    font-size: 14px;
}

.leaderboard-grid thead tr {
    background: transparent;
}

.leaderboard-grid th {
    padding: 8px 12px;
    text-align: left;
    font-weight: 500;
    color: #9ca3af;
    border-bottom: 1px solid #334155;
}

.leaderboard-grid td {
    padding: 10px 12px;
    border-top: 1px solid rgba(15,23,42,0);
    border-bottom: 1px solid rgba(15,23,42,0);
}

.leaderboard-grid tr:nth-child(even) td {
    background: #020617;
}

.leaderboard-grid tr:nth-child(odd) td {
    background: #020617;
}

.leaderboard-grid tr:hover td {
    background: #111827;
}

.leaderboard-grid td:first-child,
.leaderboard-grid th:first-child {
    text-align: center;
    width: 40px;
    color: #e5e7eb;
}

.leaderboard-grid td:nth-child(4) {
    font-weight: 600;
    color: #fbbf24;
}

.leaderboard-grid td:nth-child(2) {
    font-weight: 500;
}

/* Simple text-style admin links can reuse button look */
.link-btn {
    color: #60a5fa;
    font-size: 13px;
    margin-right: 10px;
}

.link-btn.link-danger {
    color: #f97373;
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.admin-card {
    display: block;
    padding: 18px 20px;
    border-radius: 14px;
    background: #020617;
    border: 1px solid rgba(148, 163, 184, 0.25);
    text-decoration: none;
    color: #e5e7eb;
    transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}

.admin-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.8);
    border-color: #6366f1;
    text-decoration: none;
}

.admin-card-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 6px;
}

.admin-card-subtext {
    font-size: 13px;
    color: #94a3b8;
}
