:root {
  --bg-1: #0b0712;
  --bg-2: #1a1030;
  --card: rgba(255, 255, 255, 0.1);
  --stroke: rgba(255, 255, 255, 0.15);
  --text: #ffffff;
  --muted: #c4c1d3;
  --accent: #9b59b6;
  --accent-2: #c185e4;
  --yellow-accent: #f7e05a;
  --yellow-accent-2: #ffeb99;
  --radius: 24px;
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

@keyframes glow-pulse {
  0%, 100% { box-shadow: 0 0 20px rgba(155, 89, 182, 0.3); }
  50% { box-shadow: 0 0 30px rgba(155, 89, 182, 0.6); }
}

@keyframes shimmer {
  0% { background-position: -1000px 0; }
  100% { background-position: 1000px 0; }
}

@keyframes gradient-shift {
  0%, 100% { 
    background-position: 0% 50%; 
  }
  50% { 
    background-position: 100% 50%; 
  }
}

@keyframes subtle-float {
  0%, 100% { 
    transform: translateY(0px) scale(1); 
  }
  50% { 
    transform: translateY(-8px) scale(1.01); 
  }
}

@keyframes slide-up {
  from { 
    opacity: 0; 
    transform: translateY(30px); 
  }
  to { 
    opacity: 1; 
    transform: translateY(0); 
  }
}

* {
  box-sizing: border-box;
}

*:focus-visible {
  outline: 2px solid rgba(155, 89, 182, 0.6);
  outline-offset: 2px;
}

html, body {
  height: 100%;
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background: radial-gradient(1100px 700px at 20% 0%, var(--bg-2), transparent),
              radial-gradient(900px 700px at 80% 100%, #12091f, transparent),
              linear-gradient(180deg, var(--bg-1), #0a0813 70%);
  overflow-x: hidden;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: "kern" 1, "liga" 1;
}

/* Back to Main Site Button */
.back-to-main {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 1000;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.back-to-main:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(155, 89, 182, 0.5);
  transform: translateX(-4px);
  box-shadow: 0 6px 24px rgba(155, 89, 182, 0.3);
}

.back-to-main svg {
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.back-to-main:hover svg {
  transform: translateX(-3px);
}

.container {
  width: min(1120px, 94%);
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

.logo {
  width: 400px;
  opacity: 0.95;
  display: block;
  margin: 32px auto 16px;
  animation: slide-up 0.8s ease-out;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.logo:hover {
  transform: scale(1.02);
  opacity: 1;
}

.card {
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px) saturate(170%);
  -webkit-backdrop-filter: blur(20px) saturate(170%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), 
              box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1),
              border-color 0.3s ease;
}

.card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.4), 
              0 0 0 1px rgba(155, 89, 182, 0.2),
              inset 0 1px 0 rgba(255, 255, 255, 0.12);
  border-color: rgba(155, 89, 182, 0.3);
}

.hero {
  padding: 32px;
  text-align: center;
  animation: slide-up 0.8s ease-out 0.2s both;
}

.hero h1 {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  margin: 0 0 16px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #ffffff 0%, #e0d5ff 50%, #c9b3ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: shimmer 3s ease-in-out infinite;
  background-size: 200% auto;
}

.hero p {
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.125rem);
  line-height: 1.6;
  margin: 0 0 20px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  font-weight: 400;
}

.demo-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 8px 16px;
  background: linear-gradient(135deg, rgba(255, 152, 0, 0.15), rgba(255, 193, 7, 0.1));
  border: 1px solid rgba(255, 152, 0, 0.3);
  border-radius: 999px;
  color: #ffa726;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  animation: pulse-border 2s ease-in-out infinite;
}

.demo-badge.hidden {
  display: none;
}

.upload-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 32px;
  margin-top: 32px;
}

.upload-grid > * {
  animation: slide-up 0.8s ease-out both;
}

.upload-grid > *:nth-child(1) {
  animation-delay: 0.3s;
}

.upload-grid > *:nth-child(2) {
  animation-delay: 0.4s;
}

.upload-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 28px;
  text-align: left;
  height: 100%;
  background: radial-gradient(120% 160% at 0% 0%, rgba(155, 89, 182, 0.18), transparent 60%),
              radial-gradient(140% 160% at 100% 0%, rgba(132, 88, 224, 0.16), transparent 55%),
              rgba(12, 9, 20, 0.72);
  background-size: 200% 200%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 20px 50px rgba(10, 5, 25, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              border-color 0.4s ease;
  animation: gradient-shift 15s ease infinite;
}

.upload-card::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(
    from 0deg at 50% 50%,
    transparent 0deg,
    rgba(155, 89, 182, 0.15) 60deg,
    transparent 120deg
  );
  opacity: 0;
  transition: opacity 0.6s ease, transform 0.6s ease;
  pointer-events: none;
  animation: rotate 8s linear infinite paused;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.upload-card:hover::before {
  opacity: 1;
  animation-play-state: running;
}

.upload-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 45%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.upload-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 28px 64px rgba(10, 5, 25, 0.6), 
              0 0 0 1px rgba(155, 89, 182, 0.4),
              inset 0 1px 0 rgba(255, 255, 255, 0.12);
  border-color: rgba(155, 89, 182, 0.4);
}

.upload-card:hover::after {
  opacity: 1;
}

.upload-card__header {
  display: flex;
  align-items: center;
  gap: 16px;
}

.upload-card__icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  box-shadow: 
    0 8px 16px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  color: #b97aff;
  flex-shrink: 0;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.upload-card__icon::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(185, 122, 255, 0.2), transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.upload-card__icon svg {
  width: 28px;
  height: 28px;
  filter: drop-shadow(0 0 8px rgba(185, 122, 255, 0.4));
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
              filter 0.4s ease;
  position: relative;
  z-index: 1;
}

.upload-card:hover .upload-card__icon {
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 
    0 12px 28px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(185, 122, 255, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  transform: translateY(-3px) rotate(5deg);
}

.upload-card:hover .upload-card__icon::before {
  opacity: 1;
}

.upload-card:hover .upload-card__icon svg {
  filter: drop-shadow(0 0 16px rgba(185, 122, 255, 0.8));
  transform: scale(1.1);
}

.upload-card__title h3 {
  margin: 0;
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.upload-card__title .small {
  margin-top: 6px;
  font-size: 0.9375rem;
  line-height: 1.5;
  font-weight: 400;
  letter-spacing: 0;
}

.upload-card__badge {
  margin-left: auto;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.08));
  color: #0e081a;
  font-weight: 700;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.upload-card:hover .upload-card__badge {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0.12));
}

.upload-card .dropzone {
  margin-top: 4px;
  width: 100%;
  max-width: none;
}

.upload-card .progress {
  margin-top: 16px;
  width: 100%;
  max-width: none;
}

.upload-actions {
  display: flex;
  justify-content: flex-start;
  margin-top: 12px;
}

.upload-actions.hidden {
  display: none;
}

.upload-actions .btn {
  min-width: 120px;
}

/* Upload Result Styles */
.upload-result {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.08) 0%, rgba(56, 142, 60, 0.05) 100%);
  border: 1px solid rgba(76, 175, 80, 0.3);
  border-radius: 16px;
  margin-top: 16px;
  animation: slide-up 0.5s ease-out;
  box-shadow: 0 8px 24px rgba(76, 175, 80, 0.15),
              inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.result-header {
  display: flex;
  align-items: center;
  gap: 16px;
}

.result-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  animation: icon-bounce 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.result-icon.success {
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.25), rgba(56, 142, 60, 0.25));
  border: 2px solid rgba(76, 175, 80, 0.6);
  color: #4caf50;
  box-shadow: 0 4px 16px rgba(76, 175, 80, 0.3);
}

.result-icon svg {
  width: 24px;
  height: 24px;
}

.result-info {
  flex: 1;
}

.result-info h4 {
  margin: 0 0 4px;
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #ffffff;
}

.result-info p {
  margin: 0;
  font-size: 0.875rem;
  opacity: 0.8;
}

.result-link-box {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  transition: all 0.3s ease;
}

.result-link-box:focus-within {
  border-color: rgba(76, 175, 80, 0.5);
  box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.15);
}

.result-link-box input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: #ffffff;
  font-size: 0.9375rem;
  font-family: 'Inter', monospace;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.result-link-box input::selection {
  background: rgba(76, 175, 80, 0.3);
}

.btn-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
}

.btn-icon svg {
  width: 20px;
  height: 20px;
}

.btn-icon:hover {
  background: rgba(76, 175, 80, 0.2);
  border-color: rgba(76, 175, 80, 0.5);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(76, 175, 80, 0.3);
}

.btn-icon:active {
  transform: scale(0.95);
}

.btn-icon.copied {
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.3), rgba(56, 142, 60, 0.3));
  border-color: rgba(76, 175, 80, 0.6);
  color: #4caf50;
  animation: success-pulse 0.5s ease-out;
}

.result-actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.result-actions .btn {
  flex: 1;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.result-actions .btn svg {
  width: 18px;
  height: 18px;
}

.upload-card .actions .btn.ghost {
  border-color: rgba(255, 255, 255, 0.28);
}

.muted {
  color: var(--muted);
  font-size: 0.9375rem;
  line-height: 1.6;
  font-weight: 400;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), 
              box-shadow 0.3s ease, 
              opacity 0.2s ease;
  box-shadow: 0 6px 20px rgba(155, 89, 182, 0.4);
  position: relative;
  overflow: hidden;
  line-height: 1;
  z-index: 10;
}

.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn:hover {
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 10px 30px rgba(155, 89, 182, 0.6), 
              0 0 20px rgba(155, 89, 182, 0.3);
}

.btn:hover::before {
  opacity: 1;
}

.btn:active {
  transform: translateY(0) scale(1.02);
  box-shadow: 0 4px 15px rgba(155, 89, 182, 0.5);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

.btn.loading {
  position: relative;
  pointer-events: none;
}

.btn.loading::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 8px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn.ghost {
  background: transparent;
  border-color: var(--stroke);
  box-shadow: none;
  color: var(--text);
}

.btn.ghost::before {
  background: linear-gradient(135deg, rgba(155, 89, 182, 0.2), rgba(155, 89, 182, 0.05));
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 6px 16px rgba(155, 89, 182, 0.4);
  border-color: rgba(155, 89, 182, 0.4);
}

.dropzone {
  position: relative;
  margin: 0;
  padding: 32px;
  width: 100%;
  border-radius: 14px;
  border: 3px dashed rgba(255, 255, 255, 0.28);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
  outline: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 180px;
  cursor: pointer;
}

.dropzone::before {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 14px;
  padding: 3px;
  background: linear-gradient(135deg, rgba(155, 89, 182, 0.4), rgba(193, 133, 228, 0.4));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.dropzone:hover::before {
  opacity: 0.6;
}

.dz-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  text-align: center;
  padding: 0 20px; /* Added padding for better fit */
  position: relative;
  z-index: 1;
}

.dz-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px; /* Increased gap for better spacing */
  text-align: center;
  max-width: 350px; /* Adjusted for a balanced rectangular look */
  position: relative;
  z-index: 2;
}

.dz-info {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--muted);
  font-weight: 400;
}

.dropzone:hover {
  border-color: rgba(155, 89, 182, 0.5);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.08));
  transform: scale(1.01);
}

.dropzone:focus {
  box-shadow: 0 0 0 3px rgba(155, 89, 182, 0.5);
}

.dropzone.drag {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(155, 89, 182, 0.2), rgba(155, 89, 182, 0.15));
  box-shadow: 0 0 20px rgba(155, 89, 182, 0.6), 
              inset 0 0 20px rgba(155, 89, 182, 0.1);
  transform: scale(1.02);
}

.dropzone.drag::before {
  opacity: 1;
}

.preview {
  margin: 16px auto 8px;
  max-width: 600px;
  display: grid;
  gap: 12px;
  animation: slide-up 0.4s ease-out;
}

.preview img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: #000;
  object-fit: contain;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.preview img:hover {
  transform: scale(1.02);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.preview .meta {
  display: flex;
  gap: 10px;
  justify-content: center;
  color: var(--muted);
  font-size: 0.875rem;
  animation: slide-up 0.4s ease-out 0.1s both;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.preview .meta span {
  transition: color 0.3s ease;
}

.preview .meta span:hover {
  color: var(--text);
}

.bulk-preview {
  margin: 16px auto 8px;
  max-width: 100%;
}

.bulk-preview #bulk-files-list {
  display: grid;
  gap: 12px;
  max-height: 300px;
  overflow-y: auto;
}

.bulk-file-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--stroke);
  border-radius: 12px;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  animation: slide-up 0.3s ease-out both;
}

.bulk-file-item:hover {
  background: rgba(0, 0, 0, 0.4);
  border-color: rgba(155, 89, 182, 0.4);
  transform: translateX(4px);
}

.bulk-file-item img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.bulk-file-item:hover img {
  transform: scale(1.1);
}

.bulk-file-item .file-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.bulk-file-item .file-name {
  color: var(--text);
  font-weight: 500;
  font-size: 0.9375rem;
  letter-spacing: -0.01em;
}

.bulk-file-item .file-size {
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.hidden {
  display: none !important;
}

/* Smooth transitions for visibility changes */
.preview,
.bulk-preview,
.progress,
.upload-actions {
  opacity: 1;
  transition: opacity 0.3s ease;
}

.preview.hidden,
.bulk-preview.hidden,
.progress.hidden,
.upload-actions.hidden {
  opacity: 0;
  pointer-events: none;
}

.progress {
  margin: 14px auto 0;
  width: 100%;
  max-width: none;
  height: 16px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.progress .bar {
  height: 100%;
  background: linear-gradient(90deg, #b97aff, #8e44ad, #b97aff);
  background-size: 200% 100%;
  width: 0%;
  transition: width 0.3s ease-out;
  box-shadow: 0 0 16px rgba(155, 89, 182, 0.6);
  animation: progress-shimmer 2s ease-in-out infinite;
  position: relative;
}

@keyframes progress-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.progress .bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: progress-shine 1.5s ease-in-out infinite;
}

@keyframes progress-shine {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

@keyframes pulse-glow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(155, 89, 182, 0.4);
  }
  50% {
    box-shadow: 0 0 40px rgba(155, 89, 182, 0.8);
  }
}

.progress__label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.95);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
  font-variant-numeric: tabular-nums;
}

.result {
  margin: 20px auto 0;
  max-width: 600px;
  text-align: left;
}

.result label {
  display: block;
  margin: 0 0 8px;
  color: #e7e2f7;
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: -0.01em;
}

.copyline {
  display: flex;
  gap: 10px;
}

.copyline input,
.copyline textarea {
  flex: 1;
  padding: 14px 16px;
  border-radius: 14px;
  color: #e9e6fb;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--stroke);
  outline: none;
  font-size: 0.9375rem;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  line-height: 1.5;
  resize: vertical;
  transition: all 0.3s ease;
}

.copyline input:hover,
.copyline textarea:hover {
  border-color: rgba(155, 89, 182, 0.4);
  background: rgba(0, 0, 0, 0.6);
}

.copyline input:focus,
.copyline textarea:focus {
  border-color: rgba(155, 89, 182, 0.6);
  background: rgba(0, 0, 0, 0.7);
  box-shadow: 0 0 0 3px rgba(155, 89, 182, 0.2);
}

.copyline textarea {
  min-height: 80px;
  max-height: 200px;
}

.actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.grid.info {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  margin: 24px 0 48px;
}

.grid.info .card {
  padding: 20px;
}

.grid.info h3 {
  margin: 0 0 8px;
  font-size: 1.2rem;
  font-weight: 600;
}

.footer {
  padding: 28px 0 48px;
  color: var(--muted);
  text-align: center;
  font-size: 0.875rem;
  animation: slide-up 0.8s ease-out 0.8s both;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.footer hr {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin: 20px 0;
}

.footer p {
  transition: color 0.3s ease;
}

.footer p:hover {
  color: var(--text);
}

#bg-stars {
  position: fixed;
  inset: 0;
  z-index: 0;
  filter: blur(40px);
  opacity: 0.7;
  pointer-events: none;
  will-change: transform;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(155, 89, 182, 0.6), rgba(193, 133, 228, 0.6));
  border-radius: 5px;
  transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(155, 89, 182, 0.8), rgba(193, 133, 228, 0.8));
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(155, 89, 182, 0.6) rgba(0, 0, 0, 0.2);
}

.popup {
  position: fixed;
  top: 30px;
  left: 50%;
  transform: translateX(-50%);
  padding: 16px 32px;
  background: linear-gradient(135deg, var(--yellow-accent), var(--yellow-accent-2));
  color: #1a1030;
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.4;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3), 
              0 0 20px rgba(247, 224, 90, 0.6),
              0 4px 12px rgba(247, 224, 90, 0.4);
  opacity: 1;
  animation: popup-bounce 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  z-index: 1000;
  min-width: 300px;
  text-align: center;
}

@keyframes popup-bounce {
  0% {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px) scale(0.8);
  }
  50% {
    transform: translateX(-50%) translateY(5px) scale(1.05);
  }
  100% {
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

.popup.fade-out {
  opacity: 0;
  animation: fade-out 0.5s ease;
}

@keyframes fade-in {
  from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@keyframes fade-out {
  from { opacity: 1; transform: translateX(-50%) translateY(0); }
  to { opacity: 0; transform: translateX(-50%) translateY(-10px); }
}

/* Features Section Wrapper */
.features-wrapper {
  margin: 80px 0 64px;
}

.features-header {
  text-align: center;
  margin-bottom: 48px;
}

.features-header h2 {
  font-size: clamp(2rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  margin: 0 0 12px;
  background: linear-gradient(135deg, var(--text), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.features-header p {
  font-size: 1.125rem;
  color: var(--muted);
  margin: 0;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.features > * {
  animation: slide-up 0.8s ease-out both;
}

.features > *:nth-child(1) { animation-delay: 0.1s; }
.features > *:nth-child(2) { animation-delay: 0.2s; }
.features > *:nth-child(3) { animation-delay: 0.3s; }
.features > *:nth-child(4) { animation-delay: 0.4s; }
.features > *:nth-child(5) { animation-delay: 0.5s; }
.features > *:nth-child(6) { animation-delay: 0.6s; }

.feature-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
              box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1),
              border-color 0.4s ease;
}

.feature-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 160% at 0% 0%, rgba(155, 89, 182, 0.25), transparent 60%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.feature-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 50px rgba(10, 5, 25, 0.45),
              0 0 0 1px rgba(155, 89, 182, 0.3);
  border-color: rgba(155, 89, 182, 0.3);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  box-shadow: 
    0 8px 16px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  color: #b97aff;
  margin-bottom: 8px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.feature-icon::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(185, 122, 255, 0.25), transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.feature-icon svg {
  width: 32px;
  height: 32px;
  filter: drop-shadow(0 0 8px rgba(185, 122, 255, 0.4));
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
              filter 0.4s ease;
  position: relative;
  z-index: 1;
}

.feature-card:hover .feature-icon {
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 
    0 14px 32px rgba(0, 0, 0, 0.3),
    0 0 24px rgba(185, 122, 255, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  transform: translateY(-4px) scale(1.05);
}

.feature-card:hover .feature-icon::before {
  opacity: 1;
}

.feature-card:hover .feature-icon svg {
  filter: drop-shadow(0 0 18px rgba(185, 122, 255, 0.8));
  transform: scale(1.1) rotate(5deg);
}

.feature-card h3 {
  margin: 0;
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.feature-tag {
  align-self: flex-start;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(155, 89, 182, 0.2);
  border: 1px solid rgba(155, 89, 182, 0.4);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(155, 89, 182, 0.2);
}

.feature-card:hover .feature-tag {
  background: rgba(155, 89, 182, 0.3);
  border-color: rgba(155, 89, 182, 0.6);
  box-shadow: 0 4px 12px rgba(155, 89, 182, 0.4);
  transform: scale(1.05);
}

.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 6, 18, 0.88);
  z-index: 1000;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: fade-in 0.3s ease;
  padding: 20px;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
}

.modal__dialog {
  position: relative;
  background: linear-gradient(135deg, rgba(26, 20, 38, 0.98) 0%, rgba(18, 14, 28, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 32px 80px rgba(6, 3, 14, 0.8),
              0 0 0 1px rgba(155, 89, 182, 0.3),
              inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-radius: 28px;
  padding: 40px;
  width: min(560px, 100%);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  gap: 24px;
  z-index: 1001;
  animation: modal-slide-up 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal__dialog > * {
  position: relative;
  z-index: 1;
}

.modal__dialog::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, 
    transparent 0%, 
    rgba(155, 89, 182, 0.5) 25%, 
    rgba(193, 133, 228, 0.7) 50%, 
    rgba(155, 89, 182, 0.5) 75%, 
    transparent 100%);
  animation: shimmer 3s ease-in-out infinite;
  background-size: 200% 100%;
  border-radius: 28px 28px 0 0;
  overflow: hidden;
}

.modal__dialog::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(155, 89, 182, 0.08), transparent 60%);
  pointer-events: none;
  z-index: -1;
}

@keyframes modal-slide-up {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.25rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.modal__close:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(155, 89, 182, 0.5);
  transform: rotate(90deg) scale(1.1);
  box-shadow: 0 4px 12px rgba(155, 89, 182, 0.3);
}

.modal__close:active {
  transform: rotate(90deg) scale(0.95);
}

.modal__media {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-bottom: 24px;
  margin-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: relative;
}

.modal__media::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(155, 89, 182, 0.3) 50%, transparent);
}

.modal__media img {
  width: 100%;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  object-fit: contain;
  background: linear-gradient(135deg, #0a0712 0%, #05030a 100%);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4),
              inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.modal__media img:hover {
  transform: scale(1.01);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5),
              inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.modal__icon {
  font-size: 3.5rem;
  line-height: 1;
  text-align: center;
  padding: 24px;
  background: radial-gradient(circle at center, rgba(155, 89, 182, 0.2) 0%, rgba(155, 89, 182, 0.08) 40%, transparent 70%);
  border-radius: 24px;
  animation: icon-bounce 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  position: relative;
}

.modal__icon::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 24px;
  border: 1px solid rgba(155, 89, 182, 0.2);
  animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
  0%, 100% {
    opacity: 0.3;
    transform: scale(1);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.02);
  }
}

@keyframes icon-bounce {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.modal__files-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.modal__files-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  background: linear-gradient(135deg, rgba(155, 89, 182, 0.15) 0%, rgba(155, 89, 182, 0.08) 100%);
  border-radius: 12px;
  border: 1px solid rgba(155, 89, 182, 0.2);
  animation: slide-up 0.4s ease-out 0.1s both;
}

.modal__files-count {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 1.125rem;
  font-weight: 600;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.modal__files-label {
  font-size: 0.8125rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.modal__file-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
  max-height: 320px;
  overflow-y: auto;
  padding: 16px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.modal__file-list::-webkit-scrollbar {
  width: 8px;
}

.modal__file-list::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 4px;
}

.modal__file-list::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(155, 89, 182, 0.6), rgba(193, 133, 228, 0.6));
  border-radius: 4px;
  transition: background 0.3s ease;
}

.modal__file-list::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(155, 89, 182, 0.8), rgba(193, 133, 228, 0.8));
}

.modal__file-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.4;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  animation: slide-up 0.3s ease-out both;
  position: relative;
}

.file-checkmark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.2), rgba(56, 142, 60, 0.2));
  border: 2px solid rgba(76, 175, 80, 0.5);
  color: #4caf50;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  animation: checkmark-pop 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55) both;
}

@keyframes checkmark-pop {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.modal__file-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 60%;
  background: linear-gradient(180deg, rgba(155, 89, 182, 0.6), rgba(193, 133, 228, 0.6));
  border-radius: 0 2px 2px 0;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.modal__file-list li:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(155, 89, 182, 0.3);
  transform: translateX(4px);
  box-shadow: 0 2px 8px rgba(155, 89, 182, 0.15);
}

.modal__file-list li:hover::before {
  opacity: 1;
}

.modal__file-list li .file-info {
  flex: 1;
  min-width: 0;
}

.modal__file-list li .file-name {
  font-weight: 500;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.modal__file-list li .muted {
  font-size: 0.75rem;
  opacity: 0.7;
  font-weight: 400;
}

.modal__content {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 4px 0 20px;
  margin-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: relative;
}

.modal__content::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(155, 89, 182, 0.3) 50%, transparent);
}

.modal__title {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 1.75rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0;
  color: #ffffff;
  animation: slide-up 0.4s ease-out 0.1s both;
}

.modal__description {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
  font-weight: 400;
  animation: slide-up 0.4s ease-out 0.15s both;
}

.modal__link {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 8px;
  animation: slide-up 0.4s ease-out 0.2s both;
}

.modal__link .btn {
  flex: 1;
  min-width: 140px;
  justify-content: center;
  align-items: center;
  font-size: 1rem;
  padding: 14px 28px;
  font-weight: 600;
  letter-spacing: -0.01em;
  box-shadow: 0 4px 16px rgba(155, 89, 182, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal__link .btn svg {
  transition: transform 0.3s ease;
}

.modal__link .btn:hover svg {
  transform: translateX(2px);
}

.modal__link .btn.ghost:hover svg {
  transform: scale(1.1);
}

.modal__link .btn:not(.ghost) {
  background: linear-gradient(135deg, #9b59b6 0%, #c185e4 100%);
  position: relative;
  overflow: hidden;
}

.modal__link .btn:not(.ghost)::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal__link .btn:not(.ghost):hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(155, 89, 182, 0.5),
              0 0 20px rgba(155, 89, 182, 0.3);
}

.modal__link .btn:not(.ghost):hover::before {
  opacity: 1;
}

.modal__link .btn.ghost {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: none;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.modal__link .btn.ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(155, 89, 182, 0.5);
  box-shadow: 0 4px 16px rgba(155, 89, 182, 0.25);
  transform: translateY(-2px);
}

.modal__link .btn:active {
  transform: translateY(0) scale(0.98);
}

/* Success state for copy button */
.modal__link .btn.success-state {
  animation: success-pulse 0.5s ease-out;
}

@keyframes success-pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes toast-slide-in {
  from {
    transform: translateX(400px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes toast-slide-out {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(400px);
    opacity: 0;
  }
}

@keyframes toast-progress {
  from {
    width: 100%;
  }
  to {
    width: 0%;
  }
}

body.modal-open {
  overflow: hidden;
}

/* ====== Toast Notifications ====== */
#toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
}

.toast {
  min-width: 320px;
  max-width: 420px;
  padding: 16px 20px;
  background: linear-gradient(135deg, rgba(30, 20, 45, 0.98), rgba(20, 15, 35, 0.98));
  border: 1px solid rgba(155, 89, 182, 0.3);
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4),
              0 0 0 1px rgba(255, 255, 255, 0.05) inset;
  backdrop-filter: blur(20px);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  animation: toast-slide-in 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  pointer-events: auto;
  position: relative;
  overflow: hidden;
}

.toast.removing {
  animation: toast-slide-out 0.3s ease-out forwards;
}

.toast-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin-top: 2px;
}

.toast.success .toast-icon {
  color: #4caf50;
  background: rgba(76, 175, 80, 0.15);
}

.toast.error .toast-icon {
  color: #f44336;
  background: rgba(244, 67, 54, 0.15);
}

.toast.info .toast-icon {
  color: #2196f3;
  background: rgba(33, 150, 243, 0.15);
}

.toast.warning .toast-icon {
  color: #ff9800;
  background: rgba(255, 152, 0, 0.15);
}

.toast-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.toast-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  letter-spacing: -0.01em;
}

.toast-message {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.5;
}

.toast-close {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s ease;
  padding: 0;
}

.toast-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  animation: toast-progress 4s linear forwards;
  border-radius: 0 0 16px 16px;
}

.toast.success .toast-progress {
  background: linear-gradient(90deg, #4caf50, #66bb6a);
}

.toast.error .toast-progress {
  background: linear-gradient(90deg, #f44336, #ef5350);
}

.toast.info .toast-progress {
  background: linear-gradient(90deg, #2196f3, #42a5f5);
}

.toast.warning .toast-progress {
  background: linear-gradient(90deg, #ff9800, #ffa726);
}

/* ====== Expiration Selector ====== */
.expiration-selector {
  margin: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.expiration-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
}

.expiration-options {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.expiration-btn {
  padding: 10px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
}

.expiration-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(155, 89, 182, 0.1), rgba(193, 133, 228, 0.1));
  opacity: 0;
  transition: opacity 0.2s ease;
}

.expiration-btn:hover {
  border-color: rgba(155, 89, 182, 0.4);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  transform: translateY(-1px);
}

.expiration-btn:hover::before {
  opacity: 1;
}

.expiration-btn.active {
  background: linear-gradient(135deg, rgba(155, 89, 182, 0.25), rgba(193, 133, 228, 0.15));
  border-color: rgba(155, 89, 182, 0.6);
  color: var(--text);
  box-shadow: 0 4px 12px rgba(155, 89, 182, 0.25),
              inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.expiration-btn.active::before {
  opacity: 1;
}

/* Expiration Info (non-interactive) */
.expiration-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  margin: 16px 0;
  color: var(--muted);
  font-size: 0.875rem;
}

.expiration-info svg {
  flex-shrink: 0;
  color: var(--accent-2);
}

@media (max-width: 600px) {
  .back-to-main {
    top: 16px;
    left: 16px;
    padding: 8px 14px;
    font-size: 0.8125rem;
  }
  .back-to-main svg {
    width: 16px;
    height: 16px;
  }
  .hero {
    padding: 24px;
  }
  .hero h1 {
    font-size: clamp(32px, 8vw, 44px);
    letter-spacing: -0.02em;
  }
  .hero p {
    font-size: 1rem;
  }
  .upload-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .upload-card {
    padding: 24px;
  }
  .upload-card:hover {
    transform: translateY(-3px) scale(1.01);
  }
  .dropzone {
    padding: 24px;
    min-height: 150px;
    margin: 0;
  }
  .dropzone:hover {
    transform: scale(1.005);
  }
  .dz-inner {
    flex-direction: column;
    gap: 12px;
  }
  .grid.info {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .popup {
    min-width: 80%;
    padding: 12px 20px;
    font-size: 0.9rem;
  }
  #toast-container {
    top: 16px;
    right: 16px;
    left: 16px;
  }
  .toast {
    min-width: 100%;
    max-width: 100%;
  }
  .expiration-options {
    grid-template-columns: repeat(2, 1fr);
  }
  .expiration-btn {
    padding: 8px 12px;
    font-size: 0.8125rem;
  }
  .history-section {
    margin: 32px auto;
    padding: 0 16px;
  }
  .history-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .history-item {
    padding: 12px 16px;
    gap: 12px;
  }
  .history-icon {
    width: 40px;
    height: 40px;
  }
  .history-actions {
    flex-direction: column;
  }
  .features-wrapper {
    margin: 48px 0 36px;
  }
  .features-header {
    margin-bottom: 32px;
  }
  .features-header h2 {
    font-size: 1.75rem;
  }
  .features-header p {
    font-size: 1rem;
  }
  .features {
    gap: 16px;
  }
  .feature-card:hover {
    transform: translateY(-4px) scale(1.01);
  }
  .modal__dialog {
    padding: 32px 24px;
    gap: 20px;
    border-radius: 24px;
  }
  .modal__close {
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
  }
  .modal__title {
    font-size: 1.5rem;
  }
  .modal__description {
    font-size: 0.9375rem;
  }
  .modal__link {
    flex-direction: column;
  }
  .modal__link .btn {
    width: 100%;
  }
  .progress {
    margin: 16px 0 0;
  }
  .logo {
    width: 300px;
  }
  .btn {
    padding: 12px 20px;
    font-size: 0.9375rem;
  }
  .upload-card__title h3 {
    font-size: 1.375rem;
  }
  .feature-card h3 {
    font-size: 1.125rem;
  }
  .upload-result {
    padding: 20px;
    gap: 14px;
  }
  .result-header {
    gap: 12px;
  }
  .result-icon {
    width: 40px;
    height: 40px;
  }
  .result-icon svg {
    width: 20px;
    height: 20px;
  }
  .result-info h4 {
    font-size: 1.125rem;
  }
  .result-actions {
    flex-direction: column;
  }
  .result-actions .btn {
    width: 100%;
  }
}

