@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600;700;800&family=Nunito:wght@600;700;800;900&family=Playfair+Display:wght@600;700;800&display=swap');

:root {
  --k-cream: #fbf7ef;
  --k-paper: #fffdf8;
  --k-ink: #261d18;
  --k-muted: #6f655c;
  --k-maroon: #8b1f2a;
  --k-maroon2: #68131d;
  --k-gold: #c99a45;
  --k-gold2: #e2be78;
  --k-green: #07382f;
  --k-green2: #0e604f;
  --k-line: rgba(201, 154, 69, 0.24);
  --k-shadow: 0 22px 60px rgba(45, 30, 18, 0.08);
  --k-shadow-hover: 0 34px 85px rgba(45, 30, 18, 0.16);
  --k-font: "Cormorant Garamond", "Playfair Display", Georgia, serif;
  --k-radius-lg: 24px;
  --k-radius-md: 18px;
  --k-radius-sm: 12px;
}

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

html, body {
  max-width: 100%;
  overflow-x: hidden;
  background: var(--k-cream) !important;
  color: var(--k-ink) !important;
  font-family: var(--k-font) !important;
  scroll-behavior: smooth;
  min-height: 100vh;
}

body {
  position: relative;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 120px;
}

body::before {
  content: "";
  position: fixed;
  inset: -18%;
  z-index: -1;
  pointer-events: none;
  background: 
    radial-gradient(circle at 12% 12%, rgba(201, 154, 69, 0.1), transparent 22%),
    radial-gradient(circle at 78% 18%, rgba(7, 56, 47, 0.15), transparent 26%),
    radial-gradient(circle at 45% 84%, rgba(201, 154, 69, 0.07), transparent 25%);
  animation: kgAmbient 15s ease-in-out infinite alternate;
}

@keyframes kgAmbient {
  from { transform: translate3d(-1%, 0, 0) scale(1); }
  to { transform: translate3d(1.2%, -1%, 0) scale(1.05); }
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.22s ease;
}

img {
  max-width: 100%;
  display: block;
}

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

/* TOPBAR */
.topbar {
  position: sticky;
  top: 0;
  background: rgba(251, 247, 239, 0.96) !important;
  backdrop-filter: blur(14px) !important;
  z-index: 1000;
  border-bottom: 1px solid rgba(201, 154, 69, 0.18) !important;
  box-shadow: 0 10px 28px rgba(45, 30, 18, 0.05) !important;
}

.nav {
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: flex !important;
  align-items: center !important;
  gap: 13px !important;
  text-decoration: none !important;
  min-width: 0 !important;
}

.brand::before {
  content: "" !important;
  width: 56px !important;
  height: 56px !important;
  flex: 0 0 56px !important;
  display: block !important;
  border-radius: 50% !important;
  background: url("images/logo-mark.png") center/contain no-repeat !important;
  filter: drop-shadow(0 6px 14px rgba(201, 154, 69, 0.2)) !important;
}

.brand h1 {
  font-family: var(--k-font) !important;
  color: #3e171b !important;
  font-weight: 700 !important;
  font-size: 26px !important;
  line-height: 1.05 !important;
  margin: 0 !important;
}

.brand small {
  display: block !important;
  font-family: var(--k-font) !important;
  font-weight: 700 !important;
  color: #7b4e25 !important;
  letter-spacing: 2px !important;
  text-transform: lowercase !important;
  font-size: 11px !important;
  line-height: 1.2 !important;
  margin-top: 2px !important;
}

.links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.links a {
  color: #3e171b !important;
}

.links a:hover {
  color: var(--k-gold) !important;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.btn {
  border-radius: 999px !important;
  padding: 10px 24px !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  letter-spacing: 0.5px !important;
  text-transform: uppercase !important;
  background: transparent !important;
  color: var(--k-maroon) !important;
  border: 1px solid rgba(201, 154, 69, 0.6) !important;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(139, 31, 42, 0.1);
  border-color: var(--k-maroon) !important;
}

.btn.fill {
  background: linear-gradient(135deg, var(--k-maroon), var(--k-maroon2)) !important;
  color: #fff8ed !important;
  border-color: transparent !important;
}

.btn.fill:hover {
  box-shadow: 0 10px 24px rgba(139, 31, 42, 0.25);
  background: var(--k-maroon) !important;
}

.hamb {
  display: none !important;
}

/* K5 HAMBURGER BUTTON IN NAVBAR */
.k5-top-menu {
  display: grid !important;
  place-items: center !important;
  width: 50px !important;
  height: 50px !important;
  min-width: 50px !important;
  border-radius: 50% !important;
  border: 1px solid rgba(201, 154, 69, 0.45) !important;
  background: rgba(255, 255, 255, 0.5) !important;
  color: var(--k-gold) !important;
  cursor: pointer !important;
  position: relative !important;
  z-index: 10002 !important;
  transition: all 0.25s ease;
}

.k5-top-menu:hover {
  background: rgba(201, 154, 69, 0.1) !important;
  transform: scale(1.05);
}

.k5-top-menu span,
.k5-top-menu span:before,
.k5-top-menu span:after {
  content: "" !important;
  display: block !important;
  width: 22px !important;
  height: 2px !important;
  border-radius: 99px !important;
  background: var(--k-gold) !important;
  transition: .28s ease !important;
}

.k5-top-menu span {
  position: relative;
}

.k5-top-menu span:before {
  position: absolute;
  top: -7px;
  left: 0;
}

.k5-top-menu span:after {
  position: absolute;
  top: 7px;
  left: 0;
}

body.k5-open .k5-top-menu span {
  background: transparent !important;
}

body.k5-open .k5-top-menu span:before {
  transform: rotate(45deg) !important;
  top: 0 !important;
}

body.k5-open .k5-top-menu span:after {
  transform: rotate(-45deg) !important;
  top: 0 !important;
}

/* TOP HERO */
.hero-section {
  position: relative;
  min-height: 480px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 80px 20px 100px;
  color: #fff;
  border-bottom: 1px solid rgba(201, 154, 69, 0.2);
}

.hero-section.dine {
  background: 
    linear-gradient(180deg, rgba(18, 11, 10, 0.65) 0%, rgba(18, 11, 10, 0.85) 100%),
    url('https://images.unsplash.com/photo-1600891964599-f61ba0e24092?auto=format&fit=crop&w=1600&q=80') center/cover no-repeat;
}

.hero-section.coffee {
  background: 
    linear-gradient(180deg, rgba(18, 11, 10, 0.65) 0%, rgba(18, 11, 10, 0.85) 100%),
    url('https://images.unsplash.com/photo-1495474472287-4d71bcdd2085?auto=format&fit=crop&w=1600&q=80') center/cover no-repeat;
}

.hero-section.bakery {
  background: 
    linear-gradient(180deg, rgba(18, 11, 10, 0.65) 0%, rgba(18, 11, 10, 0.85) 100%),
    url('https://images.unsplash.com/photo-1578985545062-69928b1d9587?auto=format&fit=crop&w=1600&q=80') center/cover no-repeat;
}

.hero-crest {
  width: 80px;
  height: 80px;
  margin-bottom: 16px;
  border-radius: 50%;
  background: url("images/logo-mark.png") center/contain no-repeat;
  filter: drop-shadow(0 10px 24px rgba(216, 175, 98, 0.4));
  animation: float 4s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero-section h2 {
  font-size: clamp(34px, 5vw, 68px);
  font-weight: 700;
  letter-spacing: 0.5px;
  text-shadow: 0 10px 30px rgba(0,0,0,0.5);
  margin-bottom: 8px;
}

.hero-section .welcome-text {
  font-size: 14px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--k-gold2);
  font-weight: 700;
  margin-bottom: 12px;
}

.hero-section p.subtitle {
  font-size: clamp(16px, 2vw, 22px);
  color: #f7edd7;
  max-width: 600px;
  margin: 10px auto 24px;
  font-style: italic;
  text-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

/* CUSTOMER INFO BAR */
.customer-info-bar {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 8px 20px;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  font-size: 14px;
  letter-spacing: 0.5px;
  margin-bottom: 24px;
}

.customer-info-bar span {
  font-weight: 600;
  color: #fff;
}

.customer-info-bar .divider {
  width: 1px;
  height: 14px;
  background: rgba(255, 255, 255, 0.25);
}

.customer-info-bar a.history-link {
  color: var(--k-gold2);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 5px;
}

.customer-info-bar a.history-link:hover {
  color: #fff;
  text-shadow: 0 0 10px rgba(255,255,255,0.4);
}

/* CARDS WRAPPER (Sliding up overlapping the hero) */
.cards-container-wrap {
  margin-top: -50px;
  position: relative;
  z-index: 10;
  background: var(--k-paper);
  border-radius: 40px 40px 0 0;
  padding: 48px 0 64px;
  box-shadow: 0 -15px 50px rgba(0,0,0,0.06);
  border-top: 1px solid rgba(201, 154, 69, 0.15);
}

/* SEARCH BAR */
.search-wrapper {
  max-width: 680px;
  margin: 0 auto 40px;
  padding: 0 16px;
}

.search-box {
  position: relative;
  display: flex;
  align-items: center;
  border-radius: 999px;
  border: 1px solid rgba(201, 154, 69, 0.45);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  box-shadow: var(--k-shadow);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 4px 6px;
}

.search-box:focus-within {
  border-color: var(--k-gold);
  box-shadow: 0 15px 45px rgba(201, 154, 69, 0.18);
  transform: translateY(-2px);
}

.search-box .search-icon {
  margin-left: 20px;
  color: var(--k-muted);
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-box input {
  flex: 1;
  height: 52px;
  border: 0;
  background: transparent;
  padding: 0 16px;
  font-size: 17px;
  font-weight: 600;
  color: var(--k-ink);
  outline: none;
  font-family: inherit;
}

.search-box input::placeholder {
  color: var(--k-muted);
  font-style: italic;
  font-weight: 500;
}

.search-box .clear-btn {
  margin-right: 12px;
  border: 0;
  background: transparent;
  color: var(--k-muted);
  font-size: 20px;
  cursor: pointer;
  display: none;
  padding: 4px;
}

.search-box .clear-btn.show {
  display: block;
}

/* SECTION HEADINGS */
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 28px;
  border-bottom: 1px solid rgba(201, 154, 69, 0.15);
  padding-bottom: 12px;
}

.section-head h2 {
  font-size: 32px;
  color: var(--k-maroon);
  font-weight: 700;
}

.section-head .count-pill {
  background: rgba(201, 154, 69, 0.08);
  border: 1px solid rgba(201, 154, 69, 0.25);
  border-radius: 999px;
  padding: 6px 16px;
  font-size: 15px;
  font-weight: 700;
  color: #8b5e26;
}

/* CATEGORY GRID */
.category-section-title {
  font-size: 22px;
  color: #7b4e25;
  font-weight: 700;
  margin-bottom: 20px;
  text-align: left;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.category-section-title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(201, 154, 69, 0.2);
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 48px;
  transition: opacity 0.28s ease, max-height 0.36s ease, margin 0.36s ease;
  overflow: hidden;
  max-height: 1000px;
  opacity: 1;
}

.category-grid.fade-out {
  opacity: 0;
}

.category-grid.collapsed {
  display: flex;
  grid-template-columns: none;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  gap: 10px;
  max-height: 64px;
  margin-bottom: 24px;
  padding-bottom: 6px;
  scrollbar-width: thin;
}

.category-grid.collapsed .category-card {
  flex: 0 0 auto;
  flex-direction: row;
  padding: 8px 16px;
  gap: 8px;
  border-radius: 99px;
}

.category-grid.collapsed .category-img-wrap {
  width: 34px;
  height: 34px;
}

.category-grid.collapsed .category-card span {
  font-size: 14px;
  white-space: nowrap;
}

.category-grid.collapsed .category-card:hover,
.category-grid.collapsed .category-card.active {
  transform: none;
}

.category-card {
  background: var(--k-paper);
  border: 1px solid rgba(201, 154, 69, 0.22);
  border-radius: var(--k-radius-md);
  padding: 16px;
  text-align: center;
  cursor: pointer;
  box-shadow: var(--k-shadow);
  transition: all 0.32s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.category-card:hover, .category-card.active {
  transform: translateY(-6px);
  box-shadow: var(--k-shadow-hover);
  border-color: var(--k-gold);
  background: #fffdf5;
}

.category-card.active {
  background: #fffaf0;
}

.category-img-wrap {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(201, 154, 69, 0.15);
  transition: all 0.32s ease;
}

.category-card:hover .category-img-wrap,
.category-card.active .category-img-wrap {
  border-color: var(--k-gold);
  transform: scale(1.05);
}

.category-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-card span {
  font-size: 17px;
  font-weight: 700;
  color: var(--k-ink);
  transition: color 0.22s ease;
}

.category-card:hover span,
.category-card.active span {
  color: var(--k-maroon);
}

/* PRODUCT GRID */
.product-grid-wrapper {
  min-height: 200px;
}

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

.product-card {
  background: var(--k-paper);
  border: 1px solid rgba(201, 154, 69, 0.2);
  border-radius: var(--k-radius-lg);
  overflow: hidden;
  box-shadow: var(--k-shadow);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--k-shadow-hover);
  border-color: var(--k-gold);
}

.product-img-wrap {
  height: 220px;
  overflow: hidden;
  position: relative;
  background: #fff;
}

.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-img-wrap img {
  transform: scale(1.04);
}

.product-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  background: linear-gradient(135deg, var(--k-maroon), var(--k-maroon2));
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 6px 14px;
  border-radius: 99px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  z-index: 2;
}

.product-info {
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  flex: 1;
}

.product-info h3 {
  font-size: 23px;
  color: var(--k-maroon);
  font-weight: 700;
  margin-bottom: 8px;
  line-height: 1.2;
}

.product-info p.description {
  font-size: 15px;
  color: var(--k-muted);
  line-height: 1.5;
  margin-bottom: 18px;
  flex: 1;
}

.product-info .price {
  font-size: 24px;
  font-weight: 800;
  color: var(--k-ink);
  margin-bottom: 16px;
}

/* SIZE SELECTOR PILLS */
.size-selector {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 18px;
  width: 100%;
  flex-wrap: wrap;
}

.size-pill {
  border-radius: 99px;
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  background: var(--k-cream);
  border: 1px solid rgba(201, 154, 69, 0.4);
  color: var(--k-ink);
  transition: all 0.22s ease;
}

.size-pill:hover {
  border-color: var(--k-gold);
  background: #fffdf5;
}

.size-pill.active {
  background: var(--k-green) !important;
  color: #fff !important;
  border-color: transparent !important;
  box-shadow: 0 4px 12px rgba(7, 56, 47, 0.2);
}

/* CARD ACTION CONTAINER (Add to cart or Stepper) */
.card-action-container {
  width: 100%;
  margin-top: auto;
  min-height: 48px;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* ADD TO CART BUTTON */
.add-to-cart-btn {
  width: 100%;
  height: 48px;
  border-radius: 99px;
  border: 0;
  background: var(--k-green);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(7, 56, 47, 0.18);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.add-to-cart-btn:hover {
  background: var(--k-green2);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(7, 56, 47, 0.28);
}

.add-to-cart-btn:active {
  transform: translateY(0);
}

/* STEPPER */
.quantity-stepper {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  background: rgba(7, 56, 47, 0.06);
  border: 1px solid rgba(7, 56, 47, 0.14);
  border-radius: 99px;
  padding: 4px;
}

.quantity-stepper button {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 0;
  background: var(--k-green);
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.quantity-stepper button:hover {
  background: var(--k-green2);
  transform: scale(1.05);
}

.quantity-stepper span {
  font-size: 17px;
  font-weight: 800;
  min-width: 24px;
  text-align: center;
  color: var(--k-green);
}

/* EMPTY CONTAINER */
.empty-container {
  grid-column: 1 / -1;
  text-align: center;
  padding: 48px 24px;
  border: 2px dashed rgba(201, 154, 69, 0.25);
  background: rgba(255, 255, 255, 0.4);
  border-radius: var(--k-radius-lg);
  color: var(--k-muted);
}

.empty-container svg {
  width: 48px;
  height: 48px;
  margin-bottom: 12px;
  color: var(--k-gold);
}

.empty-container p {
  font-size: 18px;
  font-weight: 700;
  font-style: italic;
}

/* FLOATING CART */
.floating-cart {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(40px);
  width: min(640px, 92%);
  height: 76px;
  background: rgba(7, 56, 47, 0.95);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 8px 24px;
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: all 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.floating-cart.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.floating-cart-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.cart-icon-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-icon-wrap svg {
  width: 26px;
  height: 26px;
  fill: var(--k-gold2);
}

.cart-count-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: var(--k-maroon);
  color: #fff;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  font-size: 11px;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.cart-totals {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.5px;
}

.cart-view-btn {
  background: linear-gradient(135deg, var(--k-gold), #b8832f);
  color: #fff;
  border: 0;
  height: 60px;
  padding: 0 32px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.5px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.25);
  transition: all 0.25s ease;
}

.cart-view-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201, 154, 69, 0.4);
}

.cart-view-btn .arrow {
  font-size: 18px;
  transition: transform 0.25s ease;
}

.cart-view-btn:hover .arrow {
  transform: translateX(4px);
}

/* SIDE DRAWER */
.k5-backdrop {
  position: fixed !important;
  inset: 0 !important;
  z-index: 99996 !important;
  background: rgba(18, 11, 10, 0.6) !important;
  backdrop-filter: blur(8px) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  transition: .35s ease !important;
}

body.k5-open .k5-backdrop {
  opacity: 1 !important;
  pointer-events: auto !important;
}

.k5-drawer {
  position: fixed !important;
  top: 0 !important;
  right: 0 !important;
  left: auto !important;
  height: 100vh !important;
  width: min(450px, 92vw) !important;
  z-index: 99997 !important;
  padding: 38px 32px !important;
  overflow-y: auto !important;
  background: 
    radial-gradient(circle at 12% 0%, rgba(201, 154, 69, 0.18), transparent 30%),
    linear-gradient(145deg, rgba(17, 11, 10, 0.98), rgba(6, 52, 43, 0.98)) !important;
  border-left: 1px solid rgba(201, 154, 69, 0.42) !important;
  box-shadow: -45px 0 110px rgba(0, 0, 0, 0.65) !important;
  transform: translateX(112%) !important;
  transition: transform 0.55s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

body.k5-open .k5-drawer {
  transform: translateX(0) !important;
}

.k5-head {
  display: flex !important;
  align-items: center !important;
  gap: 16px !important;
  margin-bottom: 32px !important;
  border-bottom: 1px solid rgba(201, 154, 69, 0.2);
  padding-bottom: 20px;
}

.k5-head img {
  width: 72px !important;
  height: 72px !important;
  object-fit: contain !important;
  border-radius: 50%;
}

.k5-head h2 {
  margin: 0 !important;
  color: #fff8ef !important;
  font-family: var(--k-font) !important;
  font-size: 30px !important;
  line-height: 1 !important;
}

.k5-head p {
  margin: 5px 0 0 !important;
  color: var(--k-gold) !important;
  font-weight: 700 !important;
  letter-spacing: 2px !important;
  text-transform: lowercase !important;
  font-size: 12px !important;
}

.k5-links {
  display: grid !important;
  gap: 14px !important;
}

.k5-links a {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  padding: 16px 20px !important;
  border-radius: var(--k-radius-md) !important;
  text-decoration: none !important;
  color: #fff8ef !important;
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(201, 154, 69, 0.18) !important;
  font-weight: 700 !important;
  letter-spacing: 1px !important;
  text-transform: uppercase !important;
  font-size: 14px !important;
  transition: all 0.25s ease !important;
}

.k5-links a:hover {
  background: rgba(201, 154, 69, 0.14) !important;
  border-color: rgba(201, 154, 69, 0.55) !important;
  transform: translateX(-4px);
}

body.k5-open {
  overflow: hidden !important;
}

/* MODALS */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(18, 11, 10, 0.6);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.show {
  display: flex;
  opacity: 1;
}

.box {
  width: min(640px, 100%);
  max-height: 85vh;
  overflow-y: auto;
  background: var(--k-paper);
  border: 1px solid rgba(201, 154, 69, 0.3);
  border-radius: var(--k-radius-lg);
  padding: 36px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.25);
  transform: translateY(30px);
  transition: transform 0.3s ease;
}

.modal.show .box {
  transform: translateY(0);
}

.box-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  border-bottom: 1px solid rgba(201, 154, 69, 0.15);
  padding-bottom: 14px;
}

.box-head h2 {
  font-size: 28px;
  color: var(--k-maroon);
}

.box-head .x {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(201, 154, 69, 0.12);
  color: var(--k-maroon);
  font-size: 26px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.box-head .x:hover {
  background: var(--k-maroon);
  color: #fff;
}

/* FORMS IN MODALS */
.form {
  display: grid;
  gap: 16px;
}

.form label {
  display: grid;
  gap: 6px;
  font-weight: 700;
  font-size: 15px;
  color: var(--k-ink);
}

.form label small {
  color: var(--k-muted);
  font-size: 12px;
  font-weight: 500;
}

.form input, .form textarea, .form select {
  width: 100%;
  border: 1px solid rgba(201, 154, 69, 0.4);
  border-radius: var(--k-radius-md);
  padding: 12px 16px;
  color: var(--k-ink);
  background: #fff;
  font-weight: 600;
  outline: none;
  font-family: inherit;
  font-size: 16px;
  transition: all 0.25s ease;
}

.form input:focus, .form select:focus, .form textarea:focus {
  border-color: var(--k-gold);
  box-shadow: 0 0 0 4px rgba(201, 154, 69, 0.15);
  background: #fffdfc;
}

.form select {
  cursor: pointer;
}

.primary {
  border: 0;
  border-radius: 99px;
  padding: 14px 28px;
  background: var(--k-green);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(7, 56, 47, 0.18);
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.primary:hover {
  background: var(--k-green2);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(7, 56, 47, 0.28);
}

.secondary {
  border: 1px solid rgba(201, 154, 69, 0.5);
  border-radius: 99px;
  padding: 14px 28px;
  background: #fffdf5;
  color: #8b5e26;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.secondary:hover {
  background: var(--k-cream);
  border-color: var(--k-gold);
}

/* LOGIN GATE */
.gate .box {
  padding: 40px;
}

.gate h2 {
  font-size: 30px;
  margin-bottom: 10px;
  color: var(--k-maroon);
}

.gate p {
  color: var(--k-muted);
  font-weight: 600;
  line-height: 1.5;
  margin-bottom: 24px;
  font-size: 16px;
}

.gate-actions {
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 14px;
}

/* CART LIST */
.cart-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid rgba(201, 154, 69, 0.15);
}

.cart-line h4 {
  font-size: 18px;
  color: var(--k-maroon);
  font-weight: 700;
}

.cart-line p {
  font-size: 14px;
  color: var(--k-muted);
  font-weight: 600;
  margin-top: 4px;
}

.total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 20px;
  font-weight: 700;
  margin: 24px 0;
  border-top: 2px solid rgba(201, 154, 69, 0.25);
  padding-top: 20px;
}

.total b {
  font-size: 28px;
  color: var(--k-maroon);
}

/* HISTORY BOX */
.history {
  display: none;
  margin-bottom: 24px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(201, 154, 69, 0.3);
  border-radius: var(--k-radius-lg);
  padding: 24px;
  box-shadow: var(--k-shadow);
  backdrop-filter: blur(8px);
}

.history-top {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  border-bottom: 1px solid rgba(201, 154, 69, 0.15);
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.history-top h3 {
  font-size: 20px;
  color: var(--k-maroon);
}

.history p {
  color: var(--k-muted);
  font-weight: 600;
  font-size: 15px;
}

.history-close {
  border: 0;
  background: rgba(201, 154, 69, 0.12);
  color: var(--k-maroon);
  border-radius: 99px;
  padding: 6px 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.history-close:hover {
  background: var(--k-maroon);
  color: #fff;
}

.history-row {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 10px;
  scrollbar-width: thin;
}

.history-card {
  min-width: 240px;
  background: #fff;
  border: 1px solid rgba(201, 154, 69, 0.22);
  border-radius: var(--k-radius-md);
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.history-card b {
  display: block;
  font-size: 16px;
  color: var(--k-maroon);
  margin-bottom: 6px;
}

.history-card small {
  display: block;
  font-size: 13px;
  color: var(--k-muted);
  line-height: 1.5;
  font-weight: 600;
}

/* FOOTER */
footer.king-footer {
  background: linear-gradient(180deg, #2a1a14 0%, #1a100c 100%) !important;
  color: #fff8e8 !important;
  border-top: 2px solid rgba(201, 154, 69, 0.72) !important;
  margin-top: 64px !important;
  padding: 0 !important;
  text-align: left !important;
  opacity: 1 !important;
}

footer.king-footer * {
  color: #fff2d6 !important;
  opacity: 1 !important;
  visibility: visible !important;
}

footer.king-footer .king-foot {
  width: min(1180px, 92%) !important;
  margin: auto !important;
  padding: 54px 0 46px !important;
  display: grid !important;
  grid-template-columns: 1.35fr 1fr 1fr 1.25fr !important;
  gap: 34px !important;
  align-items: start !important;
}

footer.king-footer h3,
footer.king-footer h4 {
  color: var(--k-gold2) !important;
  margin: 0 0 14px !important;
  font-weight: 700 !important;
}

footer.king-footer h3 {
  font-size: 30px !important;
}

footer.king-footer h4 {
  font-size: 23px !important;
}

footer.king-footer p,
footer.king-footer a {
  color: #fff2d6 !important;
  font-size: 17px !important;
  line-height: 1.72 !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  display: block !important;
  margin-bottom: 8px;
}

footer.king-footer a:hover {
  color: var(--k-gold) !important;
}

footer.king-footer .king-foot-logo {
  display: flex !important;
  align-items: center !important;
  gap: 14px !important;
  margin-bottom: 15px !important;
}

footer.king-footer .king-foot-logo img {
  width: 66px !important;
  height: 66px !important;
  border-radius: 50% !important;
  object-fit: contain !important;
}

footer.king-footer .king-foot-sub {
  color: var(--k-gold2) !important;
  margin: 2px 0 0 !important;
  line-height: 1.1 !important;
  letter-spacing: 2px !important;
  text-transform: lowercase !important;
  font-size: 11px !important;
}

footer.king-footer .king-social {
  display: flex !important;
  flex-direction: row !important;
  gap: 12px !important;
  align-items: center !important;
  flex-wrap: nowrap !important;
  margin-top: 19px !important;
}

footer.king-footer .king-social a {
  width: 46px !important;
  height: 46px !important;
  min-width: 46px !important;
  display: grid !important;
  place-items: center !important;
  border-radius: 50% !important;
  background: linear-gradient(135deg, #e6c478, #b8832f) !important;
  border: 1px solid rgba(255, 236, 190, 0.34) !important;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.24) !important;
  padding: 0 !important;
  margin-bottom: 0 !important;
}

footer.king-footer .king-social svg {
  width: 22px !important;
  height: 22px !important;
  fill: #24130c !important;
  display: block !important;
}

footer.king-footer .king-bottom {
  border-top: 1px solid rgba(201, 154, 69, 0.18) !important;
  padding: 17px 0 !important;
  text-align: center !important;
  color: var(--k-gold2) !important;
  background: rgba(0, 0, 0, 0.14) !important;
  font-weight: 700 !important;
  font-size: 16px !important;
}

/* WHATSAPP FLOAT */
.wa {
  position: fixed;
  right: 24px;
  bottom: 112px;
  background: #25d366;
  color: #fff;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 30px;
  z-index: 99;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
  transition: all 0.22s ease;
}

.wa:hover {
  transform: scale(1.08) translateY(-2px);
  box-shadow: 0 18px 45px rgba(37, 211, 102, 0.4);
}

/* FADE TRANSITIONS */
#menuArea {
  transition: opacity 0.28s ease, transform 0.28s ease;
  opacity: 1;
  transform: translateY(0);
}

#menuArea.fade-out {
  opacity: 0;
  transform: translateY(12px);
}

/* SUCCESS GLOW ON BUTTON PRESS */
@keyframes successGlow {
  0% { box-shadow: 0 0 0 0px rgba(7, 56, 47, 0.5); transform: scale(1); }
  50% { box-shadow: 0 0 20px 6px rgba(7, 56, 47, 0.3); transform: scale(1.03); }
  100% { box-shadow: 0 0 0 0px rgba(7, 56, 47, 0); transform: scale(1); }
}

.btn-success-anim {
  animation: successGlow 0.45s ease-out;
}

@keyframes bounceCart {
  0%, 100% { transform: translateX(-50%) translateY(0) scale(1); }
  50% { transform: translateX(-50%) translateY(-10px) scale(1.04); }
}

.cart-bounce-anim {
  animation: bounceCart 0.5s cubic-bezier(0.25, 1.5, 0.5, 1);
}

/* RESPONSIVE MEDIA QUERIES */
@media (max-width: 992px) {
  .category-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  footer.king-footer .king-foot {
    grid-template-columns: 1fr 1fr !important;
    gap: 30px !important;
  }
}

@media (max-width: 768px) {
  .links, .nav-actions {
    display: none !important;
  }
  .hamb {
    display: grid !important;
  }
  .nav {
    height: 76px;
  }
  .cards-container-wrap {
    padding-top: 36px;
  }
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
  .product-img-wrap {
    height: 120px;
  }
  .product-info {
    padding: 12px;
  }
  .product-info h3 {
    font-size: 15px;
    margin-bottom: 4px;
  }
  .product-info p.description {
    font-size: 12px;
    margin-bottom: 10px;
    line-height: 1.4;
  }
  .product-info .price {
    font-size: 17px;
    margin-bottom: 10px;
  }
  .product-badge {
    font-size: 9px;
    padding: 4px 9px;
    top: 8px;
    left: 8px;
  }
  .size-selector {
    gap: 5px;
    margin-bottom: 10px;
  }
  .size-pill {
    padding: 4px 10px;
    font-size: 11px;
  }
  .add-to-cart-btn {
    height: 38px;
    font-size: 12px;
    gap: 5px;
  }
  .card-action-container {
    min-height: 38px;
  }
  .hero-section {
    min-height: 400px;
    padding-top: 60px;
  }
  .customer-info-bar {
    padding: 6px 16px;
    font-size: 13px;
  }
  .gate-actions {
    grid-template-columns: 1fr;
  }
  .box {
    padding: 24px;
  }
}

@media (max-width: 576px) {
  footer.king-footer .king-foot {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
    padding: 40px 0 !important;
  }
  footer.king-footer .king-social {
    display: flex !important;
    flex-direction: row !important;
  }
  .floating-cart {
    height: 68px;
    padding-left: 18px;
    bottom: 16px;
  }
  .cart-view-btn {
    height: 52px;
    padding: 0 24px;
    font-size: 14px;
  }
  .cart-totals {
    font-size: 16px;
  }
  .wa {
    bottom: 96px;
    width: 52px;
    height: 52px;
    font-size: 26px;
  }
}


/* Exact homepage-style footer spacing + real WhatsApp icon */
footer.king-footer .king-foot-brand > p { display:none !important; }
footer.king-footer .king-contact-gap { margin-top:22px !important; }
.wa { text-decoration:none !important; }
.wa svg { width:31px !important; height:31px !important; fill:#fff !important; display:block !important; }

/* WhatsApp brand button refinement */
.wa{
  width:56px !important;
  height:56px !important;
  background:#25D366 !important;
  border-radius:50% !important;
  padding:0 !important;
  overflow:hidden !important;
}
.wa svg{
  width:32px !important;
  height:32px !important;
  fill:#fff !important;
  display:block !important;
}
@media(max-width:700px){
  .wa{width:52px !important;height:52px !important;}
  .wa svg{width:29px !important;height:29px !important;}
}


/* =========================================================
   KINGDOM CATEGORY FLOW FIX v25
   - all categories visible in initial grid (no cut-off)
   - selected/search state becomes compact top rail
   - products move immediately under the rail
   - smooth fade/slide transition
   ========================================================= */

/* Never cut the last category cards in the initial browse state */
.category-grid:not(.collapsed){
  max-height:none !important;
  overflow:visible !important;
}

/* Selected/search state: keep categories at the top as a compact rail */
.category-grid.collapsed{
  display:flex !important;
  flex-wrap:nowrap !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  max-height:none !important;
  height:auto !important;
  margin:0 0 14px !important;
  padding:3px 1px 8px !important;
  gap:8px !important;
  opacity:1 !important;
  scroll-behavior:smooth;
  scrollbar-width:thin;
  -webkit-overflow-scrolling:touch;
}

.category-grid.collapsed .category-card{
  flex:0 0 auto !important;
  min-width:auto !important;
  min-height:42px !important;
  padding:5px 11px !important;
  gap:6px !important;
  border-radius:999px !important;
  flex-direction:row !important;
  box-shadow:none !important;
  transform:none !important;
}

.category-grid.collapsed .category-img-wrap{
  width:28px !important;
  height:28px !important;
  flex:0 0 28px !important;
}

.category-grid.collapsed .category-card span{
  font-size:12px !important;
  line-height:1 !important;
  white-space:nowrap !important;
}

/* The large category heading disappears once results take its place */
body.k-results-mode .category-section-title{
  margin-bottom:8px !important;
  opacity:.74;
}

/* Products replace the tall category block visually */
body.k-results-mode #menuArea{
  margin-top:0 !important;
}

body.k-results-mode .section-head{
  margin-top:2px !important;
}

/* Smooth switch between category cards and selected products */
.category-grid,
#menuArea,
.section-head{
  transition:opacity .18s ease, transform .18s ease, margin .18s ease !important;
}

.category-grid.k-switching,
#menuArea.k-switching,
.section-head.k-switching{
  opacity:0 !important;
  transform:translateY(7px) !important;
}

/* Initial category grid must be stable on phones too */
@media screen and (max-width:700px){
  .category-grid:not(.collapsed){
    display:grid !important;
    grid-template-columns:repeat(4,minmax(0,1fr)) !important;
    max-height:none !important;
    overflow:visible !important;
    gap:8px !important;
    margin-bottom:18px !important;
  }

  .category-grid:not(.collapsed) .category-card{
    min-width:0 !important;
  }

  .category-grid.collapsed{
    position:sticky;
    top:0;
    z-index:7;
    background:rgba(255,252,245,.97);
    backdrop-filter:blur(8px);
    margin-left:-2px !important;
    margin-right:-2px !important;
  }

  .category-grid.collapsed .category-card{
    min-height:38px !important;
    padding:4px 9px !important;
  }

  .category-grid.collapsed .category-img-wrap{
    width:25px !important;
    height:25px !important;
    flex-basis:25px !important;
  }

  .category-grid.collapsed .category-card span{
    font-size:10.5px !important;
  }
}


/* CATEGORY + SEARCH FLOW FIX — mobile and desktop */
body.k-results-mode .category-grid.collapsed{
  position:sticky;
  top:86px;
  z-index:20;
  box-shadow:0 10px 24px rgba(55,35,18,.08);
}

/* Search/category transitions use one shared fade instead of leaving the old grid visible. */
.category-grid.k-switching,
#menuArea.k-switching,
.section-head.k-switching{
  opacity:0 !important;
  transform:translateY(8px) !important;
  pointer-events:none !important;
}

@media (max-width:700px){
  body.k-results-mode .category-grid.collapsed{
    top:74px;
    margin-top:2px !important;
    padding-top:6px !important;
    padding-bottom:9px !important;
  }

  /* Keep the compact category rail readable without covering search results. */
  .category-grid.collapsed .category-card{
    min-height:40px !important;
    padding:5px 10px !important;
  }
}

/* =========================================================
   KINGDOM MENU RESPONSIVE + PERFORMANCE FINAL v28
   4 category cards/row on desktop, 3/row on mobile.
   After a category/search is selected the category grid becomes
   one compact horizontal rail on BOTH desktop and mobile.
   ========================================================= */
#cats.category-grid:not(.collapsed){
  display:grid !important;
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
  max-height:none !important;
  height:auto !important;
  overflow:visible !important;
  opacity:1 !important;
}
#cats.category-grid.collapsed,
body.k-results-mode #cats.category-grid.collapsed{
  display:flex !important;
  grid-template-columns:none !important;
  flex-wrap:nowrap !important;
  width:100% !important;
  max-height:none !important;
  height:auto !important;
  overflow-x:auto !important;
  overflow-y:hidden !important;
  gap:8px !important;
  margin:0 0 14px !important;
  padding:5px 2px 8px !important;
  opacity:1 !important;
  -webkit-overflow-scrolling:touch !important;
  scrollbar-width:none !important;
  overscroll-behavior-x:contain;
  scroll-snap-type:x proximity;
}
#cats.category-grid.collapsed::-webkit-scrollbar{display:none !important;}
#cats.category-grid.collapsed .category-card{
  flex:0 0 auto !important;
  width:auto !important;
  min-width:max-content !important;
  min-height:42px !important;
  padding:5px 11px !important;
  gap:6px !important;
  border-radius:999px !important;
  flex-direction:row !important;
  align-items:center !important;
  justify-content:flex-start !important;
  box-shadow:none !important;
  transform:none !important;
  scroll-snap-align:start;
}
#cats.category-grid.collapsed .category-img-wrap{
  width:28px !important;height:28px !important;min-width:28px !important;flex:0 0 28px !important;
}
#cats.category-grid.collapsed .category-card span{
  width:auto !important;font-size:12px !important;line-height:1 !important;white-space:nowrap !important;
}
body.k-results-mode #cats.category-grid.collapsed{
  position:sticky !important;
  top:86px !important;
  z-index:60 !important;
  background:rgba(255,250,240,.97) !important;
  box-shadow:0 7px 18px rgba(70,45,20,.07) !important;
  backdrop-filter:blur(8px);
}

/* Keep switching instant; visual change is short enough to feel responsive. */
#cats.category-grid,#menuArea,.section-head{transition:opacity .08s ease !important;}
#cats.category-grid.k-switching,#menuArea.k-switching,.section-head.k-switching{transform:none !important;}

/* Avoid spending layout/paint time on product cards far below the viewport. */
.product-card{
  content-visibility:auto;
  contain-intrinsic-size:320px 260px;
}

@media (max-width:700px){
  #cats.category-grid:not(.collapsed){
    grid-template-columns:repeat(3,minmax(0,1fr)) !important;
    gap:8px !important;
    margin:0 0 18px !important;
  }
  #cats.category-grid:not(.collapsed) .category-card{
    width:100% !important;
    min-width:0 !important;
    min-height:96px !important;
    padding:8px 4px !important;
    gap:6px !important;
    flex-direction:column !important;
  }
  #cats.category-grid:not(.collapsed) .category-img-wrap{
    width:48px !important;height:48px !important;min-width:48px !important;flex:0 0 48px !important;
  }
  #cats.category-grid:not(.collapsed) .category-card span{
    width:100% !important;font-size:10.5px !important;line-height:1.08 !important;text-align:center !important;
    white-space:normal !important;overflow-wrap:anywhere !important;
  }
  body.k-results-mode .category-section-title{display:none !important;}
  body.k-results-mode #cats.category-grid.collapsed{top:74px !important;}
  #cats.category-grid.collapsed .category-card{min-height:42px !important;padding:5px 10px !important;}
  #cats.category-grid.collapsed .category-card span{font-size:10px !important;}
}


/* 55-image collection: show full portrait product photo without cropping. */
body[data-page="coffee"] .product-img-wrap, body.coffee-page .product-img-wrap { height: clamp(270px, 34vw, 390px); background:#f8f6f1; }
body[data-page="coffee"] .product-img-wrap img, body.coffee-page .product-img-wrap img { object-fit: contain !important; object-position: center center; }
@media(max-width:650px){body[data-page="coffee"] .product-img-wrap,body.coffee-page .product-img-wrap{height:280px}}

html.kingdom-coffee-photos .product-img-wrap{height:clamp(280px,33vw,410px)!important;background:#f8f6f1!important;}
html.kingdom-coffee-photos .product-img-wrap img{object-fit:contain!important;object-position:center!important;transform:none!important;}
@media(max-width:650px){html.kingdom-coffee-photos .product-img-wrap{height:290px!important}}
