/* ── VARIABLES & RESET ──────────────────────────────────────── */
:root {
    --black:      #0a0a0a;
    --red:        #d42b2b;
    --red-dark:   #a31f1f;
    --red-light:  #ff4444;
    --white:      #ffffff;
    --off-white:  #f7f5f2;
    --gray-100:   #f0eeeb;
    --gray-200:   #e0ddd9;
    --gray-400:   #9e9b96;
    --gray-600:   #5a5754;
    --gray-800:   #2c2a28;
    --border:     rgba(0,0,0,0.08);
    --shadow-sm:  0 1px 3px rgba(0,0,0,0.06);
    --shadow-md:  0 4px 16px rgba(0,0,0,0.08);
    --shadow-lg:  0 8px 32px rgba(0,0,0,0.12);
    --transition: 0.2s ease;
    --radius:     12px;
    --radius-sm:  8px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Manrope', sans-serif;
    background: var(--off-white);
    color: var(--black);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ── TYPOGRAPHY ─────────────────────────────────────────────── */
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.4} }
@keyframes spin   { to { transform: rotate(360deg); } }
@keyframes shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ── SCROLLBAR ──────────────────────────────────────────────── */
::-webkit-scrollbar       { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--gray-200); border-radius: 4px; }

/* ── UTILITIES ──────────────────────────────────────────────── */
.spinner {
    width: 32px; height: 32px;
    border: 3px solid var(--gray-200);
    border-top-color: var(--red);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin: 40px auto;
    display: block;
}

.skeleton {
    background: linear-gradient(90deg, var(--gray-100) 25%, var(--gray-200) 50%, var(--gray-100) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
}

.empty-state      { text-align: center; padding: 48px 24px; color: var(--gray-400); }
.empty-state-icon { font-size: 40px; margin-bottom: 12px; opacity: 0.5; }
.empty-state-text { font-size: 14px; }

.status-pill {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    white-space: nowrap;
}
.s-pending    { background: #f5f5f5; color: #666; }
.s-paid       { background: #e8f9ee; color: #1a6e35; }
.s-processing { background: #fff0f0; color: #a31f1f; }
.s-warehouse  { background: #e6f1fb; color: #1a5a9e; }
.s-transit    { background: #fff4cc; color: #a07000; }
.s-delivered  { background: #e8f9ee; color: #1a6e35; }
.s-cancelled  { background: #f5f5f5; color: #999; }

/* ── TOAST ──────────────────────────────────────────────────── */
.toast {
    position: fixed;
    bottom: 32px; left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--black);
    color: white;
    padding: 12px 24px;
    border-radius: 40px;
    font-size: 13px; font-weight: 600;
    z-index: 9999;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
    display: flex; align-items: center; gap: 8px;
    border: 1px solid rgba(255,255,255,0.1);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast-dot  { width: 8px; height: 8px; border-radius: 50%; background: var(--red); }

/* ── HEADER ─────────────────────────────────────────────────── */
header {
    position: fixed; top: 0; left: 0; right: 0;
    z-index: 1000;
    background: var(--white);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.header-inner {
    max-width: 1400px; margin: 0 auto;
    padding: 0 24px; height: 64px;
    display: flex; align-items: center; gap: 24px;
}

/* Logo */
.logo {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; flex-shrink: 0; cursor: pointer;
}

.logo-text {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 24px; letter-spacing: 2px;
    color: var(--black); line-height: 1;
}
.logo-text span { color: var(--red); }

/* Header search */
.header-search { flex: 1; max-width: 480px; position: relative; }
.header-search input {
    width: 100%; height: 40px;
    border: 1.5px solid var(--gray-200); border-radius: 20px;
    padding: 0 44px 0 16px;
    font-family: 'Manrope', sans-serif; font-size: 14px;
    background: var(--gray-100); color: var(--black);
    outline: none;
    transition: border-color var(--transition), background var(--transition);
}
.header-search input:focus { border-color: var(--red); background: var(--white); }
.header-search button {
    position: absolute; right: 4px; top: 4px;
    width: 32px; height: 32px;
    border: none; background: var(--red); border-radius: 50%;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background var(--transition);
}
.header-search button:hover { background: var(--red-dark); }
.header-search button svg {
    width: 14px; height: 14px;
    stroke: white; fill: none; stroke-width: 2.5; stroke-linecap: round;
}

/* Header actions */
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.china-time {
    font-size: 12px; color: var(--gray-600);
    padding: 6px 12px;
    background: var(--gray-100); border-radius: 20px;
    display: flex; align-items: center; gap: 6px;
    white-space: nowrap;
}
.china-time .dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--red);
    animation: pulse 2s infinite;
}

.lang-toggle { display: flex; border: 1.5px solid var(--gray-200); border-radius: 20px; overflow: hidden; }
.lang-btn {
    padding: 5px 12px; font-size: 12px; font-weight: 600;
    font-family: 'Manrope', sans-serif;
    border: none; background: transparent; cursor: pointer;
    transition: background var(--transition), color var(--transition);
    color: var(--gray-600);
}
.lang-btn.active { background: var(--black); color: var(--white); border-radius: 18px; }

.icon-btn {
    width: 40px; height: 40px;
    border: 1.5px solid var(--gray-200); border-radius: 50%;
    background: transparent; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    position: relative;
    transition: border-color var(--transition), background var(--transition);
    color: var(--gray-600);
}
.icon-btn:hover { border-color: var(--gray-400); background: var(--gray-100); }
.icon-btn svg   { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; }
.icon-btn .badge {
    position: absolute; top: -4px; right: -4px;
    width: 18px; height: 18px;
    background: var(--red); color: white;
    font-size: 10px; font-weight: 700;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
}

/* Subnav */
.subheader { background: var(--white); border-bottom: 1px solid var(--border); }
.nav-links {
    max-width: 1400px; margin: 0 auto;
    padding: 0 24px; height: 42px;
    display: flex; align-items: center; gap: 4px;
}
.nav-link {
    padding: 6px 14px; font-size: 13px; font-weight: 500;
    color: var(--gray-600); border-radius: 20px;
    transition: color var(--transition), background var(--transition);
    white-space: nowrap; display: flex; align-items: center; gap: 6px;
    cursor: pointer; border: none; background: transparent;
    font-family: 'Manrope', sans-serif;
}
.nav-link:hover  { color: var(--black); background: var(--gray-100); }
.nav-link.active { color: var(--red); background: #fff0f0; }
.nav-link svg    { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; }
.soon-tag {
    font-size: 10px; background: #e8f9ee; color: #1a6e35;
    padding: 1px 6px; border-radius: 10px; font-weight: 700;
}

/* ── FOOTER ─────────────────────────────────────────────────── */
footer { background: var(--black); color: white; padding: 56px 24px 24px; margin-top: 64px; }
.footer-inner  { max-width: 1400px; margin: 0 auto; }
.footer-grid   { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 48px; }
.footer-logo   { font-family: 'Bebas Neue', sans-serif; font-size: 32px; letter-spacing: 3px; margin-bottom: 12px; }
.footer-logo span { color: var(--red-light); }
.footer-desc   { font-size: 13px; color: rgba(255,255,255,0.4); line-height: 1.7; max-width: 280px; }
.footer-col-title {
    font-size: 11px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase;
    color: rgba(255,255,255,0.3); margin-bottom: 16px;
}
.footer-link {
    display: block; font-size: 13px; color: rgba(255,255,255,0.6);
    text-decoration: none; margin-bottom: 10px;
    transition: color var(--transition); cursor: pointer;
}
.footer-link:hover { color: white; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08); padding-top: 24px;
    display: flex; justify-content: space-between; align-items: center;
}
.footer-copy   { font-size: 12px; color: rgba(255,255,255,0.25); }
.alipay-badge  { background: #1677FF; color: white; font-size: 10px; font-weight: 800; padding: 3px 8px; border-radius: 4px; }

/* ── BUTTONS ────────────────────────────────────────────────── */
.btn-primary {
    width: 100%; height: 48px;
    background: var(--red); color: white;
    border: none; border-radius: 12px;
    font-family: 'Manrope', sans-serif; font-size: 14px; font-weight: 700;
    cursor: pointer; transition: background var(--transition);
}
.btn-primary:hover    { background: var(--red-dark); }
.btn-primary:disabled { background: var(--gray-400); cursor: not-allowed; }

/* ── MAIN OFFSET ────────────────────────────────────────────── */
main { padding-top: 107px; }

/* ── RESPONSIVE ─────────────────────────────────────────────── */
@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
    .header-search { display: none; }
    .china-time    { display: none; }
}
