/* ==========================================================================
   SiamHash Thailand - Vintage Early-Days Bitcoin Era (2009-2013 Nostalgia)
   Aesthetic: Bitcointalk / Slush Pool / Web 2.0 / Windows XP / CGMiner CRT
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Sarabun:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400&family=Share+Tech+Mono&family=VT323&display=swap');

:root {
  /* Vintage 2010-era Palette */
  --win-bg: #ece9d8;
  --forum-bg: #f4f6f9;
  --forum-header-bg: #274b70;
  --forum-header-sub: #4b6f96;
  --forum-header-text: #ffffff;
  --forum-border: #8099b3;
  --table-border: #b0c2d4;
  --table-row-alt: #f0f4f8;
  --table-row-hover: #e4edf5;

  /* Bitcoin Classic Gold & Accents */
  --btc-gold-vintage: #f7931a;
  --btc-gold-dark: #b86b04;
  --alert-yellow-bg: #fffce6;
  --alert-yellow-border: #e6db55;
  --alert-yellow-text: #594f06;
  
  /* CRT Terminal Colors */
  --crt-bg: #0c100c;
  --crt-green: #33ff33;
  --crt-green-dim: #1a8c1a;
  --crt-amber: #ffb000;
  --crt-cyan: #00e5ff;

  /* Button Bevel Colors */
  --btn-light: #ffffff;
  --btn-face: #e0ded4;
  --btn-dark: #808080;
  --btn-darker: #404040;

  /* Fonts */
  --font-retro: 'Tahoma', 'Verdana', 'Sarabun', sans-serif;
  --font-mono: 'Share Tech Mono', 'Courier New', monospace;
  --font-pixel: 'VT323', monospace;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: #3b5978;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 20px 20px;
  font-family: var(--font-retro);
  font-size: 13px;
  color: #222222;
  line-height: 1.5;
  padding: 16px 0 32px;
}

a {
  color: #0b5999;
  text-decoration: underline;
}

a:hover {
  color: #d15a00;
}

/* Main Fixed-Width Container (Classic 2010 Style: 980px) */
.page-wrapper {
  width: 980px;
  max-width: 96%;
  margin: 0 auto;
  background: #ffffff;
  border: 1px solid #162a3f;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
}

/* Classic Vintage Header */
.retro-header {
  background: linear-gradient(180deg, #375d86 0%, #203f62 60%, #172f4a 100%);
  color: #ffffff;
  padding: 14px 20px;
  border-bottom: 3px solid #f7931a;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* Authentic Satoshi 2009-2010 Style Gold Coin Badge */
.satoshi-coin {
  width: 58px;
  height: 58px;
  background: radial-gradient(circle at 35% 35%, #ffd768 0%, #f7931a 65%, #9b5300 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.8), 0 3px 6px rgba(0, 0, 0, 0.4);
  border: 2px solid #fff;
  color: #ffffff;
  font-family: 'Times New Roman', serif;
  font-size: 34px;
  font-weight: bold;
  text-shadow: 1px 1px 2px #5c3200, -1px -1px 0 #ffe082;
  flex-shrink: 0;
}

.brand-names h1 {
  font-size: 22px;
  font-weight: bold;
  color: #ffffff;
  letter-spacing: -0.5px;
  text-shadow: 1px 1px 2px #000000;
}

.brand-names .subtitle {
  font-size: 12px;
  color: #ffd084;
  font-weight: normal;
}

.header-quote-box {
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 8px 12px;
  border-radius: 4px;
  max-width: 380px;
  font-size: 11px;
  color: #e3edf7;
  font-style: italic;
  line-height: 1.4;
}

.header-quote-author {
  display: block;
  text-align: right;
  font-weight: bold;
  color: #ffd084;
  font-style: normal;
  margin-top: 2px;
}

/* Classic Tabbed Navigation Bar */
.retro-navbar {
  background: linear-gradient(180deg, #f0f0eb 0%, #dcd8cc 100%);
  border-bottom: 1px solid #999;
  padding: 0 10px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.nav-tabs-list {
  display: flex;
  list-style: none;
  gap: 4px;
  padding-top: 6px;
}

.nav-tab-item a {
  display: block;
  padding: 6px 14px 7px;
  font-size: 12px;
  font-weight: bold;
  color: #333333;
  text-decoration: none;
  background: linear-gradient(180deg, #ece9d8 0%, #cbc7b7 100%);
  border: 1px solid #7f7c6e;
  border-bottom: none;
  border-radius: 4px 4px 0 0;
  transition: background 0.15s;
}

.nav-tab-item a:hover {
  background: #ffffff;
  color: #0b5999;
}

.nav-tab-item.active a {
  background: #ffffff;
  border-top: 2px solid #f7931a;
  padding-top: 5px;
  color: #000000;
  position: relative;
  top: 1px;
}

.nav-right-status {
  padding-bottom: 6px;
  font-size: 11px;
  color: #444;
}

/* Marquee Scrolling Banner */
.marquee-bar {
  background: #fff8cc;
  border-bottom: 1px solid #e0d080;
  padding: 4px 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: #665200;
  display: flex;
  align-items: center;
}

.marquee-badge {
  background: #cc0000;
  color: #ffffff;
  font-weight: bold;
  padding: 1px 6px;
  font-size: 10px;
  border-radius: 2px;
  margin-right: 8px;
  text-transform: uppercase;
  flex-shrink: 0;
}

/* Main Content Area */
.main-content {
  padding: 16px;
}

/* Classic Alert Box (Sticky Note Style) */
.sticky-notice {
  background: var(--alert-yellow-bg);
  border: 1px solid #e6db55;
  border-left: 5px solid #f7931a;
  padding: 10px 14px;
  margin-bottom: 16px;
  font-size: 12px;
  color: #443c08;
}

.sticky-notice strong {
  color: #945200;
}

/* 2-Column Forum Layout */
.forum-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 16px;
}

/* Classic Section Box / Window Box */
.window-box {
  border: 1px solid var(--forum-border);
  margin-bottom: 16px;
  background: #ffffff;
}

.window-title {
  background: linear-gradient(180deg, #375d86 0%, #203f62 100%);
  color: #ffffff;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: bold;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #162a3f;
}

.window-title .sub-tag {
  font-size: 10px;
  font-weight: normal;
  color: #ffd084;
}

.window-body {
  padding: 12px;
}

/* Classic 3D Bevel Buttons */
.win-btn {
  font-family: var(--font-retro);
  font-size: 12px;
  font-weight: bold;
  padding: 5px 14px;
  background: var(--btn-face);
  border-top: 2px solid var(--btn-light);
  border-left: 2px solid var(--btn-light);
  border-right: 2px solid var(--btn-darker);
  border-bottom: 2px solid var(--btn-darker);
  cursor: pointer;
  color: #000000;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}

.win-btn:active {
  border-top: 2px solid var(--btn-darker);
  border-left: 2px solid var(--btn-darker);
  border-right: 2px solid var(--btn-light);
  border-bottom: 2px solid var(--btn-light);
  padding: 6px 13px 4px 15px;
}

.win-btn-primary {
  background: linear-gradient(180deg, #ffc060 0%, #e68000 100%);
  color: #000;
  border-color: #ffd898 #804000 #804000 #ffd898;
}

.win-btn-green {
  background: linear-gradient(180deg, #5ddb5d 0%, #289b28 100%);
  color: #fff;
  border-color: #98ff98 #005000 #005000 #98ff98;
  text-shadow: 1px 1px 1px #003300;
}

/* Classic Form Elements */
.win-input {
  background: #ffffff;
  border-top: 2px solid #7f9db9;
  border-left: 2px solid #7f9db9;
  border-right: 2px solid #d4d0c8;
  border-bottom: 2px solid #d4d0c8;
  padding: 4px 8px;
  font-family: var(--font-retro);
  font-size: 12px;
  outline: none;
}

.win-input:focus {
  border-color: #2b70b5;
}

/* CRT CGMiner 3.7.2 Terminal Simulator */
.crt-terminal-box {
  background: var(--crt-bg);
  border: 3px solid #333333;
  box-shadow: inset 0 0 15px rgba(0, 0, 0, 0.8), 0 4px 10px rgba(0,0,0,0.3);
  padding: 12px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--crt-green);
  line-height: 1.45;
  position: relative;
  overflow: hidden;
}

.crt-terminal-box::before {
  content: " ";
  display: block;
  position: absolute;
  top: 0; left: 0; bottom: 0; right: 0;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%);
  background-size: 100% 4px;
  z-index: 2;
  pointer-events: none;
}

.terminal-header-line {
  color: var(--crt-amber);
  border-bottom: 1px dashed var(--crt-green-dim);
  padding-bottom: 4px;
  margin-bottom: 6px;
  display: flex;
  justify-content: space-between;
}

.terminal-live-stats {
  background: rgba(0, 50, 0, 0.3);
  border: 1px solid var(--crt-green-dim);
  padding: 6px 10px;
  margin: 8px 0;
  color: #fff;
}

.terminal-log-scroll {
  height: 150px;
  overflow-y: auto;
  font-size: 11px;
  color: #70db70;
  margin-top: 8px;
}

.log-entry {
  margin-bottom: 3px;
}
.log-entry.ok { color: var(--crt-green); font-weight: bold; }
.log-entry.warn { color: var(--crt-amber); }
.log-entry.block { color: var(--crt-cyan); font-weight: bold; }

/* Classic Mining Packages Table */
.retro-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.retro-table th {
  background: linear-gradient(180deg, #4b6f96 0%, #2d4a68 100%);
  color: #ffffff;
  padding: 6px 10px;
  text-align: left;
  border: 1px solid #162a3f;
  font-weight: bold;
}

.retro-table td {
  padding: 8px 10px;
  border: 1px solid var(--table-border);
}

.retro-table tr:nth-child(even) {
  background-color: var(--table-row-alt);
}

.retro-table tr:hover {
  background-color: var(--table-row-hover);
}

/* Sidebar Widgets */
.sidebar-stat-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  border-bottom: 1px dotted #ccc;
  font-size: 11px;
}

.sidebar-stat-row:last-child {
  border-bottom: none;
}

.stat-bold-gold {
  font-weight: bold;
  color: #c46200;
  font-family: var(--font-mono);
}

/* Vintage Visitor Counter */
.counter-box {
  background: #111;
  border: 2px inset #999;
  padding: 6px 12px;
  display: inline-flex;
  gap: 3px;
  margin: 6px 0;
}

.counter-digit {
  background: linear-gradient(180deg, #222 0%, #000 50%, #151515 100%);
  color: #00ff00;
  font-family: var(--font-pixel);
  font-size: 26px;
  padding: 0 5px;
  border: 1px solid #444;
  border-radius: 2px;
  box-shadow: inset 0 1px 3px rgba(0,255,0,0.3);
}

/* Mode Switcher Banner */
.era-switcher {
  background: #e1e9f0;
  border: 1px solid #99b4cc;
  padding: 8px 12px;
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}

/* Classic Forum Footer */
.retro-footer {
  background: #274b70;
  border-top: 3px solid #f7931a;
  color: #d1e2f2;
  padding: 16px 20px;
  font-size: 11px;
  text-align: center;
  line-height: 1.6;
}

.footer-badges-strip {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.retro-web-badge {
  background: #fff;
  color: #000;
  border: 1px solid #333;
  padding: 2px 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: bold;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.retro-web-badge.w3c { background: #5c85b5; color: #fff; }
.retro-web-badge.ie8 { background: #005a9c; color: #fff; }
.retro-web-badge.pgp { background: #ffcc00; color: #000; }

/* Classic Windows Dialog Modal */
.win-dialog-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.win-dialog-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.win-dialog-box {
  width: 440px;
  max-width: 95%;
  background: var(--btn-face);
  border-top: 2px solid var(--btn-light);
  border-left: 2px solid var(--btn-light);
  border-right: 2px solid var(--btn-darker);
  border-bottom: 2px solid var(--btn-darker);
  box-shadow: 4px 4px 12px rgba(0, 0, 0, 0.5);
}

.win-dialog-titlebar {
  background: linear-gradient(90deg, #0a246a 0%, #a6caf0 100%);
  color: #ffffff;
  font-weight: bold;
  padding: 3px 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}

.win-dialog-close {
  width: 16px;
  height: 14px;
  background: var(--btn-face);
  border-top: 1px solid var(--btn-light);
  border-left: 1px solid var(--btn-light);
  border-right: 1px solid var(--btn-darker);
  border-bottom: 1px solid var(--btn-darker);
  font-size: 10px;
  line-height: 10px;
  text-align: center;
  cursor: pointer;
  color: #000;
  font-weight: bold;
}

.win-dialog-content {
  padding: 16px;
}

/* Responsive adjustments */
@media (max-width: 800px) {
  .forum-grid {
    grid-template-columns: 1fr;
  }
  .retro-header {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
  .header-quote-box {
    max-width: 100%;
  }
  .nav-tabs-list {
    flex-wrap: wrap;
  }
}
