/* ── Production header (title + hamburger only) ────────── */

.production-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: #0d1b2a;
    border-bottom: 1px solid #e2b96f44;
}

.production-logo {
    height: 1.4rem;
    width: 1.4rem;
    border-radius: 3px;
    flex-shrink: 0;
}

.production-title {
    font-size: 1.4rem;
    color: #e2b96f;
    margin: 0;
    white-space: nowrap;
}

.hamburger-btn {
    background: none;
    border: none;
    color: #e2b96f;
    font-size: 1.6rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    line-height: 1;
    margin-left: auto;
}

/* ── Drawer backdrop ───────────────────────────────────── */

.drawer-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
    z-index: 90;
}

.drawer-backdrop.open {
    opacity: 1;
    pointer-events: auto;
}

/* ── Slide-out drawer ──────────────────────────────────── */

.drawer {
    position: fixed;
    top: 0;
    /* Animate with right instead of transform so the drawer doesn't create
       a new containing block (which would trap position:fixed children like modals). */
    right: calc(-1 * min(20rem, 85vw));
    bottom: 0;
    width: min(20rem, 85vw);
    background: #0d1b2a;
    border-left: 1px solid #e2b96f44;
    transition: right 0.25s ease;
    z-index: 100;
    overflow-y: auto;
    padding: 1.5rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.drawer.open {
    right: 0;
}

.drawer-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.drawer-close {
    background: none;
    border: none;
    color: #888;
    font-size: 1.8rem;
    cursor: pointer;
    line-height: 1;
    padding: 0 0.25rem;
}

.drawer-close:hover {
    color: #fff;
}

/* ── Drawer contents ───────────────────────────────────── */

.drawer-section {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.drawer-label {
    font-size: 0.85rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.drawer-item {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    background: #1a1a2e;
    border: 1px solid #333;
    border-radius: 6px;
    color: #ccc;
    font-size: 1.1rem;
    cursor: pointer;
    text-align: left;
}

.drawer-item:hover {
    background: #2a2a3e;
    color: #fff;
}

/* Page toggle inside drawer */
.drawer .page-toggle-group {
    display: flex;
    gap: 0;
    width: 100%;
}

.page-toggle {
    flex: 1;
    padding: 0.5rem;
    background: #1a1a2e;
    color: #888;
    border: 1px solid #e2b96f44;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s;
}

.page-toggle:first-child {
    border-radius: 6px 0 0 6px;
}

.page-toggle:not(:first-child) {
    border-left: none;
}

.page-toggle:last-child {
    border-radius: 0 6px 6px 0;
}

.page-toggle.active {
    background: #e2b96f;
    color: #0d1b2a;
    font-weight: 600;
}

/* Lesson nav inside drawer: vertical stack */
.drawer .lesson-nav {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.drawer .nav-btn {
    text-align: left;
    width: 100%;
}

/* Language select inside drawer */
.drawer .lang-select {
    width: max-content;
    padding: 0.5rem;
    margin: 0;
    font-size: 1rem;
}

/* Ruleset select inside drawer */
.drawer .ruleset-select {
    width: 100%;
    padding: 0.6rem 0.75rem;
    background: #1a1a2e;
    color: #ccc;
    border: 1px solid #e2b96f44;
    border-radius: 6px;
    font-size: 1.1rem;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2rem;
}

.drawer .ruleset-select:focus {
    outline: none;
    border-color: #e2b96f;
}
