/* ===== ORDER PAGE ===== */

.schedule-error {
  color: #c0392b;
  font-size: 0.85rem;
  margin: 4px 0 0;
  min-height: 1.2em;
}

.summary-fee {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 6px;
  margin-top: 4px;
  font-style: italic;
  opacity: 0.8;
}

.item-options {
  flex-wrap: wrap;
  gap: 10px;
  padding: 8px 12px 10px;
  background: rgba(0,0,0,0.06);
  border-top: 1px solid rgba(0,0,0,0.06);
  margin-top: -1px;
}

.item-option {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
}

.item-option-label {
  font-weight: 500;
  white-space: nowrap;
}

.item-option-select {
  border: 1px solid rgba(0,0,0,0.18);
  border-radius: 6px;
  padding: 3px 6px;
  font-size: 0.85rem;
  background: #fff;
  cursor: pointer;
}

.summary-opts {
  color: #888;
  font-size: 0.78rem;
}

.item-min {
  font-size: 0.72rem;
  font-style: italic;
  opacity: 0.6;
  margin-left: 6px;
}

.delivery-min-notice {
  font-size: 0.82rem;
  margin: 6px 0 4px;
  min-height: 1.1em;
}
.delivery-min-notice.below { color: #c0392b; }
.delivery-min-notice.met   { color: #27ae60; }

/* Hero */
.order-hero {
  background: linear-gradient(135deg, var(--olive-dark) 0%, var(--olive) 100%);
  color: var(--white);
  padding: 64px 0 56px;
  text-align: center;
}

.order-hero .eyebrow {
  color: var(--gold);
}

.order-hero h1 {
  font-family: "Playfair Display", serif;
  font-size: clamp(2rem, 4vw, 3rem);
  margin: 12px 0;
  color: var(--white);
}

.order-hero-sub {
  font-size: 1.05rem;
  opacity: 0.85;
  margin-top: 6px;
}

/* Section wrapper */
.order-section {
  padding: 44px 0 90px;
  background: var(--beige);
}

/* Type toggle */
.order-type-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 36px;
  background: var(--white);
  padding: 5px;
  border-radius: 999px;
  width: fit-content;
  box-shadow: 0 2px 14px rgba(58, 43, 31, 0.1);
}

.type-btn {
  padding: 11px 30px;
  border-radius: 999px;
  border: none;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  background: transparent;
  color: var(--brown);
  transition: background 0.25s ease, color 0.25s ease;
}

.type-btn.active {
  background: var(--olive);
  color: var(--white);
}

/* Two-column layout */
.order-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 28px;
  align-items: start;
}

/* ---- Menu categories ---- */
.menu-cat-card {
  background: var(--white);
  border-radius: 20px;
  padding: 26px 28px;
  margin-bottom: 22px;
  box-shadow: 0 4px 18px rgba(58, 43, 31, 0.07);
}

.cat-title {
  font-family: "Playfair Display", serif;
  font-size: 1.35rem;
  color: var(--olive-dark);
  padding-bottom: 12px;
  margin-bottom: 6px;
  border-bottom: 2px solid var(--gold);
}

.cat-note {
  font-size: 0.84rem;
  color: #7a6a5a;
  font-style: italic;
  margin-bottom: 14px;
}

.items-list {
  display: grid;
}

.order-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(58, 43, 31, 0.07);
}

.order-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.order-item:first-child {
  padding-top: 4px;
}

.item-info {
  flex: 1;
  min-width: 0;
}

.item-name {
  font-weight: 600;
  font-size: 0.94rem;
  color: var(--brown);
  line-height: 1.3;
}

.item-unit {
  font-size: 0.78rem;
  color: #8a7a6a;
  font-weight: 400;
  margin-left: 3px;
}

.item-desc {
  font-size: 0.81rem;
  color: #9a8a7a;
  margin-top: 3px;
  line-height: 1.4;
}

.item-price {
  font-size: 0.88rem;
  color: var(--olive);
  font-weight: 700;
  margin-top: 4px;
}

/* Quantity controls */
.item-qty-ctrl {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.qty-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid var(--olive);
  background: transparent;
  color: var(--olive);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background 0.2s ease, color 0.2s ease;
  flex-shrink: 0;
}

.qty-btn:hover {
  background: var(--olive);
  color: var(--white);
}

.qty-display {
  min-width: 22px;
  text-align: center;
  font-weight: 700;
  font-size: 1rem;
  color: var(--brown);
}

.qty-display.active {
  color: var(--olive);
}

/* Customer info card */
.customer-card {
  background: var(--white);
  border-radius: 20px;
  padding: 26px 28px;
  box-shadow: 0 4px 18px rgba(58, 43, 31, 0.07);
  display: grid;
  gap: 16px;
  margin-bottom: 22px;
}

/* Override base input/textarea width */
.customer-card input,
.customer-card textarea,
.customer-card select {
  width: 100%;
}

.customer-card textarea {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(58, 43, 31, 0.2);
  font-family: inherit;
  font-size: 0.95rem;
  resize: vertical;
  width: 100%;
  color: var(--brown);
}

.customer-card textarea:focus {
  outline: 2px solid rgba(201, 164, 74, 0.5);
  border-color: var(--gold);
}

#delivery-fields {
  display: none;
}

/* ---- Order summary sidebar ---- */
.order-summary-col {
  position: sticky;
  top: 86px;
}

.order-summary-card {
  background: var(--white);
  border-radius: 20px;
  padding: 22px 22px 24px;
  box-shadow: 0 8px 28px rgba(58, 43, 31, 0.11);
  border-top: 4px solid var(--gold);
}

.order-summary-card h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.25rem;
  color: var(--olive-dark);
  margin-bottom: 14px;
}

.summary-empty {
  color: #b0a090;
  font-size: 0.88rem;
  text-align: center;
  padding: 16px 0 10px;
}

#summary-list {
  min-height: 40px;
}

.summary-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  padding: 7px 0;
  font-size: 0.88rem;
  border-bottom: 1px solid rgba(58, 43, 31, 0.07);
  line-height: 1.4;
}

.summary-item span:first-child {
  flex: 1;
  min-width: 0;
  word-break: break-word;
}

.summary-item span:last-child {
  flex-shrink: 0;
  font-weight: 600;
  color: var(--olive);
}

.summary-footer {
  margin-top: 14px;
  display: grid;
  gap: 12px;
}

.summary-total-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1rem;
  padding-top: 10px;
  border-top: 2px solid rgba(58, 43, 31, 0.1);
}

.summary-total-row strong {
  font-size: 1.15rem;
  color: var(--olive-dark);
}

.full-width {
  width: 100%;
  justify-content: center;
  font-size: 1rem;
}

/* Payment toggle */
.payment-toggle {
  display: flex;
  gap: 8px;
  background: rgba(58,43,31,0.06);
  padding: 5px;
  border-radius: 999px;
}

.pay-btn {
  flex: 1;
  padding: 9px 12px;
  border-radius: 999px;
  border: none;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  background: transparent;
  color: var(--brown);
  transition: background 0.25s, color 0.25s;
  text-align: center;
}

.pay-btn.active {
  background: var(--olive);
  color: var(--white);
}

.btn.primary:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.summary-note {
  font-size: 0.78rem;
  color: #9a8a7a;
  text-align: center;
  line-height: 1.5;
}

/* ---- Confirmation overlay ---- */
#order-confirmation {
  position: fixed;
  inset: 0;
  background: rgba(58, 43, 31, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
}

.confirm-box {
  background: var(--white);
  border-radius: 24px;
  padding: 48px 40px;
  text-align: center;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 20px 60px rgba(58, 43, 31, 0.25);
}

.confirm-icon {
  width: 64px;
  height: 64px;
  background: var(--olive);
  color: var(--white);
  border-radius: 50%;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.confirm-box h2 {
  font-family: "Playfair Display", serif;
  font-size: 1.8rem;
  color: var(--olive-dark);
  margin-bottom: 12px;
}

.confirm-box p {
  color: var(--brown);
  font-size: 1rem;
  margin-bottom: 8px;
}

.confirm-sub {
  color: #8a7a6a;
  font-size: 0.88rem !important;
  margin-bottom: 28px !important;
}

/* ---- Responsive ---- */
@media (max-width: 960px) {
  .order-layout {
    grid-template-columns: 1fr;
  }

  .order-summary-col {
    position: static;
    order: -1;
  }

  .order-summary-card {
    border-top: 4px solid var(--gold);
  }
}

@media (max-width: 600px) {
  .order-type-bar {
    width: 100%;
  }

  .type-btn {
    flex: 1;
    text-align: center;
    padding: 11px 16px;
  }

  .menu-cat-card,
  .customer-card {
    padding: 20px 18px;
  }
}
