/* ========================================================= */
/* 1. GLOBAL SITE WINDOWS 98 THEME & BACKGROUNDS             */
/* ========================================================= */

html, body {
  cursor: url('/cursor.png'), auto;
}

body {
  background-image: url('earthbound-bg-183-6.gif');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

.window-body {
  background-color: #ced0d0;
  font-family: "MS Sans Serif", Tahoma, Arial, sans-serif;
  font-size: 11px;
  padding: 8px;
}

/* Title bar graphics */
.title-bar {
  background: #000080; /* flat color instead of a smooth gradient — reads as pixel/retro, not glossy */
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 3px 5px 3px 3px;
  box-sizing: border-box;
  font-weight: bold;
  font-size: 14px;
  image-rendering: pixelated;
  border-top: 2px solid #1084d0;
  border-left: 2px solid #1084d0;
  border-right: 2px solid #000040;
  border-bottom: 2px solid #000040;
  /* hard inset/outset bevel, like classic Win98 chrome, instead of a soft shadow */
  box-shadow:
    inset 1px 1px 0px #3a6ea5,
    inset -1px -1px 0px #00003f;
}

/* Custom window positioning layer */
.custom-window-position {
  position: absolute;
  top: 300px;
  left: 800px;
  z-index: 999;
}

/* ========================================================= */
/* 2. WINDOWS 98 TAB SELECTION LIST SYSTEM                  */
/* ========================================================= */

menu[role="tablist"] {
  display: flex;
  list-style-type: none;
  padding: 0;
  margin: 0 0 -2px 0;
  position: relative;
  z-index: 2;
}

menu[role="tablist"] li[role="tab"] {
  border-top: 2px solid #ffffff;
  border-left: 2px solid #ffffff;
  border-right: 2px solid #808080;
  border-bottom: 2px solid #ced0d0;
  border-top-left-radius: 2px;
  border-top-right-radius: 2px;
  margin-right: 2px;
  background-color: #ced0d0;
}

menu[role="tablist"] li[role="tab"] a {
  display: block;
  padding: 3px 6px 4px 6px;
  color: #000000;
  text-decoration: none;
  outline: none;
}

menu[role="tablist"] li[role="tab"][aria-selected="true"] {
  position: relative;
  margin-top: -2px;
  padding-bottom: 2px;
  border-bottom: 2px solid #ced0d0;
  z-index: 3;
}

menu[role="tablist"] li[role="tab"][aria-selected="true"] a {
  font-weight: bold;
  padding: 4px 6px 4px 6px;
}

.window[role="tabpanel"] {
  border-top: 2px solid #ffffff;
  border-left: 2px solid #ffffff;
  border-right: 2px solid #808080;
  border-bottom: 2px solid #808080;
  background-color: #ced0d0;
  position: relative;
  box-shadow: 1px 1px 0px 0px #000000;
  z-index: 1;
}

.window[role="tabpanel"]::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border-right: 1px solid #404040;
  border-bottom: 1px solid #404040;
  pointer-events: none;
}

.window[role="tabpanel"] .window-body {
  padding: 12px;
  border: none;
}

/* ========================================================= */
/* 3. OPTIMIZED GINACITIES-STYLE COZY MUSIC PLAYER          */
/* ========================================================= */

.music-box {
  --cozy-pink: #e3d3f7;
  --cozy-cream: #ede2fb;
  --cozy-brown: #4a3b57;
  --cozy-accent: #a06fd9;
  --cozy-accent-dark: #6f4bb0;

  /* Pixel-cut corners instead of rounded/plain corners — stair-steps each corner */
  clip-path: polygon(
    0px 8px, 8px 8px, 8px 0px,
    calc(100% - 8px) 0px, calc(100% - 8px) 8px, 100% 8px,
    100% calc(100% - 8px), calc(100% - 8px) calc(100% - 8px), calc(100% - 8px) 100%,
    8px 100%, 8px calc(100% - 8px), 0px calc(100% - 8px)
  );

  background: #f6f1fc !important;
  border: 2px solid var(--cozy-accent-dark) !important;
  /* Hard-edged offset shadow instead of a soft blur — reads as "pixel" rather than "smooth" */
  box-shadow: 4px 4px 0px rgba(74, 59, 87, 0.25) !important;

  width: 240px !important;
  margin: 20px auto !important;
  display: block !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

/* Font Standardization Rule Overrides */
.music-box * {
  font-family: 'Silkscreen', monospace !important;
  box-sizing: border-box !important;
  color: var(--cozy-brown) !important;
}

/* Title bar: purple-to-pink diagonal gradient, flat (no glossy blend), replaces the
   default blue Windows title bar just for this window */
.music-box .title-bar {
  background: linear-gradient(120deg, #8b6fc9, #d98fd0) !important;
  border: none !important;
  box-shadow: none !important;
  padding: 6px 8px !important;
}

.music-box .title-bar-text {
  font-size: 12px !important;
  color: #ffffff !important;
  letter-spacing: 1px !important;
}

/* Small colored squares instead of text glyphs, matching the reference's plain
   pastel minimize/maximize/close blocks */
.music-box .title-bar-controls {
  display: flex !important;
  gap: 4px !important;
}

.music-box .title-bar-controls button {
  width: 12px !important;
  height: 12px !important;
  min-width: 12px !important;
  padding: 0 !important;
  border: 1px solid rgba(255,255,255,0.6) !important;
  border-radius: 2px !important;
  cursor: pointer !important;
}

.music-box .title-bar-controls button[aria-label="Minimize"] { background: #f3c6e8 !important; }
.music-box .title-bar-controls button[aria-label="Maximize"] { background: #d8c2f0 !important; }
.music-box .title-bar-controls button[aria-label="Close"]    { background: #f3a6b8 !important; }

.music-box .window-body {
  padding: 12px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 8px !important;
}

/* Album Art Frame — centered square placeholder */
.music-box .cover {
  width: 90px !important;
  height: 90px !important;
  border-radius: 4px !important;
  border: 1px solid var(--cozy-accent) !important;
  background-color: #ffffff !important;
  background-size: cover !important;
  background-position: center !important;
}

.music-box .now-playing-row {
  width: 100% !important;
  text-align: left !important;
  font-size: 11px !important;
  margin: 0 !important;
}

.music-box .now-playing-label {
  font-weight: bold !important;
}

.music-box .songtitle {
  font-style: normal !important;
}

/* Play/Pause/Skip/Repeat Button Row */
.music-box .button-pad {
  display: flex !important;
  justify-content: center !important;
  gap: 6px !important;
  width: 100% !important;
}

.music-box .button-pad button {
  background-color: #ffffff !important;
  border: 1px solid var(--cozy-accent) !important;
  border-radius: 3px !important;
  cursor: pointer !important;
  width: 30px !important;
  height: 26px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 12px !important;
  padding: 0 !important;
}

.music-box .button-pad button:hover {
  background-color: var(--cozy-pink) !important;
}

/* Repeat button lights up orange when toggled active, like the reference */
.music-box .repeat-track.active {
  background-color: #f2a154 !important;
  border-color: #d9812f !important;
}

/* Seek bar */
.music-box .Timeline {
  width: 100% !important;
}

.music-box .sleek-slider {
  width: 100% !important;
  cursor: pointer !important;
  accent-color: var(--cozy-accent) !important;
  background: transparent !important;
  height: auto !important;
}

.music-box .time-readout {
  font-size: 10px !important;
  width: 100% !important;
  text-align: center !important;
}

/* Volume row */
.music-box .volume-row {
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
  width: 100% !important;
  font-size: 10px !important;
  text-transform: uppercase !important;
}

.music-box .volume-slider {
  flex-grow: 1 !important;
  cursor: pointer !important;
  accent-color: var(--cozy-accent) !important;
}