/* Modern Dark Theme - Shift Converter */
:root {
  --bg-color: #09090b;
  --bg-elevated: #18181b;
  --card-bg: #27272a;
  --text-primary: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --border-color: #27272a;
  --border-hover: #3f3f46;
  --accent: #22c55e;
  --accent-hover: #16a34a;
  --accent-glow: rgba(34, 197, 94, 0.15);
  --error: #ef4444;
  --error-bg: rgba(239, 68, 68, 0.1);
  --warning: #f59e0b;
  --success: #22c55e;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 40px var(--accent-glow);
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'SF Mono', 'Fira Code', Consolas, monospace;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  overflow: hidden;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-color);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
}

/* App Container */
.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Navbar */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2rem;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-color);
  flex-shrink: 0;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.navbar-brand svg {
  width: 32px;
  height: 32px;
  color: var(--accent);
}

.navbar-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.navbar-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.navbar-links a:hover {
  color: var(--text-primary);
}

/* Main Content */
.main {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 2rem;
  overflow: hidden;
}

/* Hero Section */
.hero {
  text-align: center;
  margin-bottom: 2rem;
  flex-shrink: 0;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 0.75rem;
  background: linear-gradient(to right, var(--text-primary), var(--text-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  font-weight: 400;
}

/* Content Grid */
.content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  align-items: center;
}

/* Left Side - Info */
.info-section {
  text-align: left;
}

.info-section h2 {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.info-section h2 span {
  color: var(--accent);
}

.info-section p {
  color: var(--text-secondary);
  font-size: 1.0625rem;
  line-height: 1.6;
}

.feature-tags {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.feature-tag {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 100px;
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.feature-tag svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

/* Upload Section */
.upload-section {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Drop Zone */
.drop-zone-container {
  position: relative;
  width: 100%;
  max-width: 420px;
}

.drop-zone {
  position: relative;
  background: var(--card-bg);
  border: 2px dashed var(--border-hover);
  border-radius: var(--radius-xl);
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-md);
}

.drop-zone:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  transform: translateY(-2px);
}

.drop-zone.drag-active {
  border-color: var(--accent);
  background: var(--accent-glow);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.drop-zone-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
}

.drop-zone-icon {
  width: 64px;
  height: 64px;
  background: var(--accent-glow);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.drop-zone-icon svg {
  width: 32px;
  height: 32px;
}

.drop-zone-text {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.drop-zone-subtext {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

.drop-zone-formats {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

.drop-zone-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

/* Upload Button */
.upload-btn {
  margin-top: 1.5rem;
  padding: 1rem 2.5rem;
  font-size: 1rem;
  font-weight: 600;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 100px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}

.upload-btn:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.upload-btn:disabled {
  background: var(--card-bg);
  color: var(--text-muted);
  cursor: not-allowed;
  transform: none;
}

/* File List Section */
.file-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-width: 800px;
  margin: 0 auto;
  width: 100%;
}

.file-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  flex-shrink: 0;
}

.file-section-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

.file-count {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.file-list {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  overflow-y: auto;
  max-height: 280px;
  padding-right: 0.5rem;
}

.file-list::-webkit-scrollbar {
  width: 4px;
}

.file-list::-webkit-scrollbar-track {
  background: transparent;
}

.file-list::-webkit-scrollbar-thumb {
  background: var(--border-hover);
  border-radius: 2px;
}

.file-list::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* File Item */
.file-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.875rem 1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
  animation: slideIn 0.3s ease;
}

.file-item:hover {
  border-color: var(--border-hover);
}

.file-item-icon {
  width: 48px;
  height: 48px;
  background: var(--card-bg);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
  overflow: hidden;
}

.file-item-icon svg {
  width: 24px;
  height: 24px;
  color: var(--text-secondary);
}

.file-preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

.file-item-info {
  flex: 1;
  min-width: 0;
}

.file-item-name {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.file-item-meta {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-top: 0.125rem;
}

.file-item-actions {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  flex-shrink: 0;
}

/* Format Select with Label */
.convert-label {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 500;
}

.select-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.format-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background: var(--bg-color);
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-sm);
  padding: 0.5rem 2rem 0.5rem 0.75rem;
  font-size: 0.8125rem;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  min-width: 80px;
}

.format-select:hover, .format-select:focus {
  border-color: var(--accent);
  outline: none;
  background: var(--bg-elevated);
}

.select-arrow {
  position: absolute;
  right: 0.5rem;
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  pointer-events: none;
}

.unsupported-badge {
  font-size: 0.75rem;
  color: var(--text-muted);
  background: var(--bg-color);
  padding: 0.375rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

/* Remove Button */
.remove-btn {
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.remove-btn:hover {
  background: var(--error-bg);
  color: var(--error);
}

.remove-btn svg {
  width: 18px;
  height: 18px;
}

/* File Progress */
.file-progress {
  flex: 1;
  height: 4px;
  background: var(--border-color);
  border-radius: 2px;
  overflow: hidden;
  margin: 0 0.5rem;
}

.file-progress-bar {
  height: 100%;
  background: var(--accent);
  border-radius: 2px;
  transition: width 0.3s ease;
}

/* Status Icons */
.status-icon {
  font-size: 1rem;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem 2rem;
  color: var(--text-muted);
}

.empty-state-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 1rem;
  opacity: 0.5;
}

/* Progress Section */
.progress-section {
  margin-top: 1rem;
  padding: 1rem;
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.progress-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.progress-title {
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text-primary);
}

.progress-percent {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--accent);
  font-family: var(--font-mono);
}

.progress-bar-container {
  height: 6px;
  background: var(--border-color);
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), #4ade80);
  border-radius: 3px;
  transition: width 0.3s ease;
}

.progress-text {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  text-align: center;
}

/* Actions */
.actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1rem;
  justify-content: center;
}

.btn {
  padding: 0.75rem 1.5rem;
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: 100px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

.btn-primary:disabled {
  background: var(--card-bg);
  color: var(--text-muted);
  cursor: not-allowed;
}

.btn-secondary {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

/* Status Message */
.status-message {
  padding: 0.875rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.9375rem;
  margin-top: 1rem;
  display: none;
}

.status-message.info {
  display: block;
  background: var(--accent-glow);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: var(--accent);
}

.status-message.error {
  display: block;
  background: var(--error-bg);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: var(--error);
}

/* Download Section */
.download-section {
  margin-top: 1rem;
  animation: fadeIn 0.3s ease;
}

.download-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.download-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.download-title svg {
  color: var(--accent);
}

.download-items {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 200px;
  overflow-y: auto;
}

.download-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--success);
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: var(--radius-md);
}

.download-item-name {
  font-size: 0.9375rem;
  color: var(--text-primary);
  font-weight: 500;
}

.download-btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
  font-weight: 600;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 100px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.download-btn-small:hover {
  background: var(--accent-hover);
}

/* Footer */
.footer {
  text-align: center;
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border-color);
  background: var(--bg-color);
  flex-shrink: 0;
}

.footer-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
}

.social-link {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.social-link:hover {
  color: var(--text-primary);
  background: var(--card-bg);
}

.social-link svg {
  width: 20px;
  height: 20px;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

/* Hide elements */
.hidden {
  display: none !important;
}

/* Responsive */
@media (max-width: 900px) {
  .content-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .info-section {
    text-align: center;
  }
  
  .feature-tags {
    justify-content: center;
  }
  
  .upload-section {
    order: -1;
  }
}

@media (max-width: 640px) {
  .navbar {
    padding: 1rem;
  }
  
  .navbar-links {
    display: none;
  }
  
  .main {
    padding: 1rem;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .drop-zone {
    padding: 2rem 1.5rem;
  }
  
  .drop-zone-icon {
    width: 56px;
    height: 56px;
  }
  
  .file-list {
    max-height: 200px;
  }
  
  .actions {
    flex-direction: column;
  }
  
  .btn {
    width: 100%;
  }
}
