:root {
  --primary: #54ACBF;
  --dark: #26658C;
  --light: #EAF6FA;
  --text: #333;
}

html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* BODY */
body {
  font-family: 'Sarabun', sans-serif;
  background: var(--light);
  color: var(--text);
}

/* Reset Links & Lists */
a {
  text-decoration: none;
  color: inherit;
}
ul {
  list-style: none;
}
img {
  display: block;
  max-width: 100%;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

/* Topbar */
.topbar {
  background: var(--dark);
  color: #fff;
  padding: 6px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}
.topbar .left-links,
.topbar .right-links {
  display: flex;
  align-items: center;
  gap: 12px;
}
.topbar .left-links a,
.topbar .right-links a {
  color: #fff;
  display: flex;
  align-items: center;
  transition: color 0.2s;
}
.topbar .left-links a:hover,
.topbar .right-links a:hover {
  color: var(--primary);
}
.topbar .right-links img {
  height: 18px;
  width: auto;
}

/* Masthead */
.masthead {
  background: #fff;
  border-bottom: 1px solid #ddd;
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.masthead .logo {
  font-size: 26px;
  font-weight: bold;
  color: var(--primary);
}
.masthead .search {
  flex: 1;
  margin: 0 24px;
  position: relative;
}
.masthead .search input {
  width: 100%;
  padding: 8px 40px 8px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
}
.masthead .search button {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 4px;
  padding: 6px 10px;
  cursor: pointer;
}
.masthead .cart {
  font-size: 20px;
  color: var(--dark);
  position: relative;
  cursor: pointer;
}
.masthead .cart .badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: crimson;
  color: #fff;
  border-radius: 50%;
  padding: 2px 6px;
  font-size: 12px;
}

/* Navbar */
.navbar {
  background: var(--primary);
}
.navbar .links {
  display: flex;
  justify-content: center;
  padding: 10px 0;
}
.navbar .links a {
  color: #fff;
  margin: 0 16px;
  font-weight: 500;
  transition: color 0.2s;
}
.navbar .links a:hover {
  color: #FFD700;
}

/* Search Filter */
.search-filter {
  display: flex;
  gap: 8px;
  margin: 20px 0;
}
.search-filter input,
.search-filter select {
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}
.search-filter button {
  background: var(--dark);
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
}
.search-filter button:hover {
  background: var(--primary);
}

/* Categories */
.categories {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 24px;
}
.categories h2 {
  font-size: 20px;
  color: var(--dark);
  margin-bottom: 16px;
}
.category-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.category-item {
  width: 100px;
  text-align: center;
}
.category-item img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  margin-bottom: 8px;
  border: 2px solid transparent;
  border-radius: 8px;
  transition: border-color 0.2s;
}
.category-item:hover img {
  border-color: var(--primary);
}
.category-item p {
  font-size: 14px;
  color: var(--text);
}

/* Products */
.products {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
}
.products h2 {
  font-size: 20px;
  color: var(--dark);
  margin-bottom: 16px;
}
.product-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
.product-item {
  width: 180px;
  text-align: center;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s, box-shadow 0.2s;
}
.product-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}
.product-item img {
  height: 140px;
  object-fit: contain;
  background: #fafafa;
}
.product-item p {
  font-size: 14px;
  margin: 8px 0;
}
.product-item .price {
  font-size: 16px;
  color: var(--primary);
  font-weight: bold;
  margin-bottom: 8px;
}
.product-item a {
  display: inline-block;
  background: var(--dark);
  color: #fff;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 14px;
  margin-bottom: 12px;
}
.product-item a:hover {
  background: var(--primary);
}

/* Footer */
footer {
  background: var(--dark);
  color: #fff;
  text-align: center;
  padding: 16px;
  margin-top: 32px;
  font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
  .masthead {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }
  .navbar .links {
    flex-wrap: wrap;
    justify-content: center;
  }
  .product-list {
    justify-content: center;
  }
  .search-filter {
    flex-direction: column;
  }
  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
  .topbar .left-links,
  .topbar .right-links {
    flex-wrap: wrap;
  }
}

/* Footer แบบเต็มจอ */
footer,
.site-footer-full {
  background-color: #2f648d;
  color: #fff;
  text-align: center;
  padding: 20px 0;
  font-size: 14px;
  width: 100%;
  box-shadow: 0 -1px 5px rgba(0,0,0,0.1);
  margin: 0;
  clear: both;
}
.site-footer-full .footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

/* Suggestion Box */
.search-box {
  position: relative;
  width: 100%;
}
.suggestion-box {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #ccc;
  z-index: 10;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  border-radius: 4px;
}
.suggestion-box div {
  padding: 8px 12px;
  cursor: pointer;
  font-size: 14px;
}
.suggestion-box div:hover {
  background-color: #f0f0f0;
}
.masthead .logo img {
  height: 40px;
}


/* footer */

/* Footer Shopee Style */
.site-footer {
  background-color: #f8f8f8;
  color: #333;
  padding: 40px 0 20px;
  font-size: 14px;
  border-top: 1px solid #ddd;
  width: 100%;
}

.site-footer .footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 20px;
}

.footer-col {
  flex: 1 1 180px;
  min-width: 160px;
}

.footer-col h4 {
  font-weight: bold;
  margin-bottom: 12px;
  color: #000;
}

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col ul li {
  margin-bottom: 6px;
  color: #555;
}

.footer-col ul li a {
  color: #555;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-col ul li a:hover {
  color: var(--primary);
}

/* Footer Social */
.footer-social img {
  width: 18px;
  margin-right: 6px;
  vertical-align: middle;
}

/* Footer Payment/Shipping Icons */
.footer-col .icon-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.footer-col .icon-grid img {
  height: 28px;
  background: white;
  padding: 2px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

/* QR Code Download */
.footer-qr {
  display: flex;
  gap: 10px;
}

.footer-qr img {
  height: 80px;
  border: 1px solid #ccc;
}

/* Copyright */
.footer-bottom {
  text-align: center;
  margin-top: 20px;
  color: #999;
  font-size: 12px;
}
/*close footer */