/* ==========================================================================
   ToolIxa PDF Compressor Component Styles
   Matches global design system tokens, responsive grid, light & dark theme
   ========================================================================== */

/* Upload Dropzone Container */
.pdf-dropzone-container {
  margin-bottom: 2rem;
}

.pdf-dropzone {
  width: 100%;
  padding: 3.5rem 2rem;
  border: 2.5px dashed var(--primary-500);
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.pdf-dropzone:hover, .pdf-dropzone.dragover {
  background: rgba(99, 102, 241, 0.06);
  border-color: var(--accent-cyan);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  transform: translateY(-2px);
}

.pdf-dropzone-icon {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: var(--radius-full);
  background: var(--gradient-brand);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-glow);
}

.pdf-dropzone-title {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
  color: var(--text-main);
}

.pdf-dropzone-sub {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.pdf-file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

/* Selected PDF Header Card */
.pdf-file-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-md);
  flex-wrap: wrap;
}

.pdf-file-details {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.pdf-icon-badge {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: var(--radius-lg);
  background: rgba(244, 63, 94, 0.12);
  border: 1px solid rgba(244, 63, 94, 0.3);
  color: var(--accent-rose);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.pdf-file-meta h4 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
  color: var(--text-main);
  word-break: break-all;
}

.pdf-meta-pills {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.pdf-meta-pill {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.65rem;
  background: var(--bg-surface-elevated);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
}

/* Compression Levels Grid Cards */
.pdf-levels-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}

.pdf-level-card {
  background: var(--bg-surface);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  cursor: pointer;
  transition: all var(--transition-normal);
  position: relative;
  display: flex;
  flex-direction: column;
}

.pdf-level-card:hover {
  border-color: var(--border-brand);
  transform: translateY(-2px);
}

.pdf-level-card.active {
  border-color: var(--primary-500);
  background: var(--gradient-hero-badge);
  box-shadow: var(--shadow-md);
}

.pdf-level-title {
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.pdf-level-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

/* Advanced Settings Accordion */
.pdf-advanced-box {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  margin-top: 1.5rem;
  margin-bottom: 2rem;
}

.pdf-advanced-header {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.pdf-advanced-body {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
}

/* Results Section Grid */
.pdf-result-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.pdf-result-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
}

.pdf-result-card.highlight {
  border-color: var(--accent-emerald);
  background: rgba(16, 185, 129, 0.06);
}

.pdf-result-val {
  font-size: 1.75rem;
  font-weight: 800;
  font-family: var(--font-heading);
  color: var(--text-main);
  line-height: 1.1;
  margin-bottom: 0.25rem;
}

.pdf-result-card.highlight .pdf-result-val {
  color: #059669;
}

[data-theme="dark"] .pdf-result-card.highlight .pdf-result-val {
  color: #34D399;
}

.pdf-result-lbl {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
}

/* Optimized Notice Alert */
.pdf-optimized-notice {
  padding: 1rem 1.5rem;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-md);
  color: #D97706;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 2rem;
  text-align: center;
}

/* Responsive Adaptations */
@media (max-width: 900px) {
  .pdf-levels-grid {
    grid-template-columns: 1fr;
  }
  .pdf-result-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .pdf-file-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .pdf-result-grid {
    grid-template-columns: 1fr;
  }
}
