/* =============================================================
   2k6Economy - Stylesheet
   Based on Owen2k6 Network Design Language
   ============================================================= */

/* GLOBAL RESET */
*, *:before, *:after { box-sizing: border-box; }

html, body { height: 100%; }

body {
    margin: 0;
    font-size: 15px;
    line-height: 1.6;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    color: #f2f2f2;
    background-color: #1a1a1a;
    background-image: linear-gradient(to bottom, #181818 0%, #1a1a1a 100%);
    -webkit-text-size-adjust: 100%;
    text-rendering: optimizeLegibility;
    overflow-wrap: anywhere;
    word-wrap: break-word;
}

/* HEADER */
.site-header {
    width: 100%;
    margin: 0;
    padding: 14px 4%;
    color: #fff;
    background-color: #2b2b2b;
    border-bottom: 2px solid #555;
    background-image: linear-gradient(to bottom, #3b3b3b, #1e1e1e);
    box-shadow: 0 2px 6px rgba(0,0,0,0.6);
    font-family: "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.header-title {
    margin: 0;
    font-size: 1.8em;
    text-shadow: 1px 1px 2px #000;
    font-weight: normal;
}

.header-nav {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
}

.header-nav a {
    color: #a7c7ff;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    transition: background 0.2s;
}

.header-nav a:hover {
    background: rgba(255,255,255,0.1);
}

.header-nav a.active {
    background: rgba(255,255,255,0.15);
    color: #fff;
}

/* MAIN CONTENT */
.site-main {
    width: 100%;
    margin: 0;
    padding: 12px 4%;
}

.content-container {
    background-color: #1e1e1e;
    max-width: 1200px;
    margin: 14px auto;
    padding: 16px;
    border-radius: 10px;
    border: 1px solid #2a2a2a;
    box-shadow: 0 0 16px rgba(0,0,0,0.6);
}

/* PANELS */
.panel-inset {
    margin: 0 0 20px 0;
    padding: 20px;
    border: 1px solid #444;
    background-color: #242424;
    border-radius: 8px;
    box-shadow: inset 2px 2px 5px #0e0e0e, inset -2px -2px 5px #2e2e2e;
    background-image: linear-gradient(145deg, #2e2e2e, #1c1c1c);
}

/* TYPOGRAPHY */
h1, h2, h3 {
    font-weight: normal;
    margin: 0;
    color: #fff;
    text-shadow: 1px 1px 2px #000;
}

h1 {
    font-size: 1.8em;
    margin: 20px 0;
}

h2 {
    font-size: 1.55em;
    margin: 0 0 0.7em 0;
    line-height: 1.3;
}

h3 {
    font-size: 1.3em;
    margin: 0 0 0.5em 0;
}

.section-header {
    margin: 20px 0 10px 0;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 1.1em;
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
}

.subtitle {
    color: #888;
    margin: 0;
}

/* STATS OVERVIEW */
.stats-overview {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.stat-tile {
    background: linear-gradient(145deg, #2a2a2a, #1e1e1e);
    border: 1px solid #3a3a3a;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    box-shadow: inset 1px 1px 2px rgba(255,255,255,0.05),
                inset -1px -1px 2px rgba(0,0,0,0.3),
                0 4px 8px rgba(0,0,0,0.3);
}

.stat-tile .number {
    display: block;
    font-size: 2em;
    font-weight: bold;
    margin-bottom: 5px;
    color: #55cc55;
}

.stat-tile .label {
    font-size: 0.85em;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* TABLES */
.economy-table-container {
    overflow-x: auto;
    margin-bottom: 20px;
}

.economy-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
}

.economy-table th {
    background: #151515;
    color: #777;
    text-align: left;
    padding: 12px;
    border-bottom: 1px solid #333;
    text-transform: uppercase;
    font-size: 0.85em;
    letter-spacing: 0.5px;
}

.economy-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #2a2a2a;
    color: #ccc;
}

.economy-table tr:nth-child(even) {
    background: #1c1c1c;
}

.economy-table tr:hover {
    background: #2a2a2a;
}

.player-cell {
    white-space: nowrap;
}

.player-cell img {
    vertical-align: middle;
    margin-right: 8px;
}

.player-cell span {
    vertical-align: middle;
}

.player-head {
    width: 24px;
    height: 24px;
    border-radius: 3px;
    border: 1px solid #444;
    vertical-align: middle;
}

.balance-cell {
    color: #55cc55 !important;
    font-weight: bold;
}

.rank-1 { color: #ffd700 !important; font-weight: bold; } /* Gold */
.rank-2 { color: #c0c0c0 !important; font-weight: bold; } /* Silver */
.rank-3 { color: #cd7f32 !important; font-weight: bold; } /* Bronze */

/* BUTTONS */
.view-btn, .action-btn {
    display: inline-block;
    padding: 6px 12px;
    background: linear-gradient(to bottom, #0066cc, #004499);
    color: white;
    border: 1px solid #003366;
    border-radius: 4px;
    font-size: 0.85em;
    text-decoration: none;
    text-shadow: 1px 1px 1px #000;
    cursor: pointer;
    transition: background 0.2s;
}

.view-btn:hover, .action-btn:hover {
    background: linear-gradient(to bottom, #0055aa, #003377);
}

.action-btn.large {
    padding: 12px 24px;
    font-size: 1em;
}

.action-btn.green {
    background: linear-gradient(to bottom, #228822, #006600);
    border-color: #004400;
}

.action-btn.green:hover {
    background: linear-gradient(to bottom, #117711, #005500);
}

/* FORMS */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #888;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    background: #151515;
    border: 1px solid #333;
    border-radius: 4px;
    color: #fff;
    font-size: 1em;
    font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #0066cc;
    box-shadow: 0 0 4px rgba(0,102,204,0.3);
}

/* PAGINATION */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 15px;
}

.page-btn {
    padding: 8px 16px;
    background: #333;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.2s;
}

.page-btn:hover {
    background: #444;
}

.page-btn.active {
    background: #0066cc;
}

.page-info {
    color: #888;
}

/* ALERTS */
.alert {
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
    border-left: 4px solid;
}

.alert.success {
    background: rgba(34, 136, 34, 0.2);
    border-color: #228822;
    color: #55cc55;
}

.alert.error {
    background: rgba(204, 68, 68, 0.2);
    border-color: #cc4444;
    color: #ff7777;
}

.alert.info {
    background: rgba(0, 102, 204, 0.2);
    border-color: #0066cc;
    color: #77aaff;
}

/* CHARTS */
.chart-container {
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
}

/* LOADING */
.loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

/* LOGIN FORM */
.login-container {
    max-width: 400px;
    margin: 60px auto;
}

.login-form {
    background: #242424;
    padding: 30px;
    border-radius: 10px;
    border: 1px solid #3a3a3a;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

/* SERVER GRID */
.server-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.server-card {
    background: linear-gradient(145deg, #252525, #1a1a1a);
    border: 1px solid #3a3a3a;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.server-card h4 {
    color: #fff;
    margin-bottom: 10px;
    font-size: 1.2em;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }

    .header-nav {
        justify-content: center;
    }

    .site-main {
        padding: 8px 2%;
    }

    .stats-overview {
        grid-template-columns: repeat(2, 1fr);
    }

    .server-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .header-title {
        font-size: 1.5em;
    }

    .stats-overview {
        grid-template-columns: 1fr;
    }
}

