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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #f5f7fa;
  color: #1a1a2e;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ═══════════════════════════════════════════
   NAVBAR (matches job-perfector)
   ═══════════════════════════════════════════ */
.navbar {
  width: 100%;
  border-bottom: 1px solid #e8ecf1;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 50;
}

.navbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

.navbar-logo {
  height: 48px;
  width: auto;
  object-fit: contain;
}

.navbar-title-group {
  display: flex;
  flex-direction: column;
}

.navbar-title {
  font-family: 'Funnel Display', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #1a1a2e;
  line-height: 1.2;
}

.navbar-tagline {
  font-size: 0.8rem;
  color: #6b7280;
}

.navbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.powered-by {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #6b7280;
  font-size: 0.8rem;
  transition: color 0.2s;
}

.powered-by:hover {
  color: #0066FF;
}

.powered-logo {
  height: 32px;
  width: auto;
  object-fit: contain;
}

/* Mobile menu button */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  color: #1a1a2e;
}

.mobile-menu-btn svg {
  width: 24px;
  height: 24px;
}

/* Mobile menu dropdown */
.mobile-menu {
  display: none;
}

.mobile-menu.open {
  display: block;
  background: white;
  border-top: 1px solid #e8ecf1;
  animation: slideDown 0.2s ease-out;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  padding: 16px 24px;
  gap: 12px;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #374151;
  font-size: 0.9rem;
  padding: 8px 0;
}

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

@media (max-width: 768px) {
  .powered-by {
    display: none;
  }
  .mobile-menu-btn {
    display: block;
  }
  .navbar-tagline {
    display: none;
  }
  .navbar-title {
    font-size: 1rem;
  }
  .navbar-logo {
    height: 36px;
  }
}

/* ═══════════════════════════════════════════
   MAIN CONTENT
   ═══════════════════════════════════════════ */
.container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 24px;
  flex: 1;
}

/* Sections */
.section {
  background: white;
  border-radius: 10px;
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.section h2 {
  font-size: 1.15rem;
  margin-bottom: 16px;
  color: #1a1a2e;
  border-bottom: 2px solid #e8ecf1;
  padding-bottom: 8px;
}

/* Form */
.form-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #555;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.form-group label .required {
  color: #e74c3c;
}

.form-group input,
.form-group select {
  padding: 8px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.9rem;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: #0066FF;
  box-shadow: 0 0 0 3px rgba(0, 102, 255, 0.1);
}

.form-group.full-width {
  grid-column: 1 / -1;
}

/* URL input */
.url-input-group {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.url-input-group input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.95rem;
}

.url-input-group input:focus {
  outline: none;
  border-color: #0066FF;
}

/* Buttons */
.btn {
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-primary {
  background: #0066FF;
  color: white;
}

.btn-primary:hover {
  background: #0052cc;
}

.btn-secondary {
  background: #e8ecf1;
  color: #1a1a2e;
}

.btn-secondary:hover {
  background: #d1d5db;
}

.btn-success {
  background: #2ecc71;
  color: white;
}

.btn-success:hover {
  background: #27ae60;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-group {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

/* Status messages */
.status-info { color: #0066FF; font-size: 0.9rem; margin-top: 8px; }
.status-success { color: #2ecc71; font-size: 0.9rem; margin-top: 8px; }
.status-warning { color: #f39c12; font-size: 0.9rem; margin-top: 8px; }
.status-error { color: #e74c3c; font-size: 0.9rem; margin-top: 8px; }

/* Searchable dropdown */
.searchable-dropdown {
  position: relative;
}

.dropdown-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  max-height: 200px;
  overflow-y: auto;
  background: white;
  border: 1px solid #d1d5db;
  border-radius: 0 0 6px 6px;
  z-index: 100;
  display: none;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.dropdown-item {
  padding: 8px 12px;
  cursor: pointer;
  font-size: 0.85rem;
  border-bottom: 1px solid #f0f0f0;
}

.dropdown-item:hover {
  background: #e8ecf1;
}

/* Preview table */
.table-scroll {
  overflow-x: auto;
  margin-top: 12px;
}

.preview-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}

.preview-table th {
  background: #f5f7fa;
  padding: 8px 10px;
  text-align: left;
  font-weight: 600;
  border-bottom: 2px solid #d1d5db;
  white-space: nowrap;
}

.preview-table td {
  padding: 6px 10px;
  border-bottom: 1px solid #e8ecf1;
  max-width: 250px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-table tr:hover {
  background: #f9fafb;
}

.row-warning {
  background: #fff9e6 !important;
}

.warning-icon {
  display: inline-block;
  width: 18px;
  height: 18px;
  background: #f39c12;
  color: white;
  border-radius: 50%;
  text-align: center;
  line-height: 18px;
  font-size: 0.75rem;
  font-weight: bold;
  cursor: help;
}

.ok-icon {
  color: #2ecc71;
  font-weight: 600;
}

.cp2021-cell {
  min-width: 280px;
}

.cp2021-input {
  width: 100%;
  padding: 4px 8px !important;
  font-size: 0.8rem !important;
  border: 1px solid #d1d5db !important;
  border-radius: 4px !important;
}

/* Download section */
#download-section {
  display: none;
  text-align: center;
  padding: 20px;
}

#download-section .btn {
  font-size: 1rem;
  padding: 12px 30px;
}

/* ═══════════════════════════════════════════
   FOOTER (matches job-perfector)
   ═══════════════════════════════════════════ */
.site-footer {
  background: #111827;
  color: #9ca3af;
  padding-top: 64px;
  padding-bottom: 32px;
  margin-top: 64px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-bottom: 48px;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr;
  }
}

.footer-logo {
  height: 36px;
  width: auto;
  filter: brightness(0) invert(1);
  margin-bottom: 24px;
}

.footer-description {
  color: #9ca3af;
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 24px;
}

.footer-social {
  display: flex;
  gap: 16px;
}

.footer-social a {
  color: #9ca3af;
  transition: color 0.2s;
}

.footer-social a:hover {
  color: white;
}

.social-icon {
  width: 24px;
  height: 24px;
}

.footer-heading {
  font-size: 1.1rem;
  font-weight: 600;
  color: white;
  margin-bottom: 16px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  color: #9ca3af;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: white;
}

.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid #1f2937;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  font-size: 0.85rem;
  text-align: center;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

@media (min-width: 768px) {
  .footer-legal {
    justify-content: flex-end;
  }
}

.footer-legal a {
  color: #9ca3af;
  text-decoration: none;
  font-size: 0.85rem;
  transition: color 0.2s;
}

.footer-legal a:hover {
  color: white;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 1024px) {
  .form-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
  .url-input-group {
    flex-direction: column;
  }
  .site-footer {
    padding-top: 40px;
    margin-top: 40px;
  }
  .container {
    padding: 16px;
  }
}
