/* ==========================================================================
   WINDOWS 98 / 2000 OS FILE EXPLORER THEME (100% NATIVE VANILLA CSS)
   Restricted Adult Archive C:\SECRET_ARCHIVE\
   Zero external dependencies | <3ms TTFB | Ultra Responsive & Lightweight
   ========================================================================== */

:root {
  --win-teal: #008080;
  --win-gray: #c0c0c0;
  --win-darkgray: #808080;
  --win-light: #ffffff;
  --win-dark: #000000;
  --win-title-blue-start: #000080;
  --win-title-blue-end: #1084d0;
  --win-accent: #000080;
  --win-font: "MS Sans Serif", Tahoma, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --win-mono: "Lucida Console", "Courier New", monospace;
  --bevel-light: #dfdfdf;
  --bevel-shadow: #808080;
  --bevel-dark: #0a0a0a;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  background-color: var(--win-teal);
  background-image: 
    radial-gradient(rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 8px 8px;
  font-family: var(--win-font);
  font-size: 12px;
  color: var(--win-dark);
  user-select: text;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

/* 3D Bevel Utilities */
.win-outset {
  border-top: 2px solid var(--win-light);
  border-left: 2px solid var(--win-light);
  border-right: 2px solid var(--win-dark);
  border-bottom: 2px solid var(--win-dark);
  box-shadow: inset 1px 1px 0px var(--bevel-light), inset -1px -1px 0px var(--bevel-shadow);
}

.win-inset {
  border-top: 2px solid var(--bevel-shadow);
  border-left: 2px solid var(--bevel-shadow);
  border-right: 2px solid var(--win-light);
  border-bottom: 2px solid var(--win-light);
  box-shadow: inset 1px 1px 0px var(--win-dark), inset -1px -1px 0px var(--bevel-light);
}

.win-btn {
  background: var(--win-gray);
  border-top: 2px solid var(--win-light);
  border-left: 2px solid var(--win-light);
  border-right: 2px solid var(--win-dark);
  border-bottom: 2px solid var(--win-dark);
  box-shadow: inset 1px 1px 0px var(--bevel-light), inset -1px -1px 0px var(--bevel-shadow);
  font-family: var(--win-font);
  font-size: 11px;
  padding: 3px 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  color: #000;
  font-weight: 600;
  text-decoration: none;
}

.win-btn:active, .win-btn.active {
  border-top: 2px solid var(--win-dark);
  border-left: 2px solid var(--win-dark);
  border-right: 2px solid var(--win-light);
  border-bottom: 2px solid var(--win-light);
  box-shadow: inset 1px 1px 0px var(--bevel-shadow);
  padding: 4px 9px 2px 11px;
}

.win-btn:focus {
  outline: 1px dotted #000;
  outline-offset: -4px;
}

/* Desktop Workspace */
.desktop-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding-bottom: 34px; /* Space for taskbar */
}

/* Desktop Header Bar (optional quick shortcuts) */
.desktop-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 16px;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  font-family: var(--win-mono);
  font-size: 11px;
}

.desktop-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: bold;
  letter-spacing: 0.5px;
}

.desktop-badge {
  background: #ff0055;
  color: #fff;
  padding: 2px 6px;
  font-size: 10px;
  font-weight: bold;
  border-radius: 2px;
}

/* Main Window */
.window-wrapper {
  max-width: 1360px;
  width: 96%;
  margin: 16px auto 30px;
  background: var(--win-gray);
}

.window-titlebar {
  background: linear-gradient(90deg, var(--win-title-blue-start) 0%, var(--win-title-blue-end) 100%);
  color: #ffffff;
  padding: 3px 4px 3px 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
}

.titlebar-left {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: bold;
  font-size: 12px;
  letter-spacing: 0.3px;
  text-shadow: 1px 1px 0 rgba(0,0,0,0.5);
}

.titlebar-icon {
  width: 16px;
  height: 16px;
  display: inline-block;
}

.titlebar-controls {
  display: flex;
  gap: 2px;
}

.titlebar-btn {
  width: 18px;
  height: 16px;
  background: var(--win-gray);
  border-top: 1px solid var(--win-light);
  border-left: 1px solid var(--win-light);
  border-right: 1px solid var(--win-dark);
  border-bottom: 1px solid var(--win-dark);
  font-size: 10px;
  line-height: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #000;
  font-weight: bold;
  cursor: pointer;
  padding: 0;
}

.titlebar-btn:active {
  border-top: 1px solid var(--win-dark);
  border-left: 1px solid var(--win-dark);
  border-right: 1px solid var(--win-light);
  border-bottom: 1px solid var(--win-light);
}

/* Menu Bar */
.window-menubar {
  display: flex;
  background: var(--win-gray);
  border-bottom: 1px solid var(--win-darkgray);
  padding: 1px 4px;
}

.menu-item {
  padding: 3px 8px;
  font-size: 11px;
  cursor: default;
  color: #000;
}

.menu-item:hover {
  background: var(--win-accent);
  color: #ffffff;
}

.menu-item span {
  text-decoration: underline;
}

/* Explorer Standard Toolbar */
.window-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 3px;
  padding: 4px 6px;
  background: var(--win-gray);
  border-bottom: 1px solid var(--win-darkgray);
  border-top: 1px solid var(--win-light);
}

.tool-sep {
  width: 1px;
  height: 22px;
  background: var(--win-darkgray);
  border-right: 1px solid var(--win-light);
  margin: 0 4px;
}

.tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 7px;
  background: var(--win-gray);
  border: 1px solid transparent;
  font-size: 11px;
  cursor: pointer;
  color: #000;
}

.tool-btn:hover {
  border-top: 1px solid var(--win-light);
  border-left: 1px solid var(--win-light);
  border-right: 1px solid var(--win-dark);
  border-bottom: 1px solid var(--win-dark);
}

.tool-btn:active {
  border-top: 1px solid var(--win-dark);
  border-left: 1px solid var(--win-dark);
  border-right: 1px solid var(--win-light);
  border-bottom: 1px solid var(--win-light);
}

/* Address Bar */
.window-addressbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  background: var(--win-gray);
  border-bottom: 2px solid var(--win-darkgray);
  border-top: 1px solid var(--win-light);
}

.address-label {
  font-size: 11px;
  color: #333;
  font-weight: 600;
}

.address-input-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  background: #fff;
  padding: 2px 6px;
}

.address-icon {
  width: 16px;
  height: 16px;
  margin-right: 6px;
}

.address-input {
  border: none;
  outline: none;
  width: 100%;
  font-family: var(--win-font);
  font-size: 12px;
  color: #000;
  background: transparent;
}

.search-box-wrapper {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 280px;
}

.search-input {
  width: 100%;
  padding: 3px 8px;
  font-family: var(--win-font);
  font-size: 12px;
  background: #ffffff;
  color: #000;
}

/* Window Content (Split View) */
.window-body {
  display: flex;
  background: #ffffff;
  min-height: 520px;
  border-top: 1px solid var(--bevel-shadow);
}

/* Left Sidebar - Classic Explorer Web View Panel */
.sidebar-pane {
  width: 260px;
  flex-shrink: 0;
  background: #ffffff;
  border-right: 2px solid var(--win-gray);
  padding: 18px 14px;
  position: relative;
  background: linear-gradient(180deg, #f7f7f7 0%, #e8e8e8 100%);
  font-size: 11px;
  line-height: 1.45;
}

.sidebar-folder-hero {
  text-align: center;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid #d0d0d0;
}

.sidebar-folder-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 8px;
}

.sidebar-title {
  font-size: 16px;
  font-weight: bold;
  color: #000080;
  margin: 0 0 4px 0;
}

.sidebar-subtitle {
  font-size: 11px;
  color: #555;
  margin: 0;
}

.sidebar-stats-card {
  background: #ffffff;
  padding: 10px;
  margin-bottom: 14px;
}

.stat-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 5px;
  font-size: 11px;
}

.stat-label {
  color: #666;
}

.stat-value {
  font-weight: bold;
  color: #000;
}

.disk-meter {
  height: 14px;
  background: #e0e0e0;
  margin-top: 8px;
  position: relative;
  overflow: hidden;
}

.disk-meter-fill {
  height: 100%;
  background: linear-gradient(90deg, #000080, #ff0055);
  width: 82%;
}

.sidebar-warning-box {
  background: #ffffcc;
  border: 1px solid #d4c49b;
  padding: 10px;
  margin-bottom: 14px;
  font-size: 10px;
  color: #4a3c10;
  line-height: 1.4;
}

.sidebar-warning-title {
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 5px;
  color: #a30000;
  margin-bottom: 4px;
  font-size: 11px;
}

.sidebar-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* Right Content Area */
.content-pane {
  flex: 1;
  background: #ffffff;
  padding: 14px;
  overflow-y: auto;
  max-height: 720px;
}

/* View Mode Selector Bar */
.view-mode-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f0f0f0;
  padding: 6px 10px;
  margin-bottom: 14px;
  border: 1px solid #ccc;
  font-size: 11px;
}

.mode-switches {
  display: flex;
  gap: 6px;
}

.count-indicator {
  font-weight: bold;
  color: #000080;
}

/* ==========================================================================
   MASTER DETAILS TABLE (TABLEGA HAM URL QOY)
   Every row, title, cell, and button is fully clickable with tracking URLs
   ========================================================================== */
.table-view-container {
  margin-bottom: 24px;
}

.win-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 12px;
  background: #ffffff;
}

.win-table thead th {
  background: var(--win-gray);
  border-top: 1px solid var(--win-light);
  border-left: 1px solid var(--win-light);
  border-right: 1px solid var(--win-dark);
  border-bottom: 1px solid var(--win-dark);
  padding: 4px 8px;
  font-weight: bold;
  text-align: left;
  user-select: none;
  font-size: 11px;
  white-space: nowrap;
}

.win-table tbody tr {
  cursor: pointer;
  transition: background-color 0.1s ease;
}

.win-table tbody tr:nth-child(even) {
  background: #fbfbfb;
}

.win-table tbody tr:hover {
  background: #000080 !important;
  color: #ffffff !important;
}

.win-table tbody tr:hover a,
.win-table tbody tr:hover td {
  color: #ffffff !important;
}

.win-table tbody td {
  padding: 6px 8px;
  border-bottom: 1px solid #ebebeb;
  vertical-align: middle;
}

.table-cell-link {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #000;
  text-decoration: none;
  font-weight: bold;
}

.table-folder-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.type-badge {
  display: inline-block;
  padding: 2px 6px;
  font-size: 10px;
  background: #eef2ff;
  color: #1e3a8a;
  border: 1px solid #cbd5e1;
  border-radius: 2px;
  font-family: var(--win-mono);
}

.win-table tbody tr:hover .type-badge {
  background: rgba(255,255,255,0.2);
  color: #fff;
  border-color: #fff;
}

.table-size {
  font-family: var(--win-mono);
  font-size: 11px;
  color: #333;
}

.table-date {
  font-family: var(--win-mono);
  font-size: 11px;
  color: #555;
}

.clearance-badge {
  font-size: 10px;
  font-weight: bold;
  padding: 2px 5px;
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #f87171;
  border-radius: 2px;
}

.win-table tbody tr:hover .clearance-badge {
  background: #ff0055;
  color: #fff;
  border-color: #fff;
}

.table-action-btn {
  padding: 2px 8px;
  font-size: 11px;
  font-weight: bold;
  background: var(--win-gray);
  border-top: 1px solid var(--win-light);
  border-left: 1px solid var(--win-light);
  border-right: 1px solid var(--win-dark);
  border-bottom: 1px solid var(--win-dark);
  display: inline-block;
  white-space: nowrap;
  color: #000;
  text-decoration: none;
}

.win-table tbody tr:hover .table-action-btn {
  background: #ffff00;
  color: #000;
  border-color: #fff;
}

/* ==========================================================================
   LARGE ICONS GRID (ICONS VIEW)
   Authentic Retro Folder Icons with Windows 3D styling
   ========================================================================== */
.icons-view-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.folder-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 10px 6px;
  text-align: center;
  text-decoration: none;
  color: #000;
  border: 1px solid transparent;
  border-radius: 2px;
  transition: all 0.15s ease;
  user-select: none;
}

.folder-card:hover {
  background: rgba(0, 0, 128, 0.08);
  border: 1px dotted #000080;
}

.folder-card:active {
  background: #000080;
  color: #ffffff;
}

.folder-card:active .folder-label {
  background: #000080;
  color: #ffffff;
}

.folder-svg-wrapper {
  width: 48px;
  height: 44px;
  margin-bottom: 6px;
  position: relative;
  transition: transform 0.15s ease;
}

.folder-card:hover .folder-svg-wrapper {
  transform: translateY(-2px);
}

.folder-label {
  font-size: 11px;
  line-height: 1.25;
  font-weight: 500;
  word-break: break-word;
  max-width: 100%;
  padding: 2px 4px;
  color: #000;
}

.folder-card:hover .folder-label {
  color: #000080;
  font-weight: bold;
}

.folder-badge-tag {
  font-size: 9px;
  font-family: var(--win-mono);
  color: #666;
  margin-top: 2px;
}

/* Window Status Bar */
.window-statusbar {
  display: flex;
  background: var(--win-gray);
  border-top: 1px solid var(--win-darkgray);
  padding: 2px 4px;
  gap: 4px;
  font-size: 11px;
}

.status-panel {
  padding: 2px 6px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--win-gray);
}

.status-panel.grow {
  flex: 1;
}

/* ==========================================================================
   AUTHENTIC WINDOWS 98 TASKBAR
   ========================================================================== */
.win-taskbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 32px;
  background: var(--win-gray);
  border-top: 2px solid var(--win-light);
  display: flex;
  align-items: center;
  padding: 2px 4px;
  z-index: 99999;
  user-select: none;
}

.start-btn {
  height: 24px;
  padding: 2px 8px;
  font-family: var(--win-font);
  font-weight: bold;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: var(--win-gray);
  border-top: 2px solid var(--win-light);
  border-left: 2px solid var(--win-light);
  border-right: 2px solid var(--win-dark);
  border-bottom: 2px solid var(--win-dark);
  cursor: pointer;
  margin-right: 4px;
}

.start-btn:active {
  border-top: 2px solid var(--win-dark);
  border-left: 2px solid var(--win-dark);
  border-right: 2px solid var(--win-light);
  border-bottom: 2px solid var(--win-light);
  padding: 3px 7px 1px 9px;
}

.start-logo-flag {
  width: 16px;
  height: 16px;
}

.taskbar-sep {
  width: 2px;
  height: 22px;
  border-left: 1px solid var(--win-darkgray);
  border-right: 1px solid var(--win-light);
  margin: 0 4px;
}

.quick-launch {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-right: 4px;
}

.quick-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.taskbar-tasks {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 4px;
  overflow: hidden;
}

.task-item {
  height: 24px;
  max-width: 200px;
  flex: 1;
  background: #ece9d8;
  border-top: 2px solid var(--win-dark);
  border-left: 2px solid var(--win-dark);
  border-right: 2px solid var(--win-light);
  border-bottom: 2px solid var(--win-light);
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: inset 1px 1px 0 #808080;
}

.system-tray {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 8px;
  height: 24px;
  border-top: 1px solid var(--win-darkgray);
  border-left: 1px solid var(--win-darkgray);
  border-right: 1px solid var(--win-light);
  border-bottom: 1px solid var(--win-light);
  font-size: 11px;
  background: var(--win-gray);
  font-family: var(--win-mono);
}

.tray-icon {
  width: 14px;
  height: 14px;
}

/* Responsive adjustments */
@media (max-width: 900px) {
  .window-body {
    flex-direction: column;
  }
  .sidebar-pane {
    width: 100%;
    border-right: none;
    border-bottom: 2px solid var(--win-gray);
  }
  .search-box-wrapper {
    width: 100%;
  }
  .window-addressbar {
    flex-wrap: wrap;
  }
  .win-table th:nth-child(3),
  .win-table td:nth-child(3),
  .win-table th:nth-child(4),
  .win-table td:nth-child(4) {
    display: none;
  }
}