﻿/* ============================================================
   Ban Leong Pawnshop: Layout & Page styles
   Depends on design-system.css (imported first).
   ============================================================ */
/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: var(--z-header);
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s, box-shadow .3s;
}
.site-header.scrolled { border-color: var(--line); box-shadow: var(--shadow-xs); background: color-mix(in srgb, var(--paper) 92%, transparent); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: .65rem; font-weight: var(--fw-black); letter-spacing: -.02em; }
.brand-mark {
  width: 50px; height: 50px; border-radius: 14px; flex: none;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-strong) 100%);
  color: #ffffff; display: grid; place-items: center; font-family: var(--font-cjk);
  font-size: 1.2rem; font-weight: 800; box-shadow: var(--shadow-gold);
}
/* Stacked two-character mark (top + bottom), e.g. è¬ / éš† */
.brand-mark.stack { display: grid; place-items: center; gap: -0.1rem; line-height: .92; }
    font-family: var(--font-cjk);
  .brand-name { display: flex; flex-direction: column; line-height: 1.04; align-items: flex-start; }
  .brand-name b { display: block; width: 100%; font-size: 1.22rem; white-space: nowrap; line-height: 1.1; }
  .brand-name span { display: block; width: 100%; margin-top: .12rem; font-size: .74rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
  #site-header-root[data-active="home"] .brand-name span { font-size: 0.851rem; }
  #site-header-root[data-active="home"] .brand-name b { line-height: 1.0; }
  #site-header-root[data-active="home"] .brand-name b { transform: translateY(20%); }
  #site-header-root[data-active="home"] .brand-name span { margin-top: 0.096rem; margin-bottom: -0.096rem; }
.nav-links { display: flex; align-items: stretch; gap: .25rem; }
.nav-links a { flex: 1 1 0; min-width: 6.5rem; display: inline-flex; align-items: center; justify-content: center; text-align: center; padding: .55rem .9rem; border-radius: var(--r-pill); font-weight: var(--fw-semi); color: var(--ink-2); font-size: var(--step-0); line-height: 1.1; transition: background var(--dur-fast), color var(--dur-fast); }
.nav-links a:hover { background: var(--surface); color: var(--ink); }
.nav-links a.active { background: var(--gold-soft); color: var(--gold-deep); }
.nav-actions { display: flex; align-items: center; gap: .55rem; }
.nav-toggle { display: none; width: 44px; height: 44px; border-radius: var(--r-sm); border: 1px solid var(--line-strong); background: var(--surface); align-items: center; justify-content: center; color: var(--ink); }
.nav-toggle svg { width: 22px; height: 22px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink-bg); color: #cfcfd6; padding-block: clamp(3rem, 6vw, 4.5rem) 2rem; }
.site-footer h4 { color: #fff; font-size: var(--step-0); letter-spacing: .02em; margin-bottom: 1rem; }
.footer-link { color: #b9b9c2; padding: .35rem 0; display: inline-block; transition: color .2s; }
.footer-link:hover { color: #fff; }
.footer-meta { color: #8a8a92; font-size: var(--step--1); }
.footer-bottom { border-top: 1px solid var(--line-dark); margin-top: clamp(2rem,4vw,3rem); padding-top: 1.5rem; color: #8a8a92; font-size: var(--step--1); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero-bg {
  position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(120% 90% at 88% 0%, var(--gold-tint) 0%, transparent 55%),
    radial-gradient(90% 70% at 0% 100%, var(--gold-soft) 0%, transparent 60%),
    linear-gradient(180deg, var(--paper) 0%, var(--surface) 100%);
}
.hero-bg::after { content:""; position:absolute; inset:0; z-index:-1; opacity:.5; background-image: radial-gradient(circle at 1px 1px, color-mix(in srgb, var(--ink) 6%, transparent) 1px, transparent 0); background-size: 26px 26px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: clamp(2rem, 5vw, 4rem); padding-block: clamp(3rem, 6vw, 5.5rem); }
.hero h1 { font-size: var(--step-6); }
.hero .lead { margin-top: 1.2rem; max-width: 32rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }
.hero-stats { display: flex; flex-wrap: wrap; gap: clamp(1.2rem, 4vw, 2.4rem); margin-top: 2.4rem; }
.hero-stats .num { font-family: var(--font-serif); font-size: var(--step-3); line-height: 1; color: var(--ink); }
.hero-stats .label { font-size: var(--step--1); color: var(--muted); margin-top: .35rem; }

.accept-card { background: color-mix(in srgb, var(--surface) 88%, transparent); border: 1px solid var(--line); border-radius: var(--r-xl); padding: 1.9rem; box-shadow: var(--shadow-lg); backdrop-filter: blur(10px); display: flex; flex-direction: column; }
.accept-card h3 { font-size: var(--step-1); margin-bottom: 1.1rem; text-align: center; }
.accept-card .chip-list { justify-content: center; gap: .6rem; }
.accept-card .chip-list li { padding: .55rem 1rem; font-size: var(--step--1); font-weight: 600; }
.accept-card .divider { margin-top: 1.4rem; margin-bottom: 1.4rem; }
.accept-card .feature-list { gap: .35rem; }
.accept-card .feature-list li { padding: .65rem 0; font-size: var(--step--1); text-align: left; }
.accept-card .btn-block { margin-top: auto; width: 100%; justify-content: center; }

.rating-hero { display: inline-flex; align-items: center; gap: .6rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-pill); padding: .5rem 1rem; box-shadow: var(--shadow-sm); }
.rating-hero b { font-family: var(--font-serif); font-size: 1.4rem; }
.rating-hero .stars { color: var(--gold); letter-spacing: 2px; font-size: 1.05rem; }

/* ---------- Trust strip ---------- */
.trust-strip { border-block: 1px solid var(--line); background: var(--surface); }
.trust-strip .grid { align-items: center; }
.trust-item { display: flex; align-items: center; gap: .85rem; }
.trust-item .icon-tile { width: 44px; height: 44px; }
.trust-item b { display: block; font-size: var(--step-0); }
.trust-item span { font-size: var(--step--1); color: var(--muted); }

/* ---------- Process steps ---------- */
.steps { display: grid; gap: 1.25rem; }
.step { display: flex; gap: 1rem; align-items: flex-start; }
.step-num { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--gold-soft); color: var(--gold-deep); font-family: var(--font-serif); font-size: 1.25rem; font-weight: 800; flex: none; border: 1px solid color-mix(in srgb, var(--gold) 30%, transparent); }
.step h4 { font-size: var(--step-1); margin-bottom: .3rem; }
.step .muted { font-size: var(--step-0); }

/* ---------- Pawn estimator ---------- */
.estimator { background: linear-gradient(160deg, var(--ink-bg) 0%, #23252c 100%); color: #fff; border-radius: var(--r-xl); padding: clamp(1.5rem, 4vw, 2.5rem); box-shadow: var(--shadow-lg); }
.estimator .field label { color: #d7d7de; }
.estimator .hint { color: var(--muted); }
.estimator .input, .estimator .select { background: #2b2d34; border-color: #3a3d46; color: #fff; }
.estimator .input:focus, .estimator .select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(200,162,74,.35); }
.estimator .input::placeholder { color: #8a8c94; }
.result-box { margin-top: 1.4rem; padding: 1.25rem; border-radius: var(--r-md); background: #1c1e24; border: 1px solid #34373f; }
.result-box .row { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px dashed #34373f; font-size: var(--step-0); }
.result-box .row:last-child { border-bottom: 0; }
.result-box .row span:first-child { color: #b9b9c2; }
.result-box .row .num { font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.result-box .big { font-family: var(--font-serif); font-size: var(--step-3); color: #fff; }

/* ---------- Interest / stats ---------- */
.stat-block .num { font-family: var(--font-serif); font-size: var(--step-4); line-height: 1; color: var(--ink); }
.stat-block .num.gold { color: var(--gold-strong); }
.stat-block .label { font-size: var(--step--1); color: var(--muted); margin-top: .4rem; letter-spacing: .02em; }

/* ---------- Branch cards ---------- */
.branch-addr { color: var(--muted); }
.branch-phone { display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; color: var(--ink); margin-top: .5rem; }
.branch-phone svg { width: 18px; height: 18px; color: var(--gold-strong); }
.branch-wa { display: inline-flex; align-items: center; gap: .45rem; padding: .55rem .9rem; border-radius: var(--r-pill); background: #25d366; color: #fff; font-weight: 700; font-size: var(--step--1); transition: background var(--dur-fast), transform var(--dur-fast); }
.branch-wa:hover { background: #1ebe5b; }
.branch-wa:active { transform: translateY(1px); }
.branch-map { display:block; margin-top: 1rem; border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--line); position: relative; }
.branch-map iframe { width: 100%; height: 190px; border: 0; }
.branch-map-frame { width: 100%; height: 190px; border: 0; display: block; }

/* ---------- Reviews ---------- */
.review { display: flex; flex-direction: column; gap: 1rem; height: 100%; }
.review .stars { color: var(--gold); letter-spacing: 2px; }
.review blockquote { font-size: var(--step-1); line-height: 1.5; color: var(--ink); }
.review .who { font-weight: 700; font-size: var(--step-0); }
.review .who span { display: block; font-weight: 500; color: var(--muted); font-size: var(--step--1); }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q { width: 100%; text-align: left; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.25rem 0; background: none; border: 0; font-weight: var(--fw-semi); font-size: var(--step-1); color: var(--ink); }
.faq-q .chev { transition: transform var(--dur-slow) var(--ease); color: var(--muted); flex: none; }
.faq-item.open .faq-q .chev { transform: rotate(180deg); color: var(--gold-strong); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .35s var(--ease); }
.faq-a p { padding-bottom: 1.25rem; color: var(--muted); max-width: 62ch; }

/* ---------- CTA band ---------- */
.cta-band { background: linear-gradient(135deg, var(--gold) 0%, var(--gold-strong) 100%); color: #ffffff; border-radius: var(--r-xl); padding: clamp(2rem, 5vw, 3.5rem); text-align: center; box-shadow: var(--shadow-gold); position: relative; overflow: hidden; }
.cta-band h2 { color: #ffffff; }
.cta-band .lead { color: #4a3a12; }
.cta-band .btn-ghost { color: #ffffff; border-color: rgba(42,33,10,.35); }
.cta-band .btn-ghost:hover { background: rgba(42,33,10,.08); border-color: #ffffff; }

/* ---------- Mobile bottom nav ---------- */
.bottom-nav { display: none; position: fixed; inset: auto 0 0 0; z-index: var(--z-header); background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(12px); border-top: 1px solid var(--line); padding: .4rem .5rem calc(.4rem + env(safe-area-inset-bottom)); }
.bottom-nav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: .2rem; padding: .45rem 0; font-size: .68rem; font-weight: 600; color: var(--muted); border-radius: var(--r-sm); }
.bottom-nav a svg { width: 22px; height: 22px; }
.bottom-nav a.active { color: var(--gold-deep); }

/* ---------- Floating WhatsApp button ---------- */
.mobile-fab { display: none; position: fixed; right: 16px; bottom: 80px; z-index: var(--z-fab); align-items: center; gap: .5rem; padding: .85rem 1.2rem; border-radius: var(--r-pill); background: #25d366; color: #fff; font-weight: 700; box-shadow: 0 12px 30px rgba(37,211,102,.4); }
.mobile-fab svg { width: 20px; height: 20px; }

/* ---------- Renewal flow (online banking feel) ---------- */
.renew-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-xl); padding: clamp(1.5rem, 4vw, 2.5rem); box-shadow: var(--shadow-md); }
.timeline { display: flex; flex-direction: column; gap: 0; }
.tl-step { display: grid; grid-template-columns: 40px 1fr; gap: 1rem; padding-bottom: 1.75rem; position: relative; }
.tl-step:not(:last-child)::before { content:""; position: absolute; left: 19px; top: 40px; bottom: 0; width: 2px; background: var(--line); }
.tl-dot { width: 40px; height: 40px; border-radius: 50%; background: var(--gold-soft); color: var(--gold-deep); display: grid; place-items: center; font-weight: 800; z-index: 1; border: 1px solid color-mix(in srgb, var(--gold) 30%, transparent); }
.tl-step.active .tl-dot { background: var(--info); color: #fff; border-color: transparent; }
.tl-step.done .tl-dot { background: var(--success); color: #fff; border-color: transparent; }
.tl-step b { font-weight: var(--fw-bold); }
.kv { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--line); font-size: var(--step-0); }
.kv:last-child { border-bottom: 0; }
.kv span:first-child { color: var(--muted); }
.kv span:last-child { font-weight: 700; font-variant-numeric: tabular-nums; }
.progress { height: 10px; border-radius: var(--r-pill); background: var(--surface-2); overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: var(--r-pill); background: linear-gradient(90deg, var(--gold), var(--gold-strong)); transition: width .5s var(--ease); }
.receipt { background: var(--gold-tint); border: 1px dashed color-mix(in srgb, var(--gold) 45%, transparent); border-radius: var(--r-md); padding: 1.25rem; }

/* ---------- Skeleton loading ---------- */
.skeleton { background: linear-gradient(90deg, var(--surface-2) 25%, var(--line) 37%, var(--surface-2) 63%); background-size: 400% 100%; animation: sk 1.3s ease infinite; border-radius: var(--r-sm); }
@keyframes sk { 0% { background-position: 100% 0; } 100% { background-position: -100% 0; } }
.sk-line { height: .9rem; margin: .5rem 0; }
.sk-block { height: 120px; border-radius: var(--r-md); }

/* ---------- Page hero (interior pages) ---------- */
.page-hero { position: relative; overflow: hidden; isolation: isolate; background: linear-gradient(160deg, var(--gold-tint) 0%, var(--paper) 60%); }
.page-hero .container { padding-block: clamp(3rem, 7vw, 5rem); }
.page-hero h1 { font-size: var(--step-5); }

/* ---------- Service list ---------- */
.svc-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1rem; }
.svc-item { display: flex; gap: .9rem; align-items: flex-start; padding: 1rem; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); transition: border-color var(--dur), transform var(--dur); }
.svc-item:hover { border-color: var(--gold); transform: translateY(-2px); }
.svc-item h4 { font-size: var(--step-0); }
.svc-item p { font-size: var(--step--1); color: var(--muted); margin-top: .2rem; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .cols-4 { grid-template-columns: repeat(2, 1fr); }
  .cols-3 { grid-template-columns: repeat(2, 1fr); }
  /* Hide the "Contact Us" nav link on smaller laptops; WhatsApp button covers contact. */
  .nav-links a.nav-contact { display: none; }
}
@media (max-width: 760px) {
  .nav-links, .nav-actions .btn:not(.btn-wa) { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-links.open { display: flex; flex-direction: column; align-items: stretch; gap: .25rem; position: absolute; top: var(--header-h); left: 0; right: 0; background: var(--surface); border-bottom: 1px solid var(--line); padding: 1rem; box-shadow: var(--shadow-md); z-index: var(--z-header); }
  .nav-links.open a { padding: .8rem 1rem; }
  .cols-3, .cols-4, .cols-2 { grid-template-columns: 1fr; }
  .svc-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 1.4rem; }
  .bottom-nav { display: flex; }
  .mobile-fab { display: inline-flex !important; }
  body { padding-bottom: 64px; }
}

