/* XP Explorer windows for the site's standalone pages (My Resume, My Projects).
   An Explorer window: the blue task pane on the left and the page itself on
   the right, with Explorer group headings. On its own (/resume/, /projects/)
   the window sits on the site's wallpaper with a taskbar; opened from the
   desktop it fills a desktop window (explorer.js adds html.framed). */
:root {
    color-scheme: light;
    --desk-a: #7ab4f5;
    --desk-b: #c9a7e8;
    --desk-c: #f2b5c4;
    --frame: #0054e3;
    --title-hi: #3d95ff;
    --title-lo: #0047d9;
    --face: #ece9d8;
    --face-line: #d6d2c2;
    --paper: #ffffff;
    --ink: #1b1b1b;
    --ink-soft: #57574f;
    --xp-blue: #215dc6;
    --xp-blue-hi: #428eff;
    --group: #1c3f94;
    --pane-a: #7ba2e7;
    --pane-b: #6375d6;
    --box-body: #d6dff7;
    --box-head: #c6d3f7;
    --sel-bg: #dfe9fb;
    --sel-line: #7da2ce;
    --task: #245edb;
    --task-hi: #3f8cf3;
    --start: #3c9a3c;
    --tip: #ffffe1;
    --font-ui: Tahoma, Verdana, "Segoe UI", system-ui, sans-serif;
    --font-title: "Trebuchet MS", Tahoma, Verdana, system-ui, sans-serif;
    --chrome: 0.75rem;
    --text: 0.875rem;
}
* { box-sizing: border-box; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
body {
    margin: 0;
    background: linear-gradient(160deg, var(--desk-a) 0%, var(--desk-b) 55%, var(--desk-c) 100%) fixed;
    color: var(--ink);
    font: var(--text)/1.5 var(--font-ui);
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
    padding-block: 18px calc(60px + env(safe-area-inset-bottom, 0px));
}
button { font: inherit; color: inherit; }
a { color: var(--xp-blue); }
:focus-visible { outline: 1px dotted #000; outline-offset: 1px; }
svg.i { width: 16px; height: 16px; flex: none; }

/* ---------- window chrome ---------- */
.win {
    max-width: 1120px; margin: 0 auto;
    background: var(--face); border: 3px solid var(--frame); border-top: 0; border-radius: 8px 8px 0 0;
    box-shadow: 2px 5px 18px rgba(0, 0, 40, 0.35);
}
.titlebar {
    display: flex; align-items: center; gap: 6px; min-height: 30px; padding: 3px 5px 3px 8px;
    border-radius: 7px 7px 0 0; color: #fff;
    background: linear-gradient(180deg, var(--title-hi) 0%, var(--title-lo) 12%, var(--title-lo) 82%, var(--frame) 100%);
    font: bold 0.95rem/1 var(--font-title); text-shadow: 1px 1px 1px rgba(0, 0, 60, 0.7);
}
.titlebar .name { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ctl { width: 21px; height: 21px; flex: none; border: 1px solid #fff; border-radius: 3px; display: grid; place-items: center;
    background: linear-gradient(180deg, #5a9bff, #1f5fe0); }
.ctl.close { background: linear-gradient(180deg, #ec8f6b, #c8411c); }
.ctl svg { width: 11px; height: 11px; }
.menubar { display: flex; gap: 2px; padding: 2px 4px; border-bottom: 1px solid var(--face-line); font-size: var(--chrome); }
.menubar span { padding: 1px 7px; }
.address { display: flex; align-items: center; gap: 6px; padding: 3px 6px; border-bottom: 1px solid var(--face-line); font-size: var(--chrome); color: var(--ink-soft); }
.address .box { flex: 1; min-width: 0; display: flex; align-items: center; gap: 5px; background: #fff; border: 1px solid #7f9db9; padding: 2px 5px; color: #000; white-space: nowrap; overflow: hidden; }
.address .go { display: flex; align-items: center; gap: 4px; color: #000; }
@media (max-width: 640px) { .address { display: none; } }

/* ---------- explorer body ---------- */
.explorer { display: grid; grid-template-columns: 214px minmax(0, 1fr); background: var(--paper); border: 1px solid #a0a0a0; border-width: 1px 0; }
@media (max-width: 760px) { .explorer { grid-template-columns: minmax(0, 1fr); } }

.pane { background: linear-gradient(180deg, var(--pane-a), var(--pane-b)); padding: 12px 10px; font-size: var(--chrome); }
.pane-inner { position: sticky; top: 10px; display: grid; gap: 12px; }
.tbox-h {
    width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 6px;
    min-height: 25px; padding: 3px 4px 3px 10px; border: 0; border-radius: 4px 4px 0 0; cursor: pointer; text-align: left;
    background: linear-gradient(90deg, #fff 30%, var(--box-head)); color: var(--xp-blue); font-weight: bold;
}
.tbox-h:hover { color: var(--xp-blue-hi); }
.tbox.special .tbox-h { background: linear-gradient(90deg, #0055e5, #2c6ff1); color: #fff; }
.tbox.special .tbox-h:hover { color: #c6dbff; }
.chev { width: 18px; height: 18px; flex: none; transition: transform 0.15s; }
.tbox-h[aria-expanded="false"] .chev { transform: rotate(180deg); }
.tbox-b { background: var(--box-body); border: 1px solid #fff; border-top: 0; padding: 8px 10px 10px; display: grid; gap: 6px; }
.tbox.special .tbox-b { background: #eff3ff; }
.tbox-b[hidden] { display: none; }
.tbox-b a, .tbox-b button.link {
    display: flex; align-items: center; gap: 6px; color: var(--xp-blue); text-decoration: none;
    background: none; border: 0; padding: 0; cursor: pointer; text-align: left; font-size: var(--chrome);
}
.tbox-b a:hover, .tbox-b button.link:hover { color: var(--xp-blue-hi); text-decoration: underline; }
.tbox-b a[aria-current="true"] { font-weight: bold; color: #0b2e8a; }
.details b { display: block; font-size: 0.8rem; }
.details p { margin: 0; color: #333; }
@media (max-width: 760px) {
    .pane { padding: 10px; }
    .pane-inner { position: static; }
    .tbox:not(.special) { display: none; }
    .tbox.special .tbox-b { display: flex; flex-wrap: wrap; gap: 6px 14px; }
}

/* ---------- the page: header band, groups, lists ---------- */
.doc { min-width: 0; }
.profile {
    display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px;
    padding: 16px 22px; color: #fff;
    background: linear-gradient(180deg, #1c64d8 0%, #2e7af0 60%, #1d5fd6 100%);
    border-bottom: 3px solid #e8932f; /* the orange rule under XP's Start menu header */
}
.avatar { width: 72px; height: 72px; flex: none; object-fit: cover; background: #403e3f; border: 2px solid #fff; border-radius: 6px; box-shadow: 1px 2px 4px rgba(0, 0, 0, 0.35); }
.who { flex: 1; min-width: 200px; }
.who h1 { margin: 0; font: bold 1.55rem/1.15 var(--font-title); text-shadow: 1px 1px 2px rgba(0, 0, 50, 0.55); }
.who p { margin: 3px 0 0; font-size: 0.85rem; text-shadow: 1px 1px 1px rgba(0, 0, 50, 0.45); }
.who .loc { opacity: 0.92; font-size: 0.8rem; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.btn {
    display: inline-flex; align-items: center; gap: 6px; min-height: 26px; padding: 3px 12px; cursor: pointer; text-decoration: none;
    background: linear-gradient(180deg, #fff, #ece9d8); color: #000; border: 1px solid #003c74; border-radius: 3px; font-size: var(--chrome);
}
.btn:hover { box-shadow: inset 0 0 0 2px #fbd36b; }
.btn:active { background: #e3e0d0; }
.content { padding: 6px 26px 26px; }
@media (max-width: 560px) { .content { padding: 4px 14px 20px; } .profile { padding: 14px; } }
h2.group {
    display: flex; align-items: center; gap: 8px; margin: 22px 0 10px; padding-bottom: 4px;
    font: bold 1rem/1.2 var(--font-ui); color: var(--group); position: relative;
}
h2.group::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, #7c9be6, rgba(124, 155, 230, 0)); }
h2.group svg { width: 20px; height: 20px; }
.lead { margin: -2px 0 10px; color: var(--ink-soft); font-style: italic; max-width: 78ch; }
ul.bul { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
ul.bul li { position: relative; padding-left: 16px; max-width: 78ch; }
ul.bul li::before { content: ""; position: absolute; left: 2px; top: 0.55em; width: 6px; height: 6px; background: linear-gradient(135deg, #7aa6f8, #2a5bd7); border: 1px solid #1f48b0; }

/* Explorer's Details view (a table) */
.detailsview { border: 1px solid #c9d1e0; overflow: hidden; }
table.dv { width: 100%; border-collapse: collapse; font-size: 0.82rem; }
table.dv th { text-align: left; font-weight: normal; padding: 3px 8px; background: linear-gradient(180deg, #fff, #ebeadb); border-bottom: 1px solid var(--face-line); border-right: 1px solid var(--face-line); color: #000; white-space: nowrap; }
table.dv td { padding: 5px 8px; vertical-align: top; }
table.dv tbody tr:hover td { background: var(--sel-bg); }
table.dv td.name { font-weight: bold; }
table.dv td.name span { display: flex; gap: 6px; align-items: flex-start; }
table.dv td.date { white-space: nowrap; font-variant-numeric: tabular-nums; }
@media (max-width: 640px) {
    table.dv thead { display: none; }
    table.dv, table.dv tbody, table.dv tr, table.dv td { display: block; }
    table.dv tr { padding: 6px 8px; border-bottom: 1px solid #eceff5; }
    table.dv td { padding: 0; }
    table.dv td.name { margin-bottom: 1px; }
    table.dv td:not(.name) { display: inline; color: var(--ink-soft); }
    table.dv td:nth-child(n+3):not(:empty)::before { content: " · "; }
    table.dv td:empty { display: none; }
}

.status { display: flex; gap: 2px; padding: 2px; font-size: var(--chrome); color: #222; }
.status span { padding: 1px 8px; border: 1px solid; border-color: #aca899 #fff #fff #aca899; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.status span:first-child { flex: 1; min-width: 0; }
@media (max-width: 480px) { .status span:not(:first-child) { display: none; } }

.taskbar {
    position: fixed; inset: auto 0 0 0; z-index: 20; display: flex; align-items: center; gap: 6px;
    padding: 3px max(8px, env(safe-area-inset-right, 0px)) calc(3px + env(safe-area-inset-bottom, 0px)) env(safe-area-inset-left, 0px);
    background: linear-gradient(180deg, var(--task-hi) 0%, var(--task) 12%, var(--task) 90%, #1941a5 100%); border-top: 1px solid #0c59b9;
}
.start { flex: none; height: 32px; padding: 0 22px 0 14px; display: flex; align-items: center; border-radius: 0 12px 12px 0; text-decoration: none;
    background: linear-gradient(180deg, #4fbf4f, var(--start) 60%, #2a7d2a); color: #fff; font: italic bold 1.1rem/1 var(--font-title); text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5); }
.start:hover { filter: brightness(1.08); }
.task { min-width: 0; max-width: 220px; height: 28px; display: flex; align-items: center; gap: 6px; padding: 0 10px; color: #fff; font-size: var(--chrome);
    background: #1e4fbd; border: 1px solid #1a4fb8; border-radius: 3px; box-shadow: inset 1px 1px 3px rgba(0, 0, 0, 0.45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.clock { margin-left: auto; flex: none; color: #fff; font-size: var(--chrome); padding: 0 6px; font-variant-numeric: tabular-nums; }

/* ---------- inside the desktop window ---------- */
html.framed body { padding: 0; height: 100vh; overflow: hidden; background: var(--face); }
html.framed .titlebar, html.framed .taskbar, html.framed .standalone-only { display: none; }
html.framed .win { max-width: none; height: 100%; margin: 0; border: 0; border-radius: 0; box-shadow: none; display: flex; flex-direction: column; }
html.framed .explorer { flex: 1; min-height: 0; overflow: auto; }
