/* ============================================
   DCG PANAMA — MANIFESTO PAGE
   Retro 80s TV Terminal Display
   ============================================ */

.manifesto-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 2rem;
  padding-top: 80px;
}

/* --- TV Set Outer Shell --- */
.tv-set {
  position: relative;
  max-width: 820px;
  width: 100%;
  margin: 0 auto;
}

/* TV Body */
.tv-body {
  background: linear-gradient(145deg, #2a2520, #1a1815, #252220);
  border-radius: 20px;
  padding: 30px 30px 20px 30px;
  box-shadow:
    0 10px 60px rgba(0, 0, 0, 0.8),
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 0 2px #1a1815;
  position: relative;
}

/* Wood grain texture overlay */
.tv-body::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 20px;
  background: repeating-linear-gradient(
    90deg,
    transparent,
    transparent 3px,
    rgba(139, 90, 43, 0.03) 3px,
    rgba(139, 90, 43, 0.03) 4px
  );
  pointer-events: none;
}

/* --- TV Screen Container --- */
.tv-screen-wrapper {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #000;
  box-shadow:
    inset 0 0 80px rgba(0, 0, 0, 0.9),
    inset 0 0 20px rgba(0, 0, 0, 0.5);
  border: 3px solid #111;
}

/* Screen curvature effect */
.tv-screen-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 12px;
  background: radial-gradient(ellipse at center, transparent 60%, rgba(0, 0, 0, 0.6) 100%);
  pointer-events: none;
  z-index: 10;
}

/* Screen glare */
.tv-screen-wrapper::after {
  content: '';
  position: absolute;
  top: -10%;
  left: -10%;
  width: 60%;
  height: 60%;
  background: radial-gradient(ellipse at 30% 30%, rgba(255, 255, 255, 0.04), transparent 60%);
  pointer-events: none;
  z-index: 11;
}

/* --- Actual Screen Content Area --- */
.tv-screen {
  position: relative;
  width: 100%;
  height: 500px;
  background: #0a0a0a;
  overflow: hidden;
  font-family: var(--font-retro);
}

/* Phosphor glow effect */
.tv-screen::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(0, 255, 65, 0.03) 0%, transparent 70%);
  pointer-events: none;
  z-index: 5;
}

/* TV scanlines */
.tv-scanlines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 6;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 1px,
    rgba(0, 0, 0, 0.25) 1px,
    rgba(0, 0, 0, 0.25) 3px
  );
}

/* Horizontal sync line */
.tv-sync-line {
  position: absolute;
  width: 100%;
  height: 2px;
  background: rgba(0, 255, 65, 0.08);
  z-index: 7;
  pointer-events: none;
  animation: syncLine 8s linear infinite;
}

@keyframes syncLine {
  0% { top: -2px; }
  100% { top: 100%; }
}

/* --- Text Content Inside Screen --- */
.manifesto-content {
  position: absolute;
  inset: 0;
  padding: 30px 40px;
  overflow: hidden;
  z-index: 4;
}

.manifesto-scroller {
  position: relative;
  will-change: transform;
}

.manifesto-scroller.paused {
  animation-play-state: paused !important;
}

.manifesto-line {
  font-family: var(--font-retro);
  font-size: 1.3rem;
  color: var(--red-primary);
  text-shadow: 0 0 6px var(--red-glow);
  line-height: 1.8;
  margin-bottom: 0.3rem;
}

.manifesto-line.separator {
  color: var(--red-dim);
  margin: 1.5rem 0;
  text-align: center;
  opacity: 0.5;
}

.manifesto-line.emphasis {
  color: #fff;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
  font-size: 1.5rem;
}

.manifesto-line.title-line {
  font-family: var(--font-display);
  font-size: 1.8rem;
  color: var(--red-primary);
  text-shadow: 0 0 15px var(--red-glow);
  margin-bottom: 1rem;
  letter-spacing: 3px;
}

.manifesto-line.dim {
  color: var(--red-dim);
  opacity: 0.7;
}

/* --- TV Controls Panel --- */
.tv-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 10px 5px 10px;
}

.tv-controls-left {
  display: flex;
  gap: 10px;
  align-items: center;
}

.tv-knob {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(145deg, #3a3530, #1a1815);
  border: 2px solid #2a2520;
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  position: relative;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.tv-knob:hover {
  transform: rotate(20deg);
}

.tv-knob::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 10px;
  background: #555;
  border-radius: 1px;
}

.tv-brand {
  font-family: var(--font-display);
  font-size: 0.6rem;
  color: #5a5550;
  letter-spacing: 4px;
  text-transform: uppercase;
}

/* --- Toggle Button --- */
.tv-controls-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.toggle-btn {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--red-dim);
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--red-dark);
  padding: 8px 16px;
  cursor: pointer;
  letter-spacing: 2px;
  text-transform: uppercase;
  transition: all 0.3s ease;
  border-radius: 3px;
}

.toggle-btn:hover {
  color: var(--red-primary);
  border-color: var(--red-dim);
  box-shadow: 0 0 10px var(--red-glow);
}

.toggle-btn.active {
  color: var(--red-accent);
  border-color: var(--red-accent);
  box-shadow: 0 0 10px var(--red-glow);
}

/* LED indicator */
.tv-led {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red-primary);
  box-shadow: 0 0 6px var(--red-glow);
  animation: ledPulse 2s ease infinite;
}

.tv-led.off {
  background: #333;
  box-shadow: none;
  animation: none;
}

@keyframes ledPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* --- TV Stand / Legs --- */
.tv-legs {
  display: flex;
  justify-content: center;
  gap: 60%;
  margin-top: -2px;
}

.tv-leg {
  width: 30px;
  height: 20px;
  background: linear-gradient(to bottom, #2a2520, #1a1815);
  clip-path: polygon(15% 0%, 85% 0%, 100% 100%, 0% 100%);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

/* --- Power On Effect --- */
.tv-power-on {
  animation: powerOn 1s ease forwards;
}

@keyframes powerOn {
  0% {
    filter: brightness(0);
    transform: scaleY(0.01) scaleX(0.8);
  }
  30% {
    filter: brightness(2);
    transform: scaleY(0.01) scaleX(1);
  }
  50% {
    filter: brightness(1.5);
    transform: scaleY(1) scaleX(1);
  }
  70% {
    filter: brightness(1.2);
  }
  100% {
    filter: brightness(1);
    transform: scaleY(1) scaleX(1);
  }
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .tv-body {
    padding: 20px 15px 15px 15px;
    border-radius: 14px;
  }

  .tv-screen {
    height: 400px;
  }

  .manifesto-content {
    padding: 20px 25px;
  }

  .manifesto-line {
    font-size: 1.1rem;
  }

  .manifesto-line.title-line {
    font-size: 1.4rem;
  }

  .manifesto-line.emphasis {
    font-size: 1.2rem;
  }
}

@media (max-width: 480px) {
  .tv-screen {
    height: 350px;
  }

  .manifesto-line {
    font-size: 1rem;
  }

  .tv-brand {
    display: none;
  }
}