/* ===== RESET ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }

/* ===== DARK THEME (default) ===== */
:root {
  --bg-page:           #0a0a0a;
  --bg-wrapper:        #0f0f0f;
  --border-wrapper:    #333;
  --bg-header:         #111;
  --border-header:     #222;
  --shadow-h1:         #000;
  --color-sub:         #666;
  --bg-marquee:        #000;
  --border-marquee:    #1a1a1a;
  --color-hl:          #FFFF00;
  --bg-footer:         #080808;
  --color-footer:      #666;
  --color-footer-sub:  #555;
  --color-body:        #ccc;
  --theme-btn-bg:      #000;
  --theme-btn-color:   #FF6600;
  --theme-btn-border:  #FF6600;
}

/* ===== LIGHT THEME ===== */
body.light {
  --bg-page:           #e8e8e8;
  --bg-wrapper:        #ffffff;
  --border-wrapper:    #ccc;
  --bg-header:         #f5f5f5;
  --border-header:     #ddd;
  --shadow-h1:         #ddd;
  --color-sub:         #999;
  --bg-marquee:        #f0f0f0;
  --border-marquee:    #ddd;
  --color-hl:          #cc4400;
  --bg-footer:         #f5f5f5;
  --color-footer:      #999;
  --color-footer-sub:  #ccc;
  --color-body:        #222;
  --theme-btn-bg:      #fff;
  --theme-btn-color:   #FF6600;
  --theme-btn-border:  #FF6600;
}

/* ===== BODY ===== */
body {
  background-color: var(--bg-page);
  background-image: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 3px,
    rgba(255,102,0,0.03) 3px,
    rgba(255,102,0,0.03) 4px
  );
  color: var(--color-body);
  font-family: Arial, sans-serif;
  font-size: 13px;
  min-height: 100vh;
  transition: background-color 0.2s, color 0.2s;
}

/* ===== WRAPPER ===== */
#wrapper {
  width: 1100px;
  max-width: 100%;
  margin: 30px auto;
  border: 2px solid var(--border-wrapper);
  border-top: 3px solid #FF6600;
  background: var(--bg-wrapper);
}

/* ===== TOP BAR ===== */
#topbar {
  background: #FF6600;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: bold;
  color: #000;
  display: flex;
  justify-content: space-between;
  align-items: center;
  letter-spacing: 0.5px;
  gap: 10px;
}

#topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

#theme-toggle {
  background: var(--theme-btn-bg);
  color: var(--theme-btn-color);
  border: 1px solid var(--theme-btn-border);
  font-size: 10px;
  font-weight: bold;
  font-family: Arial, sans-serif;
  padding: 1px 6px;
  cursor: pointer;
  letter-spacing: 1px;
  text-transform: uppercase;
  line-height: 1.6;
}
#theme-toggle:hover { opacity: 0.8; }

/* ===== HEADER ===== */
#header {
  background: var(--bg-header);
  border-bottom: 2px solid var(--border-header);
  padding: 20px 20px 16px;
  text-align: center;
}

#header-info h1 {
  font-family: "Arial Black", Arial, sans-serif;
  font-size: 42px;
  font-weight: 900;
  text-shadow: 0 0 12px rgba(255,102,0,0.3), 2px 2px 0 var(--shadow-h1);
  letter-spacing: 4px;
  line-height: 1;
}

#header-info .sub {
  font-size: 11px;
  color: var(--color-sub);
  margin-top: 5px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

#header-info .tagline {
  font-size: 11px;
  color: #FF6600;
  margin-top: 3px;
  letter-spacing: 1px;
}

/* ===== MARQUEE ===== */
#marquee-wrap {
  background: var(--bg-marquee);
  border-top: 1px solid var(--border-marquee);
  border-bottom: 1px solid #FF6600;
  padding: 5px 0;
  overflow: hidden;
  white-space: nowrap;
}

#marquee-text {
  display: inline-flex;
  animation: marquee-scroll 30s linear infinite;
  color: #FF6600;
  font-size: 11px;
  font-weight: bold;
  letter-spacing: 1px;
  will-change: transform;
}

.marquee-content { flex-shrink: 0; white-space: nowrap; }
#marquee-text .hl { color: var(--color-hl); }

@keyframes marquee-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ===== FOOTER ===== */
#footer {
  background: var(--bg-footer);
  border-top: 2px solid #FF6600;
  padding: 10px 16px;
  font-size: 10px;
  color: var(--color-footer);
  text-align: center;
  letter-spacing: 0.5px;
}

#footer a { color: #FF6600; text-decoration: none; }
#footer a:hover { text-decoration: underline; }

.footer-sub {
  margin-top: 3px;
  color: var(--color-footer-sub);
  font-size: 10px;
}

/* ===== PULSE DOT ===== */
.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #00cc44;
  flex-shrink: 0;
  animation: dot-pulse 1.8s ease-in-out infinite;
}

@keyframes dot-pulse {
  0%, 100% { opacity: 1;   box-shadow: 0 0 4px #00cc44; }
  50%       { opacity: 0.3; box-shadow: none; }
}

/* ===== BLINK ===== */
@keyframes blink {
  0%, 100% { opacity: 1; }
  49%       { opacity: 1; }
  50%       { opacity: 0; }
}
.blink { animation: blink 1s step-end infinite; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  #wrapper { margin: 0 auto; }
  #header-info h1 { font-size: 34px; letter-spacing: 3px; }
}

@media (max-width: 600px) {
  body     { font-size: 12px; overflow-x: hidden; }
  #wrapper { margin: 0; border-left: none; border-right: none; }
  #topbar  { font-size: 10px; gap: 6px; }
  #topbar > span:first-child { display: none; }
  #header  { padding: 12px; }
  #header-info h1       { font-size: 28px; letter-spacing: 2px; }
  #header-info .sub     { font-size: 10px; letter-spacing: 1px; }
  #header-info .tagline { font-size: 10px; }
  #marquee-wrap { padding: 4px 0; }
  #marquee-text { font-size: 9px; letter-spacing: 0.5px; animation-duration: 55s; }
}
