/* ==========================================================================
   myilmaz.dev — Advanced Windows XP Theme (Luna Blue & Zune Noir)
   ========================================================================== */

:root {
  --xp-blue-main: #0058e6;
  --xp-blue-dark: #003c9d;
  --xp-blue-light: #3a93ff;
  --xp-blue-glass: #5ea2e3;
  --xp-green-start: #3c9c3c;
  --xp-green-start-dark: #256625;
  --xp-beige-bg: #ece9d8;
  --xp-beige-dark: #d4d0c8;
  --xp-sidebar-bg: #7ba2e7;
  --xp-sidebar-box-head: #215dc6;
  --xp-sidebar-box-bg: #d6dff7;
  --xp-text-main: #0a0a0a;
  --xp-text-muted: #555555;
  --xp-link-blue: #0d3b8a;
  --xp-link-hover: #e25822;
  --xp-border-line: #919b9c;
  --xp-grok-purple: #7952b3;
  --xp-grok-dark: #4b3585;
  --xp-orange-badge: #e8851c;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Lucida Console", monospace;
}

html[data-theme="dark"] {
  --xp-blue-main: #2b2b2b;
  --xp-blue-dark: #141414;
  --xp-blue-light: #444444;
  --xp-blue-glass: #333333;
  --xp-green-start: #e0701e;
  --xp-green-start-dark: #a84e0e;
  --xp-beige-bg: #222222;
  --xp-beige-dark: #2a2a2a;
  --xp-sidebar-bg: #2d333b;
  --xp-sidebar-box-head: #1c2128;
  --xp-sidebar-box-bg: #252b33;
  --xp-text-main: #e6edf3;
  --xp-text-muted: #8b949e;
  --xp-link-blue: #58a6ff;
  --xp-link-hover: #ff7b72;
  --xp-border-line: #484f58;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

/* ==========================================================================
   Windows XP Authentic Scrollbars (Luna Blue & Zune Noir)
   ========================================================================== */
* {
  scrollbar-width: thin;
  scrollbar-color: #c4d3eb #ece9d8;
}

html[data-theme="dark"] * {
  scrollbar-color: #555555 #222222;
}

::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}

::-webkit-scrollbar-track {
  background: #ece9d8;
  border-left: 1px solid #d4d0c8;
  box-shadow: inset 1px 0 0 #fbfbf9;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(to right, #ffffff 0%, #ece9d8 25%, #d8d4c8 75%, #b5b1a6 100%);
  border: 1px solid #ffffff;
  border-right-color: #404040;
  border-bottom-color: #404040;
  box-shadow: inset 1px 1px 0 #ffffff;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to right, #fffef5 0%, #ffeaa8 25%, #ffd46e 75%, #d4a017 100%);
  border-color: #ffffff;
  border-right-color: #8b6914;
  border-bottom-color: #8b6914;
}

::-webkit-scrollbar-thumb:active {
  background: linear-gradient(to right, #d4a017 0%, #ffd46e 25%, #ffeaa8 75%, #ffffff 100%);
}

::-webkit-scrollbar-button {
  background: #ece9d8;
  border: 1px solid #ffffff;
  border-right-color: #404040;
  border-bottom-color: #404040;
  height: 16px;
  width: 16px;
  display: block;
  background-repeat: no-repeat;
  background-position: center;
}

::-webkit-scrollbar-button:single-button:vertical:decrement {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='6' viewBox='0 0 8 6'%3E%3Cpolygon points='4,1 1,5 7,5' fill='%23000000'/%3E%3C/svg%3E");
}

::-webkit-scrollbar-button:single-button:vertical:increment {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='6' viewBox='0 0 8 6'%3E%3Cpolygon points='4,5 1,1 7,1' fill='%23000000'/%3E%3C/svg%3E");
}

::-webkit-scrollbar-button:hover {
  background-color: #ffe699;
}

/* Dark theme scrollbar */
html[data-theme="dark"] ::-webkit-scrollbar-track {
  background: #222222;
  border-left: 1px solid #333333;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb {
  background: linear-gradient(to right, #444444 0%, #303030 50%, #1e1e1e 100%);
  border: 1px solid #555555;
  border-right-color: #111111;
  border-bottom-color: #111111;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(to right, #664422 0%, #e0701e 50%, #99440e 100%);
  border-color: #ffa657;
  border-right-color: #552200;
  border-bottom-color: #552200;
}

html[data-theme="dark"] ::-webkit-scrollbar-button {
  background: #2a2a2a;
  border: 1px solid #555555;
  border-right-color: #111111;
  border-bottom-color: #111111;
}

html[data-theme="dark"] ::-webkit-scrollbar-button:single-button:vertical:decrement {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='6' viewBox='0 0 8 6'%3E%3Cpolygon points='4,1 1,5 7,5' fill='%23ffffff'/%3E%3C/svg%3E");
}

html[data-theme="dark"] ::-webkit-scrollbar-button:single-button:vertical:increment {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='6' viewBox='0 0 8 6'%3E%3Cpolygon points='4,5 1,1 7,1' fill='%23ffffff'/%3E%3C/svg%3E");
}

html {
  font-size: 16px;
  height: 100%;
}

body {
  margin: 0;
  height: 100vh;
  height: 100dvh;
  padding: 8px 12px 38px 94px;
  color: var(--xp-text-main);
  font-family: Tahoma, "Segoe UI", Arial, sans-serif;
  font-size: 13px;
  line-height: 1.5;
  user-select: text;
  background-color: #2f6cb8;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   Bliss Desktop Wallpaper (Layered Gradients & Clouds)
   ========================================================================== */
.xp-desktop {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(280px 100px at 20% 18%, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0) 70%),
    radial-gradient(340px 120px at 66% 12%, rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0) 70%),
    radial-gradient(200px 70px at 84% 28%, rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0) 70%),
    linear-gradient(to bottom, #195cb0 0%, #3a8be0 28%, #7ec2f5 48%, #9fd58b 51%, #5da33a 68%, #366d20 100%);
}

html[data-theme="dark"] .xp-desktop {
  background:
    linear-gradient(to bottom, #071322 0%, #0d2646 32%, #133420 65%, #081a0e 100%);
}

.xp-cloud {
  position: fixed;
  z-index: -1;
  background: rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  filter: blur(1.5px);
}
.xp-cloud.c1 { top: 8%; left: 14%; width: 220px; height: 38px; }
.xp-cloud.c2 { top: 5%; left: 62%; width: 300px; height: 48px; }
.xp-cloud.c3 { top: 20%; left: 80%; width: 180px; height: 32px; }

.xp-hill {
  position: fixed;
  left: -15%;
  right: -15%;
  bottom: -28%;
  height: 60%;
  z-index: -1;
  background: radial-gradient(130% 140% at 35% 0%, #99dd75 0%, #5da33a 36%, #3a7522 65%, #255515 100%);
  border-radius: 50% 50% 0 0;
}
html[data-theme="dark"] .xp-hill {
  background: radial-gradient(130% 140% at 35% 0%, #204b2c 0%, #15381f 40%, #0d2514 100%);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: #000;
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 9999;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ==========================================================================
   Desktop Icons
   ========================================================================== */
.xp-icons {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.xp-icon {
  appearance: none;
  background: transparent;
  border: 1px dotted transparent;
  padding: 4px;
  border-radius: 3px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  width: 82px;
  color: #ffffff;
  font-size: 11px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.95), 0 0 4px rgba(0, 0, 0, 0.7);
}

.xp-icon:hover {
  background: rgba(49, 106, 197, 0.35);
  border-color: rgba(255, 255, 255, 0.5);
}

.xp-icon.is-selected {
  background: rgba(49, 106, 197, 0.7);
  border-color: #ffffff;
}

.xp-icon-graphic {
  font-size: 32px;
  line-height: 1;
  filter: drop-shadow(1px 2px 3px rgba(0, 0, 0, 0.6));
}

.xp-icon-title {
  display: block;
  word-break: break-word;
  line-height: 1.25;
}

/* ==========================================================================
   Main Windows Explorer Window
   ========================================================================== */
.xp-stage {
  max-width: 1080px;
  width: 100%;
  margin: 0 auto;
  height: 100%;
  max-height: calc(100vh - 44px);
  max-height: calc(100dvh - 44px);
  position: relative;
  z-index: 20;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.xp-window {
  background: var(--xp-beige-bg);
  border: 3px solid #0055ea;
  border-top-width: 0;
  border-radius: 8px 8px 0 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.35) inset;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  max-height: 100%;
  min-height: 0;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

html[data-theme="dark"] .xp-window {
  border-color: #3b3b3b;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.1) inset;
}

/* Window Titlebar */
.xp-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 4px 6px 4px 8px;
  background: linear-gradient(to bottom, #0058e6 0%, #3a93ff 4%, #288eff 6%, #127dff 8%, #036ffc 20%, #0262ee 40%, #0057e5 60%, #0054e3 80%, #0136b8 100%);
  color: #ffffff;
  font-weight: bold;
  font-size: 12px;
  letter-spacing: 0.02em;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
  border-radius: 6px 6px 0 0;
  cursor: grab;
  user-select: none;
  flex-shrink: 0;
}

html[data-theme="dark"] .xp-titlebar {
  background: linear-gradient(to bottom, #3f3f3f 0%, #292929 45%, #181818 100%);
}

.xp-titlebar-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

.xp-titlebar-icon {
  font-size: 15px;
}

.xp-titlebar-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.xp-titlebar-buttons {
  display: flex;
  gap: 3px;
  align-items: center;
}

.xp-tbtn {
  width: 21px;
  height: 21px;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: bold;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 3px;
  background: linear-gradient(to bottom, #3c81f3 0%, #1a56c4 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.xp-tbtn:hover {
  filter: brightness(1.15);
}

.xp-tbtn:active {
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.6);
}

.xp-btn-close {
  background: linear-gradient(to bottom, #f29888 0%, #d63c2f 45%, #9b1a10 100%);
}

/* Menubar */
.xp-menubar {
  display: flex;
  gap: 0.2rem;
  padding: 2px 6px;
  font-size: 12px;
  background: var(--xp-beige-bg);
  border-bottom: 1px solid #d4d0c8;
  flex-shrink: 0;
}

.xp-menu-item {
  padding: 2px 7px;
  cursor: pointer;
  border-radius: 2px;
}

.xp-menu-item:hover, .xp-menu-item:focus {
  background: #316ac5;
  color: #ffffff;
  outline: none;
}

/* Toolbar */
.xp-toolbar {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  padding: 3px 6px;
  background: linear-gradient(to bottom, #ffffff 0%, #ece9d8 50%, #e0ddd0 100%);
  border-bottom: 1px solid #d4d0c8;
  flex-shrink: 0;
}
html[data-theme="dark"] .xp-toolbar {
  background: #2a2a2a;
  border-bottom-color: #3b3b3b;
}

.xp-toolbtn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 3px 6px;
  font-size: 11px;
  font-family: inherit;
  color: var(--xp-text-main);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 3px;
  cursor: pointer;
  text-decoration: none;
}

.xp-toolbtn:hover:not(:disabled) {
  background: linear-gradient(to bottom, #ffffff, #e0ddd0);
  border-color: #7f9db9;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.xp-toolbtn:active:not(:disabled), .xp-toolbtn[aria-pressed="true"] {
  background: #e0ddd0;
  border-color: #7f9db9;
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.xp-toolbtn:disabled {
  opacity: 0.45;
  cursor: default;
}

.xp-tool-icon { font-size: 14px; }
.xp-tool-text { font-size: 11px; }
.xp-tool-sep { width: 1px; height: 18px; background: #919b9c; margin: 0 3px; }

/* Address Bar */
.xp-addressbar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 3px 8px;
  background: var(--xp-beige-bg);
  border-bottom: 1px solid #c0c0c0;
  font-size: 12px;
  flex-shrink: 0;
}

.xp-address-label {
  color: var(--xp-text-muted);
}

.xp-address-box {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: #ffffff;
  border: 1px solid #7f9db9;
  padding: 2px 6px;
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.12);
}
html[data-theme="dark"] .xp-address-box {
  background: #181818;
  border-color: #444;
}

.xp-address-ico { font-size: 14px; }

.xp-address-input {
  width: 100%;
  border: 0;
  outline: 0;
  font-family: inherit;
  font-size: 11.5px;
  color: inherit;
  background: transparent;
}

.xp-go-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: bold;
  color: #0b450b;
  background: linear-gradient(to bottom, #dff4df, #b4e0b4);
  border: 1px solid #5aa55a;
  border-radius: 2px;
  cursor: pointer;
}
.xp-go-btn:hover { filter: brightness(1.05); }

/* Navigation Bar */
.xp-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 6px 12px;
  background: linear-gradient(to bottom, #fcfcf9, #ece9d8);
  border-bottom: 1px solid var(--xp-border-line);
  flex-shrink: 0;
}
html[data-theme="dark"] .xp-nav {
  background: #252525;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--xp-text-main);
  text-decoration: none;
}

.brand-logo {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  font-family: Georgia, serif;
  font-style: italic;
  font-weight: bold;
  font-size: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, #3a93ff, #0058e6);
  border-radius: 50%;
  box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.35);
}

.brand-name {
  font-size: 1rem;
  font-weight: bold;
  letter-spacing: -0.02em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 12px;
}

.site-nav a {
  color: var(--xp-link-blue);
  text-decoration: none;
  padding: 3px 8px;
  border: 1px solid transparent;
  border-radius: 3px;
}

.site-nav a:hover {
  background: #ffffff;
  border-color: #99b4d9;
}

.site-nav a[aria-current="page"] {
  background: #ffffff;
  border-color: #0058e6;
  font-weight: bold;
}
html[data-theme="dark"] .site-nav a[aria-current="page"] {
  background: #333;
  border-color: #555;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 24px;
  padding: 0;
  border: 1px solid #7f9db9;
  border-radius: 3px;
  background: linear-gradient(to bottom, #ffffff, #ecebe5 45%, #d8d0c4);
  cursor: pointer;
}
.theme-toggle:hover { filter: brightness(1.05); }

/* Main Window Client Area */
.xp-content {
  background: #ffffff;
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0;
  display: flex;
  flex-direction: column;
  -webkit-overflow-scrolling: touch;
}
html[data-theme="dark"] .xp-content {
  background: #1b1b1b;
  color: #e6edf3;
}

.xp-content:has(.xp-explorer-view) {
  overflow: hidden;
}

/* ==========================================================================
   Explorer Layout: Left Foldable Sidebar + Right Main Pane
   ========================================================================== */
.xp-explorer-view {
  display: grid;
  grid-template-columns: 215px minmax(0, 1fr);
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
}

.xp-explorer-view.folders-collapsed {
  grid-template-columns: 0 minmax(0, 1fr);
}
.xp-explorer-view.folders-collapsed .xp-sidebar {
  display: none;
}

/* Left Sidebar */
.xp-sidebar {
  background: linear-gradient(to bottom, #7ba2e7 0%, #6375d6 100%);
  padding: 0.75rem 0.6rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  border-right: 1px solid #5a6eb5;
  overflow-y: auto;
  overflow-x: hidden;
  height: 100%;
  min-height: 0;
  flex-shrink: 0;
}
html[data-theme="dark"] .xp-sidebar {
  background: #252b33;
  border-right-color: #383f4a;
}

.xp-sidebox {
  background: #ffffff;
  border-radius: 4px 4px 0 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
  overflow: hidden;
}

.xp-sidebox-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 8px;
  background: linear-gradient(to right, #215dc6 0%, #6385d6 100%);
  color: #ffffff;
  font-weight: bold;
  font-size: 11.5px;
  cursor: pointer;
  user-select: none;
}
html[data-theme="dark"] .xp-sidebox-head {
  background: linear-gradient(to right, #1c2128 0%, #30363d 100%);
}

.xp-sidebox-toggle {
  font-size: 9px;
  transition: transform 0.2s ease;
}

.xp-sidebox.is-collapsed .xp-sidebox-body {
  display: none;
}
.xp-sidebox.is-collapsed .xp-sidebox-toggle {
  transform: rotate(180deg);
}

.xp-sidebox-body {
  background: #d6dff7;
  padding: 0.4rem 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
html[data-theme="dark"] .xp-sidebox-body {
  background: #1e2228;
}

.xp-sidelink {
  appearance: none;
  background: transparent;
  border: 0;
  padding: 3px 4px;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 11px;
  font-family: inherit;
  color: #0c327d;
  text-decoration: none;
  border-radius: 2px;
  text-align: left;
  cursor: pointer;
}
html[data-theme="dark"] .xp-sidelink {
  color: #79c0ff;
}

.xp-sidelink:hover {
  text-decoration: underline;
  color: #e25822;
}

.xp-sidelink.is-current {
  font-weight: bold;
  background: rgba(255, 255, 255, 0.65);
}

.xp-side-ico { font-size: 14px; }

.xp-sidebox-details {
  font-size: 11px;
  color: #222;
  line-height: 1.4;
}
html[data-theme="dark"] .xp-sidebox-details {
  color: #c9d1d9;
}

.xp-detail-avatar {
  font-size: 28px;
  margin-bottom: 0.2rem;
}

.xp-detail-desc {
  margin: 0.3rem 0;
  font-size: 10.5px;
  color: #555;
}
html[data-theme="dark"] .xp-detail-desc {
  color: #8b949e;
}

.xp-detail-stat {
  display: inline-block;
  font: 10px var(--mono);
  background: rgba(255, 255, 255, 0.6);
  padding: 1px 4px;
  border-radius: 3px;
}

/* Right Main Pane */
.xp-main-pane {
  padding: 0.9rem 1.1rem 2rem;
  min-width: 0;
  overflow-y: auto;
  overflow-x: hidden;
  height: 100%;
  min-height: 0;
  flex: 1 1 auto;
}

/* Blog Sub-toolbar */
.blog-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-bottom: 0.9rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #d4d0c8;
}
html[data-theme="dark"] .blog-toolbar {
  border-bottom-color: #3b3b3b;
}

.xp-tabs {
  display: flex;
  gap: 3px;
  flex-wrap: wrap;
}

.xp-tab {
  padding: 0.4rem 0.85rem;
  font-size: 12px;
  text-decoration: none;
  color: #000000;
  background: linear-gradient(to bottom, #fcfcfc, #e8e4d4);
  border: 1px solid #919b9c;
  border-radius: 4px 4px 0 0;
}
html[data-theme="dark"] .xp-tab {
  background: #2d2d2d;
  color: #e6edf3;
  border-color: #444;
}

.xp-tab.is-active {
  background: #ffffff;
  font-weight: bold;
  border-color: #0058e6;
  border-bottom-color: #ffffff;
}
html[data-theme="dark"] .xp-tab.is-active {
  background: #1b1b1b;
  border-color: #58a6ff;
  border-bottom-color: #1b1b1b;
}

.xp-search {
  display: flex;
  gap: 0.35rem;
  align-items: center;
}

.xp-search input[type="search"] {
  width: 190px;
  font: inherit;
  font-size: 11.5px;
  padding: 0.35rem 0.55rem;
  border: 1px solid #7f9db9;
  border-radius: 2px;
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.12);
  background: #ffffff;
  color: inherit;
}
html[data-theme="dark"] .xp-search input[type="search"] {
  background: #111;
  border-color: #444;
}

.xp-search button {
  font: inherit;
  font-size: 11.5px;
  padding: 0.35rem 0.75rem;
  cursor: pointer;
  border: 1px solid #003c74;
  border-radius: 3px;
  color: #000000;
  background: linear-gradient(to bottom, #ffffff, #ecebe5 45%, #d8d0c4);
}
.xp-search button:hover { filter: brightness(1.04); }

.xp-clear {
  font-size: 12px;
  color: var(--xp-link-blue);
  text-decoration: none;
}

.result-note {
  font: 11px var(--mono);
  color: var(--xp-text-muted);
  margin: 0 0 0.6rem;
}

/* ==========================================================================
   Post List (Clean, readable, spacious Explorer list)
   ========================================================================== */
.writing-index {
  margin: 0;
}

.post-list {
  border-top: 1px solid var(--xp-border-line);
}

.post-row {
  display: grid;
  grid-template-columns: 24px 8.5rem minmax(0, 1fr) auto;
  gap: 0.75rem;
  padding: 0.85rem 0.6rem;
  border-bottom: 1px solid #e5e2d6;
  align-items: center;
  transition: background-color 0.1s ease;
}
html[data-theme="dark"] .post-row {
  border-bottom-color: #2d333b;
}

.post-row:hover {
  background-color: #f0f6ff;
}
html[data-theme="dark"] .post-row:hover {
  background-color: #21262d;
}

.file-icon {
  font-size: 18px;
  padding-top: 2px;
}

.post-row time, .article time, .archive-list time, .admin-meta {
  font: 11px var(--mono);
  color: var(--xp-text-muted);
  padding-top: 4px;
}

.post-row-content h3 {
  font-size: 1.15rem;
  margin: 0 0 0.3rem;
  font-weight: bold;
  letter-spacing: -0.01em;
}

.post-row-content h3 a {
  color: var(--xp-link-blue);
  text-decoration: none;
}

.post-row-content h3 a:hover {
  text-decoration: underline;
  color: var(--xp-link-hover);
}

.post-row-content p {
  font-size: 0.92rem;
  color: #444444;
  margin: 0;
  line-height: 1.45;
}
html[data-theme="dark"] .post-row-content p {
  color: #c9d1d9;
}

.row-arrow {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  font-family: Tahoma, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: normal;
  color: #0c327d;
  background: linear-gradient(to bottom, #ffffff 0%, #ecebe5 48%, #d8d0c4 52%, #ece9d8 100%);
  border: 1px solid #7f9db9;
  border-radius: 3px;
  text-decoration: none;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
  white-space: nowrap;
  cursor: pointer;
  align-self: center;
  transition: all 0.12s ease;
}

.row-arrow:hover {
  background: linear-gradient(to bottom, #fffdf0 0%, #ffe8a0 48%, #ffd768 52%, #ffde88 100%);
  border-color: #e2a000;
  color: #000000;
  box-shadow: 0 1px 3px rgba(226, 160, 0, 0.4);
}

.row-arrow:active {
  background: linear-gradient(to bottom, #dedbd1 0%, #ece9d8 100%);
  border-color: #7f9db9;
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.row-arrow .xp-open-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.row-arrow .xp-open-text {
  font-weight: bold;
  letter-spacing: 0.02em;
}

html[data-theme="dark"] .row-arrow {
  background: linear-gradient(to bottom, #383838 0%, #262626 100%);
  border-color: #555555;
  color: #79c0ff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

html[data-theme="dark"] .row-arrow:hover {
  background: linear-gradient(to bottom, #444444 0%, #2f2f2f 100%);
  border-color: #e0701e;
  color: #ffa657;
  box-shadow: 0 1px 3px rgba(224, 112, 30, 0.4);
}

html[data-theme="dark"] .row-arrow svg path[fill="#0055EA"] {
  fill: #e0701e;
}
html[data-theme="dark"] .row-arrow svg path[stroke="#003899"] {
  stroke: #a84e0e;
}

/* Author Badges */
.author-badge {
  display: inline-block;
  vertical-align: middle;
  font: 10px Tahoma, sans-serif;
  font-weight: bold;
  letter-spacing: 0.03em;
  padding: 1px 6px;
  border-radius: 999px;
  color: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.25);
  margin-left: 0.35rem;
}

.author-badge.author-muslim {
  background: linear-gradient(to bottom, #3a93ff, #0d3b8a);
}

.author-badge.author-grok {
  background: linear-gradient(to bottom, #9a7fe0, #4b3585);
}

.empty-state-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  color: var(--xp-text-muted);
}
.empty-icon { font-size: 36px; margin-bottom: 0.5rem; }
.empty-state { margin: 0; font-size: 13px; }

/* Statusbar */
.xp-statusbar {
  display: flex;
  align-items: center;
  border-top: 1px solid #d4d0c8;
  background: var(--xp-beige-bg);
  font-size: 11px;
  color: #444;
  flex-shrink: 0;
}
html[data-theme="dark"] .xp-statusbar {
  background: #252525;
  border-top-color: #3b3b3b;
  color: #aaa;
}

.xp-status-cell {
  padding: 3px 8px;
  border-right: 1px solid #c9c5b4;
}
html[data-theme="dark"] .xp-status-cell {
  border-right-color: #3b3b3b;
}

.xp-status-desc { flex: 1; }
.xp-status-zone { border-right: none; }

/* ==========================================================================
   Article View (Classic Document / WordPad Inspired)
   ========================================================================== */
.article {
  padding: 1.2rem 1.6rem 3rem;
  max-width: 48rem;
  width: 100%;
  margin: 0 auto;
}

.article-top-back {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 1.2rem;
  color: var(--xp-link-blue);
  font-size: 12px;
  text-decoration: none;
  padding: 3px 8px;
  border: 1px solid #7f9db9;
  border-radius: 3px;
  background: linear-gradient(to bottom, #ffffff, #ecebe5);
}
.article-top-back:hover { filter: brightness(1.05); }

.article-header {
  border-bottom: 1px solid var(--xp-border-line);
  padding-bottom: 1.2rem;
  margin-bottom: 1.5rem;
}

.eyebrow {
  margin: 0 0 0.4rem;
  font: 11px var(--mono);
  letter-spacing: 0.1em;
  color: var(--xp-link-blue);
  text-transform: uppercase;
  font-weight: bold;
}

.article-header h1 {
  font-size: 2.2rem;
  line-height: 1.15;
  margin: 0.3rem 0 0.6rem;
  letter-spacing: -0.02em;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0.4rem 0;
}

.article-dek {
  font-size: 1.1rem;
  color: #333333;
  border-left: 3px solid var(--xp-orange-badge);
  padding-left: 0.9rem;
  margin: 1.1rem 0 0;
  line-height: 1.5;
}
html[data-theme="dark"] .article-dek { color: #c9d1d9; }

.article-body {
  font-size: 1.05rem;
  line-height: 1.7;
}

.article-body h2 {
  font-size: 1.5rem;
  margin: 2rem 0 0.8rem;
  color: var(--xp-link-blue);
}

.article-body h3 {
  font-size: 1.2rem;
  margin: 1.5rem 0 0.6rem;
}

.article-body p, .article-body ul, .article-body ol {
  margin: 0 0 1.2rem;
}

.article-body a {
  color: var(--xp-link-blue);
  text-underline-offset: 2px;
}

.article-body img {
  max-width: 100%;
  height: auto;
  border: 1px solid #7f9db9;
  padding: 4px;
  background: #ffffff;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.15);
}

.article-body blockquote {
  border-left: 3px solid var(--xp-orange-badge);
  margin: 1.5rem 0;
  padding: 0.3rem 0 0.3rem 1.1rem;
  color: #555555;
  font-style: italic;
  background: #fff8ec;
}
html[data-theme="dark"] .article-body blockquote {
  background: #252320;
  color: #d1c7b8;
}

.article-body pre {
  overflow: auto;
  background: #111111;
  color: #4af626;
  padding: 1rem;
  font: 12px var(--mono);
  border: 1px solid #333333;
  border-radius: 3px;
}

.article-back {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid #e3e0d4;
  font-size: 12px;
}
.article-back a { color: var(--xp-link-blue); }

/* ==========================================================================
   Archive Page
   ========================================================================== */
.archive {
  padding: 1.2rem 1.6rem 3rem;
  max-width: 52rem;
  width: 100%;
  margin: 0 auto;
}

.archive h1 {
  font-size: 1.8rem;
  margin: 0.2rem 0 0.8rem;
}

.archive-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  border-top: 1px solid var(--xp-border-line);
}

.archive-list li {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 0.8rem;
  border-bottom: 1px solid #e5e2d6;
  padding: 0.75rem 0.2rem;
  align-items: center;
}
html[data-theme="dark"] .archive-list li { border-bottom-color: #2d333b; }
.archive-list li:hover { background-color: #f0f6ff; }
html[data-theme="dark"] .archive-list li:hover { background-color: #21262d; }

.archive-entry {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.archive-list a {
  color: var(--xp-link-blue);
  font-size: 1rem;
  text-decoration: none;
}
.archive-list a:hover { text-decoration: underline; }

/* ==========================================================================
   Floating Grok Bot Command Prompt (cmd.exe)
   ========================================================================== */
.xp-cmd-window {
  position: fixed;
  top: 15%;
  right: 5%;
  width: min(620px, 92vw);
  background: #0c0c0c;
  color: #cccccc;
  border: 2px solid #0055ea;
  border-radius: 6px 6px 0 0;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.65);
  z-index: 1000;
  font-family: Consolas, "Lucida Console", var(--mono);
  font-size: 12.5px;
  overflow: hidden;
}

.xp-cmd-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 3px 6px 3px 8px;
  background: linear-gradient(to bottom, #0058e6, #003c9d);
  color: #ffffff;
  font-family: Tahoma, sans-serif;
  font-size: 11px;
  font-weight: bold;
  cursor: grab;
  user-select: none;
}

.xp-cmd-titlebar-icon { font-size: 13px; }
.xp-cmd-title-text { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.xp-cmd-buttons { display: flex; gap: 3px; }
.xp-cmd-tbtn {
  width: 19px;
  height: 19px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 2px;
  background: linear-gradient(to bottom, #3c81f3, #1a56c4);
  color: #fff;
  font-size: 10px;
  font-weight: bold;
  cursor: pointer;
}
.xp-cmd-close {
  background: linear-gradient(to bottom, #f29888, #d63c2f 45%, #9b1a10 100%);
}

.xp-cmd-body {
  padding: 0.75rem 0.9rem;
  height: 280px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.xp-cmd-output p {
  margin: 0 0 0.35rem;
  line-height: 1.4;
}

.xp-cmd-accent { color: #58a6ff; }
.xp-cmd-highlight { color: #e3b341; font-weight: normal; }
.xp-cmd-hr { border: 0; border-top: 1px dashed #444; margin: 0.5rem 0; }

.xp-cmd-form {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: auto;
}

.xp-cmd-prompt {
  color: #4af626;
  white-space: nowrap;
}

.xp-cmd-input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: 0;
  color: #ffffff;
  font: inherit;
  caret-color: #4af626;
}

/* ==========================================================================
   Classic Windows XP Dialogs & Modals
   ========================================================================== */
.xp-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.xp-dialog {
  width: min(440px, 94vw);
  background: var(--xp-beige-bg);
  border: 2px solid #0055ea;
  border-radius: 6px 6px 0 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}
html[data-theme="dark"] .xp-dialog {
  background: #252525;
  border-color: #444;
}

.xp-dialog-body {
  padding: 0.9rem;
}

.xp-dialog-tabs {
  display: flex;
  gap: 2px;
  border-bottom: 1px solid #7f9db9;
  margin-bottom: 0.8rem;
}

.xp-dialog-tab {
  padding: 3px 9px;
  font-size: 11px;
  background: linear-gradient(to bottom, #fcfcfc, #ece9d8);
  border: 1px solid #7f9db9;
  border-bottom: 0;
  border-radius: 3px 3px 0 0;
  position: relative;
  top: 1px;
}
.xp-dialog-tab.is-active {
  background: #ffffff;
  font-weight: bold;
  border-bottom: 1px solid #ffffff;
}

.xp-sysinfo-row {
  display: flex;
  gap: 1rem;
}

.xp-sysinfo-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: #ffffff;
  border: 1px solid #7f9db9;
  border-radius: 3px;
  width: 100px;
  height: 90px;
}
.xp-sys-flag { font-size: 32px; color: #0055ea; }
.xp-sys-name { font-weight: bold; font-size: 12px; }

.xp-sysinfo-text {
  font-size: 11.5px;
  line-height: 1.4;
}
.xp-sysinfo-text strong { display: block; margin-top: 0.4rem; color: #0c327d; }
.xp-sysinfo-text p { margin: 0 0 0.4rem; }

.xp-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 1.2rem;
  padding-top: 0.6rem;
  border-top: 1px solid #d4d0c8;
}

.button {
  appearance: none;
  border: 1px solid #003c74;
  border-radius: 3px;
  cursor: pointer;
  background: linear-gradient(to bottom, #ffffff, #ecebe5 45%, #d8d0c4);
  color: #000000;
  font: 11.5px Tahoma, sans-serif;
  padding: 4px 14px;
  text-decoration: none;
  display: inline-block;
  min-width: 72px;
  text-align: center;
}
.button:hover { filter: brightness(1.05); }
.button:active { box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.3); }

.button-quiet {
  background: linear-gradient(to bottom, #f7f7f7, #e0ddd2);
}

.xp-run-top {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 0.8rem;
}
.xp-run-ico { font-size: 30px; }
.xp-run-form label { display: block; margin-bottom: 0.3rem; font-size: 12px; }
.xp-run-form input[type="text"] {
  width: 100%;
  padding: 4px 6px;
  font: inherit;
  font-size: 12px;
  border: 1px solid #7f9db9;
  border-radius: 2px;
}

/* ==========================================================================
   Windows XP Balloon Tooltip Notification
   ========================================================================== */
.xp-balloon {
  position: fixed;
  right: 18px;
  bottom: 42px;
  width: 290px;
  background: #ffffe1;
  color: #000000;
  border: 1px solid #000000;
  border-radius: 4px;
  padding: 8px 10px;
  box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.35);
  z-index: 1200;
  font-size: 11.5px;
  line-height: 1.4;
  animation: balloonPop 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}

@keyframes balloonPop {
  0% { transform: scale(0.6) translateY(20px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

.xp-balloon-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
  font-weight: bold;
}
.xp-balloon-icon { margin-right: 4px; font-size: 13px; }
.xp-balloon-title { flex: 1; font-size: 11.5px; }

.xp-balloon-close {
  background: transparent;
  border: 0;
  font-size: 11px;
  font-weight: bold;
  cursor: pointer;
  color: #666;
  padding: 0 2px;
}
.xp-balloon-close:hover { color: #d63c2f; }

.xp-balloon-body {
  margin: 0;
  color: #222;
}

.xp-balloon-tail {
  position: absolute;
  bottom: -11px;
  right: 60px;
  width: 0;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-top: 11px solid #ffffe1;
}

/* ==========================================================================
   Two-Column Windows XP Start Menu
   ========================================================================== */
.xp-startmenu {
  position: fixed;
  left: 0;
  bottom: 30px;
  z-index: 3000;
  width: min(390px, 94vw);
  background: #ffffff;
  border: 1px solid #003c74;
  border-radius: 8px 8px 0 0;
  overflow: hidden;
  box-shadow: 3px -3px 12px rgba(0, 0, 0, 0.45);
}

.xp-startmenu-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.9rem;
  background: linear-gradient(to bottom, #3a93ff 0%, #0058e6 100%);
  color: #ffffff;
  border-bottom: 2px solid #e8851c;
}
html[data-theme="dark"] .xp-startmenu-head {
  background: linear-gradient(to bottom, #444, #1b1b1b);
}

.xp-avatar {
  font-size: 30px;
  background: #ffffff;
  border: 2px solid rgba(255, 255, 255, 0.8);
  border-radius: 6px;
  padding: 0 4px;
}

.xp-user-info strong { display: block; font-size: 14px; text-shadow: 1px 1px 2px rgba(0,0,0,0.6); }
.xp-user-info small { font-size: 11px; opacity: 0.9; }

.xp-startmenu-body {
  display: flex;
  min-height: 220px;
}

.xp-startmenu-col {
  padding: 0.5rem 0.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.xp-col-programs {
  flex: 1.15;
  background: #ffffff;
}
html[data-theme="dark"] .xp-col-programs {
  background: #1c2128;
}

.xp-col-system {
  flex: 0.85;
  background: #d3e5fa;
  border-left: 1px solid #99b4d9;
}
html[data-theme="dark"] .xp-col-system {
  background: #252b33;
  border-left-color: #3b3b3b;
}

.xp-sitem {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 5px 6px;
  text-decoration: none;
  color: #111111;
  border-radius: 3px;
  background: transparent;
  border: 0;
  width: 100%;
  text-align: left;
  font: inherit;
  cursor: pointer;
}
html[data-theme="dark"] .xp-sitem { color: #e6edf3; }

.xp-sitem:hover {
  background: #2f71cd;
  color: #ffffff;
}

.xp-sitem-icon { font-size: 20px; }
.xp-sitem-text strong { display: block; font-size: 11.5px; }
.xp-sitem-text small { font-size: 10px; color: inherit; opacity: 0.85; }

.xp-sitem-sys {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 6px 8px;
  font-size: 11.5px;
  font-weight: bold;
  color: #0c327d;
  text-decoration: none;
  border-radius: 2px;
  background: transparent;
  border: 0;
  width: 100%;
  text-align: left;
  font-family: inherit;
  cursor: pointer;
}
html[data-theme="dark"] .xp-sitem-sys { color: #79c0ff; }

.xp-sitem-sys:hover {
  background: #2f71cd;
  color: #ffffff;
}
.xp-sys-ico { font-size: 15px; }

.xp-startmenu-foot {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  padding: 0.5rem 0.9rem;
  background: linear-gradient(to bottom, #3a93ff 0%, #0058e6 100%);
  color: #ffffff;
  font-size: 11.5px;
  border-top: 1px solid rgba(255, 255, 255, 0.4);
}
html[data-theme="dark"] .xp-startmenu-foot {
  background: #1e1e1e;
}

.xp-foot-btn {
  background: transparent;
  border: 0;
  color: #ffffff;
  font: inherit;
  font-size: 11px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  text-decoration: none;
}
.xp-foot-btn:hover { text-decoration: underline; }

/* ==========================================================================
   Windows XP Taskbar
   ========================================================================== */
.xp-taskbar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 30px;
  z-index: 2500;
  display: flex;
  align-items: stretch;
  background: linear-gradient(to bottom, #3c81f3 0%, #245edb 12%, #245edb 90%, #1941a5 100%);
  box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.4);
}
html[data-theme="dark"] .xp-taskbar {
  background: linear-gradient(to bottom, #383838 0%, #202020 12%, #191919 90%, #0f0f0f 100%);
}

/* Start Button */
.xp-start {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: none;
  border-radius: 0 12px 12px 0;
  padding: 0 1.2rem 0 0.75rem;
  font: italic bold 14px Tahoma, sans-serif;
  color: #ffffff;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.6);
  background: linear-gradient(to bottom, #5eac56 0%, #3c873c 12%, #2f7d2f 90%, #256625 100%);
  box-shadow: 1px 0 2px rgba(0, 0, 0, 0.4);
  cursor: pointer;
}
html[data-theme="dark"] .xp-start {
  background: linear-gradient(to bottom, #f28b38 0%, #d46419 12%, #b5500e 90%, #873604 100%);
}

.xp-start:hover { filter: brightness(1.1); }
.xp-start:active, .xp-start[aria-expanded="true"] {
  box-shadow: inset 1px 1px 3px rgba(0, 0, 0, 0.6);
}

.xp-start-flag {
  display: grid;
  grid-template-columns: 7px 7px;
  grid-template-rows: 7px 7px;
  gap: 1px;
  transform: rotate(-10deg);
}
.xp-flag-red { background: #f25022; border-radius: 2px 0 0 0; }
.xp-flag-green { background: #7fba00; border-radius: 0 2px 0 0; }
.xp-flag-blue { background: #00a4ef; border-radius: 0 0 0 2px; }
.xp-flag-yellow { background: #ffb900; border-radius: 0 0 2px 0; }

.xp-start-label { letter-spacing: 0.02em; }

/* Quick Launch */
.xp-quicklaunch {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0 6px;
  border-right: 1px solid rgba(255, 255, 255, 0.2);
  border-left: 1px solid rgba(0, 0, 0, 0.2);
}

.xp-ql-btn {
  background: transparent;
  border: 1px solid transparent;
  padding: 2px 4px;
  font-size: 13px;
  cursor: pointer;
  border-radius: 2px;
}
.xp-ql-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
}

/* Tasks */
.xp-tasks {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 0 4px;
  min-width: 0;
}

.xp-task {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 3px 0;
  padding: 0 0.75rem;
  font-size: 11px;
  color: #ffffff;
  min-width: 130px;
  max-width: 180px;
  height: 24px;
  background: linear-gradient(to bottom, #5a8def, #245edb);
  border: 1px solid rgba(0, 0, 0, 0.25);
  border-radius: 3px;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
html[data-theme="dark"] .xp-task {
  background: linear-gradient(to bottom, #444, #222);
}

.xp-task:hover { filter: brightness(1.08); }

.xp-task-active {
  background: linear-gradient(to bottom, #7aa6f5, #3a6ff0);
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.6);
  font-weight: bold;
}
html[data-theme="dark"] .xp-task-active {
  background: linear-gradient(to bottom, #555, #2b2b2b);
  box-shadow: inset 1px 1px 2px rgba(0, 0, 0, 0.8);
}

.xp-task-ico { font-size: 13px; }
.xp-task-name { overflow: hidden; text-overflow: ellipsis; }

/* System Tray */
.xp-tray {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0 0.8rem;
  font-size: 11px;
  color: #ffffff;
  background: linear-gradient(to bottom, #1290e9 0%, #19b9f3 9%, #1290e9 18%, #1290e9 92%, #1941a5 100%);
  border-left: 1px solid rgba(0, 0, 0, 0.35);
  box-shadow: inset 1px 0 1px rgba(255, 255, 255, 0.3);
}
html[data-theme="dark"] .xp-tray {
  background: linear-gradient(to bottom, #2b2b2b, #151515);
}

.xp-tray-icon {
  background: transparent;
  border: 0;
  color: #fff;
  font-size: 12px;
  cursor: pointer;
  padding: 0 2px;
  display: inline-flex;
  align-items: center;
}
.xp-tray-icon:hover { filter: drop-shadow(0 0 3px #ffffff); }

.xp-tray-bot { position: relative; }
.xp-bot-dot {
  position: absolute;
  top: -2px;
  right: -2px;
  width: 5px;
  height: 5px;
  background: #4af626;
  border-radius: 50%;
  box-shadow: 0 0 3px #4af626;
}

.xp-clock { font-size: 11px; }

/* ==========================================================================
   Admin & Editor Pages
   ========================================================================== */
.admin-page, .editor-page, .login-panel, .error-page {
  padding: 1.5rem 1.6rem 3rem;
  max-width: 56rem;
  width: 100%;
  margin: 0 auto;
}

.admin-topline, .editor-topline {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--xp-border-line);
  padding-bottom: 0.8rem;
  margin-bottom: 1rem;
}

.admin-topline h1 { font-size: 1.6rem; margin: 0.2rem 0 0; }
.admin-actions, .editor-buttons { display: flex; gap: 0.5rem; align-items: center; }

.admin-list {
  border: 1px solid var(--xp-border-line);
  background: #ffffff;
  margin-top: 0.8rem;
}
html[data-theme="dark"] .admin-list { background: #1c2128; }

.admin-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid #e5e2d6;
}
html[data-theme="dark"] .admin-row { border-bottom-color: #2d333b; }

.admin-state {
  margin: 0 0 0.3rem;
  font: 10px var(--mono);
  letter-spacing: 0.08em;
  color: var(--xp-link-blue);
  text-transform: uppercase;
}

.admin-row h2 { font-size: 1.1rem; margin: 0; }
.admin-row h2 a { color: var(--xp-link-blue); text-decoration: none; }
.admin-meta { margin: 0.25rem 0 0; }

.row-controls {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  font-size: 11.5px;
}
.row-controls button {
  font: inherit;
  color: #d63c2f;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.bot-note {
  font-size: 11.5px;
  color: var(--xp-text-muted);
  padding: 0.6rem 0.8rem;
  background: #fdfaf2;
  border: 1px dashed var(--xp-border-line);
  margin-top: 1.2rem;
}
html[data-theme="dark"] .bot-note { background: #222; }

#post-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 230px;
  gap: 1.5rem;
}

.editor-title {
  font: bold 1.6rem Tahoma, sans-serif !important;
  width: 100%;
  padding: 0.5rem 0.6rem;
  border: 1px solid #7f9db9 !important;
  margin-bottom: 0.75rem;
}

.editor-excerpt {
  width: 100%;
  font-size: 0.95rem;
  border: 1px solid #7f9db9;
  padding: 0.5rem 0.6rem;
  margin-bottom: 0.75rem;
}

.editor-toolbar {
  display: flex;
  gap: 0.25rem;
  align-items: center;
  flex-wrap: wrap;
  padding: 0.4rem;
  background: var(--xp-beige-bg);
  border: 1px solid #7f9db9;
  margin-bottom: 0.5rem;
}
.editor-toolbar button, .upload-button {
  border: 1px solid #7f9db9;
  background: linear-gradient(to bottom, #ffffff, #e4e0d0);
  font: 11px var(--mono);
  cursor: pointer;
  padding: 0.3rem 0.5rem;
  border-radius: 2px;
}

.editor-body {
  width: 100%;
  border: 1px solid #7f9db9 !important;
  padding: 0.9rem !important;
  line-height: 1.6;
  min-height: 420px;
  font-size: 0.98rem !important;
  font-family: Georgia, serif;
}

.editor-sidebar {
  border: 1px solid #7f9db9;
  background: var(--xp-beige-bg);
  padding: 0.9rem;
  height: fit-content;
}
html[data-theme="dark"] .editor-sidebar { background: #252525; }

.sidebar-field { margin-bottom: 1rem; }
.sidebar-field > label { display: block; font: 10.5px var(--mono); text-transform: uppercase; margin-bottom: 0.3rem; }
.slug-field {
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid #7f9db9;
  font: 11px var(--mono);
  padding-left: 0.4rem;
}
.slug-field input { border: 0 !important; padding: 0.4rem 0.2rem; font: inherit !important; }
.editor-sidebar select { width: 100%; font-size: 12px; padding: 0.4rem; border: 1px solid #7f9db9; background: #fff; }

.login-panel {
  max-width: 420px;
  background: var(--xp-beige-bg);
  border: 2px solid #0055ea;
  border-radius: 6px;
  padding: 1.5rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}
.login-panel h1 { font-size: 1.6rem; margin: 0 0 0.5rem; }
.login-form label { display: block; font: 11px var(--mono); text-transform: uppercase; margin: 0.8rem 0 0.3rem; }
.login-form input { width: 100%; padding: 0.5rem 0.6rem; border: 1px solid #7f9db9; font: inherit; }
.login-form button { width: 100%; margin-top: 1.1rem; }

.is-error { color: #d63c2f; font-weight: bold; }
.error-page { text-align: center; padding: 4rem 1rem; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   Responsive Adaptations
   ========================================================================== */
@media (max-width: 820px) {
  body {
    padding: 0 0 30px 0;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
  }
  .xp-stage {
    width: 100%;
    max-width: 100%;
    margin: 0;
    height: calc(100vh - 30px);
    height: calc(100dvh - 30px);
  }
  .xp-window {
    border-radius: 0;
    border: 0;
    height: 100%;
  }
  .xp-icons {
    display: none;
  }
  .xp-explorer-view {
    display: flex;
    flex-direction: column;
    height: auto;
  }
  .xp-content {
    overflow-y: auto !important;
  }
  .xp-sidebar {
    height: auto;
    border-right: none;
    border-bottom: 1px solid #5a6eb5;
    flex-shrink: 0;
  }
  .xp-main-pane {
    height: auto;
    overflow-y: visible;
  }
  .post-row {
    grid-template-columns: 20px 1fr auto;
    gap: 0.5rem;
  }
  .post-row time {
    grid-column: 2 / 3;
    padding: 0;
  }
  .xp-nav {
    flex-direction: column;
    align-items: flex-start;
  }
  .site-nav {
    flex-wrap: wrap;
  }
  #post-form {
    display: flex;
    flex-direction: column;
  }
  .editor-sidebar {
    order: -1;
  }
  .xp-task {
    min-width: 0;
    max-width: 130px;
  }
  .xp-cmd-window {
    width: 95vw;
    left: 2.5vw;
    right: 2.5vw;
  }
}

/* ==========================================================================
   Story Series (Grok'un Köşesi: seriler gruplu, bölüm gezintisi)
   ========================================================================== */
.xp-group-title {
  display: flex;
  align-items: baseline;
  gap: 0.45rem;
  margin: 0.4rem 0 0.6rem;
  padding: 0 0 0.25rem;
  font-size: 13px;
  font-weight: bold;
  color: var(--xp-sidebar-box-head);
  border-bottom: 1px solid #7aa1e6;
}
html[data-theme="dark"] .xp-group-title { color: var(--xp-link-blue); border-bottom-color: #384a63; }
.xp-group-count { font: 11px var(--mono); font-weight: normal; color: var(--xp-text-muted); }
.series-index { margin-bottom: 1.4rem; }
.series-index + .writing-index { margin-top: 0.4rem; }

.series-card {
  margin: 0 0 0.9rem;
  background: #ffffff;
  border: 1px solid #7f9db9;
  border-radius: 4px 4px 0 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
  overflow: hidden;
}
html[data-theme="dark"] .series-card { background: #1b1f24; border-color: #384a63; }
.series-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 5px 9px;
  background: linear-gradient(to right, #215dc6 0%, #6385d6 100%);
  color: #ffffff;
  font-weight: bold;
  font-size: 12.5px;
  cursor: pointer;
  user-select: none;
  list-style: none;
}
.series-head::-webkit-details-marker { display: none; }
html[data-theme="dark"] .series-head { background: linear-gradient(to right, #1c2128 0%, #30363d 100%); }
.series-head-title { display: inline-flex; align-items: center; gap: 0.4rem; flex: 1 1 auto; min-width: 0; }
.series-head-meta { font-weight: normal; font-size: 11px; opacity: 0.95; white-space: nowrap; }
.series-head-toggle { font-size: 9px; transition: transform 0.2s ease; }
.series-card:not([open]) .series-head-toggle { transform: rotate(180deg); }
.series-body { padding: 0.5rem 0.7rem 0.75rem; background: #f4f7fd; }
html[data-theme="dark"] .series-body { background: #1e2228; }
.series-dates { margin: 0 0 0.4rem; font: 11px var(--mono); color: var(--xp-text-muted); }
.series-episodes { list-style: none; margin: 0 0 0.6rem; padding: 0; border-top: 1px solid #dfe6f3; }
html[data-theme="dark"] .series-episodes { border-top-color: #2d333b; }
.series-ep-row { padding: 0.45rem 0.3rem; border-bottom: 1px solid #dfe6f3; }
html[data-theme="dark"] .series-ep-row { border-bottom-color: #2d333b; }
.series-ep-row:hover { background: #e8f0fd; }
html[data-theme="dark"] .series-ep-row:hover { background: #21262d; }
.series-ep {
  display: grid;
  grid-template-columns: 5.2rem minmax(0, 1fr) auto;
  gap: 0.6rem;
  align-items: baseline;
  color: var(--xp-link-blue);
  text-decoration: none;
}
.series-ep:hover .series-ep-title { text-decoration: underline; color: var(--xp-link-hover); }
.series-ep-no { font: bold 11px var(--mono); color: var(--xp-text-muted); }
.series-ep-title { font-weight: bold; font-size: 1rem; }
.series-ep-date { font: 11px var(--mono); color: var(--xp-text-muted); white-space: nowrap; }
.series-ep-excerpt { margin: 0.2rem 0 0 5.8rem; font-size: 0.88rem; line-height: 1.4; color: #444444; }
html[data-theme="dark"] .series-ep-excerpt { color: #c9d1d9; }
.series-final-badge {
  display: inline-block;
  margin-left: 0.3rem;
  padding: 0 5px;
  font: bold 10px Tahoma, "Segoe UI", sans-serif;
  color: #ffffff;
  background: var(--xp-orange-badge);
  border-radius: 2px;
  vertical-align: middle;
}
.series-start { text-decoration: none; }

/* Bölüm sayfası */
.series-box {
  margin: 0 0 1.4rem;
  border: 1px solid #7f9db9;
  background: #d6dff7;
  border-radius: 3px;
  font-size: 12px;
}
html[data-theme="dark"] .series-box { background: #1e2228; border-color: #384a63; }
.series-box-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.4rem;
  padding: 6px 10px;
  font-weight: bold;
}
.series-box-head a { color: var(--xp-link-blue); }
.series-box-pos { font: 11px var(--mono); color: var(--xp-text-muted); font-weight: normal; }
.series-box-list { padding: 0 10px 6px; }
.series-box-list summary { cursor: pointer; color: var(--xp-link-blue); }
.series-box-list ol { margin: 0.4rem 0 0.2rem 1.2rem; padding: 0; }
.series-box-list li { margin: 0.15rem 0; }
.series-box-list a { color: var(--xp-link-blue); }
.series-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.8rem;
  margin-top: 2rem;
}
.series-pager-link {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.6rem 0.8rem;
  border: 1px solid #7f9db9;
  border-radius: 3px;
  background: linear-gradient(to bottom, #ffffff 0%, #ece9d8 100%);
  color: var(--xp-link-blue);
  text-decoration: none;
}
html[data-theme="dark"] .series-pager-link { background: #21262d; border-color: #384a63; }
.series-pager-link:hover { border-color: var(--xp-orange-badge); }
.series-next { text-align: right; grid-column: 2; }
.series-pager-label { font: 11px var(--mono); color: var(--xp-text-muted); }
.series-pager-title { font-weight: bold; }
.article-body video {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 0 0 1.2rem;
  border: 1px solid #7f9db9;
  padding: 4px;
  background: #000000;
  box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.15);
  box-sizing: border-box;
}

@media (max-width: 820px) {
  .series-head { flex-wrap: wrap; }
  .series-ep { grid-template-columns: 1fr auto; gap: 0.15rem 0.5rem; }
  .series-ep-no { grid-column: 1; }
  .series-ep-date { grid-column: 2; grid-row: 1; }
  .series-ep-title { grid-column: 1 / -1; }
  .series-ep-excerpt { margin-left: 0; }
  .series-pager { grid-template-columns: 1fr; }
  .series-next { grid-column: 1; }
}
