/* =====================================================================
 * win95-overlay.css
 *
 * Windows 95 style taskbar pinned to the bottom of every page on
 * rickwayne.cc, plus the fullscreen overlay (with iframe) that opens
 * when the Start button is clicked.
 *
 * KILL SWITCH: Delete or comment out the <script src="/assets/win95-overlay.js">
 * tag in the site template and this entire feature disappears (the JS
 * is what injects all the DOM that this stylesheet targets; the CSS
 * left behind is inert and harmless).
 *
 * Everything is namespaced under .win95-* to avoid colliding with the
 * site's existing styles. No global selectors except body padding,
 * which is gated on a class added by the JS so it's a no-op if the
 * script never runs.
 * ===================================================================== */

/* ---- Body padding so taskbar never covers page content -------------- */
body.win95-overlay-active {
    padding-bottom: 32px;
}

@media (max-width: 768px) {
    body.win95-overlay-active {
        padding-bottom: 44px;
    }
}

/* ---- Taskbar -------------------------------------------------------- */
/* Semi-transparent gray so site content is visible behind. The Start button
   stays fully opaque below so the entry point is clearly clickable. */
.win95-taskbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 32px;
    background: rgba(192, 192, 192, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-top: 2px solid rgba(255, 255, 255, 0.6);
    box-shadow:
        inset 1px 1px 0 rgba(223, 223, 223, 0.6),
        inset -1px -1px 0 rgba(128, 128, 128, 0.6);
    font-family: Tahoma, "MS Sans Serif", "Segoe UI", sans-serif;
    font-size: 11px;
    color: #000000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 3px;
    z-index: 9998;
    box-sizing: border-box;
    -webkit-font-smoothing: none;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1;
    user-select: none;
}

@media (max-width: 768px) {
    .win95-taskbar {
        height: 44px;
        font-size: 13px;
    }
}

/* ---- Start button --------------------------------------------------- */
/* Fully opaque so the entry point reads loud and clear over any background. */
.win95-start-button {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 24px;
    padding: 0 6px 0 4px;
    background: #c0c0c0;
    border-top: 2px solid #ffffff;
    border-left: 2px solid #ffffff;
    border-right: 2px solid #808080;
    border-bottom: 2px solid #808080;
    box-shadow:
        inset 1px 1px 0 #dfdfdf,
        inset -1px -1px 0 #404040,
        0 0 0 1px rgba(0, 0, 0, 0.35);
    font-family: Tahoma, "MS Sans Serif", "Segoe UI", sans-serif;
    font-size: 11px;
    font-weight: bold;
    color: #000000;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.win95-start-button:focus {
    outline: 1px dotted #000000;
    outline-offset: -4px;
}

.win95-start-button:active,
.win95-start-button.is-pressed {
    border-top: 2px solid #808080;
    border-left: 2px solid #808080;
    border-right: 2px solid #ffffff;
    border-bottom: 2px solid #ffffff;
    box-shadow:
        inset 1px 1px 0 #404040,
        inset -1px -1px 0 #dfdfdf;
    padding: 1px 5px 0 5px;
}

@media (max-width: 768px) {
    .win95-start-button {
        height: 34px;
        padding: 0 10px 0 8px;
        font-size: 13px;
        gap: 6px;
    }
}

.win95-start-flag {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    display: block;
}

@media (max-width: 768px) {
    .win95-start-flag {
        width: 20px;
        height: 20px;
    }
}

/* ---- Clock ---------------------------------------------------------- */
/* Inherits the translucent taskbar background. Text stays readable, but the
   cell doesn't block underlying content. */
.win95-clock {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 72px;
    height: 22px;
    padding: 0 8px;
    background: rgba(192, 192, 192, 0.3);
    border-top: 1px solid rgba(128, 128, 128, 0.6);
    border-left: 1px solid rgba(128, 128, 128, 0.6);
    border-right: 1px solid rgba(255, 255, 255, 0.6);
    border-bottom: 1px solid rgba(255, 255, 255, 0.6);
    font-family: Tahoma, "MS Sans Serif", "Segoe UI", sans-serif;
    font-size: 11px;
    color: #000000;
    margin-right: 2px;
    box-sizing: border-box;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .win95-clock {
        height: 32px;
        min-width: 80px;
        font-size: 13px;
    }
}

/* ---- Fullscreen overlay --------------------------------------------- */
.win95-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #000000;
    z-index: 9999;
    display: none;
}

.win95-overlay.is-open {
    display: block;
}

.win95-overlay-iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    background: #000000;
}

/* ---- Big obvious close button (overlay) ----------------------------- */
.win95-overlay-close {
    position: fixed;
    top: 8px;
    right: 8px;
    z-index: 10000;
    width: 44px;
    height: 44px;
    background: #ffffff;
    color: #000000;
    border-top: 2px solid #ffffff;
    border-left: 2px solid #ffffff;
    border-right: 2px solid #808080;
    border-bottom: 2px solid #808080;
    box-shadow:
        inset 1px 1px 0 #dfdfdf,
        inset -1px -1px 0 #404040,
        0 2px 8px rgba(0, 0, 0, 0.6);
    font-family: Tahoma, "MS Sans Serif", "Segoe UI", sans-serif;
    font-size: 24px;
    font-weight: bold;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    -webkit-appearance: none;
    appearance: none;
}

.win95-overlay-close:focus {
    outline: 2px dotted #000000;
    outline-offset: 2px;
}

.win95-overlay-close:active {
    border-top: 2px solid #808080;
    border-left: 2px solid #808080;
    border-right: 2px solid #ffffff;
    border-bottom: 2px solid #ffffff;
    box-shadow:
        inset 1px 1px 0 #404040,
        inset -1px -1px 0 #dfdfdf,
        0 2px 8px rgba(0, 0, 0, 0.6);
}
