/* ─── HomeGadget Hub — Global Styles ─── */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=DM+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');

:root {
  --bg-primary: #faf8f5;
  --bg-dark: #1a1814;
  --bg-card: #ffffff;
  --bg-warm: #f5f0ea;
  --text-primary: #1a1814;
  --text-secondary: #6b6560;
  --text-muted: #9c9590;
  --text-light: #f5f0ea;
  --accent: #e8590c;
  --accent-hover: #c74b0a;
  --accent-soft: #fff3ed;
  --amber: #f59e0b;
  --amber-soft: #fef3c7;
  --green: #16a34a;
  --green-soft: #dcfce7;
  --border: #e8e2da;
  --border-dark: #3a3530;
  --shadow-sm: 0 1px 3px rgba(26, 24, 20, 0.06);
  --shadow-md: 0 4px 16px rgba(26, 24, 20, 0.08);
  --shadow-lg: 0 8px 32px rgba(26, 24, 20, 0.12);
  --shadow-accent: 0 4px 20px rgba(232, 89, 12, 0.2);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --max-width: 1200px;
}

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

html { scroll-behavior: smooth; }

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
}

a { color: var(--accent); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--accent-hover); }

img { max-width: 100%; height: auto; display: block; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ─── Buttons ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: var(--shadow-accent);
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(232, 89, 12, 0.3);
}

.btn-secondary {
  background: var(--bg-dark);
  color: white;
}
.btn-secondary:hover {
  background: #2a2520;
  color: white;
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--border);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-lg { padding: 16px 32px; font-size: 17px; border-radius: var(--radius-md); }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* ─── Navigation ─── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 248, 245, 0.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  color: var(--text-primary);
}
.nav-logo:hover { color: var(--text-primary); }

.nav-logo-icon {
  width: 36px;
  height: 36px;
  background: var(--accent);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: white;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 15px;
  color: var(--text-secondary);
  transition: color 0.2s ease;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a.active { color: var(--accent); }

.nav-mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  padding: 4px;
  color: var(--text-primary);
}

/* ─── Hero ─── */
.hero {
  padding: 80px 0 60px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(232, 89, 12, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-content {
  max-width: 680px;
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 6px 14px;
  border-radius: 100px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 24px;
  letter-spacing: 0.02em;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  letter-spacing: -0.03em;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.hero h1 span {
  background: linear-gradient(135deg, var(--accent), var(--amber));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  max-width: 540px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ─── Categories Grid ─── */
.categories-section {
  padding: 80px 0;
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 40px;
  gap: 20px;
}

.section-header h2 {
  font-size: 2rem;
  letter-spacing: -0.02em;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 15px;
  margin-top: 4px;
}

.section-link {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}
.section-link:hover { gap: 8px; }

.categories-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.category-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  text-align: center;
  transition: all 0.25s ease;
  cursor: pointer;
  text-decoration: none;
  color: var(--text-primary);
}
.category-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  color: var(--text-primary);
}

.category-icon {
  font-size: 36px;
  margin-bottom: 12px;
  display: block;
}

.category-card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}

.category-card p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ─── Product Grid ─── */
.products-section {
  padding: 60px 0 80px;
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.25s ease;
  cursor: pointer;
  text-decoration: none;
  color: var(--text-primary);
  display: flex;
  flex-direction: column;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
  color: var(--text-primary);
}

.product-card-image {
  width: 100%;
  height: 220px;
  object-fit: cover;
  background: var(--bg-warm);
}

.product-card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-card-category {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 6px;
}

.product-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.3;
}

.product-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  flex: 1;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.product-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.product-price {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  color: var(--text-primary);
}

.product-price-original {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-left: 8px;
}

.product-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  font-family: var(--font-display);
}

.product-badge-featured {
  background: var(--amber-soft);
  color: #b45309;
}

.product-badge-sale {
  background: var(--green-soft);
  color: var(--green);
}

/* ─── Product Detail ─── */
.product-detail {
  padding: 40px 0 80px;
}

.product-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.product-image-main {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-lg);
  background: var(--bg-warm);
}

.product-info-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 4px 12px;
  border-radius: 100px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 12px;
  margin-bottom: 16px;
}

.product-info h1 {
  font-size: 2rem;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.product-info-price {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 20px;
}

.product-info-price .current {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2rem;
  color: var(--accent);
}

.product-info-price .original {
  font-size: 18px;
  color: var(--text-muted);
  text-decoration: line-through;
}

.product-info-price .save {
  background: var(--green-soft);
  color: var(--green);
  padding: 2px 10px;
  border-radius: 100px;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
}

.product-description {
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.8;
  margin-bottom: 28px;
}

.product-specs {
  background: var(--bg-warm);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin-bottom: 28px;
}

.product-specs h3 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.product-specs-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.spec-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.spec-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.spec-value {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 14px;
}

.product-cta {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.product-cta .btn { justify-content: center; text-align: center; }

.product-cta-note {
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
}

/* ─── Breadcrumb ─── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 20px 0;
  font-size: 14px;
  color: var(--text-muted);
}
.breadcrumb a { color: var(--text-secondary); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb-sep { color: var(--border); }

/* ─── Catalog Filters ─── */
.catalog-header {
  padding: 40px 0 0;
}

.catalog-header h1 {
  font-size: 2.2rem;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.catalog-header p {
  color: var(--text-secondary);
  font-size: 16px;
  margin-bottom: 32px;
}

.catalog-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.filter-btn {
  padding: 8px 20px;
  border-radius: 100px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 14px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}
.filter-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.filter-btn.active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.catalog-search {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 32px;
}

.search-input {
  flex: 1;
  max-width: 400px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 15px;
  background: var(--bg-card);
  outline: none;
  transition: border-color 0.2s ease;
}
.search-input:focus { border-color: var(--accent); }
.search-input::placeholder { color: var(--text-muted); }

.product-count {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
  font-family: var(--font-display);
}

/* ─── CTA Section ─── */
.cta-section {
  background: var(--bg-dark);
  padding: 80px 0;
  text-align: center;
  color: var(--text-light);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -30%;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(232, 89, 12, 0.1) 0%, transparent 60%);
  pointer-events: none;
}

.cta-section h2 {
  font-size: 2.2rem;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  position: relative;
}

.cta-section p {
  color: var(--text-muted);
  font-size: 16px;
  margin-bottom: 32px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  position: relative;
}

.cta-form {
  display: flex;
  gap: 8px;
  max-width: 440px;
  margin: 0 auto;
  position: relative;
}

.cta-form input {
  flex: 1;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-dark);
  background: rgba(255,255,255,0.06);
  color: white;
  font-family: var(--font-body);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s ease;
}
.cta-form input:focus { border-color: var(--accent); }
.cta-form input::placeholder { color: var(--text-muted); }

.cta-success {
  display: none;
  color: var(--green);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  margin-top: 12px;
}

/* ─── Footer ─── */
.footer {
  background: var(--bg-dark);
  color: var(--text-muted);
  padding: 40px 0 24px;
  border-top: 1px solid var(--border-dark);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.footer-brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  color: var(--text-light);
}

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 14px;
}
.footer-links a:hover { color: var(--text-light); }

/* ─── Responsive ─── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-mobile-toggle { display: block; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border);
    padding: 20px 24px;
    gap: 16px;
  }

  .hero { padding: 48px 0 40px; }
  .hero h1 { font-size: 2.2rem; }
  .hero p { font-size: 16px; }

  .categories-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .category-card { padding: 20px 16px; }

  .products-grid { grid-template-columns: 1fr; gap: 16px; }

  .product-detail-grid { grid-template-columns: 1fr; gap: 32px; }

  .section-header { flex-direction: column; align-items: flex-start; }

  .cta-form { flex-direction: column; }

  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { flex-wrap: wrap; justify-content: center; }

  .catalog-filters { gap: 6px; }
  .filter-btn { padding: 6px 14px; font-size: 13px; }

  .product-specs-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .categories-grid { grid-template-columns: 1fr 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }
}

/* ─── Animations ─── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-up {
  animation: fadeUp 0.5s ease forwards;
  opacity: 0;
}

.fade-up:nth-child(2) { animation-delay: 0.1s; }
.fade-up:nth-child(3) { animation-delay: 0.2s; }
.fade-up:nth-child(4) { animation-delay: 0.3s; }

/* ─── Skeleton Loading ─── */
.skeleton {
  background: linear-gradient(90deg, var(--bg-warm) 25%, var(--border) 50%, var(--bg-warm) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-card {
  height: 380px;
  border-radius: var(--radius-lg);
}

/* ─── Empty State ─── */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.empty-state h3 {
  font-size: 20px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}
