/* ============================================================
   Kindle PW3 Dashboard - Base Styles
   Target: WebKit 533.2 (mesquite)
   Layout: float + table + absolute ONLY
   Box model: content-box (default)
   Screen: 1072x1448 portrait, 1448x1072 landscape
   ============================================================ */

/* ===== Reset ===== */
* { margin: 0; padding: 0; }
html, body {
    overflow: hidden;
    background: #fff;
    color: #000;
    font-family: Georgia, "Noto Serif CJK SC", SimSun, serif;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}

/* ===== Portrait (default) ===== */
html { width: 1072px; height: 1448px; }
body { width: 1072px; height: 1448px; }

.page-wrap {
    position: relative;
    width: 1072px;
    height: 1448px;
    overflow: hidden;
}

/* ===== Landscape (CSS transform rotate) =====
   Rotate page-wrap 90deg CCW so landscape content fills portrait screen.
   Transform-origin at center of page-wrap (536, 724).
   After rotation, shift left=-188, top=188 to center on screen.
*/
html.landscape { overflow: hidden; }
html.landscape body { overflow: hidden; }
html.landscape .page-wrap {
    position: absolute;
    width: 1448px;
    height: 1072px;
    left: -188px;
    top: 188px;
    -webkit-transform-origin: 724px 536px;
    -webkit-transform: rotate(90deg);
}

/* ===== Menu Trigger (top-right corner) ===== */
.menu-trigger {
    position: absolute;
    top: 0;
    right: 0;
    width: 90px;
    height: 70px;
    z-index: 500;
    cursor: pointer;
    text-align: center;
}
.menu-trigger-icon {
    display: table-cell;
    vertical-align: middle;
    width: 90px;
    height: 70px;
    font-size: 36px;
    color: #000;
    font-weight: bold;
    letter-spacing: 4px;
}

/* ===== Menu Overlay ===== */
.menu-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 600;
    display: none;
}
.menu-overlay.show { display: block; }

.menu-bg {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: #000;
    opacity: 0.3;
}

.menu-panel {
    position: absolute;
    top: 70px;
    right: 20px;
    width: 320px;
    background: #fff;
    border: 3px solid #000;
    z-index: 601;
}

/* ===== Menu Items ===== */
.menu-item {
    padding: 20px 24px;
    font-size: 26px;
    border-bottom: 2px solid #ddd;
    cursor: pointer;
    overflow: hidden;
}
.menu-item-last { border-bottom: none; }
.menu-item:hover { background: #f5f5f5; }
.menu-item-icon {
    float: left;
    width: 40px;
    font-size: 28px;
    font-weight: bold;
    text-align: center;
    margin-right: 12px;
}
.menu-item-text { float: left; }
.menu-item-arrow {
    float: right;
    color: #999;
    font-size: 22px;
}

/* ===== Menu Section Divider ===== */
.menu-divider {
    height: 3px;
    background: #000;
    margin: 0;
}

/* ===== Top Bar ===== */
.top-bar {
    overflow: hidden;
    padding: 24px 40px;
    border-bottom: 3px solid #000;
}
.top-bar-landscape {
    padding: 20px 36px;
}

/* ===== Common Panel ===== */
.panel {
    margin: 0 40px;
}
.panel-landscape {
    margin: 0 36px;
}

.panel-title {
    font-size: 20px;
    color: #666;
    letter-spacing: 4px;
    margin-bottom: 12px;
    border-bottom: 1px solid #ccc;
    padding-bottom: 6px;
}

/* ===== Content Area ===== */
.content-area {
    padding: 0 40px;
}
.content-area-landscape {
    padding: 0 36px;
}

/* ===== Progress Bar ===== */
.progress-bar {
    width: 100%;
    height: 10px;
    background: #ddd;
    margin-top: 6px;
    overflow: hidden;
}
.progress-fill {
    height: 10px;
    background: #000;
}

/* ===== E-ink Optimizations ===== */
/* No animations, no transitions, no border-radius */
/* Black & white only, high contrast */
/* Large touch targets (min 44px) */
