/* ==========================================================================
   Simple Video Downloader - Custom Stylesheet
   Designed to match the high-fidelity UI mockup
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400;1,600&family=Amiri:ital,wght@0,400;0,700;1,400;1,700&display=swap');

:root {
  --primary-orange: #FF8500;
  --primary-orange-light: #FFA336;
  --primary-orange-dark: #FF5A00;
  --accent-coral: #EE3554;
  --accent-coral-hover: #D82241;
  --accent-gold: #FFAA00;
  --accent-blue: #1877F2;
  --accent-cyan: #00F2FE;
  --accent-purple: #7000FF;
  --text-dark: #1E2530;
  --text-slate: #4A5568;
  --text-muted: #8E9AA8;
  --bg-light: #FAFBFD;
  --card-border: rgba(0, 0, 0, 0.06);
  --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.06);
  --shadow-card: 0 18px 40px -8px rgba(0, 0, 0, 0.09);
  --shadow-orange: 0 14px 35px -6px rgba(255, 110, 0, 0.35);
  --shadow-coral: 0 10px 25px -4px rgba(238, 53, 84, 0.38);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background-color: #FFFFFF;
  color: var(--text-dark);
  overflow-x: hidden;
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #F1F4F8;
}
::-webkit-scrollbar-thumb {
  background: #CBD5E1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94A3B8;
}

/* ==========================================================================
   Hero Section & Concentric Orbit Lines
   ========================================================================== */

.hero-gradient {
  background: radial-gradient(circle at 50% 35%, #FFB648 0%, #FF8800 48%, #FF5E00 100%);
  position: relative;
  overflow: hidden;
}

/* Subtle concentric orbital rings centered in the hero */
.orbit-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  pointer-events: none;
  transition: all 0.5s ease;
}

.orbit-ring-1 {
  width: 320px;
  height: 320px;
}

.orbit-ring-2 {
  width: 520px;
  height: 520px;
}

.orbit-ring-3 {
  width: 740px;
  height: 740px;
  border-color: rgba(255, 255, 255, 0.18);
}

.orbit-ring-4 {
  width: 980px;
  height: 980px;
  border-color: rgba(255, 255, 255, 0.13);
}

.orbit-ring-5 {
  width: 1240px;
  height: 1240px;
  border-color: rgba(255, 255, 255, 0.08);
}

/* Hero bottom curved boundary shape */
.hero-curve-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 48px;
  pointer-events: none;
  background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.05));
}

/* Floating Animations */
@keyframes floatSlow {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-9px) rotate(2deg);
  }
}

@keyframes floatReverse {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(9px) rotate(-2deg);
  }
}

@keyframes gentlePulse {
  0%, 100% {
    transform: scale(1);
    opacity: 0.9;
  }
  50% {
    transform: scale(1.06);
    opacity: 1;
  }
}

.float-slow {
  animation: floatSlow 5s ease-in-out infinite;
}

.float-reverse {
  animation: floatReverse 6s ease-in-out infinite;
}

.pulse-gentle {
  animation: gentlePulse 4s ease-in-out infinite;
}

/* Social Badges in Hero Orbit */
.social-badge {
  position: absolute;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
  z-index: 10;
  cursor: pointer;
}

.social-badge:hover {
  transform: scale(1.15) translateY(-4px) !important;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.28);
}

.badge-youtube {
  background: #FF0000;
  color: #FFFFFF;
}

.badge-x {
  background: #000000;
  color: #FFFFFF;
}

.badge-facebook {
  background: #1877F2;
  color: #FFFFFF;
}

.badge-instagram {
  background: linear-gradient(45deg, #FFB900 0%, #FF0055 50%, #9000D0 100%);
  color: #FFFFFF;
}

.badge-tiktok {
  background: #000000;
  color: #FFFFFF;
}

/* Decorative Geometric Elements */
.shape-ring-orange {
  position: absolute;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 3.5px solid #FF5050;
  pointer-events: none;
}

.shape-ring-coral {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid #EE3554;
  pointer-events: none;
}

.shape-triangle {
  position: absolute;
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-bottom: 18px solid #6C5CE7;
  pointer-events: none;
  transform: rotate(25deg);
}

.shape-squiggle {
  position: absolute;
  pointer-events: none;
}

/* ==========================================================================
   Input / Search Pill Box
   ========================================================================== */

.hero-search-wrapper {
  background: #FFFFFF;
  border-radius: 50px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.12);
  padding: 6px 8px 6px 24px;
  display: flex;
  align-items: center;
  transition: box-shadow 0.3s ease, transform 0.2s ease;
}

.hero-search-wrapper:focus-within {
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.18), 0 0 0 3px rgba(255, 255, 255, 0.6);
  transform: translateY(-2px);
}

.hero-search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 15px;
  font-weight: 500;
  color: #2D3748;
  background: transparent;
  width: 100%;
}

.hero-search-input::placeholder {
  color: #A0AEC0;
  font-weight: 400;
}

.btn-coral {
  background-color: var(--accent-coral);
  color: #FFFFFF;
  font-weight: 600;
  border-radius: 50px;
  padding: 12px 32px;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-coral);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}

.btn-coral:hover {
  background-color: var(--accent-coral-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -4px rgba(238, 53, 84, 0.5);
}

.btn-coral:active {
  transform: translateY(0);
}

/* Clear / Action Icon Button */
.btn-icon-clear {
  background: transparent;
  border: none;
  color: #718096;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.btn-icon-clear:hover {
  color: #E53E3E;
  background: #FEE2E2;
}

/* ==========================================================================
   Video Result Preview Card
   ========================================================================== */

.result-card {
  background: #FFFFFF;
  border-radius: 20px;
  box-shadow: 0 20px 48px -10px rgba(0, 0, 0, 0.12), 0 0 1px 1px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.result-tab-btn {
  padding: 8px 24px;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}

.result-tab-btn.active {
  background-color: var(--accent-coral);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(238, 53, 84, 0.35);
}

.result-tab-btn.inactive {
  background-color: #F1F3F5;
  color: #64748B;
}

.result-tab-btn.inactive:hover {
  background-color: #E2E8F0;
  color: #334155;
}

.table-download-btn {
  background-color: #FFF2EA;
  color: #FF5A00;
  border: 1px solid #FFD3B5;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
}

.table-download-btn:hover {
  background-color: var(--accent-coral);
  color: #FFFFFF;
  border-color: var(--accent-coral);
  box-shadow: 0 4px 12px rgba(238, 53, 84, 0.28);
  transform: translateY(-1px);
}

/* ==========================================================================
   Supported Platforms
   ========================================================================== */

.platform-card {
  background: #FFFFFF;
  border-radius: 16px;
  border: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.04);
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.platform-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 36px -6px rgba(0, 0, 0, 0.1);
  border-color: rgba(255, 133, 0, 0.2);
}

/* ==========================================================================
   How It Works Section
   ========================================================================== */

.step-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  z-index: 2;
}

.step-icon-wrapper {
  width: 76px;
  height: 76px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.09);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.step-card:hover .step-icon-wrapper {
  transform: scale(1.1) rotate(4deg);
}

.step-1-bg {
  background: linear-gradient(135deg, #FFB72B 0%, #FF9500 100%);
  color: #FFFFFF;
}

.step-2-bg {
  background: linear-gradient(135deg, #FF7B54 0%, #FF5436 100%);
  color: #FFFFFF;
}

.step-3-bg {
  background: linear-gradient(135deg, #EE3554 0%, #D41A3D 100%);
  color: #FFFFFF;
}

.steps-connector {
  position: absolute;
  top: 38px;
  left: 20%;
  right: 20%;
  height: 2px;
  border-top: 2px dashed #E2E8F0;
  z-index: 1;
}

/* ==========================================================================
   Call to Action (CTA) Banner
   ========================================================================== */

.cta-banner-wrapper {
  background: linear-gradient(135deg, #FFA03A 0%, #FF8500 45%, #FF6000 100%);
  border-radius: 24px;
  box-shadow: var(--shadow-orange);
  position: relative;
  overflow: hidden;
}

/* Decorative concentric orbit circles inside CTA banner */
.cta-orbit-curve {
  position: absolute;
  right: -80px;
  bottom: -100px;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  pointer-events: none;
}

.cta-orbit-curve-2 {
  position: absolute;
  right: -40px;
  bottom: -60px;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  pointer-events: none;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer-section {
  position: relative;
  background-color: #FFFFFF;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.footer-orbit-curve {
  position: absolute;
  right: -100px;
  bottom: -120px;
  width: 440px;
  height: 440px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 133, 0, 0.12);
  pointer-events: none;
}

.footer-orbit-curve-2 {
  position: absolute;
  right: -50px;
  bottom: -70px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 133, 0, 0.15);
  pointer-events: none;
}

.social-icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #F8FAFC;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #64748B;
  transition: all 0.2s ease;
  border: 1px solid #E2E8F0;
  text-decoration: none;
}

.social-icon-btn:hover {
  background: #FF8500;
  color: #FFFFFF;
  border-color: #FF8500;
  transform: translateY(-2px);
}

/* ==========================================================================
   Interactive Modals & Toasts
   ========================================================================== */

.modal-backdrop {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.modal-backdrop.show {
  opacity: 1;
  pointer-events: auto;
}

.modal-panel {
  background: #FFFFFF;
  border-radius: 20px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
  max-width: 520px;
  width: 92%;
  overflow: hidden;
  transform: translateY(20px) scale(0.96);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-backdrop.show .modal-panel {
  transform: translateY(0) scale(1);
}

/* Toast Notification */
.toast-container {
  display: none !important;
}

.toast {
  background: #1E293B;
  color: #FFFFFF;
  border-radius: 12px;
  padding: 14px 20px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
  font-size: 14px;
  font-weight: 500;
  animation: slideInRight 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* Preset badge tag */
.preset-tag {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(8px);
  color: #FFFFFF;
  font-size: 12px;
  font-weight: 500;
  padding: 5px 14px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.preset-tag:hover {
  background: rgba(255, 255, 255, 0.35);
  transform: translateY(-1px);
}

/* ==========================================================================
   RTL & Arabic (Amiri Font) Typography Styles
   ========================================================================== */

[dir="rtl"],
[dir="rtl"] body {
  direction: rtl;
  text-align: right;
  font-family: 'Amiri', serif !important;
}

[dir="rtl"] * {
  font-family: 'Amiri', serif;
}

[dir="rtl"] h1,
[dir="rtl"] h2,
[dir="rtl"] h3,
[dir="rtl"] h4,
[dir="rtl"] h5,
[dir="rtl"] h6 {
  font-family: 'Amiri', serif !important;
  font-weight: 700;
  line-height: 1.45;
}

[dir="rtl"] .hero-search-wrapper {
  padding: 6px 24px 6px 8px;
  flex-direction: row-reverse;
}

[dir="rtl"] .hero-search-input {
  text-align: right;
  font-family: 'Amiri', serif !important;
  font-size: 17px;
}

[dir="rtl"] .btn-coral {
  font-family: 'Amiri', serif !important;
  font-size: 16px;
  padding: 10px 28px;
}

[dir="rtl"] table {
  text-align: right;
}

[dir="rtl"] th,
[dir="rtl"] td {
  text-align: right;
}

[dir="rtl"] td:last-child,
[dir="rtl"] th:last-child {
  text-align: left;
}

[dir="rtl"] .faq-answer {
  text-align: right;
  font-size: 16px;
  line-height: 1.8;
}

[dir="rtl"] .modal-panel {
  text-align: right;
}

/* Keyboard Focus Accessibility for Header Dropdowns & Interactive Cards */
.group:focus-within > div[class*="invisible"] {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translateY(0) !important;
}

.platform-card:focus-visible,
.social-badge:focus-visible {
  outline: 2px solid #FF8500;
  outline-offset: 3px;
}


