* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: #f4f6f8;
    color: #1f2937;
}

.hidden {
    display: none !important;
}

.page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: white;
    border-radius: 18px;
    padding: 32px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.08);
}

.brand {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.brand-logo {
    width: 55px;
    height: 55px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #111827;
    color: white;
    font-weight: bold;
    font-size: 20px;
}

.brand h1 {
    margin: 0;
    font-size: 22px;
}

.brand p {
    margin: 5px 0 0;
    color: #6b7280;
}

label {
    display: block;
    margin: 15px 0 7px;
    font-weight: 600;
}

input {
    width: 100%;
    padding: 13px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    font-size: 15px;
}

button {
    border: none;
    border-radius: 10px;
    padding: 13px 18px;
    background: #111827;
    color: white;
    cursor: pointer;
    font-weight: 600;
}

#login-form button {
    width: 100%;
    margin-top: 22px;
}

.error {
    color: #b91c1c;
    margin-top: 15px;
    min-height: 20px;
}

.topbar {
    background: white;
    border-bottom: 1px solid #e5e7eb;
    padding: 18px 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar h1 {
    margin: 0;
    font-size: 21px;
}

.topbar span {
    color: #6b7280;
    font-size: 14px;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.secondary-btn {
    background: #e5e7eb;
    color: #111827;
}

.container {
    max-width: 1400px;
    margin: auto;
    padding: 25px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-bottom: 22px;
}

.stat-card {
    background: white;
    border-radius: 15px;
    padding: 22px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.04);
}

.stat-label {
    display: block;
    color: #6b7280;
    font-size: 14px;
    margin-bottom: 12px;
}

.stat-card strong {
    font-size: 30px;
    margin-right: 5px;
}

.stat-card small {
    color: #6b7280;
}

.panel {
    background: white;
    border-radius: 15px;
    padding: 22px;
    margin-bottom: 22px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.04);
}

.panel-header {
    margin-bottom: 20px;
}

.panel-header h2 {
    margin: 0;
    font-size: 20px;
}

.panel-header p {
    margin: 6px 0 0;
    color: #6b7280;
}

.plots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.plot-card {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 18px;
}

.plot-card h3 {
    margin: 0 0 7px;
}

.plot-card p {
    margin: 4px 0;
    color: #6b7280;
}

.online {
    margin-top: 12px;
    font-weight: 600;
}

.table-wrapper {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 13px 10px;
    border-bottom: 1px solid #e5e7eb;
    text-align: left;
}

th {
    font-size: 13px;
    color: #6b7280;
}

.chart-container {
    position: relative;
    height: 380px;
}

@media (max-width: 900px) {

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .plots-grid {
        grid-template-columns: 1fr;
    }

}

@media (max-width: 600px) {

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .topbar {
        padding: 15px;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .container {
        padding: 15px;
    }

}
