:root {
  --bg: #F6F8F7;
  --surface: #FFFFFF;
  --primary: #146356;
  --primary-dark: #0E4A40;
  --accent: #C88A00;
  --text: #1C2321;
  --muted: #62726C;
  --border: #E1E7E4;
}

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

body {
  font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

.layout { display: flex; min-height: 100vh; }

.sidebar {
  width: 250px;
  flex-shrink: 0;
  padding: 28px 20px;
  background: var(--surface);
  border-right: 1px solid var(--border);
}
.sidebar .logo { display: block; margin-bottom: 24px; }
.sidebar .logo img { max-height: 44px; }

.sidebar .search {
  position: relative;
  margin-bottom: 28px;
}
.sidebar .search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--muted);
}
.sidebar .search input {
  width: 100%;
  padding: 10px 12px 10px 36px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  font-size: 0.9rem;
  color: var(--text);
}
.sidebar .search input:focus {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
}

.sidebar .menu { display: flex; flex-direction: column; }
.sidebar .menu a {
  display: flex;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 6px;
  border-left: 3px solid transparent;
  font-size: 0.92rem;
  color: var(--text);
}
.sidebar .menu a:hover {
  background: var(--bg);
  border-left-color: var(--primary);
}
.sidebar .menu a span {
  color: var(--muted);
  font-size: 0.8rem;
}

.content { flex: 1; padding: 32px 40px; max-width: 1200px; }

h1 { font-size: 1.7rem; font-weight: 700; margin-bottom: 20px; letter-spacing: -0.01em; }
h2 { font-size: 1.3rem; font-weight: 700; margin-bottom: 16px; letter-spacing: -0.01em; }

.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 18px;
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb .current { color: var(--text); font-weight: 500; }
.breadcrumb .sep { color: var(--border); }

.seo-box {
  background: var(--bg);
  border-left: 3px solid var(--primary);
  border-radius: 6px;
  padding: 14px 18px;
  margin-top: 20px;
  font-size: 0.88rem;
  color: var(--muted);
  max-width: 60ch;
}

.slider { display: flex; overflow-x: auto; gap: 12px; margin-bottom: 28px; border-radius: 12px; }
.slider img { width: 100%; max-height: 320px; object-fit: cover; border-radius: 12px; }

.intro-box {
  background: var(--primary);
  color: #fff;
  padding: 20px 24px;
  border-radius: 10px;
  margin-bottom: 26px;
  max-width: 70ch;
  line-height: 1.6;
  font-size: 0.95rem;
}

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

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 3px rgba(28, 35, 33, 0.06);
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.card:hover {
  box-shadow: 0 4px 14px rgba(28, 35, 33, 0.1);
  transform: translateY(-2px);
}
.card-img {
  aspect-ratio: 1 / 1;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}
.card-img img { max-height: 100%; object-fit: contain; }
.card-body { padding: 12px 14px 16px; display: flex; flex-direction: column; gap: 4px; }
.card-cat { font-size: 0.72rem; color: var(--primary); font-weight: 600; }
.card-body h3 {
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.5em;
}
.price { color: var(--accent); font-weight: 700; font-size: 1rem; }
.price-lg { font-size: 1.6rem; display: block; margin: 14px 0; }

.product { display: flex; gap: 40px; flex-wrap: wrap; margin-bottom: 48px; }
.product-img {
  width: 340px;
  aspect-ratio: 1 / 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.product-details { flex: 1; min-width: 260px; }
.product-details h1 { margin: 6px 0 4px; }
.buy {
  display: inline-block;
  padding: 13px 28px;
  background: var(--primary);
  color: #fff;
  border-radius: 8px;
  font-weight: 600;
  margin-bottom: 20px;
}
.buy:hover { background: var(--primary-dark); }
.description { color: var(--muted); max-width: 60ch; }

.related { margin-bottom: 48px; }

.pagination { display: flex; gap: 8px; margin-top: 28px; }
.pagination a {
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
}
.pagination a.active { background: var(--primary); color: #fff; border-color: var(--primary); }

@media (max-width: 768px) {
  .layout { flex-direction: column; }
  .sidebar {
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
  .content { padding: 20px; }
  .product { gap: 20px; }
  .product-img { width: 100%; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-body { padding: 10px 10px 12px; }
}
