/* =========================================================
   ATK CORNER — STYLE SHEET
   Design tokens dan layout mobile-first
   ========================================================= */

:root {
  --ink-900: #16324F;
  --ink-700: #1E3A5F;
  --ink-100: #E8EEF4;
  --amber-500: #F5821F;
  --amber-600: #DA6C0F;
  --amber-100: #FDEBD9;
  --whatsapp: #25D366;
  --whatsapp-dark: #1EBE5A;
  --success: #2F9E64;
  --danger: #C1442A;
  --bg: #F6F7FA;
  --surface: #FFFFFF;
  --border: #E5E8EC;
  --text: #1F2A37;
  --text-muted: #6B7280;
  --text-faint: #9AA3AF;

  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --radius-pill: 999px;

  --shadow-card: 0 10px 30px rgba(16, 34, 56, 0.08);
  --shadow-float: 0 12px 24px rgba(16, 34, 56, 0.22);

  --font-display: 'Poppins', 'Segoe UI', sans-serif;
  --font-body: 'Inter', 'Segoe UI', sans-serif;
  --font-mono: 'Space Mono', ui-monospace, 'Courier New', monospace;

  --nav-h: 68px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(var(--nav-h) + 24px);
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--ink-900);
  margin: 0;
  line-height: 1.25;
}

p { margin: 0; }

button { font-family: inherit; cursor: pointer; }

a { color: inherit; }

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

:focus-visible {
  outline: 2px solid var(--amber-500);
  outline-offset: 2px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ---------------------------------------------------------
   TOP BAR
--------------------------------------------------------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.topbar__inner {
  max-width: 560px;
  margin: 0 auto;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand { display: flex; align-items: center; gap: 10px; }

.brand__mark {
  width: 38px; height: 38px;
  border-radius: var(--radius-sm);
  background: var(--ink-900);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.brand__text { display: flex; flex-direction: column; line-height: 1.2; }
.brand__text strong { font-family: var(--font-display); font-size: 15px; color: var(--ink-900); font-weight: 600; }
.brand__text span { font-size: 11px; color: var(--text-muted); }

.topbar__contact {
  display: flex; align-items: center; gap: 6px;
  background: none; border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-900);
}

/* ---------------------------------------------------------
   APP / VIEWS
--------------------------------------------------------- */
.app {
  max-width: 560px;
  margin: 0 auto;
}

.view { display: none; padding: 0 18px; }
.view.is-active { display: block; }

.view-header {
  padding: 24px 0 18px;
}
.view-header h1 {
  font-size: 24px;
  margin-bottom: 6px;
}
.view-header p {
  color: var(--text-muted);
  font-size: 14px;
}

.section { padding: 40px 0; }
.section--flush { padding: 16px 0; }

.section__title {
  font-size: 19px;
  margin-bottom: 18px;
}

/* ---------------------------------------------------------
   HERO
--------------------------------------------------------- */
.hero {
  padding: 28px 0 8px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.hero__ticket {
  align-self: center;
  margin-bottom: 20px;
}

.hero__eyebrow {
  font-size: 13px;
  color: var(--amber-600);
  font-weight: 600;
  margin-bottom: 10px;
}

.hero__title {
  font-size: 30px;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}

.hero__subtitle {
  font-size: 15px;
  color: var(--text-muted);
  max-width: 46ch;
  margin-bottom: 24px;
}

.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

/* ---------------------------------------------------------
   BUTTONS
--------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  padding: 12px 20px;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }

.btn--primary {
  background: var(--ink-900);
  color: #fff;
  box-shadow: var(--shadow-card);
}
.btn--primary:hover { background: var(--ink-700); }

.btn--ghost {
  background: transparent;
  color: var(--ink-900);
  border: 1.5px solid var(--border);
}
.btn--ghost:hover { border-color: var(--ink-900); }

.btn--secondary {
  background: var(--ink-100);
  color: var(--ink-900);
}

.btn--whatsapp {
  background: var(--whatsapp);
  color: #fff;
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.28);
}
.btn--whatsapp:hover { background: var(--whatsapp-dark); }
.btn--whatsapp:disabled {
  background: #C6D1CB; color: #8A968F; box-shadow: none; cursor: not-allowed;
}

.btn--text {
  background: none;
  color: var(--text-muted);
  font-size: 13px;
  padding: 8px 4px;
  text-decoration: underline;
}

.btn--lg { padding: 14px 22px; font-size: 15px; }
.btn--full { width: 100%; }

.icon-btn {
  background: none;
  border: none;
  padding: 6px;
  display: flex;
  border-radius: var(--radius-sm);
}
.icon-btn:hover { background: var(--ink-100); }

/* ---------------------------------------------------------
   BENEFIT CARDS
--------------------------------------------------------- */
.benefit-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.benefit-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-card);
}

.benefit-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border-radius: var(--radius-sm);
  background: var(--amber-100);
  margin-bottom: 14px;
}

.benefit-card h3 {
  font-size: 16px;
  margin-bottom: 6px;
}

.benefit-card p {
  font-size: 13.5px;
  color: var(--text-muted);
}

/* ---------------------------------------------------------
   CTA BANNER / FINAL
--------------------------------------------------------- */
.cta-banner {
  background: var(--ink-900);
  border-radius: var(--radius-lg);
  padding: 24px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.cta-banner h2 { color: #fff; font-size: 18px; margin-bottom: 6px; }
.cta-banner p { color: rgba(255,255,255,0.75); font-size: 13.5px; }
.cta-banner .btn--whatsapp { align-self: flex-start; }

.cta-final {
  text-align: center;
  padding: 12px 8px 28px;
}
.cta-final h2 { font-size: 21px; margin-bottom: 8px; }
.cta-final p { color: var(--text-muted); font-size: 14px; margin-bottom: 20px; }

/* ---------------------------------------------------------
   STEPS
--------------------------------------------------------- */
.steps {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.steps__item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.steps__index {
  flex-shrink: 0;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--amber-500);
  color: #fff;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 13px;
  display: flex; align-items: center; justify-content: center;
}

.steps__item h3 { font-size: 15px; margin-bottom: 4px; }
.steps__item p { font-size: 13.5px; color: var(--text-muted); }

/* ---------------------------------------------------------
   TRUST / TESTIMONIALS
--------------------------------------------------------- */
.trust-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.trust-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 9px 14px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-900);
}

.testimonial-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.testimonial-card {
  margin: 0;
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-card);
  border-left: 3px solid var(--amber-500);
}

.testimonial-card blockquote {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--text);
  font-style: italic;
}

.testimonial-card figcaption {
  font-size: 12.5px;
  color: var(--text-muted);
  font-weight: 600;
}

/* ---------------------------------------------------------
   CARDS / FORMS
--------------------------------------------------------- */
.card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
}

.form-card { display: flex; flex-direction: column; gap: 20px; }

.field { display: flex; flex-direction: column; gap: 8px; }

.field label {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-900);
}

.field input[type="number"],
.field input[type="text"],
.field textarea {
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  font-size: 15px;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  width: 100%;
}

.field input:focus, .field textarea:focus {
  outline: none;
  border-color: var(--amber-500);
  background: var(--surface);
}

.field textarea { resize: vertical; min-height: 64px; }

.field__error {
  font-size: 12.5px;
  color: var(--danger);
  display: flex;
  align-items: center;
  gap: 6px;
}

.field-row { width: 100%; }
.field-row--2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

/* Segmented control (radio group styled as buttons) */
.segmented {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.segmented--3 { grid-template-columns: 1fr 1fr 1fr; }

.segmented__option {
  position: relative;
}
.segmented__option input {
  position: absolute;
  opacity: 0;
  width: 100%; height: 100%;
  margin: 0;
  cursor: pointer;
}
.segmented__option span {
  display: block;
  text-align: center;
  padding: 11px 8px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  transition: all 0.12s ease;
}
.segmented__option input:checked + span {
  border-color: var(--ink-900);
  background: var(--ink-900);
  color: #fff;
}
.segmented__option input:focus-visible + span {
  outline: 2px solid var(--amber-500);
  outline-offset: 2px;
}

/* Upload box */
.upload-box {
  border: 1.5px dashed var(--border);
  border-radius: var(--radius-md);
  background: var(--bg);
}

.upload-box__empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  padding: 28px 18px;
}
.upload-box__empty p { font-size: 14px; font-weight: 600; color: var(--ink-900); margin-top: 4px; }
.upload-box__empty span { font-size: 12.5px; color: var(--text-muted); margin-bottom: 10px; }

.upload-box__filled {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
}
.upload-box__info { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.upload-box__info strong { font-size: 13.5px; color: var(--ink-900); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-box__info span { font-size: 12px; color: var(--text-muted); }

/* Estimate panel */
.estimate-panel {
  background: var(--ink-100);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.estimate-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 13.5px;
  color: var(--ink-700);
}
.estimate-row strong { font-family: var(--font-mono); font-size: 14px; color: var(--ink-900); }
.estimate-row--price {
  border-top: 1px dashed rgba(22, 50, 79, 0.25);
  padding-top: 10px;
}
.estimate-row--price strong { font-size: 18px; color: var(--amber-600); }

/* ---------------------------------------------------------
   KATALOG
--------------------------------------------------------- */
.chip-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 0 18px;
  -ms-overflow-style: none;
  scrollbar-width: none;
}
.chip-row::-webkit-scrollbar { display: none; }

.chip {
  flex-shrink: 0;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}
.chip.is-active {
  background: var(--ink-900);
  border-color: var(--ink-900);
  color: #fff;
}

.product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding-bottom: 20px;
}

.product-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 14px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.product-card__icon {
  width: 100%;
  aspect-ratio: 1.4 / 1;
  border-radius: var(--radius-sm);
  background: var(--ink-100);
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-card h3 {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}

.product-card__price {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-900);
}

.product-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 2px;
}

.stepper {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg);
  border-radius: var(--radius-pill);
  padding: 4px;
}
.stepper button {
  width: 24px; height: 24px;
  border-radius: 50%;
  border: none;
  background: var(--surface);
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink-900);
  display: flex; align-items: center; justify-content: center;
  line-height: 1;
}
.stepper span {
  font-family: var(--font-mono);
  font-size: 12.5px;
  min-width: 14px;
  text-align: center;
}

.product-card__add {
  width: 100%;
  background: var(--ink-900);
  color: #fff;
  border-radius: var(--radius-pill);
  padding: 9px;
  font-size: 12.5px;
  font-weight: 600;
  border: none;
}

/* ---------------------------------------------------------
   EMPTY STATES
--------------------------------------------------------- */
.empty-state {
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  padding: 40px 0;
}

.empty-state-card {
  text-align: center;
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 40px 24px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
}
.empty-state-card svg { margin-bottom: 8px; }
.empty-state-card p { font-weight: 600; color: var(--ink-900); font-size: 14.5px; }
.empty-state-card span { font-size: 13px; color: var(--text-muted); max-width: 32ch; }
.empty-state-card__actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ---------------------------------------------------------
   CART LIST
--------------------------------------------------------- */
.cart-list {
  list-style: none;
  margin: 12px 0 16px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cart-item {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  box-shadow: var(--shadow-card);
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.cart-item__badge {
  width: 34px; height: 34px;
  border-radius: var(--radius-sm);
  background: var(--amber-100);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}

.cart-item__body { flex: 1; min-width: 0; }
.cart-item__title { font-size: 14px; font-weight: 600; color: var(--ink-900); margin-bottom: 3px; }
.cart-item__meta { font-size: 12px; color: var(--text-muted); line-height: 1.5; }

.cart-item__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}
.cart-item__price { font-family: var(--font-mono); font-size: 13.5px; font-weight: 700; color: var(--ink-900); }

.cart-item__remove {
  background: none;
  border: none;
  padding: 4px;
  color: var(--text-faint);
}

/* ---------------------------------------------------------
   SUMMARY PANEL
--------------------------------------------------------- */
.summary-panel {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
}
.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--text-muted);
  padding: 6px 0;
}
.summary-row--total {
  border-top: 1px dashed var(--border);
  margin-top: 6px;
  padding-top: 12px;
  font-size: 16px;
  color: var(--ink-900);
}
.summary-row--total strong { font-family: var(--font-mono); font-size: 19px; color: var(--amber-600); }
.summary-row strong { color: var(--text); font-weight: 600; }

/* ---------------------------------------------------------
   ORDER HISTORY
--------------------------------------------------------- */
.order-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.order-item {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-card);
  border-left: 3px solid var(--success);
}

.order-item__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}
.order-item__id { font-family: var(--font-mono); font-size: 12.5px; font-weight: 700; color: var(--ink-900); }
.order-item__date { font-size: 11.5px; color: var(--text-faint); }
.order-item__summary { font-size: 13px; color: var(--text-muted); margin-bottom: 8px; }
.order-item__footer { display: flex; justify-content: space-between; font-size: 13px; }
.order-item__method { color: var(--text-muted); }
.order-item__total { font-family: var(--font-mono); font-weight: 700; color: var(--ink-900); }

/* ---------------------------------------------------------
   INFO CARDS (Tentang)
--------------------------------------------------------- */
.info-card h3 { font-size: 14px; margin-bottom: 6px; }
.info-card p { font-size: 13.5px; color: var(--text-muted); margin-bottom: 12px; }
.info-card p:last-child { margin-bottom: 0; }

/* ---------------------------------------------------------
   FLOATING WHATSAPP BUTTON
--------------------------------------------------------- */
.fab-whatsapp {
  position: fixed;
  right: 18px;
  bottom: calc(var(--nav-h) + 18px);
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--whatsapp);
  border: none;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-float);
  z-index: 45;
}
.fab-whatsapp:active { transform: scale(0.94); }

/* ---------------------------------------------------------
   TOAST
--------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--nav-h) + 18px);
  transform: translateX(-50%) translateY(20px);
  background: var(--ink-900);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--radius-pill);
  font-size: 13.5px;
  font-weight: 500;
  box-shadow: var(--shadow-float);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 60;
  max-width: 88%;
  text-align: center;
}
.toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---------------------------------------------------------
   BOTTOM NAV
--------------------------------------------------------- */
.bottom-nav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: var(--nav-h);
  background: var(--surface);
  border-top: 1px solid var(--border);
  display: flex;
  z-index: 50;
  max-width: 560px;
  margin: 0 auto;
  box-shadow: 0 -6px 20px rgba(16,34,56,0.05);
}

.bottom-nav__item {
  flex: 1;
  background: none;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--text-faint);
  font-size: 10.5px;
  font-weight: 600;
  padding: 6px 0;
}
.bottom-nav__item.is-active { color: var(--ink-900); }
.bottom-nav__item.is-active svg { stroke: var(--amber-500); }

.bottom-nav__icon-wrap { position: relative; }
.cart-badge {
  position: absolute;
  top: -4px; right: -8px;
  background: var(--amber-500);
  color: #fff;
  font-size: 9.5px;
  font-weight: 700;
  min-width: 15px;
  height: 15px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px;
}

/* ---------------------------------------------------------
   FOOTER
--------------------------------------------------------- */
.site-footer {
  max-width: 560px;
  margin: 0 auto;
  padding: 28px 18px calc(var(--nav-h) + 20px);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.site-footer p { font-size: 12px; color: var(--text-faint); }
.site-footer__link {
  background: none;
  border: none;
  font-size: 12px;
  color: var(--text-muted);
  text-decoration: underline;
}

/* ---------------------------------------------------------
   RESPONSIVE — small phones
--------------------------------------------------------- */
@media (max-width: 360px) {
  .hero__title { font-size: 26px; }
  .field-row--2 { gap: 10px; }
}

/* ---------------------------------------------------------
   LARGER SCREENS — keep app centered like a phone canvas
--------------------------------------------------------- */
@media (min-width: 640px) {
  body { background: #EDEFF3; }
  .topbar__inner, .app, .bottom-nav, .site-footer {
    max-width: 480px;
  }
  .bottom-nav {
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
  }
}
