:root {
  --bg-main: #fff7ed;
  --bg-section: #ffffff;
  --text-main: #1f2937;
  --accent-red: #dc2626;
  --accent-blue: #2563eb;
  --accent-yellow: #eab308;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --text-muted: #6b7280;
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
  --shadow-lg-top: 0 -10px 15px -3px rgb(0 0 0 / 0.1);
  --shadow-all: 0 0 15px rgb(0 0 0 / 0.15);
  --hero-gred: linear-gradient(90deg, #d5162f 0%, #facc15 50%, #2563eb 100%);
}

/* =========================
   Base Styles
========================= */
body {
  margin: 0;
  font-family: system-ui;
  background: #e5e7eb;
  color: var(--text-main);
  overflow-x: hidden;
}

/* =========================
   Viewer Container
========================= */
.media-container {
  height: calc(100vh - 5px);
  display: flex;
  justify-content: center;
  align-items: center;
  box-sizing: border-box;
}

/* =========================
   Media Box
========================= */
.media-box {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border: 2px solid #e5e7eb;
}

.media-box.youtube-short,
.media-box.tiktok,
.media-box.facebook {
  width: 400px;
}

.media-box.youtube {
  max-width: 800px;
}

.media-box.twitter {
  width: 400px;
}

/* Responsive widths */
@media screen and (min-width: 768px) {
  .media-box.facebook,
  .media-box.youtube-short,
  .media-box.tiktok {
    max-width: 285px;
  }
  .media-box.twitter {
    max-width: 420px;
  }
}

@media screen and (min-width: 1367px) {
  .media-box.facebook,
  .media-box.youtube-short,
  .media-box.tiktok {
    max-width: 450px;
  }
}

/* =========================
   Header
========================= */
.media-header {
  display: flex;
  background: #e5e7eb;
  align-items: center;
  justify-content: space-between;
  height: 70px;
  text-align: center;
  box-shadow: var(--shadow-lg-top);
  z-index: 10;
  border-top: 3px solid #e5e7eb;
  border-right: 3px solid #e5e7eb;
  border-left: 3px solid #e5e7eb;
  border-top-right-radius: 12px;
  border-top-left-radius: 12px;
}

.media-box.facebook .media-header,
   .media-box.youtube-short .media-header,
   .media-box.tiktok .media-header{
     width: 395px;
     position: absolute;
     top: -20px;
   }
   .media-box.twitter .media-header{
       position: absolute;
       top:-50px;
       width:400px;
   }
   @media screen and (min-width: 768px)and (max-width: 1366px) {
 .media-box.facebook .media-header,
   .media-box.youtube-short .media-header,
   .media-box.tiktok .media-header{
     width: 283px;
   }
   }
  

.candidate-name h3 {
  margin-bottom: 1px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.candidate-name h2 {
  margin-top: 1px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-main);
}

.site-logo {
  height: 50px;
  width: auto;
  display: block;
  padding-left: 10px;
}

.media-header .candidate-info {
  width: 60px;
  height: 60px;
  overflow: hidden;
  background: #e5e7eb;
  border-radius: 50%;
  box-shadow: 0 0 8px rgb(0 0 0 / 0.1);
  margin-right: 10px;
}

.candidate-info .candidate-image {
  width: 100%;
}

/* =========================
   Platform Ratios
========================= */
iframe {
  border: 2px solid #e5e7eb;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 10px;
  background:#e5e7eb;
}

.media-box.twitter iframe,
.media-box.twitter blockquote {
  border-radius: 0;
}

.media-box.youtube iframe { aspect-ratio: 16 / 9; }
.media-box.youtube-short iframe,
.media-box.tiktok iframe,
.media-box.facebook iframe { aspect-ratio: 9 / 16; }
.media-box.twitter iframe,
.media-box.twitter blockquote { aspect-ratio: 4 / 5; }
.media-box.video iframe { aspect-ratio: 16 / 9; }

.playlist-end{
    display: flex;
            flex-direction:column;
            height: 400px;
            justify-content: center;
            align-items: center;
            text-align: center;
            color: black;
            background:#e5e7eb; 
}
/* =========================
   Share Buttons
========================= */
.share-bar {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: -10px;
  position: relative;
  align-items: center;
  background:#e5e7eb;
  box-shadow: var(--shadow-lg);
  padding: 10px 0;
  z-index: 50;
}

.share-btn {
  font-size: 1rem;
  padding: 10px 20px;
  border-radius: 5px;
  border: none;
  cursor: pointer;
}

@media screen and (min-width: 768px) and (max-width: 1366px) {
  .share-btn {
    padding: 5px 10px;
  }
}

button a {
  text-decoration: none;
  color: inherit;
}

[data-share="facebook"] {
  background-color: #3b5998;
  color: white;
}

[data-share="twitter"] {
  background-color: #1da1f2;
  color: white;
}

[data-share="whatsapp"] {
  background-color: #25D366;
  color: white;
}

/* =========================
   Loader
========================= */
.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.loader {
  width: 40px;
  height: 40px;
  border: 4px solid #eee;
  border-top: 4px solid #007bff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* =========================
   Arrow Controls
========================= */
.arrow-controls {
  position: fixed;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 20px;
  z-index: 1000;
}

.arrow-btn {
  background: #f3f4f6;
  border: none;
  color: black;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
  transition: all 0.3s ease;
  display: flex;
  flex-direction:     column;
  align-items: center;
  justify-content: center;
  font-size: 0.6rem;
  padding: 5px;
}

.arrow-btn:hover {
  background: #0056b3;
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0,0,0,0.4);
}

.arrow-btn:active {
  transform: scale(0.95);
}

.arrow-btn i {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.arrow-btn span {
  font-size: 0.85rem;
  font-weight: 700;
}

.arrow-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
  opacity: 0.5;
}

@keyframes slideFromDown {
  from {
    transform: translateY(100%);
    opacity: 0;
    background: linear-gradient(to top, #87CEEB, #4169E1);
    box-shadow: 0 8px 20px rgba(65, 105, 225, .5);
  }
  to {
    transform: translateY(0);
    opacity: 1;
    background: linear-gradient(to top, #87CEEB, #4169E1);
    box-shadow: 0 4px 12px rgba(65, 105, 225, 0.1);
  }
}
@keyframes slideFromUp {
  from {
    transform: translateY(-100%);
    opacity: 0;
    background: linear-gradient(to bottom, #f0f0f0, #ffffff);
    box-shadow: 0 -8px 20px rgba(0,0,0,0.4);
  }
  to {
    transform: translateY(0);
    opacity: 1;
    background: linear-gradient(to bottom, #f0f0f0, #ffffff);
    box-shadow: 0 -4px 12px rgba(0,0,0,0.4);
  }
}

.media-box.animate-down {
  animation: slideFromDown 2.9s ease forwards;
}
.media-box.animate-up {
  animation: slideFromUp 2.9s ease forwards;
}
