/* assets/css/style.css */

/* ---------- Base Styles ---------- */
:root {
  --primary: #3b82f6;
  --primary-dark: #2563eb;
  --primary-light: #93c5fd;
  --secondary: #f59e0b;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-700: #374151;
  --red-500: #ef4444;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 
               Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  line-height: 1.5;
  color: var(--gray-700);
  background-color: var(--gray-100);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---------- Layout Components ---------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* ---------- Header Styles ---------- */
.header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 50;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.25rem;
}

.logo-icon {
  width: 2rem;
  height: 2rem;
}

.nav-list {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.nav-link {
  color: white;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-link:hover {
  color: var(--primary-light);
}

/* ---------- Main Content Styles ---------- */
.main {
  flex: 1;
  padding: 2rem 0;
}

.hero {
  text-align: center;
  margin-bottom: 3rem;
}

.hero-title {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--gray-800);
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--gray-600);
  max-width: 42rem;
  margin: 0 auto;
}

/* ---------- Upload Section Styles ---------- */
.upload-container {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  max-width: 56rem;
  margin: 0 auto;
}

.upload-content {
  padding: 2rem;
}

/* File Drop Area */
.file-drop-area {
  border: 2px dashed var(--gray-300);
  border-radius: 0.5rem;
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 1.5rem;
}

.file-drop-area.active {
  border-color: var(--primary);
  background-color: rgba(59, 130, 246, 0.05);
}

.file-drop-icon {
  color: var(--primary);
  width: 3rem;
  height: 3rem;
  margin: 0 auto 1rem;
}

.file-drop-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.file-drop-subtitle {
  color: var(--gray-500);
}

.file-info {
  font-size: 0.875rem;
  color: var(--gray-600);
  margin-top: 1rem;
}

/* Compression Controls */
.compression-control {
  margin-bottom: 1.5rem;
}

.compression-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.compression-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 0.5rem;
  background: var(--gray-200);
  border-radius: 0.25rem;
  outline: none;
}

.compression-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 1.25rem;
  height: 1.25rem;
  background: var(--primary);
  border-radius: 50%;
  cursor: pointer;
}

.compression-value {
  font-weight: 600;
  color: var(--primary);
}

.estimated-size {
  font-size: 0.875rem;
  color: var(--gray-600);
}

/* Button Styles */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 0.5rem;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
  width: 100%;
}

.btn-primary {
  background-color: var(--primary);
  color: white;
}

.btn-primary:hover {
  background-color: var(--primary-dark);
}

.btn-primary:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Loading Spinner */
.spinner {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

/* ---------- Footer Styles ---------- */
.footer {
  background-color: var(--gray-800);
  color: white;
  padding: 1.5rem 0;
  text-align: center;
  margin-top: auto;
}

/* ---------- Error Handling ---------- */
.error-message {
  color: var(--red-500);
  background-color: rgba(239, 68, 68, 0.1);
  padding: 1rem;
  border-radius: 0.5rem;
  margin: 1rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.error-icon {
  width: 1.25rem;
  height: 1.25rem;
}

/* ---------- Responsive Adjustments ---------- */
@media (max-width: 640px) {
  .header-content {
    flex-direction: column;
    gap: 1rem;
  }

  .nav-list {
    gap: 1rem;
  }

  .hero-title {
    font-size: 1.75rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }
}
