/* ============================================================
   TSUKI PROJECT — style.css
   Второй сайт (March 2018 – December 2019)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Share+Tech+Mono&family=VT323&display=swap');

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

:root {
  --gold:    #c8a84b;
  --gold-dim:#7a6425;
  --green:   #00ff88;
  --green2:  #00cc66;
  --red:     #ff4444;
  --cyan:    #00ccff;
  --blue:    #3366ff;
  --white:   #d4c89e;
  --dim:     #6e6040;
  --bg:      #000000;
  --bg2:     #050505;
  --panel:   #08080a;
  --border:  #1a1a0a;
  --border2: #2a2410;
  --font:    'Share Tech Mono', 'Courier New', monospace;
  --header-h: 22px;
  --nav-h:    38px;
}

html, body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font);
  font-size: 13px;
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--green); text-decoration: underline; }

/* ── Scanlines overlay ───────────────────────────────────── */
body::after {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  pointer-events: none;
  z-index: 9999;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0px,
    transparent 2px,
    rgba(0,0,0,0.18) 2px,
    rgba(0,0,0,0.18) 4px
  );
  opacity: var(--scanline-opacity, 0.75);
}

/* ── TOP MARQUEE BAR ─────────────────────────────────────── */
#marquee-bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  background: #000;
  border-bottom: 1px solid #111;
  overflow: hidden;
  z-index: 1000;
  display: flex;
  align-items: center;
}
#marquee-inner {
  display: flex;
  white-space: nowrap;
  animation: marquee-scroll 45s linear infinite;
  font-size: 11px;
  letter-spacing: 0.03em;
}
#marquee-bar:hover #marquee-inner { animation-play-state: paused; }
.mq-item { padding: 0 24px; color: #888; }
.mq-sep  { color: #333; padding: 0 4px; }
.mq-green { color: var(--green2); }
.mq-red   { color: var(--red); }
.mq-gold  { color: var(--gold); }
.mq-white { color: #ccc; }

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

/* ── TOP NAVIGATION BAR ──────────────────────────────────── */
#navbar {
  position: fixed;
  top: var(--header-h);
  left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(0,0,0,0.92);
  border-bottom: 1px solid #1a1a0a;
  display: flex;
  align-items: center;
  z-index: 999;
  backdrop-filter: blur(2px);
}
#nav-logo {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 14px;
  text-decoration: none;
}
#nav-logo img { width: 24px; height: 24px; }
#nav-logo span {
  font-size: 14px;
  color: var(--white);
  letter-spacing: 0.08em;
  font-family: var(--font);
}
.nav-links-left {
  display: flex;
  align-items: stretch;
  height: 100%;
}
.nav-links-right {
  margin-left: auto;
  display: flex;
  align-items: stretch;
  height: 100%;
}
.nav-link {
  display: flex;
  align-items: center;
  padding: 0 14px;
  height: 100%;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: #aaa;
  text-decoration: none;
  border-left: 1px solid #111;
  transition: background 0.15s, color 0.15s;
  cursor: pointer;
  background: none;
  border-top: none;
  border-right: none;
  border-bottom: none;
  font-family: var(--font);
}
.nav-link:hover,
.nav-link:focus {
  color: var(--white);
  background: rgba(200,168,75,0.08);
  text-decoration: none;
}
.nav-links-right .nav-link:last-child {
  border-right: none;
}
/* vertical separators between right links */
.nav-links-right .nav-link {
  border-left: 1px solid #111;
}
/* HI 2913 special */
.nav-hi { color: var(--gold) !important; }

/* ── PAGE WRAPPER ────────────────────────────────────────── */
#page-wrapper {
  padding-top: calc(var(--header-h) + var(--nav-h));
  min-height: 100vh;
}

/* ── HERO BANNER (homepage / inner pages) ────────────────── */
.hero {
  width: 100%;
  height: 270px;
  position: relative;
  overflow: hidden;
  background: #000;
}
.hero img.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0.9;
  filter: saturate(1.3) contrast(1.1);
}
.hero-text {
  position: absolute;
  top: 50%;
  left: 6%;
  transform: translateY(-50%);
  font-size: clamp(20px, 2.8vw, 32px);
  color: var(--white);
  letter-spacing: 0.25em;
  text-shadow: 0 0 30px rgba(200,168,75,0.5), 2px 2px 0 #000;
  line-height: 1.6;
}

/* Small inner hero (non-homepage) */
.hero-inner {
  height: 60px;
}

/* ── MAIN LAYOUT ─────────────────────────────────────────── */
#main-layout {
  display: grid;
  grid-template-columns: 1fr 310px;
  gap: 0;
  max-width: 1360px;
  margin: 0 auto;
  padding: 16px 12px;
  align-items: start;
}

/* ── CONTENT AREA (left column) ──────────────────────────── */
#content {
  padding-right: 16px;
}

/* Content block / panel */
.content-block {
  border: 1px solid var(--border2);
  margin-bottom: 12px;
  background: rgba(5,5,2,0.7);
}
.content-block-header {
  padding: 10px 14px;
  font-size: 22px;
  letter-spacing: 0.2em;
  color: var(--gold);
  border-bottom: 1px solid var(--border2);
  font-family: var(--font);
}
.content-block-header.cyan { color: var(--cyan); }
.content-block-header.green { color: var(--green2); }
.content-block-body {
  padding: 12px 14px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--white);
  text-align: justify;
}
.content-block-body p { margin-bottom: 8px; }

/* News section */
.news-label {
  text-align: center;
  color: #666;
  font-size: 11px;
  margin-bottom: 4px;
  letter-spacing: 0.15em;
}
.news-title {
  text-align: center;
  font-size: 20px;
  color: var(--gold);
  letter-spacing: 0.15em;
  margin-bottom: 10px;
}
.news-more {
  display: block;
  text-align: center;
  color: var(--dim);
  letter-spacing: 0.1em;
  font-size: 11px;
  margin-top: 10px;
}
.news-more:hover { color: var(--gold); }

/* Category logos strip */
.cat-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  padding: 18px 0 8px;
  border-bottom: 1px solid var(--border2);
  margin-bottom: 10px;
}
.cat-logos img {
  height: 36px;
  opacity: 0.85;
  filter: sepia(0.4) brightness(0.9);
  transition: opacity 0.2s, filter 0.2s;
}
.cat-logos img:hover { opacity: 1; filter: none; }
.cat-logos-label {
  text-align: center;
  color: #666;
  font-size: 11px;
  padding-bottom: 12px;
  letter-spacing: 0.1em;
}

/* REGISTER CTA */
.register-btn {
  display: block;
  width: 100%;
  padding: 18px;
  text-align: center;
  font-size: 20px;
  letter-spacing: 0.3em;
  color: var(--green2);
  border: 1px solid var(--green-dim, #1a4a30);
  background: rgba(0,50,20,0.3);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  font-family: var(--font);
}
.register-btn:hover { background: rgba(0,80,30,0.5); color: var(--green); text-decoration: none; }

/* ── RIGHT SIDEBAR ───────────────────────────────────────── */
#sidebar {
  position: sticky;
  top: calc(var(--header-h) + var(--nav-h) + 16px);
  background: var(--panel);
  border: 1px solid var(--border2);
}

/* Stats panel */
.sidebar-stats {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border2);
  text-align: center;
}
.stat-number {
  font-size: 52px;
  color: var(--gold);
  letter-spacing: 0.05em;
  line-height: 1;
}
.stat-label {
  font-size: 16px;
  color: var(--white);
  letter-spacing: 0.2em;
  margin-bottom: 4px;
}
.stat-sub {
  font-size: 11px;
  color: #555;
  letter-spacing: 0.05em;
}
.stat-divider {
  border: none;
  border-top: 1px solid var(--border2);
  margin: 10px 0;
}

/* Countdown */
.countdown {
  text-align: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border2);
}
.countdown-days {
  font-size: 52px;
  color: var(--gold);
}
.countdown-days-label {
  font-size: 16px;
  color: var(--white);
  letter-spacing: 0.2em;
}
.countdown-time {
  font-size: 38px;
  color: var(--gold);
  letter-spacing: 0.08em;
  margin-top: 6px;
}
.countdown-until {
  font-size: 11px;
  color: #666;
  letter-spacing: 0.15em;
  margin-top: 2px;
}

/* Nav tree sidebar */
.sidebar-nav { padding: 10px 0 16px; }
.sidebar-nav-section {
  padding: 6px 16px 2px;
}
.sidebar-nav-heading {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--gold);
  letter-spacing: 0.12em;
  margin-bottom: 4px;
  cursor: pointer;
}
.sidebar-nav-heading img {
  height: 14px;
  filter: sepia(1) brightness(0.9);
}
.sidebar-nav-item {
  display: block;
  padding: 2px 0 2px 20px;
  font-size: 11px;
  color: #888;
  letter-spacing: 0.08em;
  text-decoration: none;
  transition: color 0.15s;
}
.sidebar-nav-item:hover { color: var(--gold); text-decoration: none; }

/* 4TH ENTRY block */
.sidebar-4th-entry {
  margin: 8px 12px;
  padding: 14px;
  border: 1px solid var(--gold-dim);
  text-align: center;
  font-size: 14px;
  color: var(--gold);
  letter-spacing: 0.18em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.sidebar-4th-entry img { height: 14px; filter: sepia(1); }

/* ── FOOTER ──────────────────────────────────────────────── */
#footer {
  background: #000;
  border-top: 1px solid #111;
  padding: 20px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  font-size: 11px;
  color: #555;
  line-height: 1.7;
}
#footer img { height: 44px; opacity: 0.7; }
#footer p { margin-bottom: 2px; }

/* ── INNER PAGE LAYOUT (no sidebar on some) ──────────────── */
.inner-main {
  max-width: 1360px;
  margin: 0 auto;
  padding: 16px 12px;
  display: grid;
  grid-template-columns: 1fr 310px;
  gap: 0;
  align-items: start;
}

.inner-content {
  padding-right: 16px;
}
.inner-page-title {
  font-size: 26px;
  color: var(--gold);
  letter-spacing: 0.18em;
  margin-bottom: 4px;
}
.inner-page-divider {
  border: none;
  border-top: 1px solid var(--border2);
  margin: 8px 0 14px;
}
.inner-page-body {
  font-size: 12px;
  line-height: 1.8;
  text-align: justify;
  color: var(--white);
}
.inner-page-body p { margin-bottom: 10px; }

/* ── STARFIELD BACKGROUND pages ─────────────────────────── */
.bg-stars {
  background: radial-gradient(ellipse at 50% 40%, #0b0820 0%, #000 70%);
  min-height: 100vh;
  position: relative;
}

/* Night sky overlay (subtle stars via pseudo) */
.bg-stars::before {
  content: '';
  position: fixed;
  inset: 0;
  background: url('../assets/nightsky-overlay.png') repeat;
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}

/* ── AUTHENTICATE (Login) PAGE ───────────────────────────── */
.auth-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - var(--header-h) - var(--nav-h));
  padding: 30px;
}
.auth-box {
  background: #000;
  border: 1px solid #222;
  padding: 30px 36px;
  width: 100%;
  max-width: 640px;
}
.auth-title {
  font-size: 26px;
  color: var(--white);
  letter-spacing: 0.3em;
  text-align: center;
  margin-bottom: 16px;
  border-bottom: 1px solid #1a1a1a;
  padding-bottom: 14px;
}
.auth-desc {
  text-align: center;
  color: #888;
  font-size: 12px;
  margin-bottom: 16px;
}
.auth-input {
  display: block;
  width: 100%;
  background: #060606;
  border: 1px solid #222;
  color: var(--white);
  font-family: var(--font);
  font-size: 14px;
  padding: 10px 12px;
  margin-bottom: 8px;
  outline: none;
  letter-spacing: 0.05em;
}
.auth-input:focus { border-color: var(--gold-dim); }
.auth-submit {
  display: block;
  width: 100%;
  background: #050505;
  border: 1px solid #1a1a1a;
  color: var(--white);
  font-family: var(--font);
  font-size: 16px;
  letter-spacing: 0.3em;
  padding: 12px;
  cursor: pointer;
  transition: background 0.15s;
}
.auth-submit:hover { background: #111; }

.auth-section-heading {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 0.1em;
  margin: 16px 0 8px;
}
.auth-section-heading::before {
  content: '—';
  color: var(--gold-dim);
}
.auth-safety-text {
  font-size: 11px;
  color: #666;
  line-height: 1.7;
  margin-bottom: 12px;
}
.auth-link-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #888;
  margin-bottom: 4px;
}
.auth-link-item::before { content: '→'; color: var(--gold-dim); }
.auth-link-item a { color: #888; }
.auth-link-item a:hover { color: var(--gold); }

/* ── MEMBER PAGE ─────────────────────────────────────────── */
.member-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - var(--header-h) - var(--nav-h));
  padding: 30px;
}
.member-box {
  background: #000;
  border: 1px solid #1e1e1e;
  padding: 24px 28px;
  width: 100%;
  max-width: 640px;
  position: relative;
}
.member-id {
  font-size: 52px;
  color: var(--gold);
  letter-spacing: 0.05em;
  margin-bottom: 20px;
}
.member-eot-card {
  position: absolute;
  top: 16px; right: 16px;
  width: 160px;
  border: 1px solid #333;
  padding: 8px;
  background: rgba(200,190,170,0.08);
}
.member-eot-card img { width: 100%; }
.member-eot-card .eot-hash {
  font-size: 9px;
  color: #888;
  word-break: break-all;
  margin-top: 4px;
}
.member-divider {
  border: none;
  border-top: 1px solid #111;
  margin: 16px 0;
}
.member-status-item {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}
.member-status-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}
.member-status-text {
  font-size: 14px;
  letter-spacing: 0.12em;
}
.member-status-text .status-colored { }
.member-status-text .status-gold { color: var(--gold); }
.member-status-text .status-green { color: var(--green2); }
.member-status-sub {
  font-size: 11px;
  color: #555;
  letter-spacing: 0.05em;
}
.member-actions { margin-top: 16px; }
.member-action-link {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #777;
  margin-bottom: 4px;
  letter-spacing: 0.05em;
  text-decoration: none;
}
.member-action-link::before { content: '→'; color: var(--gold-dim); }
.member-action-link:hover { color: var(--gold); text-decoration: none; }

/* ── COMMUNITY PAGE ──────────────────────────────────────── */
.community-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  border: 1px solid var(--border2);
  padding: 16px;
  margin-bottom: 10px;
  background: rgba(5,5,2,0.5);
  cursor: pointer;
  transition: background 0.15s;
}
.community-item:hover { background: rgba(15,12,3,0.8); }
.community-item img {
  width: 52px;
  height: 52px;
  object-fit: contain;
  flex-shrink: 0;
  filter: brightness(0.85);
}
.community-item-title {
  font-size: 18px;
  letter-spacing: 0.18em;
  color: var(--gold);
  margin-bottom: 4px;
}
.community-item-desc {
  font-size: 11px;
  color: #888;
  line-height: 1.6;
}
.community-item-desc a { color: var(--gold); }

/* ── EoT PAGE ────────────────────────────────────────────── */
.eot-box {
  border: 1px solid #1a1a1a;
  background: #050505;
  padding: 16px;
  margin-top: 16px;
}
.eot-box-header {
  font-size: 16px;
  color: var(--red);
  letter-spacing: 0.15em;
  margin-bottom: 12px;
}
.eot-noise {
  width: 100%;
  min-height: 300px;
  background: repeating-linear-gradient(
    45deg,
    #222 0px, #111 1px, #0a0a0a 2px, #1a1a1a 3px, #080808 4px
  );
  position: relative;
  display: flex;
  align-items: flex-start;
  padding: 16px;
}
.eot-noise-text {
  font-size: 18px;
  color: var(--red);
  letter-spacing: 0.2em;
  font-weight: bold;
}

/* ── PREFERENCES PANEL ───────────────────────────────────── */
#prefs-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 9000;
  align-items: flex-end;
  justify-content: center;
}
#prefs-overlay.active { display: flex; }
#prefs-panel {
  background: #06060e;
  border-top: 2px solid var(--blue);
  width: 100%;
  max-width: 860px;
  padding: 20px 30px 0;
}
.prefs-title {
  font-size: 22px;
  letter-spacing: 0.25em;
  color: var(--white);
  margin-bottom: 16px;
}
.prefs-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #0d0d0d;
}
.prefs-row-label { font-size: 13px; letter-spacing: 0.1em; }
.prefs-row-sub   { font-size: 10px; color: #555; margin-top: 2px; }
.prefs-control   { display: flex; align-items: center; gap: 6px; }

/* Radio tri-state */
.tri-radio { display: flex; gap: 3px; }
.tri-btn {
  width: 28px; height: 28px;
  border: 1px solid #333;
  background: #050505;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
}
.tri-btn.red   { color: var(--red); }
.tri-btn.grey  { color: #555; }
.tri-btn.green { color: var(--green2); }
.tri-btn.active { border-color: currentColor; background: rgba(255,255,255,0.05); }

/* Range slider */
.prefs-slider {
  width: 200px;
  accent-color: var(--blue);
}

.prefs-close {
  display: block;
  width: 100%;
  text-align: center;
  padding: 14px;
  background: var(--blue);
  color: #fff;
  font-family: var(--font);
  font-size: 15px;
  letter-spacing: 0.3em;
  border: none;
  cursor: pointer;
  margin-top: 16px;
  transition: background 0.15s;
}
.prefs-close:hover { background: #2255ee; }

/* ── AZ2 PAGE ────────────────────────────────────────────── */
.az2-page {
  background: #000;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.az2-topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px;
  font-size: 12px;
  letter-spacing: 0.12em;
  z-index: 100;
  background: #000;
}
.az2-life { color: var(--cyan); }
.az2-life span { border: 1px solid var(--cyan); padding: 1px 6px; margin-left: 6px; }
.az2-pmr { color: #555; }
.az2-pmr span { border: 1px solid var(--blue); color: var(--blue); padding: 1px 6px; margin-left: 6px; }
.az2-logo { color: #333; }
.az2-horizon {
  position: absolute;
  top: 50%;
  left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--cyan), var(--blue), transparent);
  transform: translateY(-50%);
  box-shadow: 0 0 12px rgba(0,200,255,0.4);
}
.az2-body {
  position: relative;
  z-index: 1;
  text-align: center;
  margin-top: auto;
  padding: 50px 20px 80px;
}
.az2-title {
  font-size: 22px;
  color: var(--cyan);
  letter-spacing: 0.25em;
  margin-bottom: 10px;
}
.az2-subtitle {
  font-size: 12px;
  color: #555;
  margin-bottom: 20px;
  letter-spacing: 0.06em;
}
.az2-text { font-size: 11px; color: #333; max-width: 600px; margin: 0 auto 12px; line-height: 1.7; }
.az2-maintenance {
  position: fixed;
  bottom: 16px; right: 16px;
  font-size: 10px;
  color: #333;
  border: 1px solid #1a1a1a;
  padding: 3px 8px;
}

/* ── 404 PAGE ────────────────────────────────────────────── */
.page-404 {
  min-height: calc(100vh - var(--header-h) - var(--nav-h));
  position: relative;
  overflow: hidden;
}
.page-404-bg {
  position: absolute;
  inset: 0;
  background: url('../assets/pics/soshimejta.png') center/cover no-repeat;
  opacity: 0.5;
  filter: hue-rotate(200deg) saturate(1.5);
}
.page-404-content {
  position: relative;
  z-index: 1;
  padding: 40px;
}
.page-404-title {
  font-size: clamp(28px, 5vw, 52px);
  color: var(--white);
  letter-spacing: 0.25em;
  margin-bottom: 16px;
}
.page-404-text { font-size: 12px; color: #aaa; margin-bottom: 6px; }
.page-404-code { font-size: 11px; color: var(--red); }

/* ── UTILITY ─────────────────────────────────────────────── */
.text-gold   { color: var(--gold); }
.text-green  { color: var(--green2); }
.text-red    { color: var(--red); }
.text-cyan   { color: var(--cyan); }
.text-dim    { color: #555; }
.strike      { text-decoration: line-through; }
.no-suicide  { color: var(--red); font-style: italic; }

/* Responsive */
@media (max-width: 900px) {
  #main-layout, .inner-main { grid-template-columns: 1fr; }
  #sidebar { position: static; }
  .inner-content { padding-right: 0; }
  #content { padding-right: 0; }
}
