/* Reset & Base Variables */
:root {
  --font-sans: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace;

  /* Premium HSL Light Color Palette */
  --bg-primary: #f8fafc; /* slate-50 */
  --bg-secondary: #ffffff; /* white */
  --bg-tertiary: #f1f5f9; /* slate-100 */
  
  --text-primary: #0f172a; /* slate-900 */
  --text-secondary: #475569; /* slate-600 */
  --text-muted: #64748b; /* slate-500 */
  
  --accent-primary: #0ea5e9; /* sky-500 */
  --accent-hover: #0284c7; /* sky-600 */
  --accent-glow: rgba(14, 165, 233, 0.08);
  
  --border-color: rgba(15, 23, 42, 0.08);
  --border-focus: rgba(14, 165, 233, 0.3);
  
  --success: #10b981;
  --warning: #d97706;
  --error: #dc2626;

  --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --border-radius: 12px;
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Background Gradients */
.glow-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.glow-orb {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.7;
}

.orb-1 {
  top: -10%;
  right: -10%;
  background: radial-gradient(circle, rgba(14, 165, 233, 0.08) 0%, rgba(248, 250, 252, 0) 70%);
}

.orb-2 {
  bottom: -15%;
  left: -10%;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.04) 0%, rgba(248, 250, 252, 0) 70%);
}

/* Container & Layout */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

.logo-section {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-icon {
  background: linear-gradient(135deg, var(--accent-primary), #6366f1);
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: white;
  font-size: 1.25rem;
  box-shadow: 0 4px 15px rgba(14, 165, 233, 0.2);
}

.logo-text h1 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  background: linear-gradient(120deg, var(--text-primary), var(--text-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo-text p {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Badge Styling */
.badge-container {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.status-badge {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  padding: 0.4rem 0.8rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: var(--transition-smooth);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--text-muted);
}

.status-verified {
  border-color: rgba(16, 185, 129, 0.2);
  color: var(--success);
  background-color: rgba(16, 185, 129, 0.02);
}
.status-verified .status-indicator {
  background-color: var(--success);
  box-shadow: 0 0 6px var(--success);
}

.status-blocked {
  border-color: rgba(220, 38, 38, 0.2);
  color: var(--error);
  background-color: rgba(220, 38, 38, 0.02);
}
.status-blocked .status-indicator {
  background-color: var(--error);
  box-shadow: 0 0 6px var(--error);
}

/* Main Search Glassmorphic Card */
.search-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04);
  margin-bottom: 2rem;
  transition: var(--transition-smooth);
  position: relative;
}

.search-card:hover {
  border-color: rgba(15, 23, 42, 0.12);
  box-shadow: 0 15px 35px rgba(15, 23, 42, 0.06);
}

.hero-text {
  text-align: center;
  margin-bottom: 2rem;
}

.hero-text h2 {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.hero-text p {
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 500px;
  margin: 0 auto;
}

/* Form Styles */
.search-form {
  position: relative;
  margin-bottom: 1.5rem;
}

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

.search-icon {
  position: absolute;
  left: 1.25rem;
  color: var(--text-muted);
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 1.1rem 1.25rem 1.1rem 3.25rem;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  color: var(--text-primary);
  font-size: 1.05rem;
  font-family: var(--font-sans);
  transition: var(--transition-smooth);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.12);
}

.search-btn {
  position: absolute;
  right: 0.6rem;
  top: 50%;
  transform: translateY(-50%);
  background-color: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  padding: 0.6rem 1.2rem;
  border-radius: 8px;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.search-btn:hover:not(:disabled) {
  background-color: var(--accent-primary);
  border-color: var(--accent-primary);
  color: white;
}

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

/* Verification Overlay */
.verification-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(248, 250, 252, 0.95);
  backdrop-filter: blur(8px);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 2rem;
  text-align: center;
}

.verification-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.verification-box {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  padding: 2.5rem;
  border-radius: var(--border-radius);
  max-width: 400px;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

.verification-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.verification-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.verification-action-btn {
  background: linear-gradient(135deg, var(--accent-primary), #6366f1);
  border: none;
  padding: 0.8rem 2rem;
  border-radius: 8px;
  color: white;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  box-shadow: 0 4px 15px rgba(14, 165, 233, 0.2);
  transition: var(--transition-smooth);
}

.verification-action-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(14, 165, 233, 0.3);
}

.verification-action-btn:active {
  transform: translateY(0);
}

/* Configurations & Controls */
.controls-row {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  border-top: 1px solid var(--border-color);
  padding-top: 1.5rem;
}

.filter-group {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.filter-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-right: 0.5rem;
}

.btn-toggle {
  background-color: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.4rem 0.9rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.btn-toggle:hover {
  color: var(--text-primary);
  border-color: rgba(15, 23, 42, 0.15);
}

.btn-toggle.active {
  background-color: rgba(14, 165, 233, 0.08);
  border-color: var(--accent-primary);
  color: var(--accent-hover);
}

/* Quota Tracker */
.quota-info {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.quota-count {
  font-weight: 700;
  color: var(--text-primary);
}

/* Results Section */
.results-section {
  flex-grow: 1;
}

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

.results-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
}

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

.grid-results {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.25rem;
}

/* Result Cards */
.result-card {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  animation: fadeIn 0.3s ease-out forwards;
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.02);
}

.result-card:hover {
  transform: translateY(-2px);
  border-color: rgba(15, 23, 42, 0.15);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
}

.result-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.code-badge {
  font-family: var(--font-mono);
  background-color: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--accent-hover);
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.type-tag {
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.type-hsn {
  background-color: rgba(14, 165, 233, 0.08);
  color: var(--accent-hover);
}

.type-sac {
  background-color: rgba(99, 102, 241, 0.08);
  color: #4f46e5;
}

.result-description {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.result-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
}

.category-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

.gst-rate-box {
  background-color: rgba(16, 185, 129, 0.08);
  color: #059669;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.gst-label {
  font-size: 0.65rem;
  font-weight: 500;
  color: #059669;
  opacity: 0.8;
}

/* Empty State & Error States */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  color: var(--text-secondary);
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.02);
}

.empty-state svg {
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.empty-state h3 {
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.empty-state p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

footer {
  margin-top: auto;
  padding-top: 4rem;
  padding-bottom: 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);
}

.disclaimer-text {
  font-size: 0.7rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0.75rem auto 0 auto;
  line-height: 1.4;
}

footer a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition-smooth);
}

footer a:hover {
  color: var(--accent-primary);
}

/* Micro-animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Rate limit countdown layout */
.rate-limited-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.5rem;
  background-color: rgba(220, 60, 60, 0.02);
  border: 1px dashed rgba(220, 60, 60, 0.2);
  border-radius: var(--border-radius);
  margin-top: 1rem;
}

.rate-limited-title {
  color: var(--error);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.rate-limited-timer {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0.5rem 0;
  color: var(--text-primary);
}

/* Responsive adjustments */
@media (max-width: 600px) {
  header {
    flex-direction: column;
    gap: 1rem;
    align-items: flex-start;
  }
  
  .badge-container {
    align-self: flex-end;
  }

  .controls-row {
    flex-direction: column;
    align-items: stretch;
  }
  
  .filter-group {
    justify-content: space-between;
  }
}
