:root {
  --bg: #ece035;
  --surface: #ece035;
  --surface-soft: #f0efec;
  --text: #1f1f1f;
  --muted: #000000;
  --line: #C62828;
  --shadow: 0 18px 40px rgba(31, 31, 31, 0.08);
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}
img {
  transition: transform 0.3s ease;
}

img:hover {
  transform: scale(1.2);
}
body {
  margin: 0;
  font-family: "Segoe UI", "Tahoma", "Arial", sans-serif;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.95), transparent 35%),
    linear-gradient(180deg, #faf9f6 0%, var(--bg) 100%);
  color: var(--text);
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
}

main {
  width: min(1120px, calc(100% - 1.5rem));
  margin: 0 auto;
  padding: 1rem 0 3rem;
}

.topbar {
  width: min(1120px, calc(100% - 1.5rem));
  margin: 1rem auto 0;
  padding: 1rem 1.1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(228, 225, 219, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 30px rgba(31, 31, 31, 0.04);
}

.brand-mark {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;
  min-width: 120px;
  padding: 0.75rem 1rem;
  border: 1px dashed #c8c2b7;
  border-radius: 16px;
  background: #fff;
}

.brand-mark__label {
  font-weight: 700;
  font-size: 0.95rem;
}

.brand-mark__hint,
.eyebrow,
.section__note,
.hero__text,
.product-card__price,
.cart-item__meta,
.empty-state,
.summary-row span,
.checkout-form span {
  color: var(--muted);
}

.brand-mark__hint {
  font-size: 0.8rem;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.nav a {
  padding: 0.65rem 0.95rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid transparent;
  transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}

.nav a:hover {
  transform: translateY(-1px);
  border-color: var(--line);
  background: var(--surface-soft);
}

.section {
  margin-top: 1.25rem;
  padding: 1.15rem;
  border: 1px solid rgba(228, 225, 219, 0.85);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow);
}

.hero {
  display: grid;
  gap: 1rem;
  overflow: hidden;
}

.hero__content {
  padding: 0.5rem;
}

.eyebrow {
  margin: 0 0 0.45rem;
  font-size: 0.88rem;
  letter-spacing: 0.02em;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  font-size: clamp(2rem, 7vw, 4rem);
  line-height: 1.12;
  margin-bottom: 0.8rem;
}

h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  margin-bottom: 0.2rem;
}

.hero__text {
  margin-bottom: 1.15rem;
  max-width: 42rem;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.hero__panel {
  display: grid;
  gap: 0.75rem;
}

.hero-card {
  padding: 1.1rem;
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, #fff, #f7f5f1);
  border: 1px solid var(--line);
}

.hero-card strong {
  display: block;
  font-size: 1.05rem;
  margin-top: 0.4rem;
}

.hero-card--muted {
  background: var(--surface-soft);
}

.section__heading {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.section__note {
  max-width: 28rem;
  margin-bottom: 0;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.95rem;
}

.product-card,
.cart-box,
.summary-box {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.product-card {
  overflow: hidden;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.product-card__image {
  min-height: 160px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 1rem;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(239, 236, 229, 0.95)),
    repeating-linear-gradient(135deg, rgba(31, 31, 31, 0.03) 0 10px, transparent 10px 20px);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-weight: 600;
  overflow: hidden;
}

.product-card__content {
  padding: 1rem;
}

.product-card__content h3 {
  margin-bottom: 0.35rem;
  font-size: 1.05rem;
}

.product-card__price {
  margin-bottom: 0.9rem;
  font-weight: 700;
}

.btn {
  border: 0;
  border-radius: 999px;
  padding: 0.82rem 1.15rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease, border-color 160ms ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--dark {
  background: #1f1f1f;
  color: #fff;
}

.btn--dark:hover {
  background: #111;
}

.btn--ghost {
  background: #fff;
  color: var(--text);
  border: 1px solid var(--line);
}

.btn--small {
  padding: 0.7rem 1rem;
  width: 100%;
}

.btn--full {
  width: 100%;
}

.cart-layout {
  display: grid;
  gap: 1rem;
}

.cart-box,
.summary-box {
  padding: 1rem;
}

.cart-items {
  display: grid;
  gap: 0.75rem;
}

.cart-item {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 0.85rem;
  padding: 0.85rem;
  border-radius: 16px;
  background: var(--surface-soft);
  border: 1px solid rgba(228, 225, 219, 0.9);
}

.cart-item__thumb {
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, #ffffff, #ebe7df);
  color: var(--muted);
  font-size: 0.75rem;
  text-align: center;
  min-height: 64px;
}

.cart-item__content {
  display: grid;
  gap: 0.55rem;
}

.cart-item__head {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: start;
}

.cart-item__head h3 {
  margin-bottom: 0.15rem;
  font-size: 1rem;
}

.cart-item__price {
  font-weight: 700;
}

.cart-item__controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.qty-control {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.25rem;
}

.qty-control button {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--surface-soft);
  cursor: pointer;
}

.qty-control span {
  min-width: 1.5rem;
  text-align: center;
  font-weight: 700;
}

.remove-btn {
  border: 1px solid var(--line);
  background: #fff;
  color: #444;
  padding: 0.65rem 0.85rem;
  border-radius: 999px;
  cursor: pointer;
}

.summary-box {
  position: sticky;
  top: 1rem;
  align-self: start;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(228, 225, 219, 0.9);
}

.summary-row--total {
  border-bottom: 0;
  padding-top: 0.8rem;
  font-size: 1.05rem;
}

.checkout-form {
  margin-top: 1rem;
  display: grid;
  gap: 0.85rem;
}

.checkout-form label {
  display: grid;
  gap: 0.35rem;
}

.checkout-form input,
.checkout-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  padding: 0.9rem 1rem;
  color: var(--text);
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.checkout-form input:focus,
.checkout-form textarea:focus {
  border-color: #bdb5a7;
  box-shadow: 0 0 0 4px rgba(31, 31, 31, 0.06);
}

.empty-state {
  padding: 1.2rem;
  text-align: center;
  border-radius: 18px;
  background: #fff;
  border: 1px dashed #cec7bc;
}

.floating-cart-bar {
  position: fixed;
  left: 50%;
  bottom: 0.85rem;
  transform: translate(-50%, 140%);
  opacity: 0;
  pointer-events: none;
  z-index: 9999;
  width: min(680px, calc(100% - 1rem));
  display: none;
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 0.95rem;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.97);
  border: 1px solid rgba(228, 225, 219, 0.98);
  box-shadow: 0 12px 30px rgba(31, 31, 31, 0.18);
  color: var(--text);
  transition: transform 220ms ease, opacity 220ms ease;
  backdrop-filter: blur(10px);
}

.floating-cart-bar--visible {
  transform: translate(-50%, 0);
  opacity: 1;
  pointer-events: auto;
}

.floating-cart-bar__icon {
  width: 2.4rem;
  height: 2.4rem;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--line);
}

.floating-cart-bar__icon svg {
  width: 1.3rem;
  height: 1.3rem;
}

.floating-cart-bar__info {
  flex: 1 1 auto;
  display: grid;
  gap: 0.1rem;
  min-width: 0;
}

.floating-cart-bar__info strong,
.floating-cart-bar__info span {
  display: block;
}

.floating-cart-bar__info strong {
  font-size: 0.98rem;
}

.floating-cart-bar__info span {
  color: var(--muted);
  font-size: 0.82rem;
}

.floating-cart-bar__action {
  flex: 0 0 auto;
  padding: 0.72rem 1rem;
  border-radius: 999px;
  background: #1f1f1f;
  color: #fff;
  font-size: 0.88rem;
  font-weight: 700;
  white-space: nowrap;
}

.muted-link {
  color: var(--muted);
  text-decoration: underline;
}

@media (min-width: 760px) {
  .hero {
    grid-template-columns: 1.35fr 0.9fr;
    align-items: stretch;
  }

  .cart-layout {
    grid-template-columns: minmax(0, 1.3fr) 360px;
  }

  .product-card__image {
    min-height: 180px;
  }
}

@media (max-width: 759px) {
  body.has-floating-cart-bar main {
    padding-bottom: 6.5rem;
  }

  .topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .nav {
    justify-content: space-between;
  }

  .nav a {
    flex: 1 1 auto;
    text-align: center;
  }

  .summary-box {
    position: static;
  }

  .floating-cart-bar {
    display: flex;
  }
}