:root {
  --navy: #009245;
  --navy-2: #007A3D;
  --gold: #009245;
  --gold-soft: #e7f7ee;
  --bg: #f4f8f5;
  --card: #ffffff;
  --text: #173127;
  --muted: #718096;
  --line: #e6ebf2;
  --green: #0f9f6e;
  --red: #dc4c64;
  --shadow: 0 14px 38px rgba(0, 122, 61, .10);
  --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }

.shell { max-width: 540px; min-height: 100vh; margin: auto; padding-bottom: 94px; }
.hero {
  position: relative;
  overflow: hidden;
  min-height: 208px;
  padding: 24px 20px 42px;
  color: #fff;
  background: linear-gradient(135deg, var(--navy), var(--navy-2));
  border-radius: 0 0 34px 34px;
}
.hero::before, .hero::after {
  content: ""; position: absolute; border: 1px solid rgba(255,255,255,.18); border-radius: 50%;
}
.hero::before { width: 210px; height: 210px; right: -80px; top: -95px; }
.hero::after { width: 140px; height: 140px; right: 12px; top: -58px; }
.topbar { position: relative; z-index: 1; display: flex; justify-content: space-between; align-items: center; }
.brand { display: flex; align-items: center; gap: 11px; font-weight: 850; letter-spacing: .04em; }
.logo {
  width: 43px; height: 43px; display: grid; place-items: center; border-radius: 14px;
  background: #fff; color: var(--navy); font-size: 16px; box-shadow: 0 8px 20px rgba(0,0,0,.12);
}
.icon-btn {
  border: 0; color: inherit; width: 42px; height: 42px; border-radius: 14px;
  background: rgba(255,255,255,.1); backdrop-filter: blur(12px);
}
.greeting { position: relative; z-index: 1; margin-top: 32px; }
.eyebrow { margin: 0 0 6px; color: rgba(255,255,255,.65); font-size: 13px; }
.greeting h1 { margin: 0; font-size: 27px; line-height: 1.18; }
.content { padding: 0 16px; margin-top: -24px; position: relative; z-index: 2; }
.summary {
  display: grid; grid-template-columns: 1.35fr 1fr; gap: 12px; padding: 17px;
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
}
.summary strong { display: block; margin-top: 5px; font-size: 24px; color: var(--navy); }
.summary small { color: var(--muted); }
.summary .balance { padding-left: 16px; border-left: 1px solid var(--line); }
.warehouse-profile {
  margin-top: 12px; padding: 18px; border-radius: var(--radius); color: #fff;
  background: linear-gradient(135deg, var(--navy), var(--navy-2)); box-shadow: var(--shadow);
}
.warehouse-profile-head { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; }
.warehouse-profile-head small,.warehouse-line small { display:block; color:rgba(255,255,255,.68); font-size:11px; margin-bottom:4px; }
.warehouse-profile-head strong { display:block; font-size:25px; letter-spacing:.03em; }
.warehouse-profile-head span { padding:7px 10px; border-radius:99px; background:rgba(255,255,255,.13); font-size:12px; }
.warehouse-line { margin-top:15px; padding-top:14px; border-top:1px solid rgba(255,255,255,.16); }
.warehouse-line p { margin:0; line-height:1.5; font-size:13px; }
.copy-button { width:100%; margin-top:16px; padding:13px; border:0; border-radius:14px; color:var(--navy-2); background:#fff; font-weight:850; }
.gold { color: var(--navy-2) !important; }
.section-title { display: flex; justify-content: space-between; align-items: center; margin: 24px 2px 12px; }
.section-title h2 { margin: 0; font-size: 17px; }
.section-title button { border: 0; background: none; color: var(--navy-2); font-size: 13px; font-weight: 800; }
.menu-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.menu-item {
  min-height: 104px; padding: 13px 8px; border: 1px solid transparent; border-radius: 18px;
  background: var(--card); color: var(--text); text-align: center; box-shadow: 0 5px 18px rgba(15,35,66,.05);
  transition: transform .18s ease, border-color .18s ease;
}
.menu-item:active { transform: scale(.97); border-color: var(--gold); }
.menu-icon {
  display: grid; place-items: center; width: 42px; height: 42px; margin: 0 auto 8px;
  border-radius: 14px; background: var(--gold-soft); font-size: 21px;
}
.menu-item span:last-child { display: block; font-size: 12px; line-height: 1.25; font-weight: 700; }
.parcel-card, .panel, .warehouse-card, .notice {
  background: var(--card); border-radius: var(--radius); box-shadow: 0 6px 22px rgba(15,35,66,.06);
}
.parcel-card { padding: 16px; margin-bottom: 11px; }
.parcel-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.parcel-code { font-size: 16px; font-weight: 850; color: var(--navy); }
.status {
  padding: 7px 9px; border-radius: 99px; background: #eef7f3; color: var(--green);
  font-weight: 750; font-size: 10px; text-align: center;
}
.parcel-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; margin-top: 14px; }
.meta { padding: 9px; border-radius: 12px; background: #f7f9fc; }
.meta small { display: block; margin-bottom: 3px; color: var(--muted); font-size: 10px; }
.meta b { font-size: 12px; }
.bottom-nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); z-index: 10;
  width: min(540px, 100%); height: 76px; display: flex; justify-content: space-around; align-items: center;
  background: rgba(255,255,255,.94); border-top: 1px solid var(--line); backdrop-filter: blur(14px);
}
.nav-btn { border: 0; background: transparent; color: var(--muted); font-size: 11px; }
.nav-btn i { display: block; font-style: normal; font-size: 20px; margin-bottom: 2px; }
.nav-btn.active { color: var(--navy); font-weight: 800; }
.nav-btn.active i { color: var(--navy-2); }

.page { animation: rise .25s ease; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.page-header {
  display: flex; align-items: center; gap: 12px; padding: 18px 16px; position: sticky; top: 0; z-index: 8;
  background: rgba(243,246,250,.93); backdrop-filter: blur(12px);
}
.page-header h1 { margin: 0; font-size: 20px; }
.back { border: 0; width: 42px; height: 42px; border-radius: 14px; background: #fff; color: var(--navy); font-size: 18px; }
.page-body { padding: 4px 16px 30px; }
.panel { padding: 17px; margin-bottom: 13px; }
.field { margin-bottom: 14px; }
.field label { display: block; margin: 0 0 7px 2px; font-size: 12px; font-weight: 750; color: var(--muted); }
.field input, .field select {
  width: 100%; height: 50px; border: 1px solid var(--line); border-radius: 14px;
  background: #f8fafc; padding: 0 14px; outline: none; color: var(--text);
}
.field input:focus, .field select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(0,146,69,.13); }
.primary {
  width: 100%; min-height: 50px; border: 0; border-radius: 15px; padding: 0 18px;
  background: var(--gold); color: #fff; font-weight: 850; box-shadow: 0 8px 18px rgba(0,146,69,.2);
}
.secondary { background: var(--navy); color: white; }
.result-card {
  margin-top: 14px; padding: 21px; border-radius: 20px; color: white;
  background: linear-gradient(135deg, var(--navy), var(--navy-2)); overflow: hidden; position: relative;
}
.result-card::after { content: "J"; position: absolute; right: -4px; bottom: -47px; font-size: 145px; font-weight: 900; color: rgba(255,255,255,.04); }
.result-price { margin: 8px 0 3px; font-size: 35px; font-weight: 900; color: #fff; }
.result-card p { margin: 0; color: rgba(255,255,255,.7); font-size: 13px; }
.tabs { display: flex; padding: 4px; margin-bottom: 14px; border-radius: 14px; background: #e9eef5; }
.tab { flex: 1; border: 0; border-radius: 11px; padding: 10px; color: var(--muted); background: transparent; font-weight: 700; font-size: 12px; }
.tab.active { color: var(--navy); background: #fff; box-shadow: 0 3px 10px rgba(15,35,66,.08); }
.warehouse-card { padding: 18px; margin-bottom: 12px; }
.warehouse-card h3 { margin: 0 0 5px; color: var(--navy); }
.warehouse-card .cn { color: var(--navy-2); font-weight: 800; }
.warehouse-card p { color: var(--muted); line-height: 1.5; font-size: 13px; }
.warehouse-card a { color: var(--navy); font-weight: 800; text-decoration: none; }
.delivery-time { margin: 10px 0 5px; color: var(--navy-2); font-size: 28px; font-weight: 900; }
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.metric { padding: 15px; border-radius: 17px; background: white; }
.metric small { color: var(--muted); }
.metric strong { display: block; margin-top: 6px; font-size: 21px; color: var(--navy); }
.notice { padding: 15px; margin-bottom: 10px; }
.notice h3 { margin: 0 0 5px; font-size: 14px; }
.notice p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.empty { padding: 35px 15px; text-align: center; color: var(--muted); }
.empty b { display: block; color: var(--navy); margin-top: 7px; }
.toast {
  position: fixed; left: 50%; bottom: 90px; z-index: 30; transform: translate(-50%, 20px);
  width: calc(100% - 40px); max-width: 480px; padding: 13px 16px; border-radius: 14px;
  background: var(--navy); color: #fff; opacity: 0; pointer-events: none; transition: .22s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (min-width: 700px) {
  body { padding: 24px 0; background: #e9eef5; }
  .shell { border-radius: 30px; overflow: hidden; box-shadow: 0 30px 80px rgba(15,35,66,.16); background: var(--bg); min-height: calc(100vh - 48px); }
  .hero { border-radius: 0 0 34px 34px; }
  .bottom-nav { bottom: 24px; border-radius: 0 0 30px 30px; }
}
