/* ==========================================================================
   MOZ1 STORE — dark, minimal, mobile first
   ========================================================================== */

:root {
    --bg: #08090d;
    --bg-soft: #0c0e14;
    --surface: #11141c;
    --surface-2: #161a24;
    --surface-3: #1d2230;
    --border: #242936;
    --border-strong: #343b4d;
    --text: #f4f5f9;
    --text-soft: #c3c7d4;
    --muted: #8e95a8;
    --accent: #7c6cff;
    --accent-bright: #9a8dff;
    --accent-soft: rgba(124, 108, 255, 0.14);
    --success: #42d6a3;
    --success-soft: rgba(66, 214, 163, 0.12);
    --warning: #f1b85c;
    --warning-soft: rgba(241, 184, 92, 0.12);
    --danger: #ff6575;
    --danger-soft: rgba(255, 101, 117, 0.1);
    --info: #67b8ff;
    --radius: 16px;
    --radius-sm: 10px;
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
        "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(circle at 78% -8%, rgba(124, 108, 255, 0.1), transparent 38%),
        radial-gradient(circle at 6% 20%, rgba(66, 214, 163, 0.03), transparent 30%);
    pointer-events: none;
}

a {
    color: inherit;
    text-decoration: none;
}

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

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

h1,
h2,
h3,
p,
dl,
ul {
    margin: 0;
}

ul {
    padding: 0;
    list-style: none;
}

::selection {
    background: rgba(124, 108, 255, 0.4);
    color: #fff;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 18px;
}

.mono {
    font-family: var(--mono);
    font-size: 0.92em;
    letter-spacing: -0.02em;
}

.text-accent {
    color: var(--accent-bright) !important;
}

.text-danger {
    color: var(--danger);
}

.is-hidden {
    display: none !important;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 8px;
    z-index: 100;
    padding: 10px 16px;
    background: var(--accent);
    color: #fff;
    border-radius: 8px;
}

.skip-link:focus {
    left: 8px;
}

/* ---------- Flash ---------- */
.flash-wrap {
    padding-top: 16px;
}

.flash {
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-left: 3px solid var(--muted);
    border-radius: var(--radius-sm);
    background: var(--surface);
    color: var(--text-soft);
    font-size: 14px;
}

.flash-success {
    border-left-color: var(--success);
    background: var(--success-soft);
    color: #c9f5e4;
}

.flash-error {
    border-left-color: var(--danger);
    background: var(--danger-soft);
    color: #ffd5da;
}

.flash-info {
    border-left-color: var(--info);
    background: rgba(103, 184, 255, 0.1);
    color: #d5ebff;
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(36, 41, 54, 0.75);
    background: rgba(8, 9, 13, 0.82);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.header-inner {
    min-height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

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

.brand-mark {
    width: 38px;
    height: 38px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--border-strong);
    border-radius: 11px;
    background: linear-gradient(145deg, #242039, #11131b);
    color: #fff;
    font-family: var(--mono);
    font-weight: 700;
    font-size: 17px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.11);
}

.brand-mark-sm {
    width: 34px;
    height: 34px;
    font-size: 15px;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-text strong {
    font-size: 16px;
    letter-spacing: 0.08em;
}

.brand-text small {
    margin-top: 5px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 8px;
    letter-spacing: 0.18em;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 13px;
    white-space: nowrap;
}

.site-nav > a,
.nav-user {
    padding: 7px 10px;
    border-radius: 8px;
    color: var(--muted);
    transition: color 0.2s ease, background 0.2s ease;
}

.site-nav > a:hover,
.site-nav > a.is-active {
    color: var(--text);
    background: var(--surface-2);
}

.nav-user {
    display: none;
    color: var(--text-soft);
    font-family: var(--mono);
    font-size: 12px;
}

.nav-quiet {
    color: var(--muted) !important;
}

.nav-cta {
    margin-left: 3px;
    background: var(--text) !important;
    color: var(--bg) !important;
    font-weight: 600;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 44px;
    padding: 10px 20px;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: var(--text);
    color: var(--bg);
    border-color: var(--text);
}

.btn-primary:hover {
    background: #fff;
    border-color: #fff;
}

.btn-ghost {
    background: transparent;
    color: var(--text-soft);
    border-color: var(--border-strong);
}

.btn-ghost:hover {
    color: var(--text);
    border-color: var(--muted);
    background: var(--surface-2);
}

.btn-danger-ghost {
    background: transparent;
    color: #ff8d99;
    border-color: rgba(255, 101, 117, 0.28);
}

.btn-disabled {
    background: var(--surface-3);
    border-color: var(--border);
    color: var(--muted);
    cursor: not-allowed;
}

.btn-block {
    width: 100%;
}

.btn-sm {
    min-height: 36px;
    padding: 7px 14px;
    font-size: 13px;
}

.btn-xs {
    min-height: 30px;
    padding: 5px 10px;
    border-radius: 7px;
    font-size: 12px;
}

.btn-arrow {
    font-family: var(--mono);
    font-size: 16px;
}

.text-link {
    color: var(--accent-bright);
    font-size: 13px;
}

.text-link:hover {
    text-decoration: underline;
}

/* ---------- Section basics ---------- */
.section {
    padding: 46px 0;
}

.eyebrow {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.dot,
.eyebrow .dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 12px var(--accent);
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}

.section-head h1,
.section-head h2 {
    margin-top: 8px;
    font-size: 27px;
    line-height: 1.2;
    letter-spacing: -0.035em;
}

.section-head-sm {
    align-items: center;
    margin-top: 20px;
}

.section-note {
    color: var(--muted);
    font-size: 12px;
    text-align: right;
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    padding: 42px 0 38px;
}

.hero-inner {
    display: grid;
    gap: 32px;
}

.hero-copy h1 {
    margin-top: 18px;
    max-width: 700px;
    font-size: clamp(36px, 9.2vw, 64px);
    line-height: 1.05;
    letter-spacing: -0.055em;
    font-weight: 750;
}

.hero-copy h1 span {
    color: var(--muted);
}

.hero-desc {
    max-width: 530px;
    margin-top: 18px;
    color: var(--text-soft);
    font-size: 14px;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 26px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.06em;
}

.hero-meta i {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--border-strong);
}

.hero-visual {
    position: relative;
    min-height: 270px;
    display: none;
    align-items: center;
    justify-content: center;
}

.hero-orbit {
    position: absolute;
    width: min(330px, 90%);
    aspect-ratio: 1;
    border: 1px solid var(--border);
    border-radius: 50%;
}

.hero-orbit::before,
.hero-orbit::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    border: 1px solid var(--border);
}

.hero-orbit::before {
    inset: 32px;
    opacity: 0.7;
}

.hero-orbit::after {
    inset: 72px;
    border-style: dashed;
    opacity: 0.5;
}

.hero-card {
    position: relative;
    z-index: 2;
    width: 218px;
    aspect-ratio: 0.76;
    padding: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--border-strong);
    border-radius: 18px;
    background:
        linear-gradient(160deg, rgba(124, 108, 255, 0.14), transparent 48%),
        linear-gradient(180deg, #161924, #0c0d13);
    box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transform: rotate(4deg);
}

.hero-card::after {
    content: "";
    position: absolute;
    inset: 7px;
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 13px;
    pointer-events: none;
}

.hero-card-label,
.hero-card-foot {
    color: var(--muted);
    font-family: var(--mono);
    font-size: 8px;
    letter-spacing: 0.16em;
}

.hero-card-code {
    font-family: var(--mono);
    font-size: 50px;
    font-weight: 700;
    letter-spacing: -0.08em;
    line-height: 1;
}

.hero-card-code span {
    color: var(--accent);
}

.hero-grid-label {
    position: absolute;
    right: 4%;
    bottom: 4%;
    color: var(--border-strong);
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 0.12em;
}

.hero-grid-label span {
    color: var(--accent);
}

/* ---------- Product grid ---------- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.product-card {
    min-width: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    overflow: hidden;
    transition: border-color 0.25s ease, transform 0.25s ease, background 0.25s ease;
}

.product-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-strong);
    background: var(--surface-2);
}

.product-cover {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
    background: #0b0c11;
}

.product-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.product-card:hover .product-cover img {
    transform: scale(1.035);
}

.cover-fallback {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 30% 20%, rgba(124, 108, 255, 0.18), transparent 38%),
        repeating-linear-gradient(135deg, #11131a, #11131a 8px, #0d0f15 8px, #0d0f15 16px);
}

.cover-fallback span {
    color: var(--border-strong);
    font-family: var(--mono);
    font-size: 42px;
    font-weight: 700;
}

.cover-fallback-lg span {
    font-size: 88px;
}

.cover-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 9px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    background: rgba(8, 9, 13, 0.74);
    color: var(--text-soft);
    font-size: 10px;
    backdrop-filter: blur(8px);
}

.product-body {
    padding: 12px;
}

.product-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
}

.product-body h3 {
    font-size: 14px;
    line-height: 1.45;
    letter-spacing: -0.02em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-desc {
    margin-top: 7px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-foot {
    margin-top: 12px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
}

.price {
    color: var(--text);
    font-family: var(--mono);
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.04em;
}

.price::first-letter {
    color: var(--accent-bright);
}

.stock {
    color: var(--muted);
    font-size: 10px;
    font-family: var(--mono);
}

.stock-out {
    color: #7b6370;
}

/* ---------- Empty state ---------- */
.empty-state {
    padding: 60px 24px;
    text-align: center;
    border: 1px dashed var(--border-strong);
    border-radius: var(--radius);
    background: rgba(17, 20, 28, 0.55);
}

.empty-mark {
    display: inline-grid;
    place-items: center;
    min-width: 52px;
    height: 52px;
    padding: 0 10px;
    border: 1px solid var(--border-strong);
    border-radius: 14px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 16px;
    font-weight: 700;
}

.empty-state h3 {
    margin-top: 18px;
    font-size: 18px;
}

.empty-state p {
    margin-top: 7px;
    color: var(--muted);
    font-size: 13px;
}

.empty-state .btn {
    margin-top: 22px;
}

/* ---------- Console banner ---------- */
.section-console {
    padding-top: 6px;
}

.console-banner {
    display: grid;
    gap: 24px;
    padding: 26px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background:
        linear-gradient(135deg, rgba(124, 108, 255, 0.08), transparent 45%),
        var(--surface);
}

.console-banner h2 {
    margin-top: 8px;
    font-size: 23px;
    letter-spacing: -0.04em;
}

.console-banner p:not(.eyebrow) {
    max-width: 560px;
    margin-top: 9px;
    color: var(--muted);
    font-size: 13px;
}

.console-steps {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.console-steps span {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 9px;
    color: var(--text-soft);
    font-size: 12px;
    background: var(--bg-soft);
}

.console-steps b {
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 400;
}

/* ---------- Pagination ---------- */
.pagination {
    margin-top: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 5px;
}

.page-link {
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--muted);
    background: var(--surface);
    font-size: 12px;
    font-family: var(--mono);
}

.page-link:hover {
    color: var(--text);
    border-color: var(--border-strong);
}

.page-link.is-active {
    background: var(--text);
    border-color: var(--text);
    color: var(--bg);
}

.page-link.is-disabled {
    pointer-events: none;
    opacity: 0.4;
}

.page-dots {
    padding: 0 4px;
    color: var(--muted);
    font-size: 12px;
}

/* ---------- Breadcrumb / detail ---------- */
.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
    margin-bottom: 24px;
}

.breadcrumb a:hover {
    color: var(--text);
}

.breadcrumb span {
    color: var(--border-strong);
}

.product-detail-section {
    padding-top: 30px;
}

.detail-grid {
    display: grid;
    gap: 28px;
}

.detail-media {
    position: relative;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--surface);
    aspect-ratio: 1;
}

.detail-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-media .cover-fallback {
    aspect-ratio: 1;
}

.detail-index {
    position: absolute;
    left: 14px;
    bottom: 14px;
    padding: 6px 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 7px;
    background: rgba(8, 9, 13, 0.72);
    color: var(--text-soft);
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 0.12em;
    backdrop-filter: blur(8px);
}

.detail-info {
    display: flex;
    flex-direction: column;
}

.detail-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.dot-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.08em;
}

.dot-label::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--muted);
}

.dot-label.dot-online {
    color: var(--success);
}

.dot-label.dot-online::before {
    background: var(--success);
    box-shadow: 0 0 10px var(--success);
}

.detail-stock {
    color: var(--muted);
    font-family: var(--mono);
    font-size: 11px;
}

.detail-info h1 {
    margin-top: 14px;
    font-size: clamp(28px, 6vw, 44px);
    line-height: 1.16;
    letter-spacing: -0.05em;
}

.detail-price {
    margin-top: 13px;
    color: var(--text);
    font-family: var(--mono);
    font-size: 30px;
    font-weight: 700;
    letter-spacing: -0.05em;
}

.detail-price::first-letter {
    color: var(--accent-bright);
}

.detail-description {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    color: var(--text-soft);
    font-size: 14px;
    line-height: 1.9;
    white-space: pre-wrap;
}

.detail-purchase {
    margin-top: 26px;
}

.purchase-note {
    margin-top: 10px;
    color: var(--muted);
    font-size: 11px;
    text-align: center;
}

.detail-specs {
    margin-top: 26px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.detail-specs > div {
    padding: 11px 10px;
    background: var(--surface);
}

.detail-specs > div + div {
    border-left: 1px solid var(--border);
}

.detail-specs span,
.detail-specs strong {
    display: block;
}

.detail-specs span {
    color: var(--muted);
    font-size: 9px;
}

.detail-specs strong {
    margin-top: 4px;
    color: var(--text-soft);
    font-size: 11px;
    font-weight: 500;
}

/* ---------- Forms / auth ---------- */
.form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

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

.field > span {
    color: var(--text-soft);
    font-size: 12px;
    font-weight: 500;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    min-height: 46px;
    padding: 11px 13px;
    border: 1px solid var(--border-strong);
    border-radius: 9px;
    outline: none;
    background: var(--bg-soft);
    color: var(--text);
    font-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.field input::placeholder,
.field textarea::placeholder {
    color: #5d6476;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    border-color: var(--accent);
    background: #0e1017;
    box-shadow: 0 0 0 3px rgba(124, 108, 255, 0.13);
}

.field select {
    appearance: none;
    background-image:
        linear-gradient(45deg, transparent 50%, var(--muted) 50%),
        linear-gradient(135deg, var(--muted) 50%, transparent 50%);
    background-position:
        calc(100% - 18px) calc(50% - 2px),
        calc(100% - 13px) calc(50% - 2px);
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
    padding-right: 38px;
}

.form-error {
    margin-bottom: 16px;
    padding: 12px 14px;
    border: 1px solid rgba(255, 101, 117, 0.25);
    border-radius: 9px;
    background: var(--danger-soft);
    color: #ffc7ce;
    font-size: 13px;
}

.form-note {
    color: var(--muted);
    font-size: 11px;
    line-height: 1.7;
}

.field-row {
    display: grid;
    gap: 14px;
}

.auth-section {
    padding: 46px 0 70px;
}

.auth-layout {
    display: grid;
    gap: 28px;
    max-width: 940px;
}

.auth-copy {
    position: relative;
    padding: 8px 0;
}

.auth-copy h1 {
    margin-top: 14px;
    font-size: clamp(34px, 8vw, 52px);
    line-height: 1.08;
    letter-spacing: -0.055em;
}

.auth-copy p:not(.eyebrow) {
    max-width: 430px;
    margin-top: 16px;
    color: var(--muted);
    font-size: 13px;
}

.auth-deco {
    display: none;
    margin-top: 40px;
    color: var(--border-strong);
    font-family: var(--mono);
    font-size: 11px;
    letter-spacing: 0.25em;
}

.auth-card {
    padding: 24px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow);
}

.card-head h1,
.card-head h2 {
    font-size: 22px;
    letter-spacing: -0.035em;
}

.card-head p {
    margin-top: 5px;
    color: var(--muted);
    font-size: 12px;
}

.card-head {
    margin-bottom: 22px;
}

.auth-switch {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 12px;
    text-align: center;
}

.auth-switch a {
    color: var(--accent-bright);
}

/* ---------- Checkout ---------- */
.checkout-section {
    padding-top: 28px;
}

.checkout-grid {
    display: grid;
    gap: 18px;
}

.panel {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
}

.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
}

.panel-head h2 {
    font-size: 15px;
    letter-spacing: -0.02em;
}

.panel-head > span,
.panel-head > a {
    color: var(--muted);
    font-size: 11px;
}

.panel-head > a:hover {
    color: var(--text);
}

.panel-sub {
    margin-top: 3px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 400;
}

.panel-head-actions {
    align-items: center;
}

.order-summary {
    align-self: start;
}

.summary-product {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
}

.summary-thumb {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg-soft);
}

.summary-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.summary-info h3 {
    font-size: 14px;
    line-height: 1.4;
}

.summary-info p {
    margin-top: 4px;
    color: var(--muted);
    font-size: 11px;
}

.summary-price {
    flex-shrink: 0;
    font-family: var(--mono);
    font-size: 14px;
}

.summary-total {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin: 0 18px;
    padding: 17px 0;
    border-top: 1px solid var(--border);
}

.summary-total span {
    color: var(--muted);
    font-size: 12px;
}

.summary-total strong {
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 27px;
    letter-spacing: -0.05em;
}

.summary-note {
    padding: 0 18px 18px;
    color: var(--muted);
    font-size: 10px;
}

.checkout-form-panel {
    padding-bottom: 20px;
}

.checkout-form-panel .form {
    padding: 18px;
}

.checkout-submit {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-top: 5px;
}

.pay-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.pay-total span {
    color: var(--muted);
    font-size: 12px;
}

.pay-total strong {
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 20px;
}

/* ---------- Payment ---------- */
.pay-section {
    padding-top: 32px;
}

.pay-container {
    max-width: 900px;
}

.pay-head {
    margin-bottom: 24px;
    text-align: center;
}

.pay-head h1 {
    margin-top: 10px;
    font-size: clamp(28px, 6vw, 42px);
    letter-spacing: -0.05em;
}

.pay-head p:not(.eyebrow) {
    margin-top: 7px;
    color: var(--muted);
    font-size: 12px;
}

.pay-head .eyebrow {
    justify-content: center;
}

.pay-layout {
    display: grid;
    gap: 18px;
}

.qr-panel {
    padding: 20px;
}

.qr-frame {
    width: 100%;
    max-width: 270px;
    margin: 0 auto;
    padding: 14px;
    border-radius: 13px;
    background: #fff;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.28);
}

.qr-frame img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: contain;
}

.qr-empty {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 20px;
    border: 1px dashed #b9bfcc;
    border-radius: 8px;
    color: #5c6272;
    text-align: center;
}

.qr-empty strong {
    color: #2f3441;
    font-size: 14px;
}

.qr-empty span {
    font-size: 10px;
}

.qr-caption {
    margin-top: 18px;
    text-align: center;
}

.qr-caption span {
    color: var(--muted);
    font-size: 11px;
}

.qr-caption strong {
    display: block;
    margin-top: 2px;
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 34px;
    letter-spacing: -0.06em;
}

.qr-caption p {
    margin: 9px auto 0;
    max-width: 300px;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.7;
}

/* 多收款渠道（微信 + 支付宝）：点击切换出示付款码 */
.pay-channels {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.pay-channels:has(> :only-child) {
    grid-template-columns: minmax(0, 220px);
    justify-content: center;
}

.pay-channel-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    color: var(--text);
    font: inherit;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.pay-channel-btn i {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.pay-channel-btn strong {
    font-size: 14px;
}

.pay-channel-btn span {
    color: var(--muted);
    font-size: 10px;
}

.pay-channel-btn:hover {
    border-color: var(--border-strong);
}

.pay-channel-btn.is-active {
    background: var(--bg-soft);
}

.pay-channel-btn.is-active.channel-wechat {
    border-color: #2aae67;
}

.pay-channel-btn.is-active.channel-alipay {
    border-color: #1677ff;
}

.qr-single {
    margin-top: 20px;
    text-align: center;
}

.qr-single .qr-frame {
    max-width: 240px;
    margin: 0 auto;
}

.qr-single .btn {
    margin-top: 14px;
}

.qr-tip {
    margin: 10px auto 0;
    max-width: 260px;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.7;
}

.qr-channel-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    color: var(--muted);
    font-size: 11px;
    letter-spacing: 0.08em;
}

.qr-channel-label i,
.channel-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.channel-dot {
    margin-right: 7px;
    vertical-align: 1px;
}

.channel-wechat {
    background: #2aae67;
}

.channel-alipay {
    background: #1677ff;
}

.admin-qr-note {
    margin-top: 14px;
    text-align: center;
}

@media (max-width: 400px) {
    .pay-channels {
        gap: 12px;
    }
}

.pay-info {
    padding: 18px;
}

.pay-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.pay-waiting {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--warning);
    font-size: 11px;
}

.pay-waiting i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--warning);
    animation: pulse 1.7s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(241, 184, 92, 0.3); }
    50% { opacity: 0.6; box-shadow: 0 0 0 5px rgba(241, 184, 92, 0); }
}

.info-list {
    padding: 6px 0;
}

.info-list > div {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    padding: 9px 0;
    border-bottom: 1px solid rgba(36, 41, 54, 0.5);
    font-size: 12px;
}

.info-list > div:last-child {
    border-bottom: 0;
}

.info-list span {
    color: var(--muted);
    flex-shrink: 0;
}

.info-list strong {
    font-weight: 500;
    text-align: right;
    word-break: break-all;
}

.pay-steps {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 14px 0 16px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--bg-soft);
}

.pay-steps span {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-soft);
    font-size: 11px;
}

.pay-steps b {
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 400;
}

.pay-info .btn + .btn {
    margin-top: 9px;
}

.pay-hint {
    margin-top: 13px;
    color: #6c7386;
    font-size: 10px;
    line-height: 1.65;
    text-align: center;
}

/* ---------- Orders ---------- */
.orders-section {
    padding-top: 32px;
}

.order-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.order-card {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    overflow: hidden;
}

.order-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 16px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-soft);
}

.order-number span,
.order-address > span,
.order-time > span,
.order-amount span,
.tracking-box span:first-child {
    display: block;
    color: var(--muted);
    font-size: 9px;
    letter-spacing: 0.04em;
}

.order-number strong {
    display: block;
    margin-top: 2px;
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 500;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 9px;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    font-size: 10px;
    white-space: nowrap;
}

.status-badge::before {
    content: "";
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: currentColor;
}

.status-pending {
    color: var(--warning);
    border-color: rgba(241, 184, 92, 0.25);
    background: var(--warning-soft);
}

.status-paid {
    color: var(--success);
    border-color: rgba(66, 214, 163, 0.25);
    background: var(--success-soft);
}

.status-shipped {
    color: var(--accent-bright);
    border-color: rgba(124, 108, 255, 0.28);
    background: var(--accent-soft);
}

.status-completed {
    color: var(--muted);
    border-color: var(--border-strong);
    background: var(--surface-2);
}

.status-online {
    color: var(--success);
    border-color: rgba(66, 214, 163, 0.25);
    background: var(--success-soft);
}

.status-offline {
    color: var(--muted);
    border-color: var(--border-strong);
    background: var(--surface-2);
}

.order-product {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 16px;
}

.order-thumb {
    width: 56px;
    height: 56px;
    flex-shrink: 0;
    border: 1px solid var(--border);
    border-radius: 9px;
    overflow: hidden;
    background: var(--bg-soft);
}

.order-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

.order-product-info h3 {
    font-size: 13px;
    line-height: 1.4;
}

.order-product-info p {
    margin-top: 4px;
    color: var(--muted);
    font-size: 10px;
    font-family: var(--mono);
}

.order-amount {
    text-align: right;
    flex-shrink: 0;
}

.order-amount strong {
    display: block;
    margin-top: 2px;
    font-family: var(--mono);
    font-size: 15px;
}

.order-details {
    display: grid;
    gap: 10px;
    padding: 13px 16px;
    border-top: 1px solid var(--border);
}

.order-address p,
.order-time p {
    margin-top: 2px;
    color: var(--text-soft);
    font-size: 11px;
    line-height: 1.55;
}

.order-address p + p {
    margin-top: 2px;
    color: var(--muted);
}

.tracking-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 16px 14px;
    padding: 11px 13px;
    border: 1px solid rgba(124, 108, 255, 0.24);
    border-radius: 9px;
    background: var(--accent-soft);
}

.tracking-box strong {
    display: block;
    margin-top: 2px;
    font-family: var(--mono);
    font-size: 13px;
    letter-spacing: 0.03em;
    word-break: break-all;
}

.tracking-note {
    flex-shrink: 0;
    color: var(--accent-bright);
    font-size: 10px;
}

.order-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 11px 16px;
    border-top: 1px solid var(--border);
    background: var(--bg-soft);
}

.order-hint {
    color: var(--muted);
    font-size: 10px;
    line-height: 1.5;
}

/* ---------- Footer ---------- */
.site-footer {
    margin-top: 30px;
    border-top: 1px solid var(--border);
    background: var(--bg-soft);
}

.footer-inner {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding-top: 28px;
    padding-bottom: 28px;
}

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

.footer-brand strong {
    font-size: 13px;
    letter-spacing: 0.06em;
}

.footer-brand p {
    margin-top: 3px;
    color: var(--muted);
    font-size: 10px;
}

.footer-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: #5c6274;
    font-size: 10px;
}

.footer-meta a:hover {
    color: var(--muted);
}

/* ---------- Responsive: front ---------- */
@media (min-width: 560px) {
    .container {
        padding: 0 24px;
    }

    .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 14px;
    }

    .product-body {
        padding: 14px;
    }

    .product-body h3 {
        font-size: 14px;
    }

    .product-desc {
        font-size: 11.5px;
    }

    .product-foot {
        margin-top: 15px;
    }

    .hero-meta {
        gap: 12px;
    }

    .console-steps {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .field-row {
        grid-template-columns: 1fr 1fr;
    }

    .auth-card {
        padding: 30px;
    }

    .checkout-submit {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .checkout-submit .btn {
        min-width: 220px;
    }

    .pay-info .btn + .btn {
        margin-top: 0;
    }

    .pay-info .btn-block {
        display: inline-flex;
        width: calc(50% - 5px);
        margin-top: 12px;
    }

    .order-details {
        grid-template-columns: 1.5fr 1fr;
        gap: 20px;
    }

    .footer-inner {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .footer-meta {
        gap: 26px;
    }
}

@media (min-width: 760px) {
    .site-nav {
        font-size: 14px;
    }

    .nav-user {
        display: inline-block;
    }

    .product-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 16px;
    }

    .section {
        padding: 64px 0;
    }

    .section-head h1,
    .section-head h2 {
        font-size: 34px;
    }

    .pay-layout {
        grid-template-columns: 0.95fr 1.05fr;
        align-items: start;
    }

    .pay-info {
        padding: 24px;
    }

    .qr-panel {
        padding: 26px;
    }

    .orders-section .order-card {
        border-radius: 14px;
    }

    .auth-layout {
        grid-template-columns: 0.9fr 1.1fr;
        align-items: center;
        gap: 60px;
        padding-top: 40px;
    }

    .auth-deco {
        display: block;
    }

    .auth-card {
        padding: 34px;
    }

    .checkout-grid {
        grid-template-columns: 0.92fr 1.08fr;
        align-items: start;
        gap: 22px;
    }

    .summary-thumb {
        width: 72px;
        height: 72px;
    }

    .checkout-form-panel .form {
        padding: 22px;
    }
}

@media (min-width: 960px) {
    .container {
        padding: 0 32px;
    }

    .hero {
        padding: 64px 0 60px;
    }

    .hero-inner {
        grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
        align-items: center;
        gap: 40px;
        min-height: 440px;
    }

    .hero-visual {
        display: flex;
    }

    .hero-desc {
        font-size: 15px;
    }

    .detail-grid {
        grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
        gap: 52px;
        align-items: start;
    }

    .detail-media {
        position: sticky;
        top: 92px;
    }

    .detail-info {
        padding-top: 8px;
    }

    .product-detail-section {
        padding-top: 42px;
    }

    .order-summary {
        position: sticky;
        top: 92px;
    }

    .console-banner {
        grid-template-columns: 1.15fr 0.85fr;
        align-items: center;
        padding: 34px;
    }

    .console-steps {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ==========================================================================
   ADMIN
   ========================================================================== */

.admin-body {
    background: #07080c;
}

.admin-shell {
    min-height: 100vh;
}

.admin-sidebar {
    border-bottom: 1px solid var(--border);
    background: #0b0d13;
}

.admin-brand {
    padding: 15px 18px 13px;
}

.admin-nav {
    display: flex;
    gap: 3px;
    overflow-x: auto;
    padding: 0 12px 12px;
    scrollbar-width: thin;
}

.admin-nav a {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 11px;
    border: 1px solid transparent;
    border-radius: 8px;
    color: var(--muted);
    font-size: 12px;
    white-space: nowrap;
}

.admin-nav a span {
    color: #5b6273;
    font-family: var(--mono);
    font-size: 9px;
}

.admin-nav a:hover {
    color: var(--text-soft);
    background: var(--surface);
}

.admin-nav a.is-active {
    border-color: var(--border);
    background: var(--surface-2);
    color: var(--text);
}

.admin-nav a.is-active span {
    color: var(--accent-bright);
}

.admin-sidebar-foot {
    display: none;
}

.admin-main {
    min-width: 0;
}

.admin-topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 17px 18px;
    border-bottom: 1px solid var(--border);
    background: rgba(7, 8, 12, 0.86);
    backdrop-filter: blur(16px);
}

.admin-topbar h1 {
    margin-top: 5px;
    font-size: 23px;
    letter-spacing: -0.04em;
}

.admin-mobile-exit {
    flex-shrink: 0;
    padding: 7px 11px;
    border: 1px solid var(--border);
    border-radius: 7px;
    color: var(--muted);
    font-size: 11px;
}

.admin-content {
    padding: 18px;
    max-width: 1440px;
    margin: 0 auto;
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.stat-card {
    position: relative;
    overflow: hidden;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 13px;
    background: var(--surface);
}

.stat-card::after {
    content: "";
    position: absolute;
    top: -28px;
    right: -30px;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: rgba(124, 108, 255, 0.05);
}

.stat-label {
    color: var(--muted);
    font-size: 10px;
}

.stat-card strong {
    display: block;
    margin-top: 8px;
    font-family: var(--mono);
    font-size: 28px;
    line-height: 1;
    letter-spacing: -0.06em;
}

.stat-card p {
    margin-top: 9px;
    color: #616879;
    font-size: 9px;
}

.stat-card.stat-warning {
    border-color: rgba(241, 184, 92, 0.18);
}

.stat-card.stat-warning strong {
    color: var(--warning);
}

.stat-card.stat-accent {
    border-color: rgba(124, 108, 255, 0.24);
    background: linear-gradient(150deg, rgba(124, 108, 255, 0.08), var(--surface) 55%);
}

.stat-card.stat-accent strong {
    color: var(--accent-bright);
}

.stat-money {
    font-size: 22px !important;
}

.admin-grid {
    display: grid;
    gap: 16px;
}

.admin-grid > .panel {
    min-width: 0;
}

.quick-actions {
    padding: 8px;
}

.quick-actions a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 10px;
    transition: background 0.2s ease;
}

.quick-actions a:hover {
    background: var(--surface-2);
}

.quick-actions a > span {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
    border: 1px solid var(--border-strong);
    border-radius: 9px;
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 13px;
}

.quick-actions strong,
.quick-actions small {
    display: block;
}

.quick-actions strong {
    font-size: 12px;
    font-weight: 500;
}

.quick-actions small {
    margin-top: 2px;
    color: var(--muted);
    font-size: 9px;
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    min-width: 680px;
    border-collapse: collapse;
    font-size: 12px;
}

.data-table th {
    padding: 11px 14px;
    border-bottom: 1px solid var(--border);
    color: var(--muted);
    font-size: 9px;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-align: left;
    white-space: nowrap;
    background: rgba(12, 14, 20, 0.5);
}

.data-table td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(36, 41, 54, 0.65);
    color: var(--text-soft);
    vertical-align: middle;
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.data-table tbody tr:hover td {
    background: rgba(22, 26, 36, 0.45);
}

.table-sub {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.45;
}

.table-address {
    max-width: 260px;
}

.table-actions {
    white-space: nowrap;
}

.table-product {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 220px;
}

.table-thumb {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    background: var(--bg-soft);
}

.table-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.table-product strong {
    display: block;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
}

.table-product small {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    font-size: 9px;
}

.row-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
}

.inline-form {
    display: inline;
}

.panel-count {
    color: var(--muted);
    font-family: var(--mono);
    font-size: 10px;
}

.filter-tabs {
    display: flex;
    gap: 5px;
    overflow-x: auto;
    padding-bottom: 13px;
    scrollbar-width: thin;
}

.filter-tabs a {
    flex-shrink: 0;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    color: var(--muted);
    font-size: 11px;
}

.filter-tabs a:hover {
    border-color: var(--border-strong);
    color: var(--text-soft);
}

.filter-tabs a.is-active {
    border-color: var(--accent);
    background: var(--accent-soft);
    color: var(--accent-bright);
}

.admin-empty {
    padding: 44px 20px;
    color: var(--muted);
    font-size: 12px;
    text-align: center;
}

.admin-empty .btn {
    margin-top: 15px;
}

.form-panel {
    max-width: 1080px;
}

.form-grid {
    display: grid;
    gap: 22px;
    padding: 20px 18px;
}

.form-main,
.form-side {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding: 16px 18px;
    border-top: 1px solid var(--border);
}

.product-form .form-error {
    margin: 16px 18px 0;
}

.product-form .field-row {
    display: grid;
    gap: 14px;
}

.upload-box {
    padding: 11px;
    border: 1px dashed var(--border-strong);
    border-radius: 11px;
    background: var(--bg-soft);
}

.upload-preview {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
    background: var(--surface-2);
}

.upload-placeholder {
    display: block;
    margin-bottom: 9px;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.6;
}

.upload-box input[type="file"] {
    width: 100%;
    color: var(--muted);
    font-size: 10px;
}

.upload-box input[type="file"]::file-selector-button {
    margin-right: 8px;
    padding: 7px 11px;
    border: 1px solid var(--border-strong);
    border-radius: 7px;
    background: var(--surface-2);
    color: var(--text-soft);
    font: inherit;
    cursor: pointer;
}

.upload-box input[type="file"]::file-selector-button:hover {
    border-color: var(--muted);
}

.account-panel {
    max-width: 520px;
    padding-bottom: 20px;
}

.account-panel .form {
    padding: 20px 18px;
}

.account-panel .form .btn {
    align-self: flex-start;
}

.account-tip {
    max-width: 520px;
    margin-top: 16px;
    padding: 18px;
}

.account-tip h2 {
    font-size: 14px;
}

.account-tip p {
    margin-top: 6px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.7;
    word-break: break-all;
}

.admin-page-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 15px;
    color: var(--muted);
    font-size: 10px;
}

.order-detail-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 18px;
    margin-bottom: 16px;
}

.order-detail-head h2 {
    margin-top: 9px;
    font-size: 18px;
    line-height: 1.35;
    letter-spacing: -0.03em;
}

.order-detail-head p {
    margin-top: 5px;
    color: var(--muted);
    font-size: 10px;
}

.order-detail-total {
    flex-shrink: 0;
    color: var(--accent-bright);
    font-family: var(--mono);
    font-size: 24px;
    letter-spacing: -0.05em;
}

.admin-order-grid {
    display: grid;
    gap: 16px;
}

.admin-order-main,
.admin-order-side {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.detail-list {
    padding: 8px 18px 14px;
}

.detail-list > div {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    padding: 9px 0;
    border-bottom: 1px solid rgba(36, 41, 54, 0.55);
    font-size: 12px;
}

.detail-list > div:last-child {
    border-bottom: 0;
}

.detail-list dt {
    width: 72px;
    flex-shrink: 0;
    color: var(--muted);
    font-size: 10px;
}

.detail-list dd {
    margin: 0;
    color: var(--text-soft);
    word-break: break-all;
}

.admin-order-side .panel .form {
    padding: 18px;
}

.status-guide ul {
    padding: 12px 16px 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.status-guide li {
    display: flex;
    align-items: center;
    gap: 9px;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.5;
}

.status-guide .status-badge {
    flex-shrink: 0;
}

.admin-qr-grid {
    display: grid;
    gap: 16px;
}

.admin-qr-preview {
    min-height: 250px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 22px;
}

.qr-frame-admin {
    max-width: 230px;
    margin: 0;
}

.qr-empty-admin {
    width: 100%;
    min-height: 210px;
    border-color: var(--border-strong);
    background: var(--bg-soft);
    color: var(--muted);
}

.qr-empty-admin strong {
    color: var(--text-soft);
}

.admin-qr-grid .panel .form {
    padding: 18px;
}

.upload-box-simple .upload-preview {
    max-height: 240px;
    object-fit: contain;
}

.admin-qr-preview .form-note {
    margin-top: 12px;
    text-align: center;
}

/* ---------- Admin login ---------- */
.admin-login-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 18px;
    background:
        radial-gradient(circle at 50% -10%, rgba(124, 108, 255, 0.13), transparent 35%),
        var(--bg);
}

.admin-login-wrap {
    width: 100%;
    max-width: 410px;
}

.admin-login-brand {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 20px;
}

.admin-login-brand strong,
.admin-login-brand span {
    display: block;
}

.admin-login-brand strong {
    font-size: 14px;
    letter-spacing: 0.07em;
}

.admin-login-brand span {
    margin-top: 3px;
    color: var(--muted);
    font-family: var(--mono);
    font-size: 8px;
    letter-spacing: 0.15em;
}

.admin-login-card {
    padding: 26px 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow);
}

.admin-login-card .auth-switch {
    display: none;
}

.admin-login-card .btn {
    margin-top: 3px;
}

.admin-login-back {
    display: block;
    margin-top: 20px;
    color: var(--muted);
    font-size: 11px;
    text-align: center;
}

.admin-login-back:hover {
    color: var(--text-soft);
}

/* ---------- Responsive: admin ---------- */
@media (min-width: 620px) {
    .admin-content {
        padding: 22px;
    }

    .stat-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 12px;
    }

    .stat-card {
        padding: 18px;
    }

    .stat-card strong {
        font-size: 32px;
    }

    .stat-money {
        font-size: 24px !important;
    }

    .admin-login-card {
        padding: 34px;
    }

    .admin-qr-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }

    .form-grid {
        grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.65fr);
        padding: 24px;
    }

    .product-form .field-row {
        grid-template-columns: 1fr 1fr;
    }

    .upload-box {
        position: sticky;
        top: 88px;
    }
}

@media (min-width: 960px) {
    .admin-shell {
        display: grid;
        grid-template-columns: 234px minmax(0, 1fr);
    }

    .admin-sidebar {
        position: sticky;
        top: 0;
        height: 100vh;
        display: flex;
        flex-direction: column;
        border-right: 1px solid var(--border);
        border-bottom: 0;
    }

    .admin-brand {
        padding: 22px 20px 24px;
        border-bottom: 1px solid var(--border);
    }

    .admin-nav {
        flex-direction: column;
        overflow: visible;
        padding: 14px 10px;
        gap: 2px;
    }

    .admin-nav a {
        padding: 10px 12px;
    }

    .admin-sidebar-foot {
        display: block;
        margin-top: auto;
        padding: 16px 18px 20px;
        border-top: 1px solid var(--border);
    }

    .admin-user span,
    .admin-user strong {
        display: block;
    }

    .admin-user span {
        color: var(--muted);
        font-size: 9px;
    }

    .admin-user strong {
        margin-top: 3px;
        color: var(--text-soft);
        font-family: var(--mono);
        font-size: 11px;
        font-weight: 500;
    }

    .admin-foot-links {
        display: flex;
        gap: 15px;
        margin-top: 12px;
    }

    .admin-foot-links a {
        color: var(--muted);
        font-size: 10px;
    }

    .admin-foot-links a:hover {
        color: var(--text-soft);
    }

    .admin-mobile-exit {
        display: none;
    }

    .admin-topbar {
        padding: 21px 30px;
    }

    .admin-topbar h1 {
        font-size: 26px;
    }

    .admin-content {
        padding: 26px 30px 40px;
    }

    .stat-grid {
        margin-bottom: 20px;
    }

    .admin-grid {
        grid-template-columns: minmax(0, 1.55fr) minmax(270px, 0.45fr);
        gap: 20px;
    }

    .admin-order-grid {
        grid-template-columns: minmax(0, 1.35fr) minmax(290px, 0.65fr);
        align-items: start;
        gap: 20px;
    }

    .order-detail-head {
        padding: 22px;
    }

    .order-detail-head h2 {
        font-size: 22px;
    }
}

@media (min-width: 1200px) {
    .admin-content {
        padding: 30px 38px 50px;
    }

    .admin-topbar {
        padding: 23px 38px;
    }
}

