:root {
    --bg: #0f1216;
    --panel: #151a21;
    --panel-2: #1c222b;
    --text: #e8ecf1;
    --muted: #a8b3c2;
    --accent: #46d6a4;
    --accent-2: #2a8f72;
    --border: #263040;
}

html,
body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "IBM Plex Mono", "SFMono-Regular", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    background: radial-gradient(circle at 20% 20%, rgba(70, 214, 164, 0.12), transparent 40%),
        radial-gradient(circle at 80% 10%, rgba(51, 130, 245, 0.15), transparent 45%),
        linear-gradient(160deg, #0b0e12 0%, #11161d 100%);
    color: var(--text);
    padding: 32px;
}

.page {
    width: 100%;
    max-width: 100%;
}

header {
    max-width: 960px;
    margin: 0 auto 24px auto;
}

h1 {
    margin: 0 0 8px 0;
    font-size: 28px;
    letter-spacing: 0.02em;
}

p {
    margin: 0;
    color: var(--muted);
}

.grid {
    max-width: 960px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    min-width: 0;
}

.card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.28);
}

label {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
    color: var(--muted);
}

textarea {
    width: 100%;
    min-height: 140px;
    background: var(--panel-2);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 12px;
    border-radius: 10px;
    resize: vertical;
    font-size: 14px;
    line-height: 1.5;
}

.actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.summary {
    display: block;
    width: 100%;
    max-width: 100%;
    font-size: 12px;
    color: var(--muted);
    box-sizing: border-box;
    overflow: hidden;
}

.summary div {
    margin: 4px 0;
}

.summary span,
.summary b {
    color: var(--text);
}

button {
    appearance: none;
    border: none;
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: #0b0e12;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.08s ease, box-shadow 0.2s ease;
    box-shadow: 0 8px 20px rgba(70, 214, 164, 0.25);
}

button:hover {
    transform: translateY(-1px);
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
}

.status {
    font-size: 12px;
    color: var(--muted);
}

.toggle-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.is-hidden {
    display: none;
}

pre {
    margin: 0;
    background: #0c1016;
    border: 1px solid var(--border);
    padding: 16px;
    border-radius: 12px;
    overflow: auto;
    max-height: 360px;
}

code {
    color: #c7d7ea;
    font-size: 13px;
}

.table-wrap {
    margin-top: 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #0c1016;
    max-height: 360px;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: auto;
    box-sizing: border-box;
}

table {
    border-collapse: collapse;
    font-size: 13px;
}

.table-wrap table {
    width: max-content;
    max-width: none;
}

th,
td {
    padding: 8px 10px;
    border-bottom: 1px solid #1f2835;
    white-space: nowrap;
}

th {
    position: sticky;
    top: 0;
    background: #111720;
    color: var(--muted);
    text-align: left;
}

tbody tr:nth-child(odd) td {
    background: #0e141c;
}

.charts {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

.chart-wrap {
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #0c1016;
    padding: 8px;
    overflow: hidden;
}

.chart-title {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--muted);
    margin: 4px 6px 8px 6px;
}

.chart-status {
    font-size: 12px;
    color: var(--muted);
    margin: 0 0 8px 6px;
}

.chart-canvas {
    width: 100%;
    height: 420px;
    border-radius: 10px;
    overflow: hidden;
}

@media (max-width: 680px) {
    body {
        padding: 20px;
    }

    h1 {
        font-size: 22px;
    }
}
