* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Tahoma', 'Segoe UI', sans-serif;
  font-size: 13px;
  color: #000;
  background: #3a6ea5 url('/img/bliss.jpg') center/cover no-repeat fixed;
  height: 100vh;
  overflow: hidden;
  user-select: none;
}

/* ===== BOOT SCREEN ===== */
.boot-screen {
  position: fixed; inset: 0; z-index: 9999;
  background: #000; color: #c0c0c0;
  font-family: 'VT323', monospace;
  font-size: 18px;
  display: flex; align-items: flex-start; justify-content: flex-start;
  padding: 40px;
}
.boot-screen.fade-out { opacity: 0; transition: opacity 0.6s ease; pointer-events: none; }
.boot-bios pre { margin: 0; line-height: 1.4; white-space: pre-wrap; }
.boot-xp {
  position: absolute; inset: 0;
  background: #000;
  display: none;
  align-items: center; justify-content: center;
  flex-direction: column;
}
.boot-screen.show-xp .boot-bios { display: none; }
.boot-screen.show-xp .boot-xp { display: flex; }

.xp-logo-img {
  width: 200px; height: 80px;
  background: linear-gradient(180deg, #4a8edb 0%, #2960a8 100%);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-family: 'Pixelify Sans', sans-serif; font-weight: 700;
  font-size: 28px;
  letter-spacing: 0.05em;
  box-shadow: 0 4px 16px rgba(74,142,219,0.6);
}
.xp-logo-img::before { content: '$CLIPPY XP'; }

.xp-loading-bar {
  width: 200px; height: 14px; margin-top: 30px;
  background: #1a1a1a;
  border: 1px solid #444;
  overflow: hidden;
  border-radius: 2px;
}
.xp-loading-fill {
  height: 100%; width: 60px;
  background: linear-gradient(90deg, transparent 0%, #4a8edb 50%, transparent 100%);
  animation: xp-loading 1.4s ease-in-out infinite;
}
@keyframes xp-loading {
  0% { transform: translateX(-60px); }
  100% { transform: translateX(200px); }
}

/* ===== DESKTOP ===== */
.desktop {
  position: fixed; inset: 0;
  display: flex;
  flex-direction: column;
}

.desktop-icons {
  position: absolute;
  top: 16px; left: 16px;
  display: flex; flex-direction: column;
  gap: 18px;
  z-index: 1;
}
.desktop-icon {
  display: flex; flex-direction: column; align-items: center;
  width: 80px; cursor: pointer;
  padding: 4px;
  border: 1px solid transparent;
  border-radius: 2px;
}
.desktop-icon:hover { background: rgba(49, 106, 197, 0.3); border-color: rgba(255,255,255,0.5); border-style: dotted; }
.icon-img {
  width: 40px; height: 40px;
  font-size: 32px; display: flex; align-items: center; justify-content: center;
  filter: drop-shadow(1px 1px 2px rgba(0,0,0,0.4));
}
.icon-clippy::before { content: '\1F4CE'; }
.icon-folder::before { content: '\1F4C1'; }
.icon-ie::before { content: '\1F310'; }
.icon-label {
  color: #fff; font-size: 12px; text-align: center;
  text-shadow: 1px 1px 2px #000;
  margin-top: 4px;
  word-wrap: break-word;
  line-height: 1.2;
}

/* ===== WINDOW STAGE ===== */
.window-stage {
  flex: 1;
  position: relative;
  margin-bottom: 30px;
}

.xp-window {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: min(720px, 92vw);
  max-height: 80vh;
  background: #ECE9D8;
  border: 1px solid #0058CC;
  border-radius: 8px 8px 0 0;
  box-shadow: 4px 4px 16px rgba(0,0,0,0.4);
  display: none;
  opacity: 0;
  flex-direction: column;
  font-family: 'Tahoma', sans-serif;
  overflow: hidden;
  transition: opacity 0.2s, transform 0.2s;
}

/* Open state */
.xp-window.open {
  display: flex;
  animation: xp-window-open 0.35s cubic-bezier(.34,1.56,.64,1) forwards;
}

/* Focused (topmost) window — bright blue titlebar */
.xp-window.focused .xp-window-titlebar {
  background: linear-gradient(180deg, #0058CC 0%, #2A85E8 6%, #1858B8 12%, #2766CC 60%, #0E50B0 100%);
}

/* Unfocused window — grey titlebar */
.xp-window.open:not(.focused) .xp-window-titlebar {
  background: linear-gradient(180deg, #7A96DF 0%, #A0B4E8 6%, #8A9FD8 12%, #7A8FCC 60%, #6A7FB0 100%);
}

/* Minimized — hidden but still "open" */
.xp-window.minimized {
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translateY(100vh) !important;
  transition: opacity 0.2s, transform 0.3s;
}

/* Restoring from minimize */
.xp-window.restoring {
  animation: xp-restore 0.3s ease forwards;
}

/* Maximized */
.xp-window.maximized {
  top: 0 !important; left: 0 !important;
  width: 100vw !important;
  max-height: calc(100vh - 30px) !important;
  height: calc(100vh - 30px) !important;
  transform: none !important;
  border-radius: 0 !important;
}
.xp-window.maximized .xp-window-titlebar {
  border-radius: 0;
}

/* Closing animation */
.xp-window.closing {
  animation: xp-window-close 0.25s ease-in forwards;
  pointer-events: none;
}

@keyframes xp-window-open {
  0%   { opacity: 0; transform: translate(-50%, -50%) scale(0.7); }
  100% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}
@keyframes xp-window-close {
  0%   { opacity: 1; }
  100% { opacity: 0; transform: scale(0.85) translateY(30px); }
}
@keyframes xp-restore {
  0%   { opacity: 0; transform: translateY(60px); }
  100% { opacity: 1; transform: translateY(0); }
}

.xp-window-titlebar {
  background: linear-gradient(180deg, #0058CC 0%, #2A85E8 6%, #1858B8 12%, #2766CC 60%, #0E50B0 100%);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  padding: 4px 6px 4px 8px;
  display: flex; align-items: center; gap: 6px;
  cursor: grab;
  user-select: none;
  border-radius: 7px 7px 0 0;
}
.xp-window-icon { width: 16px; height: 16px; font-size: 13px; line-height: 16px; }
.xp-window-icon::before { content: '\1F4CE'; }
.xp-window-title { flex: 1; text-shadow: 1px 1px 0 rgba(0,0,0,0.4); }
.xp-window-controls { display: flex; gap: 2px; }
.xp-window-controls button {
  width: 22px; height: 21px;
  background: linear-gradient(180deg, #4A93EB 0%, #1F62C7 100%);
  border: 1px solid #073389;
  border-radius: 3px;
  color: #fff;
  font-size: 11px; font-weight: 700;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  line-height: 1;
  padding: 0;
}
.xp-btn-close {
  background: linear-gradient(180deg, #E26B5C 0%, #B22B1A 100%) !important;
  border-color: #7A1510 !important;
}
.xp-window-controls button:hover { filter: brightness(1.15); }

.xp-window-menubar {
  background: #ECE9D8;
  padding: 3px 8px;
  border-bottom: 1px solid #BFB9A4;
  display: flex; gap: 14px;
  font-size: 12px;
}
.xp-window-menubar span { padding: 1px 4px; cursor: default; }
.xp-window-menubar span:hover { background: #316AC5; color: #fff; }

.xp-window-body {
  background: #fff;
  padding: 24px 28px;
  overflow-y: auto;
  flex: 1;
  font-size: 14px;
  line-height: 1.6;
  color: #1a1a1a;
  user-select: text;
}

.xp-h1 {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: clamp(40px, 5vw, 64px);
  font-weight: 700;
  margin: 0 0 18px 0;
  color: #003399;
  line-height: 1;
}
.xp-h2 {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 700;
  margin: 0 0 14px 0;
  color: #003399;
}
.xp-subtitle {
  font-size: 16px; font-weight: 600;
  margin: 0 0 14px 0;
  color: #333;
}
.xp-body { margin-bottom: 18px; }

.xp-cta-row { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }
.xp-btn-cta {
  display: inline-block;
  padding: 10px 22px;
  background: linear-gradient(180deg, #FFE082 0%, #FF9800 100%);
  border: 2px solid #1a1a1a;
  border-radius: 4px;
  color: #1a1a1a;
  font-family: 'Tahoma', sans-serif;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 3px 0 #1a1a1a;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}
.xp-btn-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 0 #1a1a1a; }
.xp-btn-cta:active { transform: translateY(2px); box-shadow: 0 1px 0 #1a1a1a; }
.xp-btn-cta-secondary { background: linear-gradient(180deg, #C8E6FF 0%, #6FA8DC 100%); }
.xp-btn-cta-chart { background: linear-gradient(180deg, #A5D6A7 0%, #4CAF50 100%); color: #fff; }
.xp-btn-cta-tools { background: linear-gradient(180deg, #CE93D8 0%, #9C27B0 100%); color: #fff; }
.xp-btn-cta-rewards { background: linear-gradient(180deg, #FFD54F 0%, #FF8F00 100%); color: #1a1a1a; }

/* IE Address bar */
.xp-address-bar {
  background: #ECE9D8;
  padding: 3px 6px;
  border-bottom: 1px solid #BFB9A4;
  display: flex; align-items: center; gap: 6px;
  font-size: 12px;
}
.ab-label { color: #555; font-weight: 600; }
.ab-input {
  flex: 1;
  background: #fff;
  border: 1px solid #7F9DB9;
  padding: 2px 6px;
  font-size: 12px;
  border-radius: 1px;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ab-go {
  background: linear-gradient(180deg, #f0f0f0 0%, #d4d4d4 100%);
  border: 1px solid #999;
  padding: 2px 10px;
  font-size: 11px;
  cursor: pointer;
  border-radius: 2px;
}

/* Ticker bar */
.xp-ticker-bar {
  margin-top: 20px;
  background: #003399;
  padding: 6px 0;
  border-radius: 3px;
  overflow: hidden;
  position: relative;
}
.ticker-scroll {
  display: inline-block;
  white-space: nowrap;
  color: #FFD93D;
  font-size: 13px;
  font-weight: 700;
  font-family: 'Tahoma', sans-serif;
  animation: ticker 20s linear infinite;
}
@keyframes ticker {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Links grid */
.xp-links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  margin-top: 16px;
}
.xp-link-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 16px 10px;
  background: linear-gradient(180deg, #f8f8f8 0%, #e8e8e8 100%);
  border: 1px solid #ccc;
  border-radius: 4px;
  text-decoration: none;
  color: #1a1a1a;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
  cursor: pointer;
}
.xp-link-card:hover {
  background: linear-gradient(180deg, #e0eeff 0%, #c4daff 100%);
  border-color: #316AC5;
  transform: translateY(-2px);
}
.xp-link-icon { font-size: 28px; margin-bottom: 6px; }
.xp-link-name { font-weight: 700; font-size: 13px; }
.xp-link-desc { font-size: 11px; color: #666; margin-top: 2px; }

/* CA badge */
.ca-badge {
  position: fixed;
  top: 10px;
  right: 10px;
  background: rgba(0, 0, 0, 0.7);
  color: #FFD93D;
  font-family: 'VT323', monospace;
  font-size: 14px;
  padding: 6px 14px;
  border-radius: 4px;
  z-index: 90;
  cursor: pointer;
  display: flex;
  gap: 6px;
  align-items: center;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.15);
  transition: background 0.2s;
}
.ca-badge:hover { background: rgba(0,0,0,0.85); }
.ca-label { color: #aaa; }
.ca-value { color: #FFD93D; word-break: break-all; max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* More desktop icon styles */
.icon-about::before { content: '\1F4D6'; }
.icon-tokenomics::before { content: '\1F4BE'; }
.icon-howtobuy::before { content: '\1F310'; }
.icon-community::before { content: '\1F4AC'; }
.icon-links::before { content: '\1F517'; }
.icon-meme::before { content: '\1F602'; }
.icon-hero::before { content: '\1F4CE'; }

/* Tray separator */
.tray-sep { opacity: 0.3; font-size: 10px; }

.xp-window-statusbar {
  background: #ECE9D8;
  border-top: 1px solid #BFB9A4;
  padding: 3px 10px;
  font-size: 11px;
  display: flex; justify-content: space-between;
  color: #555;
}

/* ===== TASKBAR ===== */
.taskbar {
  position: fixed; bottom: 0; left: 0; right: 0;
  height: 30px;
  background: linear-gradient(180deg, #245EDC 0%, #3F8DEE 8%, #1F4FB2 50%, #1547A0 100%);
  display: flex; align-items: center;
  z-index: 100;
  border-top: 1px solid #0E3F95;
  box-shadow: 0 -1px 0 rgba(255,255,255,0.3) inset;
}

.start-btn {
  display: flex; align-items: center; gap: 6px;
  background: linear-gradient(180deg, #5EAA5E 0%, #2E7D32 100%);
  color: #fff;
  font-family: 'Tahoma', sans-serif;
  font-size: 14px; font-weight: 700; font-style: italic;
  padding: 0 16px 2px 12px;
  height: 30px;
  border: none;
  border-radius: 0 14px 14px 0;
  cursor: pointer;
  text-shadow: 1px 1px 0 rgba(0,0,0,0.4);
  box-shadow: 1px 0 0 rgba(255,255,255,0.2) inset;
}
.start-btn:hover { filter: brightness(1.08); }
.start-btn:active { filter: brightness(0.95); }
.start-icon::before { content: '\1F4CE'; font-size: 16px; font-style: normal; }

.taskbar-windows {
  flex: 1;
  display: flex; gap: 3px;
  padding: 0 8px;
  overflow-x: auto;
}
.taskbar-window {
  display: flex; align-items: center; gap: 6px;
  background: linear-gradient(180deg, #4A93EB 0%, #1F62C7 100%);
  color: #fff;
  border: 1px solid #073389;
  border-radius: 3px;
  padding: 3px 12px;
  height: 22px;
  font-size: 12px;
  cursor: pointer;
  max-width: 180px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-family: 'Tahoma', sans-serif;
}
.taskbar-window.active {
  background: linear-gradient(180deg, #1F4DA0 0%, #2A6FCB 50%, #1F4DA0 100%);
  box-shadow: inset 1px 1px 3px rgba(0,0,0,0.4);
}
.taskbar-window.tb-open { border-color: #0050b0; }
.taskbar-window:not(.tb-open) {
  display: none;
}
.taskbar-window.tb-minimized {
  opacity: 0.7;
  font-style: italic;
}
.taskbar-window:hover { filter: brightness(1.08); }
.tw-icon { font-size: 11px; }
.tw-icon::before { content: '\1F4CE'; }

.taskbar-tray {
  display: flex; align-items: center; gap: 8px;
  background: linear-gradient(180deg, #1958BD 0%, #0E3F95 100%);
  padding: 0 12px;
  height: 30px;
  border-left: 1px solid rgba(255,255,255,0.2);
  color: #fff;
  font-size: 12px;
}
.tray-icon { color: #fff; text-decoration: none; font-size: 14px; }
.tray-icon:hover { opacity: 0.7; }
.tray-clock { font-family: 'Tahoma'; font-size: 11px; }

/* ===== START MENU ===== */
.start-menu {
  position: fixed; bottom: 30px; left: 0;
  width: 380px;
  background: linear-gradient(180deg, #fff 0%, #ECE9D8 100%);
  border: 2px solid #0058CC;
  border-bottom: none;
  border-radius: 6px 6px 0 0;
  box-shadow: 4px -4px 16px rgba(0,0,0,0.3);
  display: none;
  flex-direction: column;
  z-index: 200;
  overflow: hidden;
}
.start-menu.open { display: flex; animation: xp-window-open 0.2s ease forwards; }

.start-menu-header {
  background: linear-gradient(180deg, #2A85E8 0%, #1858B8 100%);
  color: #fff;
  padding: 10px 14px;
  display: flex; align-items: center; gap: 12px;
}
.start-avatar {
  width: 42px; height: 42px;
  background: #FFD93D;
  border: 2px solid #fff;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.start-avatar::before { content: '\1F4CE'; }
.start-username { font-weight: 700; font-size: 14px; text-shadow: 1px 1px 0 rgba(0,0,0,0.3); }

.start-menu-body { display: grid; grid-template-columns: 1fr 1fr; }
.start-col-left { background: #fff; padding: 8px; }
.start-col-right { background: #D6DFF7; padding: 8px; }
.start-item {
  display: block;
  padding: 8px 12px;
  text-decoration: none;
  color: #000;
  font-size: 13px;
  border-radius: 3px;
  font-family: 'Tahoma', sans-serif;
}
.start-item:hover { background: #316AC5; color: #fff; }
.start-item-buy { background: #FFD93D; font-weight: 700; }
.start-item-buy:hover { background: #F5C518; color: #000; }
.start-col-left hr { border: none; border-top: 1px solid #BFB9A4; margin: 6px 4px; }

.start-menu-footer {
  background: linear-gradient(180deg, #2A85E8 0%, #1858B8 100%);
  padding: 6px 12px;
  display: flex; justify-content: flex-end;
}
.start-shutdown {
  background: transparent; color: #fff;
  border: none; cursor: pointer;
  font-size: 12px; font-family: 'Tahoma', sans-serif;
}
.start-shutdown:hover { text-decoration: underline; }

/* ===== CLIPPY (clippyjs uses inline styles, target via JS-added class) ===== */
.clippy-balloon {
  background: #FFFFCC !important;
  border: 1px solid #000 !important;
  border-radius: 6px !important;
  padding: 10px 14px !important;
  font-family: 'Tahoma', sans-serif !important;
  font-size: 13px !important;
  color: #000 !important;
  z-index: 101 !important;
}

/* ===== TOKENOMICS ===== */
.token-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin: 20px 0;
}
.token-details-col h3 {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: 16px;
  color: #003399;
  margin: 0 0 10px 0;
  border-bottom: 1px solid #BFB9A4;
  padding-bottom: 4px;
}
.xp-token-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.xp-token-table td { padding: 6px 8px; border-bottom: 1px dotted #BFB9A4; }
.xp-token-table td:first-child { color: #555; width: 40%; }
.xp-token-table td:last-child { text-align: right; }
.xp-token-table tr:last-child td { border-bottom: none; }

.xp-rewards-mini {
  background: linear-gradient(180deg, #f8fbff 0%, #e0ecff 100%);
  border: 1px solid #BFB9A4;
  border-radius: 4px;
  padding: 14px;
}
.rewards-stat-label { font-size: 11px; color: #555; text-transform: uppercase; letter-spacing: 0.05em; }
.rewards-stat-value {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #2e7d32;
  margin: 4px 0 8px 0;
}
.rewards-mini-note { font-size: 11px; color: #555; margin: 0 0 12px 0; line-height: 1.4; }

/* Mini iframe in tokenomics card */
.rewards-iframe-container {
  position: relative;
  width: 100%;
  height: 200px;
  background: #fff;
  border: 1px inset #ACA899;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 8px;
}
.rewards-iframe-container::before {
  content: 'Loading chart...';
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Tahoma', sans-serif; font-size: 11px; color: #999;
  background: #f5f5f5; z-index: 0;
}
.rewards-iframe-container.loaded::before { display: none; }
.rewards-iframe {
  width: 181.8%; height: 363.6%;
  border: 0; display: block;
  transform: scale(0.55);
  transform-origin: top left;
  pointer-events: none;
}
.rewards-iframe-fallback {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center; padding: 12px;
  background: linear-gradient(180deg, #f8fbff 0%, #e0ecff 100%);
}
.rewards-iframe-container.loaded .rewards-iframe-fallback { display: none; }
.rewards-fallback-icon { font-size: 36px; margin-bottom: 6px; }
.rewards-fallback-title {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: 14px; color: #003399; margin-bottom: 4px;
}
.rewards-fallback-text { font-size: 11px; color: #555; line-height: 1.3; }

.xp-contract-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin: 18px 0 4px 0;
  padding: 10px 14px;
  background: #F0F0F0;
  border: 1px solid #BFB9A4;
  border-radius: 4px;
}
.xp-contract-label { font-weight: 700; font-size: 13px; color: #003399; }
.xp-contract-value {
  flex: 1;
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 13px;
  word-break: break-all;
  background: #fff;
  padding: 4px 8px;
  border: 1px solid #d0d0d0;
  border-radius: 3px;
}
.xp-contract-copy {
  background: linear-gradient(180deg, #FFE082 0%, #FF9800 100%);
  border: 1px solid #1a1a1a;
  border-radius: 3px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.xp-contract-copy:hover { filter: brightness(1.05); }

/* ===== REWARDS IFRAME ===== */
.xp-rewards-wrapper {
  display: flex; flex-direction: column; height: 100%;
  background: #fff;
  margin: -24px -28px;
}
.xp-ie-address-bar {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px;
  background: #ECE9D8;
  border-bottom: 1px solid #BFB9A4;
  font-size: 12px;
}
.xp-address-label { color: #555; font-weight: 600; }
.xp-address-input {
  flex: 1; background: #fff;
  border: 1px inset #ACA899;
  padding: 3px 8px;
  font-size: 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  min-width: 0;
}
.xp-address-go {
  background: linear-gradient(180deg, #4A93EB 0%, #1F62C7 100%);
  color: #fff; padding: 3px 14px;
  border: 1px solid #073389; border-radius: 3px;
  text-decoration: none; font-size: 12px; font-weight: 700;
}
.xp-iframe-container { flex: 1; position: relative; background: #fff; min-height: 480px; }
.xp-iframe { width: 100%; height: 100%; border: 0; display: block; }
.xp-iframe-fallback {
  position: absolute; inset: 0;
  display: none;
  flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 40px;
  background: linear-gradient(180deg, #fff 0%, #f0f4ff 100%);
}
.xp-iframe-container.blocked .xp-iframe { display: none; }
.xp-iframe-container.blocked .xp-iframe-fallback { display: flex; }
.xp-iframe-fallback-icon { font-size: 64px; margin-bottom: 16px; }
.xp-iframe-fallback h3 {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: 24px; color: #003399; margin: 0 0 12px 0;
}
.xp-iframe-fallback p { max-width: 420px; margin: 0 0 8px 0; font-size: 14px; line-height: 1.5; }

/* ===== LORE ===== */
.xp-lore-wrapper { padding: 4px 0; }
.lore-hero {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid #BFB9A4;
}
.lore-pfp {
  width: 56px; height: 56px;
  background: linear-gradient(180deg, #4a8edb 0%, #2960a8 100%);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 32px;
  flex-shrink: 0;
}
.lore-section {
  background: #f4f4f0;
  border: 1px solid #BFB9A4;
  border-radius: 4px;
  padding: 12px 16px;
  margin-bottom: 12px;
}
.lore-h3 {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: 15px;
  color: #003399;
  margin: 0 0 8px 0;
}
.lore-section p { margin: 0 0 10px 0; font-size: 13px; line-height: 1.55; }
.lore-section p:last-child { margin-bottom: 0; }
.lore-callout {
  background: linear-gradient(180deg, #fff8e1 0%, #ffecb3 100%);
  border-color: #d4af37;
}
.lore-token {
  background: linear-gradient(180deg, #e3f2fd 0%, #bbdefb 100%);
  border-color: #1976d2;
}
.lore-cta-row {
  display: flex; gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.lore-cta-btn {
  flex: 1;
  min-width: 110px;
  display: inline-flex;
  align-items: center; justify-content: center;
  gap: 6px;
  padding: 8px 12px;
  border: 1px solid #1a1a1a;
  border-radius: 4px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 2px 0 #1a1a1a;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}
.lore-cta-btn:hover { transform: translateY(-1px); box-shadow: 0 3px 0 #1a1a1a; }
.lore-cta-btn:active { transform: translateY(2px); box-shadow: 0 0 0 #1a1a1a; }
.lore-cta-yt { background: linear-gradient(180deg, #ff6161 0%, #c62828 100%); color: #fff; }
.lore-cta-kym { background: linear-gradient(180deg, #f5e6a8 0%, #d4af37 100%); color: #1a1a1a; }
.lore-cta-twitter { background: linear-gradient(180deg, #1a1a1a 0%, #000 100%); color: #fff; }

/* Desktop icon styles for new sections */
.icon-rewards::before { content: '\1F3C6'; }
.icon-lore::before { content: '\1F4D6'; }
.icon-pfp::before { content: '\1F3A8'; }
.icon-chart::before { content: '\1F4CA'; }

/* ===== CHART PLACEHOLDER ===== */
.xp-chart-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 30px;
  min-height: 380px;
  background: linear-gradient(180deg, #fff 0%, #f0f4ff 100%);
}
.xp-chart-placeholder .placeholder-icon {
  font-size: 64px;
  margin-bottom: 16px;
  opacity: 0.6;
}
.xp-chart-placeholder h2 {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  color: #003399;
  margin: 0 0 12px 0;
}
.xp-chart-placeholder p {
  margin: 0 0 8px 0;
  font-size: 14px;
  color: #1a1a1a;
}
.xp-chart-meta {
  margin-top: 24px;
  padding: 14px 20px;
  background: #ECE9D8;
  border: 1px solid #BFB9A4;
  border-radius: 4px;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
}
.status-pending { color: #b8860b; }

/* ===== PFP MAKER ===== */
.pfp-maker-app {
  display: flex; flex-direction: column;
  margin: -24px -28px;
  height: calc(100% + 48px);
  background: #ECE9D8;
  font-size: 12px;
}
.pfp-tabs {
  display: flex; gap: 2px;
  background: #ECE9D8;
  border-bottom: 1px solid #BFB9A4;
  padding: 4px 6px 0 6px;
  overflow-x: auto;
}
.pfp-tab {
  background: linear-gradient(180deg, #f5f4ec 0%, #d4d0c4 100%);
  border: 1px solid #BFB9A4;
  border-bottom: none;
  border-radius: 4px 4px 0 0;
  padding: 5px 10px;
  cursor: pointer;
  font-family: 'Tahoma', sans-serif;
  font-size: 12px;
  white-space: nowrap;
}
.pfp-tab.active {
  background: linear-gradient(180deg, #fff 0%, #f0eee5 100%);
  font-weight: 700;
  position: relative; z-index: 2;
}
.pfp-tab-count {
  background: #ffd54f;
  border-radius: 10px;
  padding: 0 5px;
  font-size: 10px;
  margin-left: 4px;
}
.pfp-asset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(56px, 1fr));
  gap: 4px;
  padding: 8px;
  background: #fff;
  border-bottom: 1px solid #BFB9A4;
  max-height: 140px;
  overflow-y: auto;
}
.pfp-asset {
  width: 56px; height: 56px;
  border: 1px solid #d0d0d0;
  background: #fafafa;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  border-radius: 3px;
  transition: transform 0.1s ease;
}
.pfp-asset:hover { transform: scale(1.05); border-color: #003399; }
.pfp-asset.selected { border: 2px solid #003399; background: #e3eefb; }
.pfp-asset img { max-width: 100%; max-height: 100%; }
.pfp-asset-empty {
  background: repeating-linear-gradient(45deg, #fff, #fff 4px, #f0f0f0 4px, #f0f0f0 8px);
  font-size: 10px; color: #999;
}
.pfp-workspace {
  display: grid;
  grid-template-columns: 200px 1fr;
  flex: 1;
  min-height: 360px;
  background: #ECE9D8;
}
.pfp-controls {
  padding: 12px;
  border-right: 1px solid #BFB9A4;
  background: #f5f4ec;
}
.pfp-control-title {
  font-family: 'Pixelify Sans', 'Tahoma', sans-serif;
  font-size: 13px;
  margin: 0 0 8px 0;
  color: #003399;
}
.pfp-control-row {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 8px;
  font-size: 11px;
}
.pfp-control-row label { width: 44px; }
.pfp-control-row input[type="range"] { flex: 1; }
.pfp-btn-small {
  background: linear-gradient(180deg, #f5f5f5 0%, #d8d8d8 100%);
  border: 1px solid #999;
  border-radius: 3px;
  padding: 4px 10px;
  font-size: 11px;
  cursor: pointer;
  width: 100%;
  margin-top: 4px;
}
.pfp-protips {
  margin-top: 16px;
  padding: 8px;
  background: #fff8c5;
  border: 1px solid #d4b800;
  border-radius: 3px;
  font-size: 11px;
  line-height: 1.4;
}
.pfp-protips p { margin: 0; }
.pfp-protips kbd {
  background: #fff; border: 1px solid #999;
  border-radius: 2px; padding: 1px 5px;
  font-family: monospace; font-size: 10px;
}
.pfp-canvas-area {
  display: flex; flex-direction: column;
  align-items: center;
  padding: 12px;
  background: #fff;
}
.pfp-actions {
  display: flex; gap: 6px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.pfp-action-btn {
  background: linear-gradient(180deg, #fff 0%, #d4d0c4 100%);
  border: 1px solid #777;
  border-radius: 3px;
  padding: 5px 12px;
  font-size: 12px;
  cursor: pointer;
  font-weight: 600;
}
.pfp-action-btn:hover { filter: brightness(1.05); }
.pfp-randomize { background: linear-gradient(180deg, #fff3a0 0%, #ffd54f 100%); }
.pfp-download { background: linear-gradient(180deg, #4A93EB 0%, #1F62C7 100%); color: #fff; }
.pfp-share { background: linear-gradient(180deg, #1da1f2 0%, #0d8ddb 100%); color: #fff; }
.pfp-canvas-wrapper {
  border: 2px inset #ACA899;
  background: #fff;
  display: inline-block;
}
#pfp-canvas {
  display: block;
  max-width: 100%;
  width: 400px;
  height: 400px;
  cursor: grab;
  background: #fff;
}
#pfp-canvas:active { cursor: grabbing; }
.pfp-caption { font-size: 11px; color: #666; margin-top: 6px; }

/* Custom bg options */
.pfp-asset-special {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: linear-gradient(180deg, #fff 0%, #e0e8f5 100%) !important;
  border: 1px dashed #003399 !important;
}
.pfp-asset-special:hover {
  background: linear-gradient(180deg, #fff 0%, #c8d8f0 100%) !important;
  transform: scale(1.05);
}
.pfp-asset-color {
  background: conic-gradient(from 0deg, #ff0000, #ffff00, #00ff00, #00ffff, #0000ff, #ff00ff, #ff0000) !important;
  border: 1px solid #003399 !important;
}
.pfp-asset-color:hover { transform: scale(1.05); }
.pfp-asset-color span:first-child {
  background: rgba(255,255,255,0.85);
  width: 26px; height: 26px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.pfp-asset-color span:nth-child(2) {
  background: rgba(255,255,255,0.85);
  padding: 1px 4px;
  border-radius: 2px;
}

/* ===== MOBILE ===== */
@media (max-width: 700px) {
  .desktop-icons { display: none; }
  .xp-window { width: 96vw; max-height: 78vh; }
  .xp-window-body { padding: 16px; font-size: 13px; }
  .xp-h1 { font-size: 36px; }
  .xp-h2 { font-size: 24px; }
  .taskbar-window .tw-label { display: none; }
  .taskbar-window { padding: 3px 8px; }
  .start-menu { width: 90vw; }
  .token-details-grid { grid-template-columns: 1fr; gap: 14px; }
  .xp-contract-value { font-size: 11px; }
  .lore-hero { flex-direction: column; text-align: center; }
  .lore-cta-btn { flex: 1 1 100%; }
  .xp-rewards-wrapper { margin: -16px; }
  .pfp-workspace { grid-template-columns: 1fr; }
  .pfp-controls { border-right: none; border-bottom: 1px solid #BFB9A4; }
  .pfp-maker-app { margin: -16px; height: calc(100% + 32px); }
}
