/* MFZ Studio Limited Edition - Light Modern Theme */
:root {
  --bg: #f8f9fb;
  --bg2: #f0f2f6;
  --surface: #ffffff;
  --surface2: #fafbfc;
  --text: #111318;
  --text2: #2e333a;
  --muted: #5a5f68;
  --muted2: #788088;
  --border: #dbdee2;
  --border2: #c8ccd2;
  --orange: #d45305;
  --orange2: #e8650a;
  --orange-light: #fff5ed;
  --orange-glow: rgba(212,83,5,.14);
  --yellow: #ca8a04;
  --green: #15803d;
  --green-light: #f0fdf4;
  --red: #ef4444;
  --red-light: #fef2f2;
  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.04);
  --shadow: 0 2px 8px rgba(0,0,0,.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,.08);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  font-size: 13px;
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: ""; position: fixed; top: 0; left: 0; right: 0; height: 4px; z-index: 200;
  background: linear-gradient(90deg, #e8650a, #eab308, #16a34a, #eab308, #e8650a);
}
a { color: var(--orange); text-decoration: none; transition: color .12s; }
a:hover { color: #d45305; }
img { max-width: 100%; height: auto; display: block; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 16px; }

/* Header */
.topbar {
  position: sticky; top: 4px; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 0; flex-wrap: wrap;
  background: rgba(255,255,255,.94); backdrop-filter: blur(10px);
  margin: 0 -16px; padding: 12px 16px;
}
.brand { display: flex; align-items: center; gap: 8px; color: var(--text); font-weight: 700; font-size: 14px; min-width: 0; }
.brand:hover { color: var(--text); }
.logo {
  width: 34px; height: 34px; border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  background: #1a1d26; color: var(--orange); font-weight: 900; font-size: 14px;
  flex-shrink: 0; box-shadow: 0 2px 8px var(--orange-glow);
}
.brand small { display: block; color: var(--muted); font-size: 10px; }
.brand strong { display: block; line-height: 1.2; }

.nav { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.nav a { padding: 6px 10px; font-size: 11px; font-weight: 500; color: var(--text2); border-radius: var(--radius-sm); transition: all .1s; }
.nav a:hover { background: var(--bg2); color: var(--orange); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  padding: 9px 16px; border-radius: var(--radius-sm); font-size: 12px; font-weight: 600;
  border: none; cursor: pointer; transition: all .12s;
  line-height: 1.3; white-space: nowrap;
}
.btn.primary, .btn-primary { background: var(--orange); color: #fff; box-shadow: 0 2px 10px var(--orange-glow); }
.btn.primary:hover, .btn-primary:hover { background: #d45305; color: #fff; }
.btn.orange { background: var(--orange); color: #fff; box-shadow: 0 2px 10px var(--orange-glow); }
.btn.orange:hover { background: #d45305; color: #fff; }
.btn.ghost { background: var(--surface); color: var(--text2); border: 1px solid var(--border2); }
.btn.ghost:hover { border-color: var(--orange); color: var(--orange); }
.btn.danger { background: var(--red); color: #fff; }
.btn.danger:hover { background: #dc2626; }

.tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 12px; font-size: 9px; font-weight: 700; letter-spacing: .03em; background: var(--orange-light); color: var(--orange); }
.tag.orange { background: var(--orange-light); color: var(--orange); }
.badge { display: inline-block; padding: 2px 6px; border-radius: 8px; font-size: 8px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; background: var(--red); color: #fff; }
.badge.orange { background: var(--orange); }

/* Hero */
.hero { display: grid; grid-template-columns: 2fr 1fr; gap: 14px; margin: 10px 0 16px; align-items: start; }
.hero-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 22px; box-shadow: var(--shadow-sm);
}
.hero-card h1 { font-size: clamp(22px, 4vw, 36px); font-weight: 800; line-height: 1.08; letter-spacing: -.02em; margin: 6px 0 10px; }
.hero-card h1 span { color: var(--orange); }
.hero-card p { color: var(--text2); font-size: 13px; line-height: 1.55; }
.hero-card .tag { margin-bottom: 8px; }

/* Panel */
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin-bottom: 12px; box-shadow: var(--shadow-sm); }
.panel h1 { font-size: 18px; font-weight: 700; }
.panel h2 { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.panel h3 { font-size: 14px; font-weight: 600; }
.panel .small { font-size: 12px; color: var(--muted); }

/* Products */
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; margin: 12px 0; }
.product {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; transition: all .2s; box-shadow: var(--shadow-sm);
}
.product:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.product-img { display: block; position: relative; background: var(--bg2); aspect-ratio: 4/3; overflow: hidden; }
.product-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.product:hover .product-img img { transform: scale(1.03); }
.product-img .badges { position: absolute; top: 6px; left: 6px; display: flex; gap: 3px; }
.product-body { padding: 14px; }
.product-body h3 { font-size: 14px; font-weight: 700; margin-bottom: 3px; }
.product-body .meta { font-size: 11px; color: var(--muted); margin-bottom: 5px; }
.product-body .desc { font-size: 11px; color: var(--text2); line-height: 1.4; margin-bottom: 8px; }
.product-body .price { font-size: 22px; font-weight: 800; color: var(--orange); margin-bottom: 8px; }

.sizes { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 10px; }
.size { padding: 3px 8px; border-radius: 6px; font-size: 10px; font-weight: 600; background: var(--bg2); color: var(--text2); border: 1px solid var(--border2); }

.product-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.section-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 16px 0 10px; flex-wrap: wrap; }
.section-title h2 { font-size: 16px; font-weight: 700; }
.section-title p { color: var(--muted); font-size: 12px; margin-top: 2px; }

/* Quick Strip */
.quick-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 10px; }
.quick-step { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 9px; background: var(--bg2); }
.quick-step b { display: block; font-size: 11px; color: var(--text); }
.quick-step span { display: block; font-size: 10px; color: var(--muted); margin-top: 2px; }

.fee-list { display: grid; gap: 5px; }
.fee-item { display: flex; justify-content: space-between; align-items: center; padding: 7px 10px; background: var(--bg2); border-radius: var(--radius-sm); font-size: 11px; }
.fee-item strong { color: var(--orange); }

/* Guide */
.compact-guide { margin-top: 14px; }
.guide-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.guide-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 14px; margin-top: 8px; }
.mini-flow { display: flex; gap: 3px; flex-wrap: wrap; margin: 6px 0; }
.mini-flow span { padding: 3px 7px; border-radius: 10px; font-size: 9px; font-weight: 600; background: var(--orange-light); color: var(--orange); border: 1px solid rgba(232,101,10,.15); }
.simple-list { margin: 0; padding: 0 0 0 14px; list-style: square; }
.simple-list li { font-size: 11px; margin: 3px 0; color: var(--text2); line-height: 1.4; }
.simple-list li::marker { color: var(--orange); }
.bottom-help { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; margin-top: 8px; }

/* Forms */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid .full { grid-column: 1 / -1; }
.field { margin-bottom: 4px; }
.field label { display: block; font-size: 12px; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--border2); border-radius: var(--radius-sm);
  font-size: 13px; font-family: var(--font); color: var(--text); background: var(--surface); transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-glow); }
.field input::placeholder, .field textarea::placeholder { color: var(--muted2); }
.field small { display: block; font-size: 10px; color: var(--muted); margin-top: 3px; }
.field textarea { min-height: 70px; resize: vertical; }
.field.actions { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }

/* Notices */
.notice { padding: 10px 14px; border-radius: var(--radius-sm); font-size: 12px; line-height: 1.5; margin: 8px 0; border-left: 3px solid var(--orange); background: var(--orange-light); color: #9a3412; }
.notice.warn { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.notice.danger { background: var(--red-light); border-color: #fecaca; color: #991b1b; }

.summary-box { background: var(--bg2); border-radius: var(--radius); padding: 14px; }
.total-row { display: flex; justify-content: space-between; padding: 4px 0; font-size: 12px; }

/* Mini */
.mini-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; margin: 8px 0; }
.mini { display: flex; justify-content: space-between; align-items: center; padding: 7px 10px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 11px; background: var(--surface); }
.mini strong { color: var(--text); }
.mini span { color: var(--text2); text-align: right; }
.mini-grid .mini { flex-direction: column; align-items: flex-start; gap: 2px; }
.mini-grid .mini strong { font-size: 12px; }

/* Cart */
.cart-row { display: grid; grid-template-columns: 48px 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--border); }
.cart-row img { width: 48px; height: 40px; object-fit: cover; border-radius: 6px; }
.cart-actions { display: flex; gap: 5px; align-items: center; }
.qty-input { width: 50px; padding: 6px 8px; border: 1px solid var(--border2); border-radius: 6px; font-size: 12px; text-align: center; background: var(--surface); color: var(--text); }

.empty { text-align: center; padding: 40px 20px; }
.empty h2 { font-size: 16px; margin-bottom: 8px; }
.empty p { color: var(--muted); font-size: 12px; margin-bottom: 16px; }

/* Invoice */
.invoice-print-actions { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0; }
.invoice-a4-note { font-size: 11px; color: var(--muted); margin-top: 4px; }
.invoice .access-box { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 8px 0; }
.invoice .access-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 9px; background: var(--bg2); }
.invoice .access-card small { display: block; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .04em; font-weight: 700; }
.invoice .access-card strong { display: block; margin-top: 2px; font-size: 15px; }
.invoice .access-note { border: 1px dashed var(--orange); border-radius: var(--radius-sm); padding: 7px 10px; background: var(--orange-light); font-size: 11px; margin-bottom: 8px; }
.invoice-form input { width: 100%; padding: 10px 14px; border: 1px solid var(--border2); border-radius: var(--radius-sm); font-size: 13px; margin: 4px 0 8px; background: var(--surface); color: var(--text); }
.invoice-form input:focus { outline: none; border-color: var(--orange); box-shadow: 0 0 0 3px var(--orange-glow); }

.footer { text-align: center; padding: 16px 0; margin-top: 20px; font-size: 11px; color: var(--muted); border-top: 1px solid var(--border); }

/* Modal */
.modal { position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.4); display: none; align-items: center; justify-content: center; padding: 20px; }
.modal.active { display: flex; }
.modal-box { background: var(--surface); border-radius: var(--radius-lg); padding: 20px; max-width: 500px; width: 100%; box-shadow: var(--shadow-md); }
.modal-box img { border-radius: var(--radius-sm); max-height: 400px; object-fit: cover; width: 100%; }
.modal-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; }

/* Print */
@media print {
  @page { size: A4 portrait; margin: 8mm; }
  html, body { background: #fff !important; color: #111 !important; font-size: 11px !important; }
  .topbar, .nav, .invoice-print-actions, .product-actions, .footer, .no-print { display: none !important; }
  .wrap { max-width: 100% !important; padding: 0 !important; }
  .panel, .hero-card { box-shadow: none !important; border: 0 !important; background: #fff !important; margin: 0 0 6px !important; padding: 0 !important; }
  h1, h2, h3, p, span, .small { color: #111 !important; }
  .mini { border: 1px solid #d1d5db !important; }
  .mini-grid { grid-template-columns: repeat(3, 1fr) !important; gap: 4px !important; }
}

/* Responsive */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .guide-grid { grid-template-columns: 1fr; }
  .quick-strip { grid-template-columns: repeat(2, 1fr); }
  .products { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
  .bottom-help { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .wrap { padding: 0 8px; }
  .topbar { margin: 0 -8px; padding: 10px 8px; }
  .hero-card { padding: 16px; }
  .hero-card h1 { font-size: 20px; }
  .quick-strip { grid-template-columns: 1fr; }
  .products { grid-template-columns: 1fr; }
  .bottom-help { grid-template-columns: 1fr; }
  .panel { padding: 14px; }
  .product-actions { flex-direction: column; }
  .product-actions .btn { width: 100%; justify-content: center; }
  .nav a { padding: 4px 7px; font-size: 10px; }
  .invoice .access-box { grid-template-columns: 1fr; }
  .cart-row { grid-template-columns: 40px 1fr; }
  .cart-actions { grid-column: 1 / -1; justify-content: flex-end; }
}
