:root {
    --primary-bg: #f4f7f9;
    --secondary-bg: #ffffff;
    --text-color: #333;
    --light-text: #667;
    --primary-color: #007bff;
    --green: #28a745;
    --red: #dc3545;
    --blue: #17a2b8;
    --purple: #6f42c1;
    --orange: #fd7e14;
    --pink: #e83e8c;
    --border-color: #e3e8ee;
    --shadow: 0 4px 12px rgba(0,0,0,0.08);
    --border-radius: 12px;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--primary-bg);
    color: var(--text-color);
    margin: 0;
    padding: 15px;
    display: flex;
    justify-content: center;
}
.game-container {
    width: 100%;
    max-width: 1200px;
    display: grid;
    grid-template-columns: 300px 1fr;
    grid-gap: 20px;
    transition: all 0.3s ease;
}
@media (max-width: 900px) {
    .game-container {
        grid-template-columns: 1fr;
    }
}
.sidebar, .main-content {
    background-color: var(--secondary-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 20px;
}
.player-stats h2, .time-info h2 {
    font-size: 1.2rem;
    margin-top: 0;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
    color: var(--primary-color);
}
.stat {
    display: flex;
    justify-content: space-between;
    margin: 12px 0;
    font-size: 0.95rem;
}
.stat-label {
    color: var(--light-text);
}
.stat-value {
    font-weight: 600;
}
.progress-bar {
    background-color: var(--border-color);
    border-radius: 5px;
    height: 10px;
    margin-top: 5px;
    overflow: hidden;
}
.progress-bar-inner {
    background-color: var(--green);
    height: 100%;
    width: 50%;
    border-radius: 5px;
    transition: width 0.3s ease;
}
.time-info {
    text-align: center;
    margin-top: 20px;
}
#date, #economy-status {
    font-size: 1.5rem;
    font-weight: 500;
    margin: 10px 0;
}
#economy-status {
    padding: 5px 10px;
    border-radius: 8px;
    color: white;
    font-size: 1rem;
}
.advance-time {
    width: 100%;
    padding: 12px;
    font-size: 1rem;
    font-weight: 600;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    margin-top: 10px;
}
.advance-time:hover {
    background-color: #0056b3;
}
.tabs {
    display: flex;
    flex-wrap: wrap;
    border-bottom: 2px solid var(--border-color);
    margin-bottom: 20px;
}
.tab-button {
    padding: 10px 15px;
    cursor: pointer;
    border: none;
    background: none;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--light-text);
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
}
.tab-button.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}
.tab-content {
    display: none;
}
.tab-content.active {
    display: block;
}
.action-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 15px;
}
.action-button {
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--primary-bg);
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.action-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.1);
    border-color: var(--primary-color);
}
.action-button.active-subscription, .action-button.active {
    background-color: var(--blue);
    color: white;
    border-color: var(--blue);
}
.action-button.active-subscription p, .action-button.active-subscription .req-text,
.action-button.active p, .action-button.active .req-text {
    color: rgba(255,255,255,0.9);
}
.action-button.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #e9ecef;
    transform: none;
    box-shadow: none;
    border-color: var(--border-color);
}
.action-button.danger {
    border-color: var(--red);
}
.action-button.danger:hover {
    background-color: var(--red);
    color: white;
}
.action-button.danger:hover p {
    color: white;
}
.action-button h3 {
    margin: 0 0 5px 0;
    font-size: 1rem;
}
.action-button p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--light-text);
    flex-grow: 1;
}
.req-text {
    font-size: 0.75rem;
    color: var(--purple);
    margin-top: 8px;
    font-style: italic;
}
.log-area {
    height: 150px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    padding: 10px;
    margin-top: 20px;
    border-radius: 8px;
    background-color: var(--primary-bg);
}
.log-entry {
    margin-bottom: 5px;
    font-size: 0.9rem;
}
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}
.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}
.modal-content {
    background-color: white;
    padding: 30px;
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 500px;
    text-align: center;
    transform: scale(0.9);
    transition: all 0.3s ease;
}
.modal-overlay.active .modal-content {
    transform: scale(1);
}
.modal-content h2 {
    margin-top: 0;
}
.modal-content button {
    padding: 10px 20px;
    font-size: 1rem;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    background-color: var(--primary-color);
    color: white;
    margin: 5px;
}
.modal-section {
    text-align: left; 
    border: 1px solid var(--border-color); 
    padding: 15px; 
    border-radius: 8px; 
    margin-bottom: 15px;
}
#event-modal-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}
#event-modal-effect {
    font-weight: bold;
    margin-top: 15px;
}
.finance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 15px;
}
.finance-card {
    background: var(--primary-bg);
    padding: 15px;
    border-radius: 8px;
}
.finance-card h3 {
    margin: 0 0 10px 0;
    font-size: 1.1rem;
    color: var(--primary-color);
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 8px;
}
.finance-card .stat {
    font-size: 0.9rem;
}
.list-item {
    background: white;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 8px;
    font-size: 0.9rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.status-card {
    background-color: var(--blue);
    color: white;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 15px;
}
.status-card h3 {
    margin: 0 0 10px 0;
    color: white;
}
.status-card p {
    margin: 0;
    opacity: 0.9;
}