:root {
  --bg: #000;
  --text: #33ff99;
  --border: #33ff99;
  --glow: rgba(51, 255, 153, 0.3);

  --scrollbar-bg: #000;
  --scrollbar-thumb: #33ff99;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  font-family: 'VT323', monospace;
  color: var(--text);
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.crt {
  position: relative;
  width: 95%;
  max-width: 960px;
  height: 90vh;
  padding: 25px;
  background: var(--bg);
  border-radius: 12px;
  box-shadow: 0 0 40px var(--glow);
  overflow: hidden;
}

/* Scanlines */
.crt::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,0.03),
    rgba(255,255,255,0.03) 1px,
    transparent 2px,
    transparent 4px
  );
  pointer-events: none;
}

/* Slight screen flicker */
.crt::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.02);
  animation: flicker 0.15s infinite;
  pointer-events: none;
}

@keyframes flicker {
  0% { opacity: 0.95; }
  100% { opacity: 1; }
}

.terminal {
  color: var(--text);
  position: relative;
  height: 100%;
  overflow-y: auto;
}

pre {
  margin: 0;
  white-space: pre-wrap;
}

.input-line {
  display: flex;
  align-items: center;
  margin-top: 8px;
}

.input-line span {
  margin-right: 6px;
}

.terminal input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-family: inherit;
  font-size: 24px;
  width: 100%;
}

/* Scrollbar width */
.terminal::-webkit-scrollbar {
  width: 10px;
}

/* Track */
.terminal::-webkit-scrollbar-track {
  background: var(--scrollbar-bg);
  border-left: 1px solid var(--border);
}

/* Handle */
.terminal::-webkit-scrollbar-thumb {
  background-color: var(--scrollbar-thumb);
  border-radius: 6px;
  box-shadow: 0 0 8px var(--glow);
}

/* Handle on hover */
.terminal::-webkit-scrollbar-thumb:hover {
  background-color: var(--text);
}

.terminal {
  scrollbar-width: thin;
  scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-bg);
}

input:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}


/* ===== 90s MODE ===== */

body.era-90s {
  background: #c0c0c0; /* Windows 95 grey */
  font-family: "Tahoma", "Verdana", sans-serif;
  color: black;
}

/* Ocultar terminal en 90s */
body.era-90s .terminal {
  display: none;
}

/* Contenedor 90s */
.nineties-container {
  display: none;
}

body.era-90s .nineties-container {
  display: block;
  width: 800px;
  margin: 40px auto;
  background: white;
  border: 3px solid #000;
  padding: 20px;
}

#era-hint {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 12px;
  opacity: 0.6;
  font-family: monospace;
}

#era-hint {
  animation: blink 2s infinite;
}

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

.era-90s .win95-window {
  background: silver;
  padding: 20px;
  border: 2px solid #000;
  font-family: Tahoma, sans-serif;
  width: 465px;
  margin: 40px auto;
  box-shadow: 4px 4px 0px #808080;
}

/* Oculto por defecto */
.old-header {
  display: none;
}

/* Visible solo en 90s */
.era-90s .old-header {
  display: block;
}
.nav-buttons button {
  background: #c0c0c0;
  border: 2px outset #fff;
  padding: 5px 10px;
  margin: 5px;
  cursor: pointer;
}

.nav-buttons button:active {
  border: 2px inset #fff;
}

#contact-form input,
#contact-form textarea {
  width: 300px;
  border: 2px inset #fff;
  background: white;
  font-family: Tahoma, sans-serif;
}

#contact-form button {
  background: #c0c0c0;
  border: 2px outset #fff;
  padding: 4px 10px;
  cursor: pointer;
}

#contact-form button:active {
  border: 2px inset #fff;
}

.era-2000s {
  background: linear-gradient(to bottom, #eef2f7, #d6dee8);
  font-family: "Helvetica Neue", Arial, sans-serif;
  color: #333;
}

.era-2000s #nineties-container {
  max-width: 800px;
  margin: 60px auto;
  background: white;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.15);
  padding: 40px;
}


.era-2000s button {
  background: linear-gradient(to bottom, #6ec1ff, #2a82e4);
  border: 1px solid #1f6ed4;
  color: white;
  padding: 8px 18px;
  border-radius: 20px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2),
              inset 0 1px 0 rgba(255,255,255,0.5);
  transition: all 0.2s ease;
}

.era-2000s button:hover {
  background: linear-gradient(to bottom, #7ccaff, #3a92f4);
  transform: translateY(-1px);
}

.era-2000s .section {
  background: #fafafa;
  border-radius: 10px;
  padding: 25px;
  margin-top: 20px;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
}


.era-2000s table {
  width: 100%;
  border-collapse: collapse;
}

.era-2000s th {
  background: #f0f4f8;
  font-weight: bold;
}

.era-2000s td,
.era-2000s th {
  border-bottom: 1px solid #ddd;
  padding: 10px;
}



.era-2000s input,
.era-2000s textarea {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  border: 1px solid #ccc;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
  font-size: 14px;
}

.era-2000s .startup-header {
  background: linear-gradient(to bottom, #4da3ff, #1f6ed4);
  color: white;
  padding: 20px;
  border-radius: 12px 12px 0 0;
  font-size: 28px;
  font-weight: bold;
  text-align: center;
  margin: -40px -40px 30px -40px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
}

.era-2000s .startup-header .tagline {
  display: block;
  font-size: 14px;
  font-weight: normal;
  opacity: 0.9;
}

/* Oculto por defecto */
.startup-header {
  display: none;
}

/* Visible solo en 2000s */
.era-2000s .startup-header {
  display: block;
}

/* Quitar look 95 en 2000s */
.era-2000s .win95-window {
  background: none;
  border: none;
  padding: 0;
}

/* 90s */
.era-90s .nav-container {
  background: #c0c0c0;
  border: 2px solid #000;
  padding: 10px;
}

/* 2000s */
.era-2000s .nav-container {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.era-2010s {
  background: #f4f6f8;
  font-family: "Helvetica Neue", Arial, sans-serif;
  color: #333;
}

.era-2010s #nineties-container {
  max-width: 800px;
  margin: 40px auto 80px auto;
  background: white;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.08);
  padding: 30px;
}

.era-2010s .nav-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 30px;
}

.era-2010s button {
  background: #3498db;
  border: none;
  color: white;
  padding: 8px 18px;
  border-radius: 4px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.era-2010s button:hover {
  background: #2980b9;
}

.era-2010s .section {
  margin-top: 20px;
  padding: 20px;
  border: 1px solid #e3e6e8;
  border-radius: 4px;
  background: #ffffff;
}

.era-2010s table {
  width: 100%;
  border-collapse: collapse;
}

.era-2010s th {
  text-align: left;
  border-bottom: 2px solid #e3e6e8;
  padding: 10px;
}

.era-2010s td {
  padding: 10px;
  border-bottom: 1px solid #eee;
}

.era-2010s input,
.era-2010s textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #dcdfe3;
  border-radius: 4px;
  font-size: 14px;
}

.era-2010s input:focus,
.era-2010s textarea:focus {
  border-color: #3498db;
  outline: none;
}

.era-2010s .modern-header {
  text-align: center;
  margin-bottom: 40px;
}

.era-2010s .modern-header h1 {
  margin: 0;
  font-size: 32px;
  font-weight: 600;
}

.era-2010s .modern-header p {
  color: #888;
  margin-top: 8px;
}

/* Oculto por defecto */
.modern-header {
  display: none;
}

/* Visible solo en 2010s */
.era-2010s .modern-header {
  display: block;
}


.era-2020s {
  background: linear-gradient(to bottom, #f9fafb, #eef2f7);
  font-family: 'Inter', sans-serif;
  color: #111;
}

.era-2020s #nineties-container {
  max-width: 900px;
  margin: 80px auto;
  background: white;
  border-radius: 16px;
  padding: 60px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.era-2020s .nav-buttons {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin-bottom: 40px;
}

.era-2020s button {
  background: none;
  border: none;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  color: #555;
  position: relative;
}

.era-2020s button::after {
  content: "";
  position: absolute;
  width: 0%;
  height: 2px;
  left: 0;
  bottom: -4px;
  background: #111;
  transition: width 0.3s ease;
}

.era-2020s button:hover::after {
  width: 100%;
}

.era-2020s .section {
  margin-top: 30px;
  padding: 30px;
  border-radius: 12px;
  background: #fafafa;
  border: 1px solid #eee;
}

.era-2020s table {
  width: 100%;
  border-collapse: collapse;
}

.era-2020s th {
  text-align: left;
  font-weight: 600;
  border-bottom: 2px solid #eee;
  padding-bottom: 10px;
}

.era-2020s td {
  padding: 12px 0;
  border-bottom: 1px solid #f0f0f0;
}

.era-2020s input,
.era-2020s textarea {
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid #ddd;
  font-size: 14px;
  transition: all 0.2s ease;
}

.era-2020s input:focus,
.era-2020s textarea:focus {
  border-color: #111;
  outline: none;
}

.era-2020s .modern-2020-header {
  text-align: center;
  margin-bottom: 50px;
}

.era-2020s .modern-2020-header h1 {
  font-size: 40px;
  font-weight: 700;
  margin: 0;
}

.era-2020s .modern-2020-header p {
  color: #666;
  margin-top: 10px;
}

/* Oculto por defecto */
.modern-2020-header {
  display: none;
}

/* Visible solo en 2010s */
.era-2020s .modern-2020-header {
  display: block;
}

.era-2020s .dark-toggle {
  position: absolute;
  top: 30px;
  right: 30px;
  background: none;
  border: 1px solid #ddd;
  border-radius: 20px;
  padding: 6px 12px;
  cursor: pointer;
  font-size: 14px;
}

.era-2020s.dark-mode {
  background: linear-gradient(to bottom, #0f172a, #111827);
  color: #f3f4f6;
}

.era-2020s.dark-mode #nineties-container {
  background: #1f2937;
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
}

.era-2020s.dark-mode .section {
  background: #111827;
  border: 1px solid #2d3748;
}

.era-2020s.dark-mode button {
  color: #e5e7eb;
}

.era-2020s.dark-mode input,
.era-2020s.dark-mode textarea {
  background: #111827;
  border: 1px solid #374151;
  color: #f3f4f6;
}

.era-2020s,
.era-2020s * {
  transition: background 0.3s ease,
              color 0.3s ease,
              border 0.3s ease;
}

.era-90s .era-switcher {
  position: relative;
  display: inline-block;
}

.era-90s .era-current {
  background: #c0c0c0;
  border: 2px outset #fff;
  padding: 5px 10px;
  cursor: pointer;
}

.era-90s .era-menu {
  display: none;
  position: absolute;
  background: #c0c0c0;
  border: 2px solid #000;
}

.era-90s .era-switcher.open .era-menu {
  display: block;
}

.era-90s .era-menu button {
  display: block;
  width: 100%;
  border: none;
  background: none;
  padding: 5px;
  text-align: left;
}

 .era-timeline {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 30px;
  z-index: 1000;
}

.era-line {
  position: absolute;
  height: 2px;
  width: 100%;
  background: #ccc;
  z-index: -1;
}

.era-dot {
  background: white;
  border: 2px solid #ccc;
  border-radius: 20px;
  padding: 4px 10px;
  cursor: pointer;
  font-size: 12px;
  transition: all 0.2s ease;
}



.era-90s .era-dot {
  background: #c0c0c0;
  border: 2px outset #fff;
  font-family: Tahoma;
}

.era-90s .era-dot.active {
  border: 2px inset #fff;
}

.era-2000s .era-dot {
  background: linear-gradient(to bottom, #6ec1ff, #2a82e4);
  color: white;
  border: none;
  border-radius: 20px;
}

.era-2000s .era-dot.active {
  box-shadow: 0 0 0 3px rgba(42,130,228,0.4);
  transform: scale(1.15);
}

.era-2010s .era-dot {
  border-radius: 4px;
  border: 1px solid #ddd;
}

.era-2010s .era-dot.active {
  background: #2c3e50;
  color: white;
  border-color: #2c3e50;
}

.era-2020s .era-dot {
  background: none;
  border: none;
  font-weight: 600;
  position: relative;
}

.era-2020s .era-dot {
  color: #111;
}

.era-2020s .era-dot.active {
  color: #111;
  font-weight: 700;
}

.era-2020s.dark-mode .era-dot {
  color: #e5e7eb;
}

.era-2020s.dark-mode .era-dot.active {
  color: #ffffff;
}


.era-2020s .era-dot::after {
  content: "";
  position: absolute;
  height: 2px;
  width: 0%;
  left: 0;
  bottom: -4px;
  background: #111;
  transition: width 0.3s ease;
}

.era-2020s .era-dot.active::after {
  width: 100%;
}

/* ===== 80s BIOS MODE ===== */

.era-80s {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.era-80s .era-timeline {
  position: fixed;
  top: 15px;
  left: 30px;
  transform: none;
  display: flex;
  gap: 30px;
  font-family: 'VT323', monospace;
  font-size: 26px; 
  letter-spacing: 1px;
}

.era-80s .era-line {
  display: none;
}

.era-80s .era-dot {
  background: none;
  border: none;
  color: var(--text);
  font-family: 'VT323', monospace;
  font-size: 24px;          
  padding: 2px 6px;
  cursor: pointer;
}


.era-80s .era-dot::before {
  content: "[ ";
}

.era-80s .era-dot::after {
  content: " ]";
  opacity: 0;
}

.era-80s .era-dot.active {
  background: var(--text);
  color: black;
  padding: 2px 8px;
}

.era-80s .era-dot.active::after {
  opacity: 1;
}

.era-80s .era-timeline::before {
  content: "SYSTEM ERA SELECT:";
  display: block;
  margin-bottom: 5px;
}

.era-80s #terminal-container {
  margin-top: 8vh;
}

.era-80s .terminal {
  font-size: 18px;
}

.era-90s .visitor-counter {
  margin-top: 20px;
  font-family: Courier, monospace;
}


.era-2000s .loading-bar {
  width: 100%;
  height: 6px;
  background: #e0e0e0;
  border-radius: 10px;
  margin-bottom: 20px;
  overflow: hidden;
}

.era-2000s .progress {
  width: 0%;
  height: 100%;
  background: linear-gradient(to right, #6ec1ff, #2a82e4);
  transition: width 2s ease;
}

.section.hidden {
  display: none;
}

/* Override display:none solo en 2010 */
.era-2010s .section.hidden {
  display: block;
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  height: 0;
  overflow: hidden;
}



.era-2010s .section {
  position: relative;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

/* Sección visible */
.era-2010s .section:not(.hidden) {
  opacity: 1;
  transform: translateY(0);
}

.era-2010s #nineties-container {
  animation: fadeIn2010 0.6s ease;
}

@keyframes fadeIn2010 {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {

  body {
    align-items: flex-start;
    justify-content: flex-start;
  }

  #nineties-container {
    width: 95% !important;
    margin: 20px auto !important;
    padding: 20px !important;
    margin-top: 60px !important;

    
  }

  .section {
    padding: 15px !important;
  }

}

@media (max-width: 768px) {

  .crt {
    width: 100%;
    height: 85vh;
    border-radius: 0;
  }

  .era-80s .terminal {
    font-size: 16px;
  }

  .terminal input {
    font-size: 16px;
  }
  
  .era-80s .era-timeline {
    top: auto;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    gap: 15px;
  }

  .era-80s .era-dot {
    font-size: 14px;
  }
}


@media (max-width: 768px) {

  .era-timeline {
    position: fixed;
    top: 10px;
    bottom: auto;
    left: 50%;
    transform: translateX(-50%);
    gap: 10px;
    flex-wrap: nowrap;
  }

  .era-dot {
    font-size: 11px;
    padding: 3px 6px;
    border-radius: 12px;
  }

}



@media (max-width: 768px) {

  .era-90s .win95-window {
    width: 100%;
    margin: 20px 0;
  }

  .era-90s .nav-buttons {
    display: flex;
    flex-direction: column;
  }

}

@media (max-width: 768px) {

  .era-2000s .nav-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .era-2000s button {
    width: 100%;
  }

  .era-2000s .era-dot,
  .era-2010s .era-dot {
    font-size: 12px;
    padding: 4px 8px;
  }
  
}

@media (max-width: 768px) {

  .era-2010s .nav-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .era-2010s button {
    width: 100%;
  }

}

@media (max-width: 768px) {

  .era-2020s #nineties-container {
    padding: 30px 20px;
  }

  .era-2020s .modern-2020-header h1 {
    font-size: 28px;
  }

  .era-2020s .nav-buttons {
    flex-direction: column;
    gap: 10px;
  }

  .era-2020s button {
    width: 100%;
  }

   .era-2020s .dark-toggle {
    position: static;
    display: block;
    margin: 10px auto 0 auto;
  }
}

@media (max-width: 768px) {

  .era-90s table,
  .era-2000s table,
  .era-2010s table,
  .era-2020s table {
    display: block;
    width: 100%;
  }

  .era-90s th,
  .era-2000s th,
  .era-2010s th,
  .era-2020s th {
    display: none;
  }

  .era-90s tr,
  .era-2000s tr,
  .era-2010s tr,
  .era-2020s tr {
    display: block;
    margin-bottom: 20px;
    border: 1px solid #ddd;
    padding: 15px;
    border-radius: 6px;
  }

  .era-90s td,
  .era-2000s td,
  .era-2010s td,
  .era-2020s td {
    display: block;
    width: 100%;
    padding: 5px 0;
    border: none;
  }

  .mobile-label {
    display: inline-block;
    margin-right: 6px;
  }

}

.mobile-label {
  display: none;
  font-weight: bold;
}

body:not(.era-80s) {
  padding-top: 100px;
}

.ackbar-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.ackbar-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.ackbar-content {
  max-width: 90%;
  max-height: 80vh;
}

.ackbar-content img {
  max-width: 100%;
  border-radius: 12px;
}

.era-90s .ackbar-modal {
  background: rgba(0,0,0,0.4);
}

.era-90s .ackbar-content {
  background: silver;
  border: 3px solid black;
  padding: 20px;
  box-shadow: 6px 6px 0px #808080;
}

.era-2000s .ackbar-modal {
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
}

.era-2000s .ackbar-content {
  transform: scale(0.7);
  transition: transform 0.3s ease;
}

.era-2000s .ackbar-modal.active .ackbar-content {
  transform: scale(1);
}

.era-2010s .ackbar-modal {
  background: rgba(0,0,0,0.6);
}

.era-2010s .ackbar-content {
  transform: translateY(40px);
  opacity: 0;
  transition: all 0.3s ease;
}

.era-2010s .ackbar-modal.active .ackbar-content {
  transform: translateY(0);
  opacity: 1;
}

.era-2020s .ackbar-modal {
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
}

.era-2020s .ackbar-content {
  transform: scale(0.9);
  opacity: 0;
  transition: all 0.3s ease;
}

.era-2020s .ackbar-modal.active .ackbar-content {
  transform: scale(1);
  opacity: 1;
}
