:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --secondary: #10b981;
  --accent: #f59e0b;
  --bg-color: #f8fafc;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --white: #ffffff;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --radius: 0.75rem;
}

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

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header & Hero Section */
.hero {
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: var(--white);
  padding: 6rem 1.5rem;
  text-align: center;
  border-bottom-left-radius: 2rem;
  border-bottom-right-radius: 2rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin: 0 auto;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: 2.5rem;
  color: #e2e8f0;
  font-weight: 400;
}

/* Search Container */
.search-container {
  background: var(--white);
  padding: 0.5rem;
  border-radius: 1rem;
  display: flex;
  box-shadow: var(--shadow-lg);
  max-width: 600px;
  margin: 0 auto;
  transition: transform 0.2s, box-shadow 0.2s;
}

.search-container:focus-within {
  transform: translateY(-2px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.search-input {
  flex: 1;
  border: none;
  padding: 1rem 1.5rem;
  font-size: 1.1rem;
  border-radius: 0.75rem;
  outline: none;
  color: var(--text-main);
  background: transparent;
}

.search-input::placeholder {
  color: #94a3b8;
}

.search-btn {
  background-color: var(--primary);
  color: var(--white);
  border: none;
  padding: 1rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.1s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.search-btn:hover {
  background-color: var(--primary-hover);
}

.search-btn:active {
  transform: scale(0.98);
}

.search-btn:disabled {
  background-color: #94a3b8;
  cursor: not-allowed;
}

/* Results Section */
.results-section {
  max-width: 800px;
  margin: -3rem auto 3rem;
  padding: 0 1.5rem;
  position: relative;
  z-index: 3;
}

.result-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  margin-top: 1rem;
  display: none;
  animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
}

.domain-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-main);
}

.status-badge {
  padding: 0.5rem 1rem;
  border-radius: 2rem;
  font-weight: 600;
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-available {
  background-color: #d1fae5;
  color: #065f46;
}

.status-unavailable {
  background-color: #fee2e2;
  color: #991b1b;
}

.status-error {
  background-color: #fef3c7;
  color: #92400e;
}

.action-area {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.price-info {
  font-size: 1.1rem;
  color: var(--text-muted);
}

.buy-btn {
  background-color: var(--secondary);
  color: white;
  text-decoration: none;
  padding: 0.75rem 2rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1.1rem;
  transition: background-color 0.2s, transform 0.1s;
  border: none;
  cursor: pointer;
  display: inline-block;
}

.buy-btn:hover {
  background-color: #059669;
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.buy-btn:active {
  transform: scale(0.98);
}

.unavailable-msg {
  color: var(--text-muted);
  font-size: 1rem;
}

/* Loader */
.loader {
  display: none;
  margin: 2rem auto;
  width: 40px;
  height: 40px;
  border: 4px solid #e2e8f0;
  border-top: 4px solid var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Features Section (SEO) */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  max-width: 1000px;
  margin: 4rem auto;
  padding: 0 1.5rem;
}

.feature-item {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  text-align: center;
  transition: transform 0.3s ease;
}

.feature-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.feature-item h3 {
  font-size: 1.25rem;
  color: var(--text-main);
  margin-bottom: 0.5rem;
}

.feature-item p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

footer {
  margin-top: auto;
  text-align: center;
  padding: 2rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  border-top: 1px solid #e2e8f0;
}

@media (max-width: 640px) {
  .hero h1 { font-size: 2rem; }
  .hero p { font-size: 1rem; }
  .search-container { flex-direction: column; gap: 0.5rem; padding: 1rem; }
  .search-input { width: 100%; padding: 0.75rem; }
  .search-btn { width: 100%; justify-content: center; }
  .action-area { flex-direction: column; gap: 1rem; text-align: center; }
  .buy-btn { width: 100%; }
}
