/* ==============================================
   BASE - Full-height layout & shared styles
   ============================================== */

* {
    box-sizing: border-box;
}

/* Full-height flex layout */
html,
body {
    height: 100%;
    margin: 0;
    overflow: hidden;
}

body {
    display: flex;
    flex-direction: column;
    font: 14px/1.5 system-ui, -apple-system, sans-serif;
    background: var(--bg-base);
    color: var(--text-base);
}

/* ==============================================
   HEADER
   ============================================== */

header {
    align-items: center;
    background: var(--bg-deep);
    border-bottom: 1px solid var(--line);
    display: flex;
    flex: 0 0 var(--header-height);
    gap: var(--pad);
    justify-content: space-between;
    padding: 0 var(--pad-lg);
}

header-left,
header-center,
header-right {
    align-items: center;
    display: flex;
    gap: var(--pad-sm);
}

header-left {
    flex: 0 0 auto;
}

header-center {
    flex: 1;
    justify-content: center;
}

header-right {
    flex: 0 0 auto;
}

/* ==============================================
   MAIN
   ============================================== */

main {
    display: flex;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* ==============================================
   FOOTER
   ============================================== */

footer {
    align-items: center;
    background: var(--bg-deep);
    border-top: 1px solid var(--line);
    color: var(--text-muted);
    display: flex;
    flex: 0 0 var(--footer-height);
    font-size: 12px;
    justify-content: center;
    padding: 0 var(--pad-lg);
}

/* ==============================================
   TYPOGRAPHY
   ============================================== */

h1,
h2,
h3 {
    color: var(--text-bright);
    font-weight: 600;
    margin: 0;
}

h1 {
    font-size: 1.25rem;
}

h2 {
    font-size: 1.1rem;
}

h3 {
    font-size: 1rem;
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

code {
    background: var(--bg-hover);
    border-radius: var(--radius-sm);
    font-size: 0.9em;
    padding: 2px 6px;
}

/* ==============================================
   BUTTONS
   ============================================== */

button {
    background: var(--overlay-white-10);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    color: var(--text-base);
    cursor: pointer;
    font: inherit;
    padding: var(--pad-sm) var(--pad);
    transition:
        background var(--transition-fast),
        border-color var(--transition-fast),
        color var(--transition-fast);
}

button:hover {
    background: var(--overlay-blue-10);
    border-color: var(--accent);
    color: var(--text-bright);
}

button:active {
    transform: scale(0.98);
}