/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: #1a1a1a;
  background: #ffffff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

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

button {
  font-family: inherit;
  cursor: pointer;
}

ul {
  list-style: none;
}

/* ===== WIDGET PLACEHOLDER ===== */
.widget-placeholder {
  border: 2px dashed #d1d5db;
  background: #f9fafb;
  border-radius: 8px;
  padding: 24px 16px;
  position: relative;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.widget-placeholder::after {
  content: attr(data-widget);
  font-size: 12px;
  font-weight: 500;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ===== STAGING BANNER ===== */
.staging-banner {
  background: #f59e0b;
  color: #1a1a1a;
  text-align: center;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  position: sticky;
  top: 0;
  z-index: 101;
}

.staging-banner + .nav {
  top: 37px;
}

/* ===== NAVIGATION ===== */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
}

.nav-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-logo {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  white-space: nowrap;
  color: #1a1a1a;
}

.nav-search-wrapper {
  flex: 1;
  max-width: 480px;
  position: relative;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav-cart {
  position: relative;
  background: none;
  border: none;
  padding: 8px;
  color: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-cart svg {
  width: 22px;
  height: 22px;
}

.nav-links {
  display: flex;
  gap: 24px;
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: #4b5563;
  transition: color 0.2s;
}

.nav-link:hover {
  color: #1a1a1a;
}

/* ===== HERO ===== */
.hero {
  position: relative;
  background: #f3f4f6;
  overflow: hidden;
}

.hero-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 80px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
}

.hero-content {
  max-width: 520px;
}

.hero-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #ffffff;
  background: #1a1a1a;
  padding: 4px 12px;
  border-radius: 4px;
  margin-bottom: 16px;
}

.hero-title {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  color: #1a1a1a;
}

.hero-subtitle {
  font-size: 18px;
  color: #6b7280;
  margin-bottom: 32px;
  line-height: 1.5;
}

.hero-image {
  flex-shrink: 0;
  width: 480px;
  height: 360px;
  border-radius: 12px;
  overflow: hidden;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  transition: all 0.2s;
}

.btn-primary {
  background: #1a1a1a;
  color: #ffffff;
}

.btn-primary:hover {
  background: #333333;
}

.btn-outline {
  background: transparent;
  color: #1a1a1a;
  border: 1px solid #d1d5db;
}

.btn-outline:hover {
  background: #f3f4f6;
}

.btn-lg {
  padding: 16px 36px;
  font-size: 16px;
}

/* ===== SECTIONS ===== */
.section {
  max-width: 1280px;
  margin: 0 auto;
  padding: 64px 24px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}

.section-title {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #1a1a1a;
}

.section-link {
  font-size: 14px;
  font-weight: 500;
  color: #6b7280;
  transition: color 0.2s;
}

.section-link:hover {
  color: #1a1a1a;
}

/* ===== PRODUCT GRID ===== */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.product-card {
  border-radius: 12px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  transition:
    box-shadow 0.2s,
    transform 0.2s;
}

.product-card:hover {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.product-card-image {
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #f3f4f6;
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.product-card:hover .product-card-image img {
  transform: scale(1.05);
}

.product-card-info {
  padding: 16px;
}

.product-card-name {
  font-size: 14px;
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 4px;
}

.product-card-price {
  font-size: 14px;
  color: #6b7280;
}

/* ===== CATEGORY GRID ===== */
.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.category-card {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  background: #f3f4f6;
}

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.category-card:hover img {
  transform: scale(1.05);
}

.category-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent);
  display: flex;
  align-items: flex-end;
  padding: 24px;
}

.category-card-label {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
}

/* ===== SEARCH PAGE LAYOUT ===== */
.search-layout {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 24px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 32px;
}

.search-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.search-sidebar-title {
  font-size: 18px;
  font-weight: 700;
  color: #1a1a1a;
  padding-bottom: 16px;
  border-bottom: 1px solid #e5e7eb;
}

.search-main {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.search-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.search-top-bar-left {
  flex: 1;
}

/* ===== PRODUCT DETAIL ===== */
.product-detail {
  max-width: 1280px;
  margin: 0 auto;
  padding: 48px 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
}

.product-gallery {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.product-gallery-main {
  aspect-ratio: 3 / 4;
  border-radius: 12px;
  overflow: hidden;
  background: #f3f4f6;
}

.product-gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-gallery-thumbs {
  display: flex;
  gap: 12px;
}

.product-gallery-thumb {
  width: 80px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color 0.2s;
}

.product-gallery-thumb:hover,
.product-gallery-thumb.active {
  border-color: #1a1a1a;
}

.product-gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-top: 16px;
}

.product-breadcrumb {
  font-size: 13px;
  color: #9ca3af;
}

.product-breadcrumb a:hover {
  color: #1a1a1a;
}

.product-title {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #1a1a1a;
}

.product-price {
  font-size: 24px;
  font-weight: 600;
  color: #1a1a1a;
}

.product-description {
  font-size: 15px;
  color: #6b7280;
  line-height: 1.7;
}

.product-options {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 0;
  border-top: 1px solid #e5e7eb;
  border-bottom: 1px solid #e5e7eb;
}

.product-option-label {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #4b5563;
  margin-bottom: 8px;
}

.product-sizes {
  display: flex;
  gap: 8px;
}

.product-size {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #ffffff;
  color: #1a1a1a;
  cursor: pointer;
  transition: all 0.2s;
}

.product-size:hover,
.product-size.active {
  border-color: #1a1a1a;
  background: #1a1a1a;
  color: #ffffff;
}

.product-add-to-cart {
  width: 100%;
  padding: 16px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  background: #1a1a1a;
  color: #ffffff;
  cursor: pointer;
  transition: background 0.2s;
}

.product-add-to-cart:hover {
  background: #333333;
}

.product-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  color: #9ca3af;
}

/* ===== FOOTER ===== */
.footer {
  background: #f9fafb;
  border-top: 1px solid #e5e7eb;
  margin-top: 64px;
}

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

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

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-brand-name {
  font-size: 20px;
  font-weight: 700;
  color: #1a1a1a;
}

.footer-brand-text {
  font-size: 14px;
  color: #6b7280;
  max-width: 280px;
  line-height: 1.6;
}

.footer-col-title {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #1a1a1a;
  margin-bottom: 16px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  font-size: 14px;
  color: #6b7280;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: #1a1a1a;
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-copy {
  font-size: 13px;
  color: #9ca3af;
}

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

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

.footer-socials a:hover {
  color: #1a1a1a;
}

.footer-socials svg {
  width: 20px;
  height: 20px;
}

/* ===== FLOATING CHAT ===== */
.chat-float {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 200;
}

.chat-container {
  position: absolute;
  bottom: 72px;
  right: 0;
  width: 380px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .hero-inner {
    padding: 48px 24px;
  }

  .hero-title {
    font-size: 36px;
  }

  .hero-image {
    width: 360px;
    height: 280px;
  }

  .product-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .category-grid {
    grid-template-columns: repeat(2, 1fr);
  }

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

@media (max-width: 768px) {
  .nav-inner {
    padding: 0 16px;
  }

  .nav-links {
    display: none;
  }

  .hero-inner {
    flex-direction: column;
    padding: 32px 16px;
    text-align: center;
  }

  .hero-image {
    width: 100%;
    height: 240px;
  }

  .hero-title {
    font-size: 28px;
  }

  .hero-subtitle {
    font-size: 16px;
  }

  .section {
    padding: 40px 16px;
  }

  .section-title {
    font-size: 22px;
  }

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

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

  .search-layout {
    grid-template-columns: 1fr;
    padding: 24px 16px;
  }

  .search-sidebar {
    order: -1;
  }

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

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .chat-container {
    width: calc(100vw - 48px);
    right: -8px;
  }
}

@media (max-width: 480px) {
  .product-grid {
    grid-template-columns: 1fr;
  }

  .product-gallery-thumbs {
    gap: 8px;
  }

  .product-gallery-thumb {
    width: 60px;
    height: 60px;
  }
}
