/* ==========================================================================
   INSTAFLOW PRO - ULTRA MODERN GLASSMORPHISM DESIGN SYSTEM (RESPONSIVE)
   ========================================================================== */

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

:root {
  /* Theme Colors */
  --bg-dark: #07090e;
  --bg-surface: #0e131f;
  --bg-card: rgba(18, 24, 38, 0.75);
  --bg-card-hover: rgba(26, 35, 54, 0.9);
  
  /* Gradients */
  --grad-primary: linear-gradient(135deg, #f43f5e 0%, #d946ef 50%, #8b5cf6 100%);
  --grad-accent: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
  --grad-gold: linear-gradient(135deg, #f59e0b 0%, #f43f5e 100%);
  --grad-glow: radial-gradient(circle at 50% -20%, rgba(217, 70, 239, 0.22) 0%, rgba(139, 92, 246, 0.08) 45%, transparent 70%);

  /* Borders & Glass */
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-glass-hover: rgba(217, 70, 239, 0.4);
  --glass-blur: blur(20px);
  --glass-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.06);

  /* Typography */
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;

  /* Feedback Colors */
  --success: #10b981;
  --error: #ef4444;
  --warning: #f59e0b;
  --info: #3b82f6;

  /* Layout */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   RESET & STRICT ZERO HORIZONTAL SCROLLBAR
   ========================================================================== */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  scrollbar-width: none !important; /* Firefox */
  -ms-overflow-style: none !important; /* IE/Edge */
}

*::-webkit-scrollbar {
  display: none !important; /* Chrome, Safari, Opera */
  width: 0 !important;
  height: 0 !important;
}

html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden !important;
  position: relative;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--bg-dark);
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-dark);
  background-image: var(--grad-glow);
  background-attachment: fixed;
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

button, input {
  font-family: inherit;
  border: none;
  outline: none;
  background: none;
}

img, video, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ==========================================================================
   LAYOUT CONTAINERS
   ========================================================================== */

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
}

.section {
  padding: 60px 0;
  position: relative;
  width: 100%;
  overflow: hidden;
}

/* ==========================================================================
   GLASSMORPHISM NAVBAR
   ========================================================================== */

.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(7, 9, 14, 0.85);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--border-glass);
  padding: 14px 0;
  width: 100%;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.5px;
  flex-shrink: 0;
}

.logo-icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.logo-text {
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo-badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: var(--radius-pill);
  background: rgba(217, 70, 239, 0.15);
  color: #d946ef;
  border: 1px solid rgba(217, 70, 239, 0.3);
  font-weight: 700;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
}

.nav-link {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  transition: var(--transition-fast);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
}

.nav-cta {
  background: var(--grad-primary);
  color: #fff;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 4px 15px rgba(217, 70, 239, 0.3);
  transition: var(--transition-fast);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(217, 70, 239, 0.45);
}

.menu-btn {
  display: none;
  cursor: pointer;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  align-items: center;
  justify-content: center;
  color: var(--text-main);
  flex-shrink: 0;
}

/* ==========================================================================
   HERO & DOWNLOADER FORM
   ========================================================================== */

.hero {
  text-align: center;
  padding: 45px 0 30px;
  position: relative;
  width: 100%;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 7px 16px;
  background: rgba(217, 70, 239, 0.08);
  border: 1px solid rgba(217, 70, 239, 0.3);
  border-radius: var(--radius-pill);
  font-size: 12.5px;
  font-weight: 600;
  color: #f0abfc;
  margin-bottom: 22px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 0 22px rgba(217, 70, 239, 0.16);
  white-space: nowrap;
  max-width: calc(100vw - 32px);
  transition: all var(--transition-fast);
}

.hero-pill:hover {
  border-color: rgba(217, 70, 239, 0.55);
  box-shadow: 0 0 28px rgba(217, 70, 239, 0.28);
  transform: translateY(-1px);
}

.hero-pill svg {
  color: #38bdf8;
  flex-shrink: 0;
}

.hero-pill .pill-dot {
  color: #d946ef;
  opacity: 0.7;
  font-size: 10px;
  margin: 0 2px;
}

.pill-text-mobile {
  display: none;
}

@media (max-width: 540px) {
  .hero-pill {
    padding: 6px 14px;
    font-size: 12px;
    gap: 6px;
    margin-bottom: 18px;
  }

  .pill-text-desktop {
    display: none;
  }

  .pill-text-mobile {
    display: inline;
    white-space: nowrap;
  }
}

.hero-title {
  font-size: clamp(26px, 5vw, 48px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
  letter-spacing: -0.8px;
  word-break: break-word;
}

.hero-title span {
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: clamp(14px, 2.5vw, 17px);
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 30px;
  padding: 0 10px;
  font-weight: 400;
}

/* ==========================================================================
   INTERACTIVE GLASS INPUT BOX
   ========================================================================== */

.downloader-card {
  max-width: 740px;
  margin: 0 auto;
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 10px;
  box-shadow: var(--glass-shadow);
  transition: var(--transition-smooth);
  width: 100%;
}

.downloader-card:focus-within {
  border-color: var(--border-glass-hover);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6), 0 0 25px rgba(217, 70, 239, 0.2);
}

.input-form {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.input-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  position: relative;
  min-width: 0; /* Prevents overflow */
}

.input-icon {
  color: var(--text-dim);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.url-input {
  width: 100%;
  min-width: 0;
  padding: 14px 0;
  font-size: 15px;
  color: var(--text-main);
  background: transparent;
}

.url-input::placeholder {
  color: var(--text-dim);
}

.action-btns {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.paste-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
  white-space: nowrap;
}

.paste-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
}

.clear-btn {
  display: none;
  padding: 6px;
  color: var(--text-dim);
  cursor: pointer;
  border-radius: 50%;
  flex-shrink: 0;
}

.clear-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.1);
}

.submit-btn {
  padding: 12px 24px;
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-fast);
  box-shadow: 0 4px 15px rgba(217, 70, 239, 0.35);
  white-space: nowrap;
  flex-shrink: 0;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(217, 70, 239, 0.5);
}

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

.submit-btn.loading {
  pointer-events: none;
  opacity: 0.85;
}

/* Feature badges under input */
.badges-row {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin-top: 22px;
  font-size: 12px;
  color: var(--text-muted);
  padding: 0 10px;
}

.badge-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  flex-shrink: 0;
}

/* ==========================================================================
   LOADER & SKELETON STATE
   ========================================================================== */

/* ==========================================================================
   LOADER & MODERN SKELETON LOADING SYSTEM
   ========================================================================== */

.loader-container {
  display: none;
  max-width: 780px;
  margin: 20px auto 0;
  text-align: center;
  padding: 16px 20px;
  background: rgba(13, 17, 28, 0.85);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  backdrop-filter: var(--glass-blur);
  width: 100%;
}

.spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(217, 70, 239, 0.15);
  border-top-color: #d946ef;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 10px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loader-text {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 2px;
}

.loader-subtext {
  font-size: 12px;
  color: var(--text-muted);
}

/* Skeleton Shimmer System */
.skeleton-box {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-sm);
}

.skeleton-box::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.12) 50%,
    transparent 100%
  );
  animation: skeletonShimmer 1.5s infinite ease-in-out;
}

@keyframes skeletonShimmer {
  100% {
    transform: translateX(100%);
  }
}

.skeleton-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-shadow);
  width: 100%;
  animation: pulseGlow 2s infinite ease-in-out;
}

@keyframes pulseGlow {
  0%, 100% { border-color: var(--border-glass); }
  50% { border-color: rgba(217, 70, 239, 0.35); }
}

/* Profile Skeleton Specifics */
.skeleton-profile-header {
  display: flex;
  align-items: flex-start;
  gap: 22px;
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-glass);
}

.skeleton-avatar {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  flex-shrink: 0;
}

.skeleton-info-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.skeleton-line {
  height: 16px;
  border-radius: 6px;
}

.skeleton-line-title {
  width: 45%;
  height: 22px;
}

.skeleton-line-name {
  width: 28%;
  height: 14px;
}

.skeleton-line-pill {
  width: 120px;
  height: 28px;
  border-radius: var(--radius-pill);
}

.skeleton-actions-row {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}

.skeleton-btn {
  height: 38px;
  border-radius: var(--radius-md);
}

.skeleton-tabs-bar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  margin: 20px 0 16px;
  border-bottom: 1px solid var(--border-glass);
  padding: 4px 4px 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.skeleton-tabs-bar::-webkit-scrollbar {
  display: none;
}

.skeleton-tab-item {
  width: 76px;
  height: 30px;
  border-radius: var(--radius-pill);
  flex-shrink: 0;
}

@media (min-width: 641px) {
  .skeleton-tabs-bar {
    justify-content: center;
    gap: 12px;
  }

  .skeleton-tab-item {
    width: 95px;
    height: 34px;
  }
}

.skeleton-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: 100%;
}

.skeleton-grid-item {
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-md);
}

/* Media / Single Reel Skeleton Specifics */
.skeleton-media-preview {
  width: 100%;
  aspect-ratio: 1 / 1;
  max-height: 480px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.skeleton-play-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
}

.skeleton-dl-btn {
  width: 100%;
  height: 48px;
  border-radius: var(--radius-md);
  margin-top: 12px;
}

/* ==========================================================================
   RESULT CARD SECTION
   ========================================================================== */

.result-section {
  display: none;
  max-width: 780px;
  margin: 25px auto 0;
  animation: fadeIn 0.4s ease forwards;
  width: 100%;
}

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

.result-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 22px;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-shadow);
  width: 100%;
}

.result-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-glass);
  flex-wrap: wrap;
  gap: 10px;
}

.result-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-pill);
  color: #34d399;
  font-size: 12px;
  font-weight: 700;
}

.caption-box {
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
  line-height: 1.5;
  word-break: break-word;
}

/* Single Media Box */
.single-media-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
}

.media-preview-container {
  width: 100%;
  max-width: 400px;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-glass);
  background: #000;
}

.media-preview-container video,
.media-preview-container img {
  width: 100%;
  max-height: 480px;
  display: block;
  object-fit: cover;
}

.download-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  max-width: 400px;
  padding: 14px 20px;
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(217, 70, 239, 0.4);
  transition: var(--transition-fast);
  text-align: center;
}

/* Carousel Media Grid */
.carousel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
  gap: 16px;
  width: 100%;
}

.carousel-card {
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition-fast);
}

@media (hover: hover) and (pointer: fine) {
  .download-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(217, 70, 239, 0.55);
  }

  .carousel-card:hover {
    border-color: var(--border-glass-hover);
    transform: translateY(-3px);
  }
}

.carousel-thumb {
  width: 100%;
  height: 220px;
  object-fit: cover;
  background: #000;
}

.carousel-card-body {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.carousel-type-tag {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: #d946ef;
  display: flex;
  align-items: center;
  gap: 4px;
}

.carousel-btn {
  padding: 10px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: var(--transition-fast);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.carousel-btn:hover {
  background: var(--grad-primary);
  border-color: transparent;
  color: #fff;
}

/* Download All Multi-Media Button */
.download-all-box {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border-glass);
  display: flex;
  justify-content: center;
  width: 100%;
}

.download-all-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 440px;
  padding: 16px 24px;
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 25px rgba(217, 70, 239, 0.45);
  transition: var(--transition-fast);
}

.download-all-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 35px rgba(217, 70, 239, 0.6);
}

.download-all-btn.loading, .carousel-btn.loading, .download-action-btn.loading {
  pointer-events: none;
  opacity: 0.85;
}

/* ==========================================================================
   INSTAGRAM PROFILE CARD & 3-COLUMN SQUARE FEED GRID
   ========================================================================== */

.profile-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-shadow);
  width: 100%;
}

.profile-header-box {
  display: flex;
  align-items: flex-start;
  gap: 22px;
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-glass);
}

.profile-avatar-wrapper {
  flex-shrink: 0;
}

.profile-story-ring {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  padding: 3px;
  background: var(--grad-instagram);
  box-shadow: 0 0 25px rgba(217, 70, 239, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
}

.profile-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #111;
  border: 2px solid var(--bg-dark);
  display: block;
}

.profile-info-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.profile-title-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  flex-wrap: wrap;
  width: 100%;
}

.profile-username {
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.3px;
  word-break: break-word;
}

.verified-icon {
  width: 18px;
  height: 18px;
  color: #38bdf8;
  flex-shrink: 0;
}

.account-status-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  text-transform: uppercase;
}

.profile-fullname {
  font-size: 15px;
  font-weight: 700;
  color: #f1f5f9;
  line-height: 1.3;
  text-align: left;
  margin: 0;
  display: block;
  width: 100%;
}

/* Stats Row (Clean Single Pill) */
.profile-stats-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  margin-top: 2px;
  width: 100%;
}

.stat-pill-clean {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  font-size: 13px;
  width: fit-content;
}

.stat-pill-clean strong {
  color: var(--text-main);
  font-weight: 800;
}

/* Profile Action Buttons */
.profile-actions-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 6px;
}

.dp-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(217, 70, 239, 0.35);
  transition: var(--transition-fast);
}

.dp-download-btn.loading {
  pointer-events: none;
  opacity: 0.85;
}

.dp-download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(217, 70, 239, 0.5);
}

.ig-profile-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 600;
  transition: var(--transition-fast);
}

.ig-profile-link-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
}

/* Instagram Switchable Tabs Bar (Posts / Reels / Stories / Highlights) */
.profile-tabs-bar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  margin: 20px 0 16px;
  border-bottom: 1px solid var(--border-glass);
  padding: 4px 4px 12px;
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge */
  -webkit-overflow-scrolling: touch;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.profile-tabs-bar::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.profile-tab-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 15px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--transition-fast);
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.profile-tab-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
}

.profile-tab-btn.active {
  color: #fff;
  background: rgba(217, 70, 239, 0.2);
  border-color: rgba(217, 70, 239, 0.55);
  box-shadow: 0 0 16px rgba(217, 70, 239, 0.3);
}

.profile-tab-btn svg {
  flex-shrink: 0;
  width: 15px;
  height: 15px;
}

.profile-tab-count {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-dim);
}

.profile-tab-btn.active .profile-tab-count {
  background: rgba(217, 70, 239, 0.3);
  color: #fff;
}

@media (min-width: 641px) {
  .profile-tabs-bar {
    justify-content: center;
    gap: 12px;
  }

  .profile-tab-btn {
    padding: 9px 18px;
    font-size: 13px;
  }
}

/* 3-Column Instagram Square Feed Grid */
.ig-feed-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: 100%;
  min-height: 120px;
}

/* Load More Section */
.load-more-box {
  display: flex;
  justify-content: center;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--border-glass);
  width: 100%;
}

.load-more-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass-hover);
  border-radius: var(--radius-pill);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  backdrop-filter: var(--glass-blur);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: var(--transition-fast);
}

.load-more-btn:hover {
  background: var(--grad-primary);
  color: #fff;
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(217, 70, 239, 0.4);
}

.load-more-btn.loading {
  pointer-events: none;
  opacity: 0.75;
}

.ig-square-card {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #000;
  border: 1px solid var(--border-glass);
  cursor: pointer;
}

.ig-square-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.ig-square-card:hover .ig-square-img {
  transform: scale(1.05);
}

.ig-type-badge-corner {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}

/* Hover Overlay - Desktop Only */
.ig-square-overlay {
  display: none;
}

@media (hover: hover) and (pointer: fine) {
  .ig-square-card:hover .ig-square-img {
    transform: scale(1.05);
  }

  .ig-square-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    background: rgba(7, 9, 14, 0.75);
    backdrop-filter: blur(4px);
    opacity: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px;
    transition: opacity var(--transition-fast);
    pointer-events: none;
  }

  .ig-square-card:hover .ig-square-overlay {
    opacity: 1;
  }

  .ig-overlay-stats {
    display: flex;
    align-items: center;
    gap: 14px;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
  }

  .ig-stat-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
  }

  .ig-quick-dl {
    padding: 8px 16px;
    background: var(--grad-primary);
    color: #fff;
    border-radius: var(--radius-pill);
    font-size: 13px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 15px rgba(217, 70, 239, 0.5);
    transition: transform var(--transition-fast);
  }

  .ig-quick-dl:hover {
    transform: scale(1.06);
  }
}

/* Touch & Mobile Active Tap Feedback (Never Sticky) */
.ig-square-card:active {
  transform: scale(0.96);
  opacity: 0.9;
  transition: transform 0.1s ease, opacity 0.1s ease;
}

.carousel-card:active {
  transform: scale(0.98);
}

.submit-btn:active,
.download-action-btn:active,
.download-all-btn:active,
.dp-download-btn:active,
.modal-dl-btn:active,
.load-more-btn:active,
.paste-btn:active {
  transform: scale(0.97) !important;
  opacity: 0.92;
}

/* ==========================================================================
   INSTAGRAM MEDIA PREVIEW MODAL (Popup Dialog)
   ========================================================================== */

.media-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(4, 6, 10, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.media-modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.media-modal-card {
  background: rgba(13, 17, 28, 0.95);
  border: 1px solid var(--border-glass-hover);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.85), 0 0 40px rgba(217, 70, 239, 0.15);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.92) translateY(20px);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.media-modal-backdrop.active .media-modal-card {
  transform: scale(1) translateY(0);
}

/* Modal Header */
.media-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-glass);
  background: rgba(0, 0, 0, 0.25);
}

.modal-meta-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.modal-type-tag {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: rgba(217, 70, 239, 0.15);
  color: #d946ef;
  border: 1px solid rgba(217, 70, 239, 0.3);
}

.modal-stats-pill {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.modal-close-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
}

.modal-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  transform: rotate(90deg);
}

/* Modal Media Body - Stable Zero-Collapse Container */
.media-modal-body {
  position: relative;
  background: #06080e;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  width: 100%;
  height: 420px;
  min-height: 380px;
  max-height: 60vh;
}

@media (max-width: 480px) {
  .media-modal-body {
    height: 360px;
    min-height: 320px;
  }
}

.modal-media-player {
  width: 100%;
  height: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
  transition: opacity 0.3s ease-in-out;
}

.modal-media-player.modal-media-loading {
  opacity: 0;
}

/* Modern Colorful Glowing Instagram Spinner Loader Overlay */
.modal-media-loader {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: rgba(6, 8, 14, 0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 8;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.spinner-ring-wrapper {
  position: relative;
  width: 62px;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.colorful-spinner-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 3.5px solid rgba(255, 255, 255, 0.08);
  border-top-color: #d946ef;
  border-right-color: #8b5cf6;
  border-bottom-color: #06b6d4;
  border-left-color: #10b981;
  animation: colorfulSpin 0.85s linear infinite;
  box-shadow: 0 0 25px rgba(217, 70, 239, 0.5);
  box-sizing: border-box;
}

.spinner-center-icon {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
}

.spinner-center-icon svg {
  width: 24px;
  height: 24px;
  stroke: #f472b6;
  animation: iconColorGlow 1.8s ease-in-out infinite;
  filter: drop-shadow(0 0 8px rgba(217, 70, 239, 0.9));
}

@keyframes iconColorGlow {
  0%, 100% {
    transform: scale(1);
    stroke: #f472b6;
    filter: drop-shadow(0 0 8px rgba(217, 70, 239, 0.9));
  }
  50% {
    transform: scale(1.15);
    stroke: #38bdf8;
    filter: drop-shadow(0 0 12px rgba(56, 189, 248, 0.95));
  }
}

@keyframes colorfulSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loader-status-text {
  font-size: 12px;
  font-weight: 700;
  color: #f1f5f9;
  letter-spacing: 0.5px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

/* Modal Slider Navigation Arrows */
.modal-slide-counter {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 10;
  padding: 4px 12px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.modal-nav-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  transition: var(--transition-fast);
  user-select: none;
}

.modal-nav-arrow:hover {
  background: var(--grad-primary);
  border-color: transparent;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 6px 20px rgba(217, 70, 239, 0.6);
}

.modal-nav-arrow:active {
  transform: translateY(-50%) scale(0.92);
}

.modal-prev-btn {
  left: 12px;
}

.modal-next-btn {
  right: 12px;
}

/* Modal Caption Preview */
.modal-caption-box {
  padding: 10px 18px;
  font-size: 13px;
  line-height: 1.4;
  color: var(--text-muted);
  max-height: 70px;
  overflow-y: auto;
  background: rgba(0, 0, 0, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
}

/* Modal Footer Actions */
.media-modal-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-top: 1px solid var(--border-glass);
  background: rgba(0, 0, 0, 0.35);
  flex-wrap: wrap;
}

.modal-dl-btn {
  flex: 1;
  min-width: 160px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(217, 70, 239, 0.45);
  transition: var(--transition-fast);
}

.modal-dl-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(217, 70, 239, 0.6);
}

.modal-dl-all-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-fast);
  white-space: nowrap;
}

.modal-dl-all-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.modal-dl-btn.loading {
  pointer-events: none;
  opacity: 0.85;
}

.modal-ig-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 16px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  transition: var(--transition-fast);
  white-space: nowrap;
}

.modal-ig-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
}

/* ==========================================================================
   FEATURES GRID SECTION
   ========================================================================== */

.section-header {
  text-align: center;
  margin-bottom: 40px;
  padding: 0 10px;
}

.section-subtitle {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #d946ef;
  margin-bottom: 6px;
}

.section-title {
  font-size: clamp(24px, 4vw, 36px);
  font-weight: 800;
  letter-spacing: -0.6px;
  line-height: 1.25;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 20px;
  width: 100%;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 26px;
  backdrop-filter: var(--glass-blur);
  transition: var(--transition-smooth);
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glass-hover);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.feature-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(217, 70, 239, 0.12);
  border: 1px solid rgba(217, 70, 239, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.feature-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-desc {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.55;
}

/* ==========================================================================
   HOW TO USE STEPS
   ========================================================================== */

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 20px;
  width: 100%;
}

.step-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 24px;
  position: relative;
}

.step-number {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--grad-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 14px;
}

.step-title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 6px;
}

.step-desc {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.5;
}

/* ==========================================================================
   FAQ ACCORDION
   ========================================================================== */

.faq-container {
  max-width: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition-fast);
}

.faq-item.active {
  border-color: var(--border-glass-hover);
}

.faq-question {
  width: 100%;
  padding: 16px 20px;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  gap: 10px;
}

.faq-icon {
  font-size: 18px;
  transition: transform var(--transition-smooth);
  color: #d946ef;
  flex-shrink: 0;
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-smooth);
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.55;
}

.faq-answer-inner {
  padding: 0 20px 16px;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */

.footer {
  margin-top: auto;
  border-top: 1px solid var(--border-glass);
  background: rgba(5, 7, 10, 0.95);
  padding: 45px 0 25px;
  width: 100%;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 30px;
  margin-bottom: 30px;
  width: 100%;
}

.footer-desc {
  color: var(--text-muted);
  font-size: 13px;
  max-width: 360px;
  margin-top: 10px;
  line-height: 1.5;
}

.footer-col-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-link {
  color: var(--text-muted);
  font-size: 13px;
}

.footer-link:hover {
  color: #d946ef;
}

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid var(--border-glass);
  text-align: center;
  font-size: 12px;
  color: var(--text-dim);
}

/* ==========================================================================
   MODERN FLOATING TOAST NOTIFICATIONS (MOBILE & DESKTOP)
   ========================================================================== */

.toast-container {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
  max-width: calc(100vw - 32px);
}

@media (max-width: 480px) {
  .toast-container {
    top: 14px;
    right: 14px;
    left: 14px;
    align-items: center;
  }
}

.toast {
  pointer-events: auto;
  width: auto;
  min-width: 270px;
  max-width: 420px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  background: rgba(14, 18, 30, 0.96);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-main);
  font-size: 13px;
  font-weight: 500;
  animation: toastSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transition: all var(--transition-fast);
  word-break: break-word;
}

.toast.hiding {
  opacity: 0;
  transform: translateX(100%);
}

.toast-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast-icon svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  display: block;
}

.toast-text {
  flex: 1;
  line-height: 1.4;
  color: #f1f5f9;
  font-weight: 600;
}

.toast.success { 
  border-color: rgba(16, 185, 129, 0.45); 
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px rgba(16, 185, 129, 0.15);
}
.toast.success .toast-icon { color: #10b981; }

.toast.error { 
  border-color: rgba(239, 68, 68, 0.45); 
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px rgba(239, 68, 68, 0.15);
}
.toast.error .toast-icon { color: #ef4444; }

.toast.warning { 
  border-color: rgba(245, 158, 11, 0.45); 
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.15);
}
.toast.warning .toast-icon { color: #f59e0b; }

.toast.info { 
  border-color: rgba(56, 189, 248, 0.45); 
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6), 0 0 20px rgba(56, 189, 248, 0.15);
}
.toast.info .toast-icon { color: #38bdf8; }

@keyframes toastSlideIn {
  from { opacity: 0; transform: translateY(-8px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ==========================================================================
   MOBILE-ONLY PWA INSTALL BOTTOM PROMPT BANNER
   ========================================================================== */

.pwa-install-banner {
  position: fixed;
  bottom: 14px;
  left: 12px;
  right: 12px;
  z-index: 99999;
  background: rgba(10, 14, 26, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(217, 70, 239, 0.38);
  border-radius: 16px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.85), 0 0 24px rgba(217, 70, 239, 0.25);
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  animation: pwaSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  box-sizing: border-box;
}

/* Hide on Desktop - Show only on Mobile */
@media (min-width: 769px) {
  .pwa-install-banner {
    display: none !important;
  }
}

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

.pwa-install-content {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.pwa-icon-wrap {
  width: 36px;
  height: 36px;
  min-width: 36px;
  flex-shrink: 0;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 10px rgba(217, 70, 239, 0.3);
}

.pwa-app-icon {
  width: 26px;
  height: 26px;
  object-fit: contain;
  display: block;
}

.pwa-text-box {
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.pwa-title {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.pwa-subtitle {
  font-size: 10.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.pwa-btn-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.pwa-install-btn {
  background: var(--grad-primary);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-pill);
  padding: 0 14px;
  height: 34px;
  font-size: 12px;
  font-weight: 700;
  display: inline-flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(217, 70, 239, 0.45);
  transition: var(--transition-fast);
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  line-height: 1;
  box-sizing: border-box;
}

.pwa-install-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(217, 70, 239, 0.65);
}

.pwa-install-btn svg {
  width: 14px;
  height: 14px;
  color: #ffffff;
  flex-shrink: 0;
  display: block;
}

.pwa-install-btn span {
  display: inline-block;
  white-space: nowrap;
  line-height: 1;
}

.pwa-dismiss-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition-fast);
  flex-shrink: 0;
  padding: 0;
  box-sizing: border-box;
}

.pwa-dismiss-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.pwa-dismiss-btn svg {
  width: 13px;
  height: 13px;
  color: currentColor;
  display: block;
}

/* ==========================================================================
   PERFECT RESPONSIVE BREAKPOINTS (TABLET & MOBILE)
   ========================================================================== */

@media (max-width: 860px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px 20px;
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 680px) {
  .container {
    padding: 0 16px;
  }

  .nav-links {
    display: none;
  }

  /* Hide Quick Guide CTA in top navbar on mobile for clean, uncluttered layout */
  .nav-cta {
    display: none !important;
  }

  .menu-btn {
    display: flex;
  }

  .hero {
    padding: 28px 0 20px;
  }

  .downloader-card {
    padding: 8px;
    border-radius: var(--radius-md);
  }

  .input-form {
    flex-direction: column;
    gap: 8px;
    width: 100%;
  }

  .input-wrapper {
    width: 100%;
    padding: 2px 8px;
  }

  .url-input {
    padding: 10px 0;
    font-size: 14px;
  }

  .action-btns {
    width: 100%;
    display: flex;
    gap: 8px;
  }

  .paste-btn {
    flex: 1;
    justify-content: center;
    padding: 12px;
    font-size: 14px;
  }

  .submit-btn {
    flex: 2;
    justify-content: center;
    padding: 12px;
    font-size: 14px;
  }

  .badges-row {
    gap: 8px 12px;
    font-size: 11px;
  }

  /* Footer 2-Column Side-by-Side on Mobile */
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 24px 16px;
  }

  .footer-brand {
    grid-column: 1 / -1;
    margin-bottom: 4px;
  }

  .footer-col-title {
    font-size: 13px;
    margin-bottom: 10px;
  }

  .footer-links {
    gap: 7px;
  }

  .footer-link {
    font-size: 12px;
  }

  /* Profile Card Mobile Responsive */
  .profile-card {
    padding: 16px;
  }

  .profile-header-box {
    gap: 16px;
    margin-bottom: 16px;
    padding-bottom: 16px;
  }

  .profile-story-ring {
    width: 76px;
    height: 76px;
  }

  .profile-username {
    font-size: 17px;
  }

  .profile-fullname {
    font-size: 14px;
  }

  .profile-stats-row {
    gap: 10px;
    margin-top: 2px;
  }

  .stat-pill-clean {
    font-size: 12px;
    padding: 4px 10px;
  }

  /* Profile Action Buttons Mobile Optimization */
  .profile-actions-row {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    margin-top: 8px;
  }

  .dp-download-btn {
    flex: 1.2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 12px 14px;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
    border-radius: var(--radius-md);
    min-height: 44px;
  }

  .ig-profile-link-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 12px 12px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    border-radius: var(--radius-md);
    min-height: 44px;
  }

  /* Profile Tabs Mobile Touch Optimization */
  .profile-tabs-bar {
    justify-content: flex-start;
    gap: 6px;
    padding: 2px 2px 10px;
    margin: 16px 0 14px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .profile-tab-btn {
    padding: 7px 13px;
    font-size: 11.5px;
    gap: 5px;
  }

  .profile-tab-btn svg {
    width: 13px;
    height: 13px;
  }

  .ig-feed-grid {
    gap: 4px;
  }

  .ig-square-card {
    border-radius: 6px;
  }

  .ig-type-badge-corner {
    width: 22px;
    height: 22px;
    top: 4px;
    right: 4px;
  }

  .ig-type-badge-corner svg {
    width: 12px;
    height: 12px;
  }

  .toast-container {
    left: 12px;
    right: 12px;
    top: 12px;
    align-items: center;
    max-width: calc(100vw - 24px);
  }

  .toast {
    min-width: unset;
    width: 100%;
    max-width: 100%;
  }
}

/* Extra Small Mobile Devices (e.g. 360px - 440px) */
@media (max-width: 440px) {
  .profile-actions-row {
    flex-direction: column;
    gap: 8px;
  }

  .dp-download-btn, .ig-profile-link-btn {
    width: 100%;
    flex: unset;
    min-height: 44px;
    padding: 12px 16px;
    font-size: 13px;
  }

  .media-modal-footer {
    flex-direction: column;
    gap: 8px;
    padding: 12px 14px;
  }

  .modal-dl-btn, .modal-dl-all-btn, .modal-ig-btn {
    width: 100%;
    min-height: 44px;
    font-size: 13px;
    justify-content: center;
  }

  .download-action-btn, .download-all-btn {
    padding: 14px 16px;
    font-size: 14px;
    min-height: 48px;
  }
}

/* ==========================================================================
   PWA INSTALL FLOATING PROMPT BANNER
   ========================================================================== */

.pwa-install-banner {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 20px;
  max-width: 520px;
  width: calc(100% - 32px);
  background: rgba(13, 17, 28, 0.95);
  border: 1px solid rgba(217, 70, 239, 0.4);
  border-radius: var(--radius-lg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.7), 0 0 25px rgba(217, 70, 239, 0.25);
  animation: pwaSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes pwaSlideUp {
  from { opacity: 0; transform: translate(-50%, 30px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

.pwa-install-content {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.pwa-app-icon {
  flex-shrink: 0;
  border-radius: 8px;
}

.pwa-text-box {
  min-width: 0;
}

.pwa-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
}

.pwa-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pwa-btn-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.pwa-install-btn {
  padding: 8px 16px;
  background: var(--grad-primary);
  color: #fff;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(217, 70, 239, 0.35);
  transition: var(--transition-fast);
  white-space: nowrap;
}

.pwa-install-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(217, 70, 239, 0.5);
}

.pwa-dismiss-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
}

.pwa-dismiss-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

/* ==========================================================================
   🎵 REELS AUDIO / MP3 EXTRACTOR BUTTONS
   ========================================================================== */

.download-audio-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 13px 20px;
  background: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(6, 182, 212, 0.35);
  transition: var(--transition-fast);
  margin-top: 10px;
}

.download-audio-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(6, 182, 212, 0.5);
}

.download-audio-btn.loading {
  pointer-events: none;
  opacity: 0.85;
}

.modal-audio-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.2) 0%, rgba(59, 130, 246, 0.2) 100%);
  border: 1px solid rgba(6, 182, 212, 0.4);
  color: #38bdf8;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-fast);
  white-space: nowrap;
}

.modal-audio-btn:hover {
  background: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
  color: #fff;
  border-color: transparent;
}

.modal-audio-btn.loading {
  pointer-events: none;
  opacity: 0.85;
}

/* Tab Badge Counter */
.tab-count-pill {
  font-size: 11px;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: var(--radius-pill);
  background: rgba(217, 70, 239, 0.25);
  color: #f472b6;
  border: 1px solid rgba(217, 70, 239, 0.35);
  margin-left: 4px;
}

.story-indicator-ring {
  box-shadow: 0 0 15px rgba(244, 63, 94, 0.4);
  border: 2px solid #f43f5e;
}

/* ==========================================================================
   💰 MONETIZATION / GOOGLE ADSENSE SLOTS
   ========================================================================== */

.ad-slot-container {
  max-width: 780px;
  margin: 25px auto;
  padding: 14px 18px;
  background: rgba(13, 17, 28, 0.7);
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  text-align: center;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  position: relative;
  overflow: hidden;
}

.ad-label {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-dim);
  margin-bottom: 8px;
  text-transform: uppercase;
}

.ad-banner-box {
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ad-slot-mid {
  margin: 20px auto;
}

.ad-slot-footer {
  margin: 30px auto;
}
