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

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, Tahoma, sans-serif;
  background: #f7f6f2;
  color: #171717;
  line-height: 1.7;
}

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

button {
  font: inherit;
}

.container {
  width: min(1180px, 92%);
  margin: auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.96);
  border-bottom: 1px solid #e6e3dc;
}

.nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}

.logo {
  font-size: 27px;
  font-weight: 900;
  letter-spacing: 4px;
}

nav {
  display: flex;
  gap: 28px;
  font-size: 14px;
}

nav a:hover {
  opacity: .55;
}

.cart-btn {
  border: 1px solid #222;
  background: transparent;
  padding: 9px 15px;
  cursor: pointer;
}

.cart-btn span {
  background: #171717;
  color: white;
  display: inline-flex;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  margin-right: 7px;
  font-size: 12px;
}

.hero {
  min-height: 650px;
  background:
    radial-gradient(circle at 15% 25%, #ddd7ca, transparent 30%),
    linear-gradient(135deg, #f4f1e9, #d9d2c5);
  display: flex;
  align-items: center;
}

.hero-content {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: 70px;
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 4px;
}

.hero h1 {
  margin: 18px 0;
  font-size: clamp(45px, 6vw, 78px);
  line-height: 1.1;
  font-weight: 500;
}

.hero p {
  color: #5b5852;
  max-width: 530px;
  margin-bottom: 30px;
}

.primary-btn {
  display: inline-block;
  background: #171717;
  color: white;
  padding: 13px 30px;
}

.hero-card {
  height: 440px;
  background: #111;
  color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 30px 60px rgba(0,0,0,.18);
}

.ring {
  width: 170px;
  height: 170px;
  border: 22px solid #c7c7c7;
  border-radius: 50%;
  font-size: 50px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 35px;
}

.hero-card p {
  color: white;
  font-size: 32px;
  letter-spacing: 7px;
  margin: 0;
}

.hero-card span {
  font-size: 12px;
  letter-spacing: 4px;
  opacity: .55;
}

.features {
  background: white;
  border-bottom: 1px solid #e8e5df;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.feature-grid div {
  padding: 28px;
  text-align: center;
  border-left: 1px solid #eeeae4;
}

.feature-grid strong {
  display: block;
  font-size: 23px;
}

.feature-grid span {
  font-size: 13px;
  color: #777;
}

.products-section {
  padding: 95px 0;
}

.section-heading span {
  color: #8c877e;
  font-size: 13px;
}

.section-heading h2 {
  font-size: 38px;
  margin: 5px 0 35px;
}

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

.product-card {
  background: white;
  border: 1px solid #ece9e2;
  transition: .25s;
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 35px rgba(0,0,0,.08);
}

.product-image {
  height: 280px;
  background: #e7e3db;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 75px;
}

.product-info {
  padding: 22px;
}

.category {
  font-size: 11px;
  color: #999;
}

.product-info h3 {
  font-size: 17px;
  margin: 5px 0 14px;
  min-height: 58px;
}

.price {
  font-weight: bold;
  margin-bottom: 14px;
}

.product-info button {
  width: 100%;
  border: 0;
  background: #171717;
  color: white;
  padding: 11px;
  cursor: pointer;
}

.about {
  padding: 110px 0;
  background: #161616;
  color: white;
  text-align: center;
}

.about-box {
  max-width: 700px;
}

.about span {
  font-size: 11px;
  letter-spacing: 5px;
  opacity: .5;
}

.about h2 {
  font-size: 43px;
  margin: 14px 0;
}

.about p {
  color: #aaa;
}

footer {
  background: #0b0b0b;
  color: white;
  padding-top: 60px;
}

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

.footer-grid h3 {
  font-size: 27px;
  letter-spacing: 5px;
}

.footer-grid strong,
.footer-grid a {
  display: block;
  margin-bottom: 10px;
}

.footer-grid a {
  color: #969696;
  font-size: 13px;
}

.copyright {
  border-top: 1px solid #252525;
  text-align: center;
  margin-top: 50px;
  padding: 20px;
  color: #666;
  font-size: 12px;
}

@media (max-width: 850px) {
  nav {
    display: none;
  }

  .hero {
    padding: 70px 0;
  }

  .hero-content,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-card {
    height: 330px;
  }

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

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

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

  .hero h1 {
    font-size: 43px;
  }
}

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

.product-detail-image {
  background: #ebe7de;
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-detail-image img {
  width: 100%;
  height: 520px;
  object-fit: cover;
}

.no-product-image {
  font-size: 120px;
}

.product-detail-info {
  padding-top: 30px;
}

.product-detail-info h1 {
  font-size: 42px;
  line-height: 1.25;
  margin: 10px 0 20px;
}

.product-detail-price {
  font-size: 27px;
  font-weight: bold;
  margin-bottom: 25px;
}

.product-detail-description {
  color: #666;
  margin-bottom: 25px;
}

.product-stock {
  margin-bottom: 25px;
  font-size: 14px;
}

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

  .product-detail-image,
  .product-detail-image img {
    min-height: 350px;
    height: 350px;
  }

  .product-detail-info h1 {
    font-size: 32px;
  }
}

.cart-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
  align-items: start;
}

.cart-item {
  display: grid;
  grid-template-columns: 130px 1fr auto;
  gap: 20px;
  align-items: center;
  border-bottom: 1px solid #e5e5e5;
  padding: 20px 0;
}

.cart-item-image {
  width: 130px;
  height: 130px;
  background: #ebe7de;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 50px;
}

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

.cart-item-info h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

.cart-item-price {
  margin-bottom: 12px;
}

.quantity-control {
  display: inline-flex;
  align-items: center;
  border: 1px solid #ccc;
  margin-bottom: 10px;
}

.quantity-control button {
  width: 38px;
  height: 38px;
  border: 0;
  background: #f5f5f5;
  cursor: pointer;
  font-size: 20px;
}

.quantity-control span {
  width: 45px;
  text-align: center;
}

.remove-btn {
  display: block;
  border: 0;
  background: transparent;
  color: #a00000;
  cursor: pointer;
  padding: 0;
}

.cart-item-total {
  font-weight: bold;
  white-space: nowrap;
}

.cart-summary {
  border: 1px solid #e0e0e0;
  padding: 25px;
  position: sticky;
  top: 100px;
}

.cart-summary h2 {
  margin-top: 0;
  margin-bottom: 25px;
}

.summary-row,
.summary-total {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid #eee;
}

.summary-total {
  font-size: 20px;
  border-bottom: 0;
  margin-bottom: 20px;
}

.checkout-btn {
  width: 100%;
  display: block;
  text-align: center;
  box-sizing: border-box;
}

.continue-shopping {
  display: block;
  text-align: center;
  margin-top: 15px;
}

.empty-cart {
  text-align: center;
  padding: 70px 20px;
}

.empty-cart p {
  margin-bottom: 30px;
}

@media (max-width: 800px) {
  .cart-layout {
    grid-template-columns: 1fr;
  }

  .cart-item {
    grid-template-columns: 90px 1fr;
  }

  .cart-item-image {
    width: 90px;
    height: 90px;
  }

  .cart-item-total {
    grid-column: 2;
  }

  .cart-summary {
    position: static;
  }
}

.checkout-layout {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 50px;
  align-items: start;
}

.checkout-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.checkout-form h2 {
  margin-bottom: 15px;
}

.checkout-form label {
  font-weight: 600;
  margin-top: 8px;
}

.checkout-form input,
.checkout-form textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #ccc;
  padding: 13px;
  font: inherit;
  background: #fff;
}

.checkout-form input:focus,
.checkout-form textarea:focus {
  outline: none;
  border-color: #222;
}

.checkout-form .primary-btn {
  margin-top: 20px;
}

.checkout-summary {
  border: 1px solid #e0e0e0;
  padding: 25px;
  position: sticky;
  top: 100px;
}

.checkout-item {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid #eee;
}

#checkoutMessage {
  margin-top: 10px;
}

@media (max-width: 800px) {
  .checkout-layout {
    grid-template-columns: 1fr;
  }

  .checkout-summary {
    position: static;
  }
}
