

@import url('https://fonts.googleapis.com/css2?family=VT323&family=Special+Elite&family=Permanent+Marker&family=Courier+Prime&family=Rock+Salt&family=Creepster&family=Press+Start+2P&display=swap');

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

:root {
  --blood-red: #8b1a1a;
  --dark-maroon: #4a0e0e;
  --gutter-black: #0d0d0d;
  --grime-gray: #1a1a1a;
  --paper-dirty: #d4c5a9;
  --paper-white: #e8e0d0;
  --tape-yellow: #c9b458;
  --safety-pin: #9a9a9a;
  --punk-pink: #c4385a;
  --stamp-red: #a02020;
  --ink-black: #111;
  --scrawl-white: #f0ece4;
  --highlight-red: #ff3333;
}

/* Scanline overlay on body */
body {
  background-color: var(--gutter-black);
  background-image:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 2px,
      rgba(0,0,0,0.15) 2px,
      rgba(0,0,0,0.15) 4px
    ),
    radial-gradient(ellipse at 20% 50%, #1a0a0a 0%, #0d0d0d 70%);
  color: var(--paper-dirty);
  font-family: 'Courier Prime', 'Courier New', monospace;
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  cursor: crosshair;
  overflow-x: hidden;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 12px;
}
::-webkit-scrollbar-track {
  background: var(--grime-gray);
  border-left: 2px solid var(--blood-red);
}
::-webkit-scrollbar-thumb {
  background: var(--blood-red);
  border: 2px solid var(--gutter-black);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--punk-pink);
}

/* Page Wrapper */
.page-wrapper {
  max-width: 850px;
  margin: 0 auto;
  padding: 10px;
}

/* Header / Logo */
.site-header {
  text-align: center;
  padding: 20px 0 10px;
  border-bottom: 3px dashed var(--blood-red);
  position: relative;
}

.site-header::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  right: 0;
  height: 3px;
  border-bottom: 1px dashed var(--safety-pin);
}

.logo-img {
  max-width: 500px;
  width: 90%;
  height: auto;
  image-rendering: auto;
  filter: drop-shadow(2px 2px 0px var(--blood-red)) drop-shadow(-1px -1px 0px rgba(0,0,0,0.8));
  transition: transform 0.3s ease;
}

.logo-img:hover {
  transform: rotate(-2deg) scale(1.03);
}

/* Marquee Banner */
.marquee-banner {
  background: var(--blood-red);
  color: var(--scrawl-white);
  font-family: 'VT323', monospace;
  font-size: 18px;
  padding: 6px 0;
  border: 2px solid var(--dark-maroon);
  margin: 10px 0;
  overflow: hidden;
  white-space: nowrap;
}

.marquee-inner {
  display: inline-block;
  animation: marquee-scroll 20s linear infinite;
}

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

/* Navigation */
.nav-bar {
  display: flex;
  justify-content: center;
  gap: 0;
  margin: 15px 0;
  flex-wrap: wrap;
  border: 2px solid var(--blood-red);
  background: linear-gradient(180deg, #2a1010 0%, #1a0808 100%);
}

.nav-bar a {
  color: var(--paper-dirty);
  text-decoration: none;
  font-family: 'Press Start 2P', monospace;
  font-size: 11px;
  padding: 12px 18px;
  border-right: 1px solid var(--blood-red);
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
}

.nav-bar a:last-child {
  border-right: none;
}

.nav-bar a:hover,
.nav-bar a.active {
  background: var(--blood-red);
  color: var(--scrawl-white);
  text-shadow: 0 0 8px rgba(255,50,50,0.6);
}

.nav-bar a.active::after {
  content: '◄';
  margin-left: 6px;
  animation: blink 1s step-end infinite;
}

/* Ransom Note Headings */
.ransom-heading {
  font-size: 0;
  line-height: 1.2;
  margin: 20px 0 15px;
  text-align: center;
}

.ransom-heading span {
  display: inline-block;
  font-size: 24px;
  padding: 4px 6px;
  margin: 2px;
  position: relative;
}

.ransom-heading .r-dark {
  background: var(--dark-maroon);
  color: var(--scrawl-white);
  font-family: 'Permanent Marker', cursive;
  transform: rotate(-3deg);
}

.ransom-heading .r-light {
  background: var(--paper-dirty);
  color: var(--ink-black);
  font-family: 'Special Elite', serif;
  transform: rotate(2deg);
}

.ransom-heading .r-red {
  background: var(--blood-red);
  color: var(--scrawl-white);
  font-family: 'Rock Salt', cursive;
  font-size: 20px;
  transform: rotate(-1deg);
}

.ransom-heading .r-black {
  background: var(--ink-black);
  color: var(--highlight-red);
  font-family: 'Creepster', system-ui;
  transform: rotate(3deg);
  border: 1px solid var(--blood-red);
}

.ransom-heading .r-stamp {
  background: transparent;
  color: var(--stamp-red);
  font-family: 'Permanent Marker', cursive;
  border: 2px solid var(--stamp-red);
  transform: rotate(-4deg);
}

/* Content Boxes */
.content-box {
  border: 2px solid var(--blood-red);
  background: linear-gradient(135deg, rgba(20,8,8,0.95) 0%, rgba(13,13,13,0.98) 100%);
  margin: 15px 0;
  padding: 0;
  position: relative;
}

.content-box::before {
  content: '';
  position: absolute;
  top: -3px;
  left: 20px;
  width: 60px;
  height: 18px;
  background: var(--tape-yellow);
  opacity: 0.7;
  transform: rotate(-2deg);
  z-index: 2;
}

.box-title {
  background: var(--blood-red);
  color: var(--scrawl-white);
  font-family: 'VT323', monospace;
  font-size: 20px;
  padding: 8px 15px;
  border-bottom: 2px solid var(--dark-maroon);
  text-transform: uppercase;
  letter-spacing: 3px;
}

.box-content {
  padding: 15px;
}

/* Two Column Old-Web Layout */
.old-web-columns {
  display: flex;
  gap: 15px;
  margin: 15px 0;
}

.sidebar-col {
  width: 220px;
  flex-shrink: 0;
}

.main-col {
  flex: 1;
  min-width: 0;
}

/* Sidebar Widgets */
.widget {
  border: 2px solid var(--blood-red);
  margin-bottom: 15px;
  background: var(--grime-gray);
}

.widget-title {
  background: linear-gradient(90deg, var(--dark-maroon), var(--blood-red));
  color: var(--scrawl-white);
  font-family: 'VT323', monospace;
  font-size: 16px;
  padding: 6px 10px;
  text-transform: uppercase;
  letter-spacing: 2px;
  border-bottom: 1px solid var(--blood-red);
}

.widget-body {
  padding: 10px;
  font-size: 13px;
}

/* About Section */
.about-text {
  font-family: 'Courier Prime', monospace;
  line-height: 1.7;
}

.about-text p {
  margin-bottom: 12px;
  text-indent: 20px;
}

.about-text .highlight {
  color: var(--highlight-red);
  font-weight: bold;
  text-shadow: 0 0 6px rgba(255,50,50,0.3);
}

/* Music List */
.music-list {
  list-style: none;
  padding: 0;
}

.music-list li {
  padding: 8px 10px;
  border-bottom: 1px dashed rgba(139,26,26,0.4);
  font-family: 'Special Elite', serif;
  font-size: 14px;
  position: relative;
  padding-left: 25px;
  transition: all 0.2s ease;
}

.music-list li::before {
  content: '♫';
  position: absolute;
  left: 5px;
  color: var(--blood-red);
}

.music-list li:hover {
  background: rgba(139,26,26,0.15);
  padding-left: 30px;
  color: var(--highlight-red);
}

.music-list li:last-child {
  border-bottom: none;
}

.music-genre {
  color: var(--safety-pin);
  font-family: 'VT323', monospace;
  font-size: 12px;
  margin-left: 8px;
}

/* Interests / Links List */
.interests-list {
  list-style: none;
  padding: 0;
}

.interests-list li {
  padding: 5px 0;
  font-size: 14px;
}

.interests-list li::before {
  content: '★ ';
  color: var(--blood-red);
}

/* Visitor Counter */
.visitor-counter {
  text-align: center;
  padding: 8px;
  font-family: 'VT323', monospace;
  font-size: 14px;
  color: var(--safety-pin);
}

.counter-display {
  display: inline-block;
  background: #000;
  border: 2px inset #444;
  padding: 4px 12px;
  font-size: 22px;
  color: #0f0;
  font-family: 'VT323', monospace;
  letter-spacing: 4px;
  margin-top: 4px;
  text-shadow: 0 0 8px rgba(0,255,0,0.5);
}

/* Status / Now Playing */
.status-box {
  font-family: 'VT323', monospace;
}

.status-line {
  padding: 4px 0;
  font-size: 14px;
}

.status-label {
  color: var(--blood-red);
  font-weight: bold;
}

/* Blinking Text */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.blink {
  animation: blink 1s step-end infinite;
}

/* Under Construction */
.under-construction {
  text-align: center;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  color: var(--tape-yellow);
  padding: 10px;
  border: 1px dashed var(--tape-yellow);
  margin: 10px 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 10px,
    rgba(201,180,88,0.08) 10px,
    rgba(201,180,88,0.08) 20px
  );
}

/* Anti-ICE Banner */
.anti-ice-banner {
  text-align: center;
  margin: 8px 0 0;
  overflow: hidden;
  border: 2px solid var(--blood-red);
  background: var(--ink-black);
}

.anti-ice-img {
  display: block;
  width: 100%;
  height: auto;
  image-rendering: auto;
  filter: contrast(1.1);
  transition: filter 0.3s ease;
}

.anti-ice-img:hover {
  filter: contrast(1.3) brightness(1.1);
}

/* Section Dividers */
.section-divider {
  margin: 20px 0;
  position: relative;
  text-align: center;
  min-height: 4px;
}

/* Fallback: generic CSS divider (applied by default, hidden when image loads) */
.section-divider.fallback {
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--blood-red), var(--dark-maroon), var(--blood-red), transparent);
}

.section-divider.fallback::after {
  content: '✦';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--gutter-black);
  padding: 0 10px;
  color: var(--blood-red);
  font-size: 14px;
}

/* Image divider mode */
.section-divider img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 80px;
  object-fit: contain;
  image-rendering: auto;
  filter: saturate(0.9);
  transition: filter 0.3s ease;
}

.section-divider img:hover {
  filter: saturate(1.2) brightness(1.1);
}

/* Legacy punk-divider (still usable) */
.punk-divider {
  border: none;
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--blood-red), var(--dark-maroon), var(--blood-red), transparent);
  margin: 20px 0;
  position: relative;
}

.punk-divider::after {
  content: '✦';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--gutter-black);
  padding: 0 10px;
  color: var(--blood-red);
  font-size: 14px;
}

/* Webring */
.webring {
  text-align: center;
  border: 2px double var(--blood-red);
  padding: 10px;
  margin: 15px 0;
  font-family: 'VT323', monospace;
  font-size: 16px;
  background: rgba(74,14,14,0.15);
}

.webring a {
  color: var(--highlight-red);
  text-decoration: underline;
  margin: 0 8px;
}

.webring a:hover {
  color: var(--scrawl-white);
  text-shadow: 0 0 8px var(--highlight-red);
}

/* Footer */
.site-footer {
  text-align: center;
  padding: 15px;
  margin-top: 20px;
  border-top: 3px dashed var(--blood-red);
  font-family: 'VT323', monospace;
  font-size: 14px;
  color: var(--safety-pin);
}

.site-footer a {
  color: var(--punk-pink);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
  text-shadow: 0 0 6px var(--punk-pink);
}

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

.badge-img {
  display: block;
  height: 31px;
  width: auto;
  image-rendering: pixelated;
  border: 1px solid var(--blood-red);
  transition: all 0.2s ease;
  filter: saturate(0.85);
}

.badge-img:hover {
  filter: saturate(1.2) brightness(1.15);
  transform: scale(1.08);
  box-shadow: 0 0 10px rgba(139,26,26,0.6);
  border-color: var(--highlight-red);
}

.footer-banners {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.banner-img {
  display: block;
  max-width: 300px;
  width: 100%;
  height: auto;
  image-rendering: auto;
  border: 2px solid var(--blood-red);
  transition: all 0.2s ease;
}

.banner-img:hover {
  border-color: var(--highlight-red);
  box-shadow: 0 0 12px rgba(139,26,26,0.5);
}

/* Art Portfolio Page */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 15px;
  padding: 15px;
}

.gallery-item {
  border: 3px solid var(--blood-red);
  background: var(--grime-gray);
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  cursor: pointer;
}

.gallery-item:hover {
  transform: rotate(-1deg) scale(1.02);
  box-shadow: 0 0 20px rgba(139,26,26,0.5), 0 0 40px rgba(139,26,26,0.2);
  z-index: 10;
}

.gallery-item::before {
  content: '';
  position: absolute;
  top: -3px;
  right: 15px;
  width: 40px;
  height: 16px;
  background: var(--tape-yellow);
  opacity: 0.6;
  transform: rotate(3deg);
  z-index: 3;
}

.gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  filter: contrast(1.05) saturate(0.9);
  transition: filter 0.3s ease;
}

.gallery-item:hover img {
  filter: contrast(1.1) saturate(1.1);
}

.gallery-caption {
  padding: 8px 10px;
  font-family: 'Special Elite', serif;
  font-size: 13px;
  border-top: 2px solid var(--blood-red);
  background: var(--ink-black);
}

.gallery-caption .art-title {
  color: var(--paper-dirty);
  display: block;
}

.gallery-caption .art-date {
  color: var(--safety-pin);
  font-size: 11px;
  font-family: 'VT323', monospace;
}

/* Lightbox */
.lightbox-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.92);
  z-index: 1000;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.lightbox-overlay.active {
  display: flex;
  animation: fadeIn 0.3s ease;
}

.lightbox-content {
  max-width: 90vw;
  max-height: 85vh;
  border: 4px solid var(--blood-red);
  box-shadow: 0 0 60px rgba(139,26,26,0.4);
}

.lightbox-content img {
  max-width: 100%;
  max-height: 85vh;
  display: block;
}

.lightbox-close {
  position: fixed;
  top: 20px;
  right: 30px;
  color: var(--scrawl-white);
  font-size: 40px;
  font-family: 'Permanent Marker', cursive;
  cursor: pointer;
  z-index: 1001;
  text-shadow: 0 0 10px var(--blood-red);
  transition: all 0.2s ease;
}

.lightbox-close:hover {
  color: var(--highlight-red);
  transform: rotate(15deg) scale(1.2);
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes glitch-skew {
  0%    { transform: skew(0deg); }
  20%   { transform: skew(-2deg); }
  40%   { transform: skew(1deg); }
  60%   { transform: skew(-1deg); }
  80%   { transform: skew(2deg); }
  100%  { transform: skew(0deg); }
}

.glitch-hover:hover {
  animation: glitch-skew 0.3s ease;
}

/* Sparkle Cursor Trail Effect */
.sparkle {
  position: fixed;
  pointer-events: none;
  font-size: 14px;
  z-index: 9999;
  animation: sparkle-fade 0.8s ease-out forwards;
  color: var(--blood-red);
  text-shadow: 0 0 4px var(--highlight-red);
}

@keyframes sparkle-fade {
  0%   { opacity: 1; transform: scale(1) translateY(0); }
  100% { opacity: 0; transform: scale(0.3) translateY(-30px); }
}

/* Responsive */
@media (max-width: 700px) {
  .old-web-columns {
    flex-direction: column;
  }
  .sidebar-col {
    width: 100%;
  }
  .nav-bar a {
    font-size: 9px;
    padding: 10px 12px;
  }
  .ransom-heading span {
    font-size: 18px;
  }
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
}

/* Link Styles */
a {
  color: var(--highlight-red);
  text-decoration: underline;
  text-decoration-style: wavy;
  text-underline-offset: 3px;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--scrawl-white);
  text-shadow: 0 0 8px rgba(255,50,50,0.5);
}

/* ==================
   REDUCED MOTION
   ================== */
.motion-toggle {
  position: fixed;
  top: 10px;
  right: 10px;
  background: var(--gutter-black);
  color: var(--safety-pin);
  border: 1px solid var(--blood-red);
  font-family: 'VT323', monospace;
  font-size: 14px;
  padding: 4px 8px;
  cursor: pointer;
  z-index: 10000;
  transition: all 0.2s ease;
}

.motion-toggle:hover {
  color: var(--scrawl-white);
  border-color: var(--highlight-red);
  box-shadow: 0 0 8px rgba(139,26,26,0.5);
}

body.reduced-motion *, body.reduced-motion *::before, body.reduced-motion *::after {
  animation: none !important;
  transition: none !important;
}

body.reduced-motion .marquee-inner {
  animation: none !important;
  white-space: normal;
  display: block;
}

body.reduced-motion .marquee-banner {
  white-space: normal;
}


/* --- Misc Old Web Flavor --- */
.best-viewed {
  text-align: center;
  font-family: 'VT323', monospace;
  font-size: 13px;
  color: var(--safety-pin);
  margin: 8px 0;
}

.ascii-border {
  font-family: 'Courier Prime', monospace;
  font-size: 11px;
  color: var(--blood-red);
  text-align: center;
  letter-spacing: 2px;
  overflow: hidden;
  user-select: none;
}

/* --- Tape decoration variants --- */
.tape-left::after {
  content: '';
  position: absolute;
  bottom: -3px;
  right: 30px;
  width: 50px;
  height: 16px;
  background: var(--tape-yellow);
  opacity: 0.5;
  transform: rotate(5deg);
}

/* --- Stamps --- */
.stamp {
  display: inline-block;
  border: 3px double var(--stamp-red);
  color: var(--stamp-red);
  font-family: 'Permanent Marker', cursive;
  padding: 5px 15px;
  transform: rotate(-8deg);
  opacity: 0.8;
  font-size: 16px;
  margin: 10px;
}

/* ==================
   BADGES PAGE
   ================== */

.badge-wall {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  padding: 10px;
}

.badge-wall a {
  display: inline-block;
  text-decoration: none;
  line-height: 0;
}

.badge-wall .badge-img {
  height: 31px;
  width: auto;
  image-rendering: pixelated;
  border: 1px solid var(--blood-red);
  transition: all 0.2s ease;
  filter: saturate(0.85);
}

.badge-wall .badge-img:hover {
  filter: saturate(1.2) brightness(1.15);
  transform: scale(1.15);
  box-shadow: 0 0 12px rgba(139,26,26,0.7);
  border-color: var(--highlight-red);
  z-index: 5;
  position: relative;
}

.badge-code {
  display: inline-block;
  background: var(--gutter-black);
  border: 1px solid var(--blood-red);
  color: var(--paper-dirty);
  font-family: 'Courier Prime', monospace;
  font-size: 12px;
  padding: 8px 14px;
  word-break: break-all;
  max-width: 100%;
  user-select: all;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.badge-code:hover {
  border-color: var(--highlight-red);
  box-shadow: 0 0 8px rgba(139,26,26,0.4);
}
