@charset "UTF-8";
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body {
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  background: #0a0a0a;
  color: #00ff00;
  line-height: 1.4;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}
body.terminal-startup {
  background: black;
}
body.terminal-startup * {
  opacity: 0;
  animation: terminal-boot 2s ease-out forwards;
}

@keyframes terminal-boot {
  0% {
    opacity: 0;
    transform: scale(1.1);
  }
  50% {
    opacity: 0.5;
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}
.matrix-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -2;
  opacity: 0.1;
}

.app {
  min-height: 100vh;
  position: relative;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

.content-wrapper {
  position: relative;
  z-index: 10;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
  width: 100%;
  overflow-x: hidden;
}

.terminal-header {
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
  border-radius: 8px;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2);
  background: rgba(26, 26, 26, 0.9);
  padding: 2rem;
  border: 2px solid #00ff00;
}
.terminal-header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}

.ascii-art {
  margin-bottom: 1rem;
}
.ascii-art .ascii-name {
  color: #00ff00;
  font-size: 0.7rem;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
  animation: pulse-glow 3s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% {
    text-shadow: 0 0 5px #00ff00, 0 0 10px #00ff00;
  }
  50% {
    text-shadow: 0 0 20px #00ff00, 0 0 30px #00ff00, 0 0 40px #00ff00;
  }
}
.terminal-prompt {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}
.terminal-prompt .prompt-user {
  color: #00cc00;
}
.terminal-prompt .prompt-separator {
  color: #ffffff;
}
.terminal-prompt .prompt-path {
  color: #ffb000;
}
.terminal-prompt .prompt-symbol {
  color: #ffffff;
}
.terminal-prompt .cursor {
  color: #00ff00;
  animation: blink 1s infinite;
}

@keyframes blink {
  0%, 50% {
    opacity: 1;
  }
  51%, 100% {
    opacity: 0;
  }
}
.tagline .comment {
  color: #666666;
  font-style: italic;
}

.terminal-nav {
  margin-top: 1.5rem;
}
.terminal-nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 2rem;
}
.terminal-nav .nav-command {
  color: #00cc00;
  text-decoration: none;
  padding: 0.5rem 1rem;
  border: 1px solid #00cc00;
  border-radius: 4px;
  transition: all 0.3s ease;
}
.terminal-nav .nav-command:hover {
  background: #00cc00;
  color: #0a0a0a;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
  transform: translateY(-2px);
}

.terminal-section {
  margin-bottom: 4rem;
  position: relative;
  border-radius: 8px;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2);
  background: rgba(26, 26, 26, 0.8);
  border: 1px solid #008800;
  border-radius: 8px;
  overflow: hidden;
}
.terminal-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}

.section-header {
  background: #1a1a1a;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #008800;
}
.section-header .prompt {
  color: #00cc00;
  margin-right: 1rem;
}
.section-header .command {
  color: #ffb000;
}

.section-content {
  padding: 1.5rem;
}
.section-content .about-content,
.section-content .skills-content,
.section-content .projects-intro,
.section-content .contact-content {
  background: #1a1a1a;
  border: 1px solid #00ff00;
  border-radius: 4px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  line-height: 1.6;
  color: #cccccc;
}
.section-content .about-content h2,
.section-content .skills-content h2,
.section-content .projects-intro h2,
.section-content .contact-content h2 {
  color: #00ff00;
  font-size: 1.3rem;
  margin-bottom: 1rem;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
.section-content .about-content h3,
.section-content .skills-content h3,
.section-content .projects-intro h3,
.section-content .contact-content h3 {
  color: #00cc00;
  font-size: 1.1rem;
  margin: 1.5rem 0 0.75rem 0;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
.section-content .about-content p,
.section-content .skills-content p,
.section-content .projects-intro p,
.section-content .contact-content p {
  margin-bottom: 1rem;
  line-height: 1.6;
}
.section-content .about-content ul,
.section-content .skills-content ul,
.section-content .projects-intro ul,
.section-content .contact-content ul {
  list-style-type: disc;
  margin-left: 1.5rem;
  margin-bottom: 1.5rem;
}
.section-content .about-content ul li,
.section-content .skills-content ul li,
.section-content .projects-intro ul li,
.section-content .contact-content ul li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
  color: #cccccc;
}
.section-content .about-content .call-to-action,
.section-content .skills-content .call-to-action,
.section-content .projects-intro .call-to-action,
.section-content .contact-content .call-to-action {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #008800;
}
.section-content .about-content div,
.section-content .skills-content div,
.section-content .projects-intro div,
.section-content .contact-content div {
  white-space: pre-line;
  word-wrap: break-word;
  overflow-wrap: break-word;
}
.section-content .about-content div strong,
.section-content .skills-content div strong,
.section-content .projects-intro div strong,
.section-content .contact-content div strong {
  color: #00ff00;
}

.code-block {
  color: #cccccc;
  white-space: pre-wrap;
  line-height: 1.6;
}
.code-block .rust-keyword {
  color: #ff79c6;
}
.code-block .rust-string {
  color: #f1fa8c;
}
.code-block .rust-comment {
  color: #666666;
}
.code-block .rust-type {
  color: #8be9fd;
}

.file-listing {
  color: #cccccc;
  line-height: 1.8;
}
.file-listing .file-executable {
  color: #00ff00;
}
.file-listing .file-directory {
  color: #8be9fd;
}
.file-listing .file-size {
  color: #ffb000;
}

.git-log {
  color: #cccccc;
  line-height: 1.6;
}
.git-log .git-hash {
  color: #ffb000;
}
.git-log .git-branch {
  color: #00ff00;
}
.git-log .git-merge {
  color: #ff79c6;
}

.project-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.project-card {
  background: #1a1a1a;
  border: 1px solid #008800;
  border-radius: 6px;
  padding: 1.5rem;
  transition: all 0.3s ease;
}
.project-card:hover {
  border-color: #00ff00;
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 255, 0, 0.1);
}

.card-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.card-header .file-icon {
  font-size: 1.5rem;
}
.card-header .project-name {
  color: #00ff00;
  font-weight: bold;
  flex: 1;
}
.card-header .language-tag {
  color: #ffb000;
  font-size: 0.8rem;
  padding: 0.25rem 0.5rem;
  border: 1px solid #ffb000;
  border-radius: 4px;
}

.card-content p {
  color: #cccccc;
  margin-bottom: 1rem;
}

.tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tech {
  color: #00cc00;
  font-size: 0.8rem;
  padding: 0.25rem 0.5rem;
  background: rgba(0, 204, 0, 0.1);
  border-radius: 4px;
}

.contact-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: #1a1a1a;
  border: 1px solid #008800;
  border-radius: 6px;
  color: #00ff00;
  text-decoration: none;
  transition: all 0.3s ease;
}
.contact-link:hover {
  border-color: #00ff00;
  background: rgba(0, 255, 0, 0.05);
  transform: translateX(10px);
}
.contact-link .link-icon {
  font-size: 1.5rem;
}
.contact-link .link-text {
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
}

.terminal-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 600px;
  max-height: 400px;
  background: #0a0a0a;
  border: 2px solid #00ff00;
  border-radius: 8px;
  position: relative;
  border-radius: 8px;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
  z-index: 1000;
}
.terminal-container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}

.terminal-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #1a1a1a;
  padding: 0.5rem 1rem;
  border-bottom: 1px solid #008800;
}

.terminal-controls {
  display: flex;
  gap: 0.5rem;
}
.terminal-controls .control {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.terminal-controls .control.close {
  background: #ff5f56;
}
.terminal-controls .control.minimize {
  background: #ffbd2e;
}
.terminal-controls .control.maximize {
  background: #27ca3f;
}

.terminal-title {
  color: #cccccc;
  font-size: 0.9rem;
}

.terminal-content {
  height: 300px;
  overflow-y: auto;
  padding: 1rem;
}

.terminal-output {
  margin-bottom: 1rem;
}

.terminal-line {
  color: #cccccc;
  margin-bottom: 0.2rem;
}
.terminal-line:empty {
  height: 1em;
}

.terminal-input-line {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.terminal-input-line .terminal-prompt {
  color: #00cc00;
  white-space: nowrap;
}
.terminal-input-line .terminal-input {
  flex: 1;
  background: transparent;
  border: none;
  color: #00ff00;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  font-size: 1rem;
  outline: none;
}
.terminal-input-line .terminal-input::placeholder {
  color: #666666;
}
.terminal-input-line .terminal-cursor {
  color: #00ff00;
  animation: blink 1s infinite;
}

.skill-highlight {
  margin-top: 2rem;
  padding: 1rem;
  background: rgba(0, 255, 0, 0.05);
  border-left: 4px solid #00ff00;
}
.skill-highlight .comment {
  color: #666666;
  font-style: italic;
}

@media (max-width: 768px) {
  body {
    font-size: 14px;
  }
  .content-wrapper {
    padding: 0.5rem;
    max-width: 100vw;
    overflow-x: hidden;
  }
  .ascii-art .ascii-name {
    font-size: 0.3rem;
    line-height: 1.1;
  }
  .terminal-nav ul {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
  .terminal-container {
    position: static;
    width: 100%;
    margin-top: 2rem;
  }
  .project-cards {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .contact-links {
    grid-template-columns: 1fr;
  }
  #snake-game .section-header .prompt, #snake-game .section-header .command {
    font-size: 0.8rem;
    line-height: 1.2;
  }
  #snake-game .game-container {
    padding: 0.5rem;
  }
  #snake-game .game-info {
    flex-direction: column;
    gap: 0.5rem;
  }
  #snake-game .game-info .score, #snake-game .game-info .status {
    text-align: center;
    font-size: 0.9rem;
  }
  #snake-game .game-canvas {
    width: 100% !important;
    max-width: 350px !important;
    height: auto !important;
    border-width: 1px !important;
  }
  #snake-game .game-controls .controls-info h4 {
    font-size: 1rem;
  }
  #snake-game .game-controls .controls-info ul {
    font-size: 0.8rem;
    padding-left: 1rem;
  }
  #snake-game .game-controls .controls-info ul li {
    margin: 0.25rem 0;
    word-wrap: break-word;
  }
  #snake-game .game-controls .game-buttons .restart-btn {
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
  }
  #snake-game .leaderboards-always-visible {
    flex-direction: column !important;
    gap: 1rem !important;
    margin-top: 1rem !important;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel {
    min-width: auto !important;
    width: 100% !important;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel h4 {
    font-size: 1rem;
    text-align: center;
    margin-bottom: 0.5rem;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table {
    font-size: 0.8rem;
    width: 100%;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table th, #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table td {
    padding: 0.25rem 0.5rem;
    text-align: center;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table th:first-child, #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table td:first-child {
    width: 15%;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table th:nth-child(2), #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table td:nth-child(2) {
    width: 35%;
  }
  #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table th:last-child, #snake-game .leaderboards-always-visible .leaderboard-panel .leaderboard-table td:last-child {
    width: 50%;
    text-align: right;
  }
  #snake-game .initials-modal-overlay {
    padding: 1rem;
  }
  #snake-game .initials-modal-overlay .modal-content {
    width: 90%;
    max-width: 300px;
    padding: 1rem;
  }
  #snake-game .initials-modal-overlay .modal-content h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
  }
  #snake-game .initials-modal-overlay .modal-content label {
    font-size: 0.9rem;
    display: block;
    margin-bottom: 0.5rem;
  }
  #snake-game .initials-modal-overlay .modal-content input {
    width: 100%;
    font-size: 1rem;
    padding: 0.5rem;
    margin-bottom: 1rem;
  }
  #snake-game .initials-modal-overlay .modal-content button {
    width: 100%;
    font-size: 1rem;
    padding: 0.75rem;
  }
  .terminal-section {
    margin: 1rem 0;
  }
  .terminal-section .section-header {
    margin-bottom: 1rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }
  .about-content .intro-text {
    font-size: 0.9rem;
    line-height: 1.5;
  }
  .skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.75rem;
  }
  .skills-grid .skill-item {
    font-size: 0.8rem;
    padding: 0.5rem;
  }
  .project-card .project-title {
    font-size: 1.1rem;
  }
  .project-card .project-description {
    font-size: 0.85rem;
    line-height: 1.4;
  }
  .project-card .tech-stack {
    font-size: 0.75rem;
  }
  .project-card .tech-stack .tech-item {
    padding: 0.2rem 0.4rem;
    margin: 0.1rem;
  }
  .project-card .project-links {
    gap: 0.5rem;
  }
  .project-card .project-links .project-link {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
  }
  .terminal-container .terminal-header .terminal-title {
    font-size: 0.8rem;
  }
  .terminal-container .terminal-body {
    font-size: 0.8rem;
  }
  .terminal-container .terminal-body .command-line {
    flex-wrap: wrap;
  }
  .terminal-container .terminal-body .command-line .prompt {
    word-break: break-all;
  }
}
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #0a0a0a;
}

::-webkit-scrollbar-thumb {
  background: #008800;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #00cc00;
}

#snake-game {
  position: relative;
  z-index: 5;
}
#snake-game .game-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  position: relative;
  z-index: 5;
}
#snake-game .game-info {
  display: flex;
  justify-content: space-between;
  width: 600px;
  max-width: 100%;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  font-size: 1.1rem;
}
#snake-game .game-info .score .label {
  color: #cccccc;
}
#snake-game .game-info .score .value {
  color: #00ff00;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#snake-game .game-info .status .playing {
  color: #00ff00;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#snake-game .game-info .status .paused {
  color: #ffb000;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#snake-game .game-info .status .game-over {
  color: #ff0000;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#snake-game .game-canvas {
  position: relative;
  border-radius: 8px;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2);
  border: 2px solid #00ff00;
  background: #0a0a0a;
  max-width: 100%;
  height: auto;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
  position: relative;
  z-index: 10;
}
#snake-game .game-canvas::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}
#snake-game .game-canvas:focus {
  outline: none;
  border-color: #ffb000;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2), 0 0 20px rgba(255, 176, 0, 0.5);
}
#snake-game .game-canvas:hover {
  border-color: #33ff33;
}
#snake-game .game-controls {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  width: 600px;
  max-width: 100%;
}
#snake-game .game-controls .controls-info {
  flex: 1;
}
#snake-game .game-controls .controls-info h4 {
  color: #00ff00;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#snake-game .game-controls .controls-info ul {
  list-style: none;
}
#snake-game .game-controls .controls-info ul li {
  color: #cccccc;
  margin-bottom: 0.3rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  font-size: 0.9rem;
}
#snake-game .game-controls .controls-info ul li::before {
  content: "> ";
  color: #00ff00;
}
#snake-game .game-controls .restart-btn {
  background: transparent;
  border: 2px solid #00ff00;
  color: #00ff00;
  padding: 0.5rem 1rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  cursor: pointer;
  transition: all 0.3s ease;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#snake-game .game-controls .restart-btn:hover {
  background: #00ff00;
  color: #0a0a0a;
  box-shadow: 0 0 20px #00ff00;
}

.mobile-controls {
  display: none;
  margin: 1.5rem 0;
  padding: 1rem;
  background: rgba(0, 255, 0, 0.05);
  border: 1px solid #008800;
  border-radius: 8px;
}
.mobile-controls .mobile-control-grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  max-width: 200px;
  margin: 0 auto;
}
.mobile-controls .mobile-control-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  justify-content: center;
}
.mobile-controls .mobile-control-btn {
  width: 60px;
  height: 60px;
  background: #0a0a0a;
  border: 2px solid #00ff00;
  border-radius: 8px;
  color: #00ff00;
  font-size: 1.5rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: center;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
.mobile-controls .mobile-control-btn:hover, .mobile-controls .mobile-control-btn:active {
  background: rgba(0, 255, 0, 0.1);
  border-color: #00cc00;
  transform: scale(0.95);
  box-shadow: 0 0 10px #00ff00, inset 0 0 20px rgba(0, 255, 0, 0.1);
}
.mobile-controls .mobile-control-btn:active {
  transform: scale(0.9);
  background: rgba(0, 255, 0, 0.2);
}
.mobile-controls .pause-btn {
  background: rgba(255, 176, 0, 0.1);
  border-color: #ffb000;
  color: #ffb000;
}
.mobile-controls .pause-btn:hover, .mobile-controls .pause-btn:active {
  background: rgba(255, 176, 0, 0.2);
  border-color: rgb(255, 191.8, 51);
  box-shadow: 0 0 10px #ffb000, inset 0 0 20px rgba(255, 176, 0, 0.1);
}

@media (max-width: 768px) {
  .mobile-controls {
    display: block;
  }
  #snake-game .game-controls {
    margin-bottom: 1rem;
  }
  #snake-game .game-controls .controls-info ul {
    font-size: 0.7rem;
  }
  #snake-game .game-controls .controls-info ul li {
    margin: 0.2rem 0;
  }
}
@media (max-width: 480px) {
  .mobile-controls {
    margin: 1rem 0;
    padding: 0.75rem;
  }
  .mobile-controls .mobile-control-btn {
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
  }
  .mobile-controls .mobile-control-grid {
    max-width: 170px;
    gap: 0.4rem;
  }
  .mobile-controls .mobile-control-row {
    gap: 0.4rem;
  }
}
#leaderboard .leaderboard-container {
  max-width: 600px;
  margin: 0 auto;
}
#leaderboard .leaderboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}
#leaderboard .leaderboard-header .leaderboard-title {
  color: #00ff00;
  font-size: 1.5rem;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .leaderboard-header .mode-toggle {
  display: flex;
  gap: 0.5rem;
}
#leaderboard .leaderboard-header .mode-toggle .mode-btn {
  background: transparent;
  border: 2px solid #008800;
  color: #cccccc;
  padding: 0.4rem 0.8rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
}
#leaderboard .leaderboard-header .mode-toggle .mode-btn.active {
  border-color: #00ff00;
  color: #00ff00;
  background: rgba(0, 255, 0, 0.1);
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .leaderboard-header .mode-toggle .mode-btn:disabled {
  cursor: default;
}
#leaderboard .leaderboard-header .mode-toggle .mode-btn:not(:disabled):hover {
  border-color: #00cc00;
  color: #00cc00;
}
#leaderboard .loading {
  text-align: center;
  color: #ffb000;
  padding: 2rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .no-scores {
  text-align: center;
  color: #cccccc;
  padding: 2rem;
}
#leaderboard .no-scores p {
  margin-bottom: 0.5rem;
}
#leaderboard .scores-list .scores-header {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: 1rem;
  padding: 0.5rem;
  margin-bottom: 0.5rem;
  border-bottom: 2px solid #008800;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  font-weight: bold;
  color: #ffb000;
  font-size: 0.9rem;
}
#leaderboard .scores-list .scores-header .rank-header,
#leaderboard .scores-list .scores-header .name-header,
#leaderboard .scores-list .scores-header .score-header,
#leaderboard .scores-list .scores-header .date-header {
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .scores-list .scores-header .score-header,
#leaderboard .scores-list .scores-header .date-header {
  text-align: right;
}
#leaderboard .scores-list .score-entry {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: 1rem;
  padding: 0.5rem;
  margin-bottom: 0.3rem;
  border-left: 3px solid transparent;
  transition: all 0.3s ease;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
}
#leaderboard .scores-list .score-entry.top-three {
  border-left-color: #00ff00;
  background: rgba(0, 255, 0, 0.05);
}
#leaderboard .scores-list .score-entry:hover {
  background: rgba(0, 255, 0, 0.1);
}
#leaderboard .scores-list .score-entry .rank {
  color: #ffb000;
  font-weight: bold;
  min-width: 3rem;
}
#leaderboard .scores-list .score-entry .name {
  color: #00ff00;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .scores-list .score-entry .score {
  color: #ffffff;
  font-weight: bold;
  text-align: right;
}
#leaderboard .scores-list .score-entry .date {
  color: #cccccc;
  font-size: 0.9rem;
  text-align: right;
}
#leaderboard .score-form {
  background: rgba(0, 255, 0, 0.1);
  border: 2px solid #00ff00;
  padding: 1.5rem;
  margin: 1rem 0;
  text-align: center;
  position: relative;
  border-radius: 8px;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2);
}
#leaderboard .score-form::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}
#leaderboard .score-form h4 {
  color: #00ff00;
  margin-bottom: 1rem;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .score-form p {
  color: #ffffff;
  margin-bottom: 1rem;
}
#leaderboard .score-form .form-group {
  margin-bottom: 1rem;
  text-align: left;
}
#leaderboard .score-form .form-group label {
  display: block;
  color: #cccccc;
  margin-bottom: 0.5rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
}
#leaderboard .score-form .form-group .name-input {
  background: #0a0a0a;
  border: 2px solid #008800;
  color: #00ff00;
  padding: 0.5rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  font-size: 1rem;
  width: 200px;
  max-width: 100%;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .score-form .form-group .name-input:focus {
  outline: none;
  border-color: #00ff00;
  box-shadow: 0 0 10px #00ff00;
}
#leaderboard .score-form .form-group .checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  margin-bottom: 0.5rem;
}
#leaderboard .score-form .form-group .checkbox-label .global-checkbox {
  appearance: none;
  width: 16px;
  height: 16px;
  border: 2px solid #008800;
  background: #0a0a0a;
  cursor: pointer;
  position: relative;
}
#leaderboard .score-form .form-group .checkbox-label .global-checkbox:checked {
  border-color: #00ff00;
  background: #00ff00;
}
#leaderboard .score-form .form-group .checkbox-label .global-checkbox:checked::after {
  content: "✓";
  position: absolute;
  top: -2px;
  left: 2px;
  color: #0a0a0a;
  font-size: 12px;
  font-weight: bold;
}
#leaderboard .score-form .form-group .checkbox-label .global-checkbox:focus {
  outline: none;
  box-shadow: 0 0 5px #00ff00;
}
#leaderboard .score-form .form-group .checkbox-label .checkbox-text {
  color: #00ff00;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .score-form .form-group .checkbox-help {
  font-size: 0.8rem;
  color: #cccccc;
  font-style: italic;
  margin-left: 1.5rem;
}
#leaderboard .score-form .form-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
}
#leaderboard .score-form .form-buttons button {
  background: transparent;
  border: 2px solid;
  padding: 0.5rem 1rem;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  cursor: pointer;
  transition: all 0.3s ease;
}
#leaderboard .score-form .form-buttons button.submit-btn {
  border-color: #00ff00;
  color: #00ff00;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
#leaderboard .score-form .form-buttons button.submit-btn:hover {
  background: #00ff00;
  color: #0a0a0a;
  box-shadow: 0 0 20px #00ff00;
}
#leaderboard .score-form .form-buttons button.cancel-btn {
  border-color: #ff0000;
  color: #ff0000;
}
#leaderboard .score-form .form-buttons button.cancel-btn:hover {
  background: #ff0000;
  color: #ffffff;
}
#leaderboard .leaderboard-info {
  text-align: center;
  margin-top: 2rem;
  color: #cccccc;
  font-style: italic;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
}
#leaderboard .leaderboard-info p {
  margin-bottom: 0.3rem;
  font-size: 0.9rem;
}
#leaderboard .leaderboard-info p:first-child {
  color: #ffb000;
}
#leaderboard .leaderboard-info p:nth-child(2) {
  color: #00cc00;
}
@media (max-width: 768px) {
  #leaderboard .leaderboard-header {
    flex-direction: column;
    text-align: center;
  }
  #leaderboard .scores-list .scores-header,
  #leaderboard .scores-list .score-entry {
    grid-template-columns: auto 1fr auto;
  }
  #leaderboard .scores-list .scores-header .date,
  #leaderboard .scores-list .scores-header .date-header,
  #leaderboard .scores-list .score-entry .date,
  #leaderboard .scores-list .score-entry .date-header {
    display: none;
  }
}

.counter-display {
  position: relative;
  border-radius: 8px;
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.2);
  background: #0a0a0a;
  border: 2px solid #00ff00;
  padding: 1rem;
  margin: 1rem 0;
  font-family: "Fira Code", "JetBrains Mono", "Courier New", monospace;
  text-align: center;
  position: relative;
}
.counter-display::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}
.counter-display .counter-label {
  color: #ffb000;
  font-size: 0.9rem;
  font-weight: bold;
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
.counter-display .counter-value {
  color: #00ff00;
  font-size: 2rem;
  font-weight: bold;
  letter-spacing: 3px;
  text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor;
}
.counter-display .counter-value .loading {
  color: #00cc00;
  animation: pulse 1.5s infinite;
}
.counter-display .counter-value .number {
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 5px #00ff00, 0 0 10px #00ff00, 0 0 20px #00ff00;
}
.counter-display::before {
  content: "╔═══════════════════════════════════╗";
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  color: #00ff00;
  font-size: 0.8rem;
  white-space: nowrap;
  z-index: 2;
}
.counter-display::after {
  content: "╚═══════════════════════════════════╝";
  position: absolute;
  bottom: -1px;
  left: 50%;
  transform: translateX(-50%);
  color: #00ff00;
  font-size: 0.8rem;
  white-space: nowrap;
  z-index: 2;
}

.site-counter {
  margin: 2rem auto;
  max-width: 600px;
}
.site-counter .counter-display {
  background: linear-gradient(135deg, #0a0a0a 0%, #0f0f0f 100%);
  box-shadow: inset 0 0 100px rgba(0, 255, 0, 0.1), 0 0 50px rgba(0, 255, 0, 0.3), 0 10px 30px rgba(0, 0, 0, 0.5);
}

.game-counter {
  margin: 1rem 0;
}
.game-counter .counter-display {
  background: linear-gradient(135deg, #0a0a0a 0%, #001100 100%);
  border-color: #00cc00;
}
.game-counter .counter-display .counter-label {
  color: #00cc00;
}
.game-counter .counter-display .counter-value .number {
  color: #00cc00;
  text-shadow: 0 0 5px #00cc00, 0 0 10px #00cc00, 0 0 20px #00cc00;
}
.game-counter .counter-display::before, .game-counter .counter-display::after {
  color: #00cc00;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
@media (max-width: 768px) {
  .counter-display {
    padding: 0.5rem;
    margin: 0.5rem 0;
    border-width: 1px;
  }
  .counter-display .counter-label {
    font-size: 0.7rem;
    letter-spacing: 1px;
    line-height: 1.2;
  }
  .counter-display .counter-value {
    font-size: 1.2rem;
    letter-spacing: 1px;
  }
  .counter-display::before, .counter-display::after {
    font-size: 0.5rem;
    display: none;
  }
  .site-counter {
    margin: 1rem auto;
    padding: 0 0.5rem;
  }
  .game-counter {
    margin: 0.5rem 0;
  }
}
@media (max-width: 480px) {
  .content-wrapper {
    padding: 0.25rem;
  }
  #snake-game .game-canvas {
    max-width: 280px !important;
  }
  #snake-game .leaderboards-always-visible .leaderboard-table {
    font-size: 0.7rem;
  }
  #snake-game .leaderboards-always-visible .leaderboard-table th, #snake-game .leaderboards-always-visible .leaderboard-table td {
    padding: 0.2rem 0.3rem;
  }
  #snake-game .initials-modal-overlay .modal-content {
    width: 95%;
    padding: 0.75rem;
  }
  .ascii-art .ascii-name {
    font-size: 0.25rem;
    line-height: 1;
  }
  .counter-display .counter-label {
    font-size: 0.6rem;
  }
  .counter-display .counter-value {
    font-size: 1rem;
  }
}
