:root {
    --bg: #f4f4f4;
    --surface: #fff;
    --ink: #444;
    --ink-strong: #222;
    --accent: #333;
    --accent-soft: #555;
    --accent-active: #acacac;
    --muted: #9e9e9e;
    --border: #e9e9e9;
    --shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 10px 24px rgba(0, 0, 0, 0.10);
    --radius: 8px;
    --sidebar-w: 90px;
    --sidebar-h-mobile: 56px;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
    margin: 0;
    font-family: 'Cascadia Code', monospace;
    background: var(--bg);
    color: var(--ink);
    display: flex;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* ---------- Sidebar ---------- */
.sidebar {
    background-color: var(--accent);
    width: var(--sidebar-w);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 0;
    gap: 10px;
    z-index: 1000;
}

.sidebar button {
    background-color: #fff;
    border: none;
    width: 62px;
    height: 62px;
    border-radius: 8px;
    cursor: pointer;
    font-family: inherit;
    font-size: 1.4em;
    color: #222;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.sidebar button:hover {
    background-color: #ddd;
}

.sidebar button[aria-current="page"] {
    background-color: var(--accent-active);
    color: #fff;
}

/* ---------- Layout ---------- */
main {
    margin-left: var(--sidebar-w);
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

/* ---------- Header (default slim band) ---------- */
header {
    background-color: var(--accent);
    color: #fff;
    padding: 24px 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 96px;
}

.header-title {
    font-size: 1.5em;
    margin: 0;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* ---------- Sections ---------- */
section {
    padding: 48px 24px;
    max-width: 960px;
    margin: 0 auto;
    width: 100%;
}

.section-title {
    font-size: 2em;
    margin: 0 0 28px;
    text-align: center;
    font-weight: 600;
    color: var(--ink-strong);
}

/* ---------- Footer ---------- */
footer {
    margin-top: auto;
    text-align: center;
    padding: 18px;
    background-color: var(--accent);
    color: #fff;
    font-size: 0.9em;
}

footer p { margin: 0; }

/* ---------- Mobile ---------- */
@media (max-width: 768px) {
    body { flex-direction: column; }

    .sidebar {
        flex-direction: row;
        width: 100%;
        height: var(--sidebar-h-mobile);
        justify-content: space-around;
        padding: 0 6px;
        gap: 0;
    }

    .sidebar button {
        width: 44px;
        height: 44px;
        font-size: 1.15em;
    }

    main {
        margin-left: 0;
        margin-top: var(--sidebar-h-mobile);
    }

    header {
        padding: 22px 16px;
        min-height: 0;
    }

    section { padding: 32px 16px; }
    .section-title { font-size: 1.6em; margin-bottom: 22px; }
}
