@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&family=Inter:wght@300;400;500;600&display=swap');

:root {
    --bg-color: #0b0b1a;
    --card-bg: rgba(22, 22, 43, 0.65);
    --border-color: rgba(99, 99, 153, 0.35);
    --text-primary: #f0f0f7;
    --text-secondary: #aaaab9;
    --accent-color: #7b66ff;
    --accent-glow: rgba(123, 102, 255, 0.4);
}

body {
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(at 0% 0%, rgba(20, 20, 60, 0.5) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(30, 20, 50, 0.4) 0px, transparent 50%);
    color: var(--text-primary);
    font-family: 'Inter', 'Outfit', system-ui, sans-serif;
    font-size: 14px;
    margin: 0;
    padding: 0;
}

body.modern-ui {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

/* Container & Grid layout */
.game-container {
    width: 100%;
    max-width: 960px;
    margin: 20px auto;
    padding: 0 15px;
    box-sizing: border-box;
}

.game-layout {
    display: grid;
    grid-template-columns: 1fr 240px;
    gap: 20px;
    margin-top: 15px;
}

@media (max-width: 768px) {
    .game-layout {
        grid-template-columns: 1fr;
    }
}

/* Card components */
.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    margin-bottom: 20px;
}

.card-title {
    font-family: 'Outfit', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Format tables inside cards */
.card table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
    color: var(--text-primary);
    background-color: transparent !important;
}

.card tr {
    background-color: transparent !important;
    transition: background-color 0.2s ease;
}

.card tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.02) !important;
}

.card tr:hover {
    background-color: rgba(255, 255, 255, 0.06) !important;
}

.card th, .card td {
    padding: 12px 10px;
    border-bottom: 1px solid var(--border-color);
    text-align: center;
    background-color: transparent !important;
}

.card th {
    background-color: rgba(255, 255, 255, 0.05) !important;
    font-weight: 600;
    color: #ffffff;
}

/* Style legacy header row having bgcolor attribute or align center */
.card tr[bgcolor="#ccccee"] td, .card tr[align="center"] td {
    background-color: rgba(255, 255, 255, 0.08) !important;
    font-weight: 600;
    color: #ffffff !important;
}


/* Legacy fonts overrides */
tt, pre {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 14px;
    line-height: 1.6;
}

.moji1 { font-size: 14px; color: var(--text-primary); }
.moji2 { font-size: 12px; color: var(--text-secondary); }

/* Buttons & Inputs */
.button1, .button2, .button3, input[type="submit"], input[type="button"], input[type="reset"] {
    font-family: 'Outfit', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #ffffff;
    background-color: var(--accent-color);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 8px 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px var(--accent-glow);
    display: inline-block;
    text-align: center;
    box-sizing: border-box;
}

.button1 {
    width: 100%;
    height: auto;
    margin-bottom: 10px;
}

.button1:hover, .button2:hover, .button3:hover, input[type="submit"]:hover, input[type="button"]:hover {
    background-color: #644eff;
    box-shadow: 0 6px 16px rgba(123, 102, 255, 0.6);
    transform: translateY(-2px);
}

select {
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    color: #ffffff;
    background-color: #1a1a3a;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 8px 12px;
    width: 100%;
    height: auto;
    cursor: pointer;
    box-sizing: border-box;
    margin-bottom: 10px;
}

input[type="text"], input[type="password"] {
    background-color: rgba(10, 10, 25, 0.6);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 6px 10px;
    color: #ffffff;
    font-family: 'Inter', sans-serif;
}

/* Stat progress bars */
img[src*="spc.gif"] {
    display: inline-block !important;
    height: 10px !important;
    border-radius: 5px;
    vertical-align: middle;
    margin: 0 8px;
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.2);
}

/* Header illustration */
.menu-illustration {
    width: 100%;
    max-height: 200px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.title-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.title-images {
    display: flex;
    align-items: center;
    gap: 15px;
}

.title-images img {
    max-height: 50px;
}

hr {
    border: 0;
    height: 1px;
    background-image: linear-gradient(to right, rgba(99, 99, 153, 0), rgba(99, 99, 153, 0.75), rgba(99, 99, 153, 0));
    margin: 20px 0;
}

/* Quick fixes for alignment */
center {
    display: block;
    width: 100%;
}
