/* =========================================================
   KLIKCAFE PLATFORM CSS v1
   Layered Architecture:
   1. PLATFORM BASE (invariants)
   2. DISCOVERY LAYER (storefront UX)
   3. COMMERCE LAYER (transaction system)
   ========================================================= */

/* =========================================================
   1. PLATFORM BASE (Klikcafe identity system)
   ========================================================= */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  background: #fff;
  color: #111;

  -webkit-font-smoothing: antialiased;
}

.hidden {
  display: none !important;
}

/* Tap target baseline (mobile-first UX rule) */
button,
.section-header,
.menu-item,
.spotlight {
  touch-action: manipulation;
}

/* =========================================================
   2. DISCOVERY LAYER (Intent / storefront surface)
   ========================================================= */

/* -------------------------
   HERO (identity layer)
-------------------------- */

#heroSection {
  text-align: center;
  padding: 40px 16px;
}

#heroCafeName {
  margin: 0;
  font-size: 28px;
}

#heroTagline {
  margin-top: 8px;
  opacity: 0.7;
}

/* -------------------------
   SPOTLIGHTS (intent surfacing)
-------------------------- */

#spotlightASection,
#spotlightBSection {
  padding: 0 16px;
  margin-bottom: 20px;

  display: flex;
  flex-direction: column;
  align-items: center;
}

/* square, responsive, mobile safe */
.spotlight {
  position: relative;

  width: min(70vw, 220px);
  aspect-ratio: 1 / 1;

  border-radius: 14px;
  overflow: hidden;

  border: 1px solid #eee;
  background: #ddd;

  cursor: pointer;

  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

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

/* label overlay */
.spotlight-label {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;

  padding: 8px 10px;

  border-radius: 8px;

  font-size: 13px;
  font-weight: 600;

  color: #fff;
  background: rgba(0, 0, 0, 0.55);

  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* controls */
.spotlight-controls {
  position: absolute;
  top: 10px;
  right: 10px;

  display: flex;
  gap: 6px;
  z-index: 2;
}

.spotlight-controls button {
  width: 34px;
  height: 34px;

  border-radius: 50%;
  border: none;

  background: rgba(255, 255, 255, 0.92);

  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 13px;
  font-weight: 600;

  cursor: pointer;
}

/* -------------------------
   MENU ENTRY POINT (CTA / preview layer)
-------------------------- */

.section-heading {
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  margin: 14px 0;
}

/* =========================================================
   3. COMMERCE LAYER (transaction system)
   ========================================================= */

/* -------------------------
   MENU ROOT (snapshot renderer target)
-------------------------- */

#menuContainers {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* -------------------------
   MENU CONTAINER
-------------------------- */

.menu-container {
  border: 1px solid #eee;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

/* CTA header */
.menu-cta {
  padding: 14px;
  background: #111;
  color: #fff;

  border: none;
  width: 100%;

  font-size: 16px;
  font-weight: 600;

  cursor: pointer;
}

/* -------------------------
   SECTION SYSTEM
-------------------------- */

.menu-body {
  padding: 12px;
}

.menu-section {
  margin-bottom: 10px;
  border-bottom: 1px solid #f3f3f3;
}

.section-header {
  width: 100%;

  padding: 12px;
  background: #f7f7f7;

  border: none;
  border-radius: 10px;

  text-align: left;
  font-size: 15px;
  font-weight: 600;

  cursor: pointer;
}

/* items container */
.section-items {
  display: flex;
  flex-direction: column;
}

/* -------------------------
   COMMERCE MENU ITEM (AUTHORITATIVE ENTITY)
   ONLY ONE DEFINITION EXISTS
-------------------------- */

.menu-item {
  padding: 12px;

  background: #fff;
  border: 1px solid #eee;
  border-radius: 10px;

  margin-top: 8px;

  font-size: 15px;

  cursor: pointer;

  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);

  transition:
    transform 120ms ease,
    box-shadow 120ms ease;
}

.menu-item:active {
  transform: scale(0.98);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

/* =========================================================
   4. MODAL SYSTEM (commerce decision layer)
   ========================================================= */

.modal {
  position: fixed;
  inset: 0;

  background: rgba(0, 0, 0, 0.6);

  display: none;
  justify-content: center;
  align-items: center;

  z-index: 9999;
}

.modal:not(.hidden) {
  display: flex;
}

.modal-content {
  width: 92%;
  max-width: 420px;

  background: #fff;
  border-radius: 12px;

  padding: 16px;

  max-height: 80vh;
  overflow-y: auto;
}

.close-btn {
  border: none;
  background: none;

  font-size: 22px;
  float: right;

  cursor: pointer;
}

/* =========================================================
   5. INFO / FOOTER LAYER (context system)
   ========================================================= */

.info-drawer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 48px;

  background: #fafafa;
  border-top: 1px solid #ddd;

  padding: 14px;

  max-height: 40vh;
  overflow-y: auto;

  transform: translateY(100%);
  transition: transform 0.25s ease;

  z-index: 1000;
}

.info-drawer.open {
  transform: translateY(0);
}

#infoContent {
  font-size: 14px;
  color: #333;
}

/* footer navigation */
.footer-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;

  display: flex;
  justify-content: space-around;

  background: #fff;
  border-top: 1px solid #eee;

  padding: 10px;

  z-index: 1001;
}

.footer-nav button {
  border: none;
  background: none;

  font-size: 13px;
  text-decoration: underline;

  cursor: pointer;
}
