:root {
  --bg: #f6f7fb; --ink: #0f172a; --muted: #64748b; --line: #e5e7eb; --card: #fff;
  --dark: #05070f; --dark2: #0d1430; --blue: #1f5bff; --blue2: #4d8dff; --gold: #f5b301; --gold2: #ffcf3f; --red: #e11d48; --green: #059669;
  --radius: 14px; --shadow: 0 6px 24px rgba(15, 23, 42, .08);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans", "PingFang SC", "Noto Sans JP", "Microsoft YaHei", sans-serif; background: var(--bg); color: var(--ink); line-height: 1.55; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); } .small { font-size: 13px; }
[hidden] { display: none !important; }

/* top bar */
.topbar { position: sticky; top: 0; z-index: 40; background: rgba(5, 7, 15, .96); backdrop-filter: blur(8px); color: #fff; }
.topbar-in { display: flex; align-items: center; gap: 24px; height: 64px; }
.logo { display: flex; align-items: center; gap: 10px; font-size: 20px; letter-spacing: .5px; }
.logo-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: linear-gradient(135deg, var(--gold), #ff8a00); color: var(--dark); font-weight: 900; font-size: 15px; }
.logo-text b { color: var(--gold); font-weight: 900; }
.nav { display: flex; gap: 22px; margin-left: 12px; font-size: 14px; }
.nav a { opacity: .8; } .nav a:hover { opacity: 1; color: var(--gold); }
.top-actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }
#langSel { background: transparent; border: 1px solid rgba(255,255,255,.25); border-radius: 8px; padding: 6px 8px; color: #fff; }
#langSel option { color: #000; }
.cart-btn { position: relative; background: var(--gold); color: var(--dark); border: 0; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; cursor: pointer; }
.cart-count { position: absolute; top: -6px; right: -6px; background: var(--red); color: #fff; font-size: 11px; font-weight: 700; min-width: 20px; height: 20px; border-radius: 10px; display: grid; place-items: center; padding: 0 5px; }

.notice { background: var(--gold); color: var(--dark); text-align: center; padding: 8px 16px; font-size: 14px; font-weight: 600; }

/* hero */
.hero { background: radial-gradient(700px 420px at 78% 45%, rgba(31,91,255,.38) 0%, transparent 65%), radial-gradient(500px 260px at 15% 0%, rgba(245,179,1,.14) 0%, transparent 70%), linear-gradient(180deg, var(--dark), var(--dark2)); color: #fff; overflow: hidden; border-bottom: 3px solid var(--gold); }
.hero-in { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: center; padding: 64px 20px 72px; }
.hero-tag { display: inline-block; font-size: 13px; padding: 5px 12px; border: 1px solid rgba(245,179,1,.5); color: var(--gold2); border-radius: 999px; background: rgba(245,179,1,.08); }
.hero h1 b, .hero h1 strong { color: var(--gold2); }
.hero h1 { font-size: clamp(28px, 4vw, 46px); line-height: 1.2; margin: 18px 0 14px; font-weight: 900; }
.hero p { color: #cbd5e1; max-width: 520px; margin: 0 0 26px; }
.hero-logo { display: grid; place-items: center; }
/* The logo is a JPG on black: "lighten" lets the dark page background show through the black. */
.hero-logo img { width: 100%; max-width: 500px; height: auto; mix-blend-mode: lighten; }
.logo-img { display: block; height: 46px; width: auto; mix-blend-mode: lighten; }
.logo-img.lg { height: 80px; }
.hero-contacts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; align-items: center; }
.hero-contacts:empty { display: none; }
.hcx-title { width: 100%; font-size: 13px; color: #94a3b8; }
.hcx { display: inline-flex; flex-direction: column; gap: 1px; padding: 8px 14px; border: 1px solid rgba(255,255,255,.18); border-radius: 10px; color: #fff; text-decoration: none; font-size: 13px; background: rgba(255,255,255,.06); max-width: 100%; overflow-wrap: anywhere; }
.hcx b { font-size: 11px; color: var(--gold2); font-weight: 800; letter-spacing: .5px; }
a.hcx:hover { border-color: var(--gold2); }
.hc { position: absolute; width: 160px; height: 224px; border-radius: 14px; box-shadow: 0 20px 50px rgba(0,0,0,.5); display: flex; align-items: flex-end; padding: 14px; font-weight: 900; font-size: 18px; border: 3px solid rgba(255,255,255,.85); }
.hc span { background: rgba(0,0,0,.45); padding: 3px 10px; border-radius: 6px; }
.hc1 { left: 0; top: 30px; transform: rotate(-12deg); background: linear-gradient(135deg, #f43f5e, #f59e0b 60%, #fde047); }
.hc2 { left: 32%; top: 0; transform: rotate(2deg); background: linear-gradient(135deg, #2563eb, #7c3aed); z-index: 2; }
.hc3 { left: 62%; top: 36px; transform: rotate(13deg); z-index: 3; background: linear-gradient(135deg, #10b981, #0ea5e9); }

.btn { display: inline-block; border: 0; border-radius: 10px; padding: 12px 22px; font-weight: 700; cursor: pointer; transition: transform .1s, filter .15s; text-align: center; }
.btn:active { transform: scale(.98); }
.btn-gold { background: var(--gold); color: var(--dark); } .btn-gold:hover { filter: brightness(1.07); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.block { display: block; width: 100%; }

/* shop */
#shop { padding-top: 36px; padding-bottom: 40px; scroll-margin-top: 70px; }
.cats { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.cat { border: 1px solid var(--line); background: #fff; padding: 9px 16px; border-radius: 999px; cursor: pointer; font-weight: 600; font-size: 14px; }
.cat.active { background: var(--dark); color: #fff; border-color: var(--dark); }
.cat .n { opacity: .55; font-weight: 500; margin-left: 4px; }
.toolbar { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-bottom: 22px; }
.toolbar input[type=search], .toolbar select { border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 10px 12px; }
.toolbar input[type=search] { flex: 1; min-width: 200px; }
.chk { display: flex; align-items: center; gap: 6px; font-size: 14px; cursor: pointer; user-select: none; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; transition: transform .15s, box-shadow .15s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(15,23,42,.12); }
.card.soldout { opacity: .65; }
.thumb { position: relative; aspect-ratio: 1 / 1; background: #eef1f6; display: grid; place-items: center; overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: contain; }
.ph { width: 100%; height: 100%; display: grid; place-items: center; color: #fff; font-weight: 900; font-size: 22px; letter-spacing: 1px; text-align: center; padding: 16px; }
.ph.pokemon { background: linear-gradient(135deg, #ef4444, #f59e0b); }
.ph.onepiece { background: linear-gradient(135deg, #1d4ed8, #0ea5e9); }
.ph.single { background: linear-gradient(135deg, #7c3aed, #ec4899); }
.ph.psa { background: linear-gradient(135deg, #111827, #b91c1c); }
.ph.case { background: linear-gradient(135deg, #78350f, #f5b301); }
.ph.gundam { background: linear-gradient(135deg, #1e3a8a, #dc2626); }
.ph.yugioh { background: linear-gradient(135deg, #3b0764, #b45309); }
.ph.dragonball { background: linear-gradient(135deg, #f97316, #facc15); }
.ph.unionarena { background: linear-gradient(135deg, #0f766e, #22d3ee); }
.ph.holobeat { background: linear-gradient(135deg, #2563eb, #a855f7); }
.ph.ws { background: linear-gradient(135deg, #334155, #e11d48); }
.ph.juicyhoney { background: linear-gradient(135deg, #f472b6, #fb923c); }
.ph.divinecross { background: linear-gradient(135deg, #78350f, #d97706); }
.ph.mtg { background: linear-gradient(135deg, #451a03, #ea580c); }
.ph.othergame { background: linear-gradient(135deg, #475569, #94a3b8); }
.badges { position: absolute; top: 10px; left: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.badge { font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 6px; background: rgba(15,23,42,.85); color: #fff; }
.badge.sale { background: var(--red); } .badge.gold { background: var(--gold); color: var(--dark); } .badge.green { background: var(--green); }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-title { font-weight: 700; font-size: 15px; line-height: 1.35; min-height: 2.7em; }
.card-desc { font-size: 12.5px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { font-size: 20px; font-weight: 900; }
.price s { color: var(--muted); font-size: 13px; font-weight: 500; margin-left: 6px; }
.price.sale { color: var(--red); }
.stock { font-size: 12.5px; color: var(--green); font-weight: 600; }
.stock.low { color: #d97706; } .stock.out { color: var(--muted); }
.card-actions { display: flex; gap: 8px; margin-top: auto; padding-top: 6px; }
.qty { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.qty button { width: 30px; height: 38px; border: 0; background: #f8fafc; cursor: pointer; font-size: 16px; }
.qty input { width: 36px; text-align: center; border: 0; height: 38px; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; }
.card-actions .btn { flex: 1; padding: 9px 10px; font-size: 14px; }
.empty { text-align: center; color: var(--muted); padding: 50px 0; }

/* howto */
.howto { background: var(--dark); color: #fff; padding: 64px 0; scroll-margin-top: 64px; }
.howto h2, .faq h2 { font-size: 28px; margin: 0 0 28px; text-align: center; }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 1000px) { .steps { grid-template-columns: repeat(2, 1fr); } }
.howto-note { margin: 22px 0 0; padding: 14px 18px; border-radius: 12px; background: rgba(245,179,1,.12); border: 1px solid rgba(245,179,1,.45); color: var(--gold2); font-weight: 700; line-height: 1.6; }
.howto-note.info { margin-top: 12px; background: rgba(31,91,255,.14); border-color: rgba(77,141,255,.5); color: #cfe0ff; }
.step { background: var(--dark2); border: 1px solid rgba(255,255,255,.08); border-radius: var(--radius); padding: 26px; }
.step .num { width: 42px; height: 42px; border-radius: 50%; background: var(--gold); color: var(--dark); font-weight: 900; display: grid; place-items: center; font-size: 18px; }
.step h3 { margin: 16px 0 8px; } .step p { margin: 0; color: #cbd5e1; font-size: 14.5px; }

.faq { padding: 64px 20px; max-width: 820px; scroll-margin-top: 64px; }
.faq details { background: #fff; border-radius: 12px; box-shadow: var(--shadow); margin-bottom: 12px; padding: 0 20px; }
.faq summary { cursor: pointer; padding: 16px 0; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::after { content: "+"; color: var(--gold); font-size: 22px; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0 0 16px; color: #334155; }

.footer { background: #070b16; color: #cbd5e1; padding: 40px 0; }
.footer-in { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.footer h4 { color: #fff; margin: 0 0 10px; }
.contacts { list-style: none; padding: 0; margin: 0; font-size: 14px; } .contacts li { margin-bottom: 6px; } .contacts a:hover { color: var(--gold); }

/* drawer + modal */
.overlay { position: fixed; inset: 0; background: rgba(2,6,23,.55); opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 50; }
.overlay.show { opacity: 1; pointer-events: auto; }
.drawer { position: fixed; top: 0; right: 0; height: 100%; width: min(420px, 100%); background: #fff; z-index: 60; transform: translateX(100%); transition: transform .25s; display: flex; flex-direction: column; }
.drawer.show { transform: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { margin: 0; }
.x { border: 0; background: none; font-size: 28px; cursor: pointer; line-height: 1; color: var(--muted); }
.drawer-body { flex: 1; overflow: auto; padding: 8px 20px; }
.drawer-foot { border-top: 1px solid var(--line); padding: 16px 20px; }
.row-between { display: flex; justify-content: space-between; align-items: center; font-size: 17px; }
.ci { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: center; }
.ci-img { width: 56px; height: 56px; border-radius: 8px; overflow: hidden; background: #eef1f6; }
.ci-img img { width: 100%; height: 100%; object-fit: cover; } .ci-img .ph { font-size: 10px; padding: 4px; }
.ci-name { font-weight: 600; font-size: 14px; line-height: 1.3; }
.ci-meta { font-size: 12px; color: var(--muted); }
.ci-right { text-align: right; display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.ci .qty button { height: 28px; width: 26px; } .ci .qty input { height: 28px; width: 30px; }
.link-btn { border: 0; background: none; color: var(--red); font-size: 12px; cursor: pointer; padding: 0; }

.modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 20px; background: rgba(2,6,23,.6); opacity: 0; pointer-events: none; transition: opacity .2s; }
.modal.show { opacity: 1; pointer-events: auto; }
.modal-box { background: #fff; border-radius: 16px; width: min(640px, 100%); max-height: 92vh; overflow: auto; }
.modal-box form, .modal-box > #lkResult { padding: 18px 20px 20px; }
.modal-box.center { text-align: center; padding: 32px 26px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 600; color: #334155; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid input, .form-grid select, .form-grid textarea { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-weight: 400; background: #fff; }
.form-grid input:focus, .form-grid select:focus, .form-grid textarea:focus, .toolbar input:focus { outline: 2px solid var(--gold); border-color: transparent; }
.co-summary { background: #f8fafc; border-radius: 10px; padding: 12px 14px; margin-bottom: 14px; font-size: 14px; }
.co-summary div { display: flex; justify-content: space-between; gap: 10px; padding: 2px 0; }
.co-summary .tot { border-top: 1px dashed var(--line); margin-top: 6px; padding-top: 8px; font-weight: 800; }
.err { background: #fef2f2; color: #b91c1c; padding: 10px 12px; border-radius: 10px; font-size: 14px; white-space: pre-line; }
.ok-icon { width: 64px; height: 64px; border-radius: 50%; background: var(--green); color: #fff; font-size: 34px; display: grid; place-items: center; margin: 0 auto 12px; }
.order-no { font-size: 26px; font-weight: 900; letter-spacing: 1px; background: #fef9c3; display: inline-block; padding: 8px 18px; border-radius: 10px; margin-bottom: 8px; user-select: all; }
.lk-card { background: #f8fafc; border-radius: 12px; padding: 14px; font-size: 14px; }
.status { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: #e2e8f0; }
.status.new { background: #dbeafe; color: #1d4ed8; } .status.confirmed { background: #ede9fe; color: #6d28d9; }
.status.paid { background: #fef3c7; color: #b45309; } .status.shipped { background: #cffafe; color: #0e7490; }
.status.completed { background: #d1fae5; color: #047857; } .status.cancelled { background: #f1f5f9; color: #64748b; }

.toast { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(20px); background: var(--dark); color: #fff; padding: 11px 20px; border-radius: 10px; opacity: 0; transition: all .2s; z-index: 90; pointer-events: none; font-size: 14px; }
.toast.show { opacity: 1; transform: translateX(-50%); }

@media (max-width: 860px) {
  .nav { display: none; }
  .hero-in { grid-template-columns: 1fr; padding: 40px 20px 48px; }
  .hero-logo { order: -1; } .hero-logo img { max-width: 260px; }
  .steps { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-title { font-size: 13.5px; } .price { font-size: 17px; }
  .card-actions { flex-direction: column; } .qty { justify-content: space-between; } .qty input { flex: 1; }
  .form-grid { grid-template-columns: 1fr; }
}

.form-grid .req { color: #e11d48; font-weight: 700; }

/* Homepage slogan: "No prepayment! Orders handled in order!" */
.hero-slogan { display: flex; flex-wrap: wrap; gap: 10px; margin: -6px 0 24px; }
.slogan { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px; background: linear-gradient(135deg, rgba(245,179,1,.22), rgba(245,179,1,.08)); border: 1.5px solid var(--gold); color: #fff; font-weight: 900; font-size: 16px; letter-spacing: .3px; box-shadow: 0 0 18px rgba(245,179,1,.18); }
.slogan b { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--gold); color: var(--dark); font-size: 13px; }
@media (max-width: 600px) { .slogan { font-size: 14.5px; padding: 8px 14px; } }
