/* CSS Variables for theme colors */
:root {
  --bg-color: #ffffff;
  --text-color: #333333;
  --border-color: #ddd;
  --light-border-color: #eee;
}

[data-theme="dark"] {
  --bg-color: #1a1a1a;
  --text-color: #e0e0e0;
  --border-color: #444;
  --light-border-color: #333;
  --link-color: #66b3ff;
  --visited-color: #cc99ff;
}

body {
  font-family: 'Fira Mono', 'Consolas', 'Menlo', 'Monaco', 'Liberation Mono', 'Courier New', monospace;
  background-color: var(--bg-color);
  color: var(--text-color);
  transition: background-color 0.3s ease, color 0.3s ease;
  margin: 0;
  padding: 1rem;
  /* line-height: 1.6; */
}

/* Mobile-first responsive adjustments */
@media (max-width: 768px) {
  body {
    padding: 0.5rem;
  }
  
  h1 {
    font-size: 1.8rem;
  }
  
  .badge-container {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
  
  .badge-image {
    max-width: 100%;
    height: auto;
  }
}

/* Navigation */
nav {
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.nav-left {
  display: flex;
  gap: 1rem;
}

/* Hamburger menu button - Web 1.0 style */
.hamburger {
  display: none;
  border: 2px outset #cccccc;
  background: #f0f0f0;
  color: #000000;
  font-family: 'MS Sans Serif', sans-serif;
  font-size: 11px;
  font-weight: bold;
  padding: 4px 8px;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: none;
  z-index: 1001;
}

[data-theme="dark"] .hamburger {
  border: 2px outset #888888;
  background: #404040;
  color: #ffffff;
}

.hamburger:hover {
  border: 2px inset #cccccc;
}

[data-theme="dark"] .hamburger:hover {
  border: 2px inset #888888;
}

.hamburger:active {
  border: 2px inset #999999;
  background: #e0e0e0;
}

[data-theme="dark"] .hamburger:active {
  border: 2px inset #333333;
  background: #303030;
}

/* Simple text-based hamburger icon */
.hamburger::after {
  content: "MENU";
}

/* Instead of on body */
p, li, blockquote {
  line-height: 1.4;
}

/* And preserved tight spacing for code */
pre, code, .ascii-art {
  line-height: normal; /* or even 1.0 for ASCII art */
}

nav a {
  transition: none;
}

nav a:hover {
  text-decoration: underline;
}

nav a.active {
  font-weight: bold;
}

/* Custom link colors only in dark mode */
[data-theme="dark"] a {
  color: var(--link-color);
}

[data-theme="dark"] a:visited {
  color: var(--visited-color);
}


/* Theme toggle button */
.theme-toggle {
  border: 3px outset #cccccc;
  border-radius: 0;
  padding: 4px 12px;
  cursor: pointer;
  font-size: 11px;
  font-weight: bold;
  font-family: 'MS Sans Serif', sans-serif;
  transition: none;
  background: repeating-linear-gradient(
    45deg,
    #ff0000,
    #ff0000 6px,
    #ffffff 6px,
    #ffffff 12px
  );
  color: #000000;
  text-transform: uppercase;
  letter-spacing: 1px;
  /* box-shadow: 2px 2px 4px rgba(0,0,0,0.5); */
  position: relative;
}

[data-theme="dark"] .theme-toggle {
  border: 3px outset #888888;
  background: repeating-linear-gradient(
    45deg,
    #cc0000,
    #cc0000 6px,
    #eeeeee 6px,
    #eeeeee 12px
  );
  /* box-shadow: none; */
}

.theme-toggle:hover {
  border: 3px inset #cccccc;
}

[data-theme="dark"] .theme-toggle:hover {
  border: 3px inset #888888;
}

.theme-toggle:active {
  border: 3px inset #999999;
  box-shadow: inset 2px 2px 4px rgba(0,0,0,0.3);
}

.theme-toggle-text {
  background: #ffffff;
  padding: 1px 3px;
  border-radius: 1px;
  position: relative;
  z-index: 1;
  text-align: center;
  display: inline-block;
}

/* Mobile Navigation Styles */
@media (max-width: 768px) {
  nav {
    flex-wrap: wrap;
    padding-bottom: 0.5rem;
  }

  .hamburger {
    display: flex;
    order: 3;
  }

  .theme-toggle {
    order: 2;
    font-size: 10px;
    padding: 3px 8px;
  }

  .nav-left {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--bg-color);
    border: 2px inset var(--border-color);
    border-top: 1px solid var(--border-color);
    flex-direction: column;
    gap: 0;
    z-index: 1000;
    box-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    margin-top: 2px;
  }

  [data-theme="dark"] .nav-left {
    border: 2px inset #666666;
    box-shadow: 2px 2px 4px rgba(0,0,0,0.5);
  }

  .nav-left.active {
    display: flex;
  }

  .nav-left a {
    padding: 8px 12px;
    border-bottom: 1px solid var(--light-border-color);
    border-left: 1px outset #cccccc;
    border-right: 1px outset #cccccc;
    border-top: 1px outset #cccccc;
    width: calc(100% - 26px);
    text-align: left;
    display: block;
    background: #f0f0f0;
    text-decoration: none;
    font-weight: normal;
    transition: none;
  }

  [data-theme="dark"] .nav-left a {
    background: #404040;
    border-left: 1px outset #666666;
    border-right: 1px outset #666666;
    border-top: 1px outset #666666;
  }

  .nav-left a:last-child {
    border-bottom: 1px outset #cccccc;
  }

  [data-theme="dark"] .nav-left a:last-child {
    border-bottom: 1px outset #666666;
  }

  .nav-left a:hover {
    border-left: 1px inset #cccccc;
    border-right: 1px inset #cccccc;
    border-top: 1px inset #cccccc;
    background-color: #e0e0e0;
  }

  [data-theme="dark"] .nav-left a:hover {
    border-left: 1px inset #666666;
    border-right: 1px inset #666666;
    border-top: 1px inset #666666;
    background-color: #303030;
  }

  .nav-left a:active {
    border-left: 1px inset #999999;
    border-right: 1px inset #999999;
    border-top: 1px inset #999999;
    background-color: #d0d0d0;
  }

  [data-theme="dark"] .nav-left a:active {
    border-left: 1px inset #333333;
    border-right: 1px inset #333333;
    border-top: 1px inset #333333;
    background-color: #202020;
  }

  .nav-left a.active {
    font-weight: bold;
    background-color: #ffffff;
    border-left: 1px inset #999999;
    border-right: 1px inset #999999;
    border-top: 1px inset #999999;
  }

  [data-theme="dark"] .nav-left a.active {
    background-color: var(--bg-color);
    border-left: 1px inset #333333;
    border-right: 1px inset #333333;
    border-top: 1px inset #333333;
  }
}

/* Header */
h1 {
  font-size: 2.2rem;
  border-bottom: 1px solid var(--light-border-color);
  color: var(--text-color);
}

h2 {
  color: var(--text-color);
}

/* Table */
table {
  border-collapse: collapse;
}

th, td {
  border: 1px solid var(--border-color);
  padding: 8px;
  text-align: left;
  background-color: var(--bg-color);
}

th {
  font-weight: bold;
}

/* Lists */
ul {
  color: var(--text-color);
}

/* Paragraphs */
p {
  color: var(--text-color);
}
/* Web 1.0 Music Player Styles */
.music-container {
  background-color: var(--bg-color);
  border: 2px inset var(--border-color);
  padding: 20px;
  margin: 20px 0;
}

.music-list {
  list-style: none;
  padding: 0;
}

.music-item {
  display: flex;
  align-items: center;
  padding: 8px;
  border-bottom: 1px solid var(--light-border-color);
  gap: 12px;
}

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

.track-name {
  flex: 1;
  font-family: 'Fira Mono', monospace;
  color: var(--text-color);
  font-size: 14px;
}

.music-controls {
  display: flex;
  gap: 4px;
  align-items: center;
}

.retro-btn {
  border: 2px outset #cccccc;
  background: #f0f0f0;
  color: #000000;
  font-family: 'MS Sans Serif', sans-serif;
  font-size: 11px;
  font-weight: bold;
  padding: 3px 8px;
  cursor: pointer;
  transition: none;
  text-transform: uppercase;
  min-width: 45px;
}

.retro-btn:hover {
  border: 2px inset #cccccc;
}

.retro-btn:active {
  border: 2px inset #999999;
  background: #e0e0e0;
}

.retro-btn:disabled {
  border: 2px outset #dddddd;
  background: #f8f8f8;
  color: #888888;
  cursor: not-allowed;
}

[data-theme="dark"] .retro-btn {
  border: 2px outset #666666;
  background: #404040;
  color: #ffffff;
}

[data-theme="dark"] .retro-btn:hover {
  border: 2px inset #666666;
}

[data-theme="dark"] .retro-btn:active {
  border: 2px inset #333333;
  background: #303030;
}

[data-theme="dark"] .retro-btn:disabled {
  border: 2px outset #444444;
  background: #2a2a2a;
  color: #666666;
}

.play-btn {
  background: #90ee90;
  color: #000000;
}

.pause-btn {
  background: #ffb6c1;
  color: #000000;
}

.stop-btn {
  background: #ffcccb;
  color: #000000;
}

[data-theme="dark"] .play-btn {
  background: #228b22;
  color: #ffffff;
}

[data-theme="dark"] .pause-btn {
  background: #c71585;
  color: #ffffff;
}

[data-theme="dark"] .stop-btn {
  background: #8b0000;
  color: #ffffff;
}

.progress-container {
  flex: 1;
  margin-left: 12px;
  display: none;
}

.progress-container.show {
  display: block;
}

.progress-bar {
  width: 100%;
  height: 16px;
  border: 1px inset var(--border-color);
  background: var(--bg-color);
  cursor: pointer;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: repeating-linear-gradient(
    45deg,
    #0066cc,
    #0066cc 4px,
    #ffffff 4px,
    #ffffff 8px
  );
  width: 0%;
  transition: width 0.1s ease;
}

[data-theme="dark"] .progress-fill {
  background: repeating-linear-gradient(
    45deg,
    #4da6ff,
    #4da6ff 4px,
    #333333 4px,
    #333333 8px
  );
}

.time-display {
  font-size: 10px;
  color: var(--text-color);
  margin-top: 2px;
  font-family: 'Fira Mono', monospace;
}

.now-playing {
  background: repeating-linear-gradient(
    90deg,
    transparent,
    transparent 10px,
    var(--light-border-color) 10px,
    var(--light-border-color) 11px
  );
}

.player-header {
  background: var(--border-color);
  color: var(--text-color);
  padding: 8px 12px;
  border: 2px outset var(--border-color);
  margin-bottom: 12px;
  font-weight: bold;
  text-align: center;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.global-controls {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  padding: 8px;
  background: var(--light-border-color);
  border: 1px inset var(--border-color);
}

.volume-control {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.volume-slider {
  width: 80px;
  height: 16px;
  border: 1px inset var(--border-color);
  background: var(--bg-color);
  -webkit-appearance: none;
  cursor: pointer;
}

/* Webkit browsers (Chrome, Safari, Edge) */
.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 14px;
  background: #cccccc;
  border: 1px outset #cccccc;
  cursor: pointer;
}

/* Firefox */
.volume-slider::-moz-range-thumb {
  width: 12px;
  height: 14px;
  background: #cccccc;
  border: 1px outset #cccccc;
  cursor: pointer;
  border-radius: 0; /* Make it square like webkit */
}

[data-theme="dark"] .volume-slider::-webkit-slider-thumb {
  background: #666666;
  border: 1px outset #666666;
}

[data-theme="dark"] .volume-slider::-moz-range-thumb {
  background: #666666;
  border: 1px outset #666666;
}

/* Now Playing Marquee */
.now-playing-marquee {
  background: #000000;
  color: #00ff00;
  border: 2px inset var(--border-color);
  padding: 8px;
  margin: 12px 0;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  font-weight: bold;
  overflow: hidden;
  white-space: nowrap;
  position: relative;
  height: 28px;
  display: flex;
  align-items: center;
}

[data-theme="dark"] .now-playing-marquee {
  background: #001100;
  color: #00ff00;
}

.marquee-text {
  display: inline-block;
  animation: marquee 15s linear infinite;
  padding-left: 100%;
}

@keyframes marquee {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-100%, 0, 0);
  }
}

.marquee-text.paused {
  animation-play-state: paused;
}

/* Retro status indicators */
.status-indicator {
  display: inline-block;
  padding: 2px 6px;
  margin-left: 8px;
  font-size: 10px;
  font-weight: bold;
  border: 1px outset var(--border-color);
  background: #c0c0c0;
  color: #000000;
  font-family: 'MS Sans Serif', sans-serif;
}

.status-indicator.playing {
  background: #ff6b6b;
  color: #ffffff;
  animation: blink 1s infinite;
}

.status-indicator.stopped {
  background: #888888;
  color: #ffffff;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0.3; }
}

.quote-container {
  text-align: center;
  margin: 2rem 0;
}

.quote-text {
  font-style: italic;
  font-size: 1.1rem;
  color: #555;
  margin: 0 0 0.5rem 0;
  position: relative;
}

.quote-text::before,
.quote-text::after {
  content: '"';
  font-size: 1.3rem;
  color: #888;
  font-family: Georgia, serif;
}

.quote-author {
  font-size: 0.9rem;
  color: #888;
  font-style: normal;
}

.quote-author::before {
  content: "~ ";
}

.post-signature {
  margin-top: 0;
  margin-left: 0;
  text-align: left;
  transform: scale(0.75); /* Scale down to 50% */
  transform-origin: top left; /* Scale from top-left corner */
}

.signature-svg {
  max-width: 100%;
  height: auto;
  display: block;
}

:root {
  --signature-color: black;
}

/* Dark mode colors */
[data-theme="dark"] {
  --signature-color: white;
}

/* Dark mode compatibility */
[data-theme="dark"] .quote-text {
  color: #ccc;
}

[data-theme="dark"] .quote-author {
  color: #aaa;
}

[data-theme="dark"] .quote-text::before,
[data-theme="dark"] .quote-text::after {
  color: #777;
}

/* Web 1.0 Style Badge */
.badge-container {
  margin: 1rem 0;
  display: flex;
  gap: 0;
  align-items: flex-start;
}

.web1-badge {
  display: inline-block;
  border: 3px outset #c0c0c0;
  background: linear-gradient(135deg, #f0f0f0 0%, #d0d0d0 100%);
  padding: 8px;
  margin: 0;
  text-decoration: none;
  font-family: "MS Sans Serif", sans-serif;
  font-size: 11px;
  font-weight: bold;
  color: #000000;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: all 0.1s ease;
  box-shadow: 2px 2px 4px rgba(0,0,0,0.3);
  position: relative;
}

.web1-badge:hover {
  border: 3px inset #c0c0c0;
  background: linear-gradient(135deg, #d0d0d0 0%, #b0b0b0 100%);
  transform: translateY(1px);
  box-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.web1-badge:active {
  border: 3px inset #a0a0a0;
  background: #b0b0b0;
  transform: translateY(2px);
  box-shadow: none;
}

.badge-image {
  display: block;
  width: 200px;
  height: 60px;
  border: 1px solid #808080;
  object-fit: cover;
}

#leetcode-badge {
  background: #263238;
  cursor: pointer;
}

/* Dark mode adjustments for badge */
[data-theme="dark"] .web1-badge {
  border: 3px outset #606060;
  background: linear-gradient(135deg, #404040 0%, #303030 100%);
  color: #ffffff;
}

[data-theme="dark"] .web1-badge:hover {
  border: 3px inset #606060;
  background: linear-gradient(135deg, #303030 0%, #202020 100%);
}

[data-theme="dark"] .web1-badge:active {
  border: 3px inset #404040;
  background: #202020;
}

[data-theme="dark"] .badge-image {
  border: 1px solid #505050;
}

#socials ul, #contact ul {
  display: grid;
  grid-template-columns: max-content max-content;
  grid-template-rows: auto auto;
  column-gap: 50px; 
  row-gap: 10px;    
  list-style: square;
  padding-left: 40px;
}

#socials li, #contacts li {
  margin: 0;
}

/* Kanban Board Styles */
.legend {
  margin-bottom: 2rem;
  padding: 1rem;
  border: 2px solid var(--border-color);
  background-color: var(--bg-color);
  font-size: 0.9rem;
}

[data-theme="dark"] .legend {
  border: 2px solid #666;
  background-color: var(--border-color);
}

.priority-indicator {
  margin-right: 1.5rem;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.priority-square {
  width: 12px;
  height: 12px;
  display: inline-block;
  border: 1px solid #000;
}

.priority-square-high {
  background-color: #cc0000;
}

.priority-square-medium {
  background-color: #ffcc00;
}

.priority-square-low {
  background-color: #00aa00;
}

[data-theme="dark"] .priority-square {
  border: 1px solid #ccc;
}

.kanban-board {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.kanban-column {
  flex: 1;
  min-width: 280px;
  border: 2px solid #000;
  background-color: #f0f0f0;
}

[data-theme="dark"] .kanban-column {
  border: 2px solid #666;
  background-color: var(--border-color);
}

.column-header {
  background-color: #c0c0c0;
  border-bottom: 2px solid #000;
  padding: 1rem;
  font-weight: bold;
  text-align: center;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #000;
}

[data-theme="dark"] .column-header {
  background-color: #666;
  border-bottom: 2px solid #888;
  color: #fff;
}

.column-content {
  padding: 1rem;
  min-height: 400px;
  background-color: #f0f0f0;
}

[data-theme="dark"] .column-content {
  background-color: var(--border-color);
}

.kanban-card {
  background-color: #fff;
  border: 1px solid #000;
  padding: 1rem;
  margin-bottom: 1rem;
  cursor: move;
  transition: background-color 0.2s ease;
}

[data-theme="dark"] .kanban-card {
  background-color: var(--bg-color);
  border: 1px solid #666;
}

.kanban-card:hover {
  background-color: #ffffcc;
}

[data-theme="dark"] .kanban-card:hover {
  background-color: #2a2a2a;
}

.card-title {
  font-weight: bold;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.card-description {
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.card-meta {
  font-size: 0.75rem;
  color: #666;
  border-top: 1px dotted #999;
  padding-top: 0.5rem;
}

[data-theme="dark"] .card-meta {
  color: #aaa;
  border-top: 1px dotted #666;
}

.priority-high { 
  border-left: 4px solid #cc0000 !important; 
}

.priority-medium { 
  border-left: 4px solid #ffcc00 !important; 
}

.priority-low { 
  border-left: 4px solid #00aa00 !important; 
}

.last-updated {
  text-align: center;
  margin-top: 2rem;
  font-size: 0.8rem;
  opacity: 0.7;
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
}