:root {
  --primary: #5d4037; /* Dark Walnut */
  --secondary: #8d6e63;
  --accent: #d7ccc8;
  --bg-light: #fafafa;
  --text-dark: #333333;
  --white: #ffffff;
  --shadow:
    0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --radius: 12px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}
html,
body {
  height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
}
/* Header & Nav */
header {
  background: var(--white);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 1000;
}
nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary);
  text-decoration: none;
}
.nav-links a {
  margin-left: 20px;
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 500;
  transition: 0.3s;
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--primary);
}

/* Layout Container */
.container {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 1rem;
  flex: 1;
}

/* Forms */
.form-box {
  max-width: 500px;
  margin: 3rem auto;
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.form-group {
  margin-bottom: 1.5rem;
}
label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
}
input,
select,
textarea {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
}
button {
  background: var(--primary);
  color: var(--white);
  border: none;
  padding: 0.8rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1rem;
  transition: 0.3s;
  width: 100%;
}
button:hover {
  background: var(--secondary);
  transform: translateY(-2px);
}
/* ===== judul halaman ===== */

.section-title-box {
  background: var(--white);
  padding: 2rem;
  border-radius: 16px;
  box-shadow: var(--shadow);
  text-align: center;
  margin-bottom: 2.5rem;
  position: relative;
  overflow: hidden;
}

.section-title-box::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 5px;
  width: 100%;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.section-title-box h2 {
  font-size: 1.8rem;
  color: var(--primary);
  margin: 0.5rem 0;
}

.section-title-box p {
  font-size: 0.95rem;
  color: #777;
}

.section-badge {
  display: inline-block;
  background: var(--accent);
  color: var(--primary);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}
/* Product Grid (Responsive) */

/* Desktop Default 4 kolom */
@media (min-width: 1024px) {
  .grid-layout {
    grid-template-columns: repeat(4, 1fr);
  }
}
/* Tablet 2 kolom */
@media (min-width: 600px) and (max-width: 1023px) {
  .grid-layout {
    grid-template-columns: repeat(2, 1fr);
  }
}
/* Mobile 1 kolom
@media (max-width: 599px) {
  .grid-layout {
    grid-template-columns: 1fr;
  }
} */
/* =========================
   KATEGORI 2 KIRI 2 KANAN
========================= */

/* 2 kategori per baris */
.kategori-row {
  display: grid;
  gap: 1rem;
}

/* Desktop */
@media (min-width: 1024px) {
  .kategori-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Tablet */
@media (min-width: 600px) and (max-width: 1023px) {
  .kategori-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile */
@media (min-width: 400px) and (max-width: 500px) {
  .kategori-row {
    grid-template-columns: repeat(3, 1fr);
  }

  .kategori-row .card-img {
    aspect-ratio: 1 / 1;
  }

  .kategori-row .card-body {
    padding: 0.8rem;
  }

  .kategori-row .card-title {
    font-size: 0.85rem;
  }

  .kategori-row .card-price {
    font-size: 0.85rem;
  }
}

/* Box kategori */
.kategori-box {
  background: var(--white);
  padding: 1.5rem;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

/* Header kategori  */
.kategori-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid #eee;
  padding-bottom: 0.8rem;
}

.kategori-name {
  font-size: 1.2rem;
  color: var(--primary);
  margin: 0;
}

.kategori-info {
  font-size: 0.8rem;
  color: #777;
}

.kategori-rank {
  background: linear-gradient(135deg, #8e24aa, #5d4037);
  color: white;
  font-size: 0.75rem;
  padding: 6px 12px;
  border-radius: 20px;
}

/* Produk 2 per kategori */
.kategori-products {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(2, 1fr);
}

/* Mobile produk jadi 1 */
@media (max-width: 768px) {
  .kategori-products {
    grid-template-columns: 1fr;
  }
}
/* Product Card */
.card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: 0.3s;
  display: flex;
  flex-direction: column;
}
.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
}
.card-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: #eee;
}
.card-body {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card-body .btn-card {
  margin-top: auto;
}
/* =========================
   UNIVERSAL MODERN SECTION
========================= */

.modern-section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--white);
  padding: 1.2rem 1.5rem;
  border-radius: 16px;
  box-shadow: var(--shadow);
  margin: 3rem 0 1.5rem 0;
  position: relative;
  overflow: hidden;
  transition: 0.3s;
}

.modern-section-title:hover {
  transform: translateY(-3px);
}

.btn-rekomendasi-utama {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  padding: 6px 14px;
  border-radius: 18px;
  text-decoration: none;
  font-size: 0.85rem;
  transition: 0.3s;
}
@media (max-width: 768px) {
  .btn-rekomendasi-utama {
    padding: 6px 14px;
    font-size: 0.6rem;
   
  }
}
.btn-rekomendasi-utama:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}
.color-dot {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  margin-left: 6px;
  border: 1px solid #ddd;
  vertical-align: middle;
}
.modern-section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 6px;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
}
.section-heading {
  font-size: 1.2rem;
  line-height: 1.3;
  font-weight: 600;
  position: relative;
  padding-left: 12px;
}

.section-heading::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 4px;
  height: 18px;
  background: var(--primary);
  border-radius: 2px;
}
.modern-title-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.modern-icon {
  font-size: 1.6rem;
  background: var(--accent);
  padding: 10px;
  border-radius: 50%;
}

.modern-section-title h3 {
  margin: 0;
  color: var(--primary);
  font-size: 1.3rem;
}

.modern-section-title p {
  margin: 0;
  font-size: 0.85rem;
  color: #777;
}

.modern-badge {
  background: var(--primary);
  color: white;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}

/* Variasi badge */

.modern-badge.hot {
  background: #e53935;
}

.modern-badge.category {
  background: #8e24aa;
}

.modern-badge.color {
  background: #00897b;
}

.badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  background: var(--accent);
  color: var(--primary);
  border-radius: 20px;
  font-size: 0.8rem;
  margin-bottom: 0.5rem;
}
.btn-card {
  margin-top: auto;
  background: var(--text-dark);
}

/* Admin Dashboard */
.admin-layout {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  width: 250px;
  background: var(--primary);
  color: var(--white);
  padding: 2rem 1rem;
}
.sidebar a {
  display: block;
  color: var(--white);
  text-decoration: none;
  padding: 10px;
  margin-bottom: 5px;
  border-radius: 5px;
}
.sidebar a:hover {
  background: rgba(255, 255, 255, 0.1);
}
.admin-content {
  flex: 1;
  padding: 2rem;
  background: #f0f2f5;
}

/* Utils */
.score-badge {
  background: #4caf50;
  color: white;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
}
.text-center {
  text-align: center;
}

/* ===== Responsive Navbar ===== */

.menu-toggle {
  display: none;
  font-size: 1.8rem;
  cursor: pointer;
}

.btn-register {
  background: var(--primary);
  color: white !important;
  padding: 6px 14px;
  border-radius: 6px;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    right: 20px;
    background: var(--white);
    flex-direction: column;
    box-shadow: var(--shadow);
    border-radius: 12px;
    padding: 1rem;
    width: 200px;
  }

  .nav-links a {
    margin: 10px 0;
  }

  .nav-links.show {
    display: flex;
  }
}

/* Katalog */
@media (max-width: 599px) {
  .grid-layout {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* footer */
.main-footer {
  background: var(--primary);
  color: white;
  text-align: center;
  padding: 1.5rem;
  margin-top: auto;
}

/* =========================
   TOPBAR FIX UNTUK REKOMENDASI
========================= */

header.topbar {
  background: var(--white);
  box-shadow: var(--shadow);
}

.topbar nav {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.topbar .logo {
  font-size: 1.4rem;
  font-weight: bold;
  color: var(--primary);
}

.topbar .nav-links a {
  margin-left: 18px;
}

/* =========================
   SECTION REKOMENDASI
========================= */

.rekomendasi-section {
  margin-bottom: 3rem;
}

.rekomendasi-section h2 {
  margin-bottom: 1.5rem;
  color: var(--primary);
  font-size: 1.5rem;
}

/* =========================
   CARD KHUSUS REKOMENDASI
========================= */

.card-body h3 {
  font-size: 1rem;
  margin-bottom: 0.4rem;
  color: var(--primary);
}

.badge.match-badge {
  background: #4caf50;
  color: white;
  font-weight: 600;
}

/* =========================
   GRID 
========================= */

.grid-layout {
  align-items: stretch;
  display: grid;
  gap: 2rem;
}

.card {
  height: 100%;
}

/* =========================
   RESPONSIVE NAV STABIL
========================= */

@media (max-width: 768px) {
  nav {
    position: relative;
  }

  .nav-links {
    right: 10px;
    width: 180px;
  }

  .section-title-box {
    padding: 1.5rem;
  }

  .section-title-box h2 {
    font-size: 1.4rem;
  }
}

.pagination-btn {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 6px;
  text-decoration: none;
  background: #eee;
  color: var(--primary);
  font-size: 0.85rem;
  transition: 0.2s;
}

.pagination-btn:hover {
  background: var(--secondary);
  color: white;
}

.pagination-btn.active {
  background: var(--primary);
  color: white;
  font-weight: 600;
}

.filter-actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem; 
}

/* detail */
.detail-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
  background: var(--white);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-top: 2rem;
}

.detail-image {
  flex: 1 1 400px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #f9f9f9;
  border-radius: var(--radius);
  padding: 1rem;
}

.detail-image img {
  max-width: 100%;
  object-fit: contain;
}

.detail-info {
  flex: 1 1 400px;
  display: flex;
  flex-direction: column;
}

.detail-title {
  font-size: 1.8rem;
  color: var(--primary);
  margin: 0.5rem 0;
}

.detail-price {
  font-size: 1.4rem;
  color: var(--secondary);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.detail-specs {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem 1.5rem;
  background: var(--bg-light);
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.spec-label {
  font-weight: 600;
  color: #555;
}

.action-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-back {
  background: #ccc;
}

.btn-fav {
  background: #e57373;
  color: white;
}

.btn-fav.active {
  background: #4CAF50;
}

.related-section {
  margin-top: 4rem;
}

.action-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.btn-action {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.9rem;
  cursor: pointer;
  transition: 0.3s;
  border: none;
  width: auto !important;
}

/* Back */
.btn-back {
  background: #ddd;
  color: #333;
}

.btn-back:hover {
  background: #ccc;
}

/* Favorit */
.btn-fav {
  background: #e57373;
  color: white;
}

.btn-fav.active {
  background: #4CAF50;
}

/* =========================
   PREMIUM HERO SECTION
========================= */

.hero {
  position: relative;
  background: url("../images/hero-furniture.png") center/cover no-repeat;
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(30, 20, 15, 0.75),
    rgba(93, 64, 55, 0.7)
  );
}

.hero-content {
  position: relative;
  max-width: 800px;
  padding: 2rem;
  z-index: 2;
}

.hero-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.8rem;
  letter-spacing: 1px;
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: 3rem;
  line-height: 1.2;
  margin-bottom: 1rem;
  font-weight: 700;
}

.hero p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  opacity: 0.9;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-hero {
  padding: 12px 24px;
  border-radius: 30px;
  text-decoration: none;
  font-weight: 600;
  transition: 0.3s;
}

.btn-hero.primary {
  background: white;
  color: var(--primary);
}

.btn-hero.primary:hover {
  background: var(--accent);
}

.btn-hero.secondary {
  background: transparent;
  border: 2px solid white;
  color: white;
}

.btn-hero.secondary:hover {
  background: white;
  color: var(--primary);
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 0.95rem;
  }
}

/* profil */
.profile-layout{
  display:grid;
  grid-template-columns:300px 1fr;
  gap:2rem;
}

.profile-card{
  background:var(--white);
  padding:2rem;
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  text-align:center;
}

.profile-avatar{
  width:90px;
  height:90px;
  background:var(--primary);
  color:white;
  font-size:2rem;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:50%;
  margin:0 auto 1rem;
}

.profile-form-box{
  background:var(--white);
  padding:2rem;
  border-radius:var(--radius);
  box-shadow:var(--shadow);
}

.modal{
  display:none;
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.5);
  justify-content:center;
  align-items:center;
  z-index:9999;
}

.modal-content{
  background:white;
  padding:2rem;
  border-radius:var(--radius);
  width:400px;
}

.modal-close{
  margin-top:1rem;
  background:#ccc;
}
/* wa */
.btn-wa{
    background:#3ee80b;
    color:rgb(21, 21, 21);
    text-decoration:none;
    text-align:center;
}

.btn-wa:hover{
    background:#1ebe5d;
}
@media(max-width:768px){
  .profile-layout{
    grid-template-columns:1fr;
  }
}

