/* Blue Infinity shop, distributor portal and admin — extends css/style.css tokens */
.shop-main { padding-block: clamp(2rem, 4vw, 4rem) clamp(3rem, 6vw, 6rem); min-height: 60vh; }
.shop-head { margin-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.shop-head h1 { font-size: clamp(1.9rem, 1.4rem + 2vw, 2.9rem); line-height: 1.1; margin: .4rem 0 .75rem; color: var(--color-text); }
.shop-head p { color: var(--color-text-muted); max-width: 62ch; margin: 0 0 1rem; }
.shop-h2 { font-size: 1.15rem; margin: 0 0 1rem; color: var(--color-text); }
.muted { color: var(--color-text-muted); }
.small { font-size: .875rem; }
.inline { display: inline; }
.shop-grid { display: grid; gap: clamp(1rem, 2vw, 1.5rem); grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.shop-card { background: var(--color-surface); border: 1px solid var(--color-divider); border-radius: var(--radius-lg); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .2s ease, transform .2s ease; }
.shop-card:hover { box-shadow: 0 10px 30px -12px rgba(11, 59, 140, .25); transform: translateY(-2px); }
.shop-card img, .shop-noimg { width: 100%; aspect-ratio: 4 / 5; object-fit: contain; background: var(--color-surface-2); padding: 1rem; display: block; }
.shop-card-body { padding: 1rem 1.1rem 1.2rem; display: flex; flex-direction: column; gap: .3rem; flex: 1; }
.shop-card h2 { font-size: 1.05rem; line-height: 1.3; margin: 0; color: var(--color-text); }
.shop-card p { margin: 0; }
.shop-price { font-size: 1.25rem; font-weight: 700; color: var(--color-primary); margin-top: .35rem !important; font-variant-numeric: tabular-nums; }
.shop-add { display: flex; gap: .5rem; margin-top: auto; padding-top: .75rem; }
.shop-main .shop-add input[type=number] { width: 4.5rem; flex: none; text-align: center; padding-inline: .3rem; }
.shop-add .btn { flex: 1; justify-content: center; white-space: nowrap; border-radius: var(--radius-full); min-height: 44px; padding-inline: .9rem; }
.shop-main input[type=number], .shop-main input:not([type]), .shop-main input[type=text], .shop-main input[type=email], .shop-main input[type=tel], .shop-main input[type=password], .shop-main select, .shop-main textarea {
  font: inherit; color: var(--color-text); background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: .6rem .7rem; min-height: 44px; width: 100%; }
.shop-main input:focus-visible, .shop-main select:focus-visible, .shop-main textarea:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 1px; border-color: var(--color-accent); }
.shop-table td input[type=number] { width: 5.5rem; text-align: right; }
.shop-narrow { max-width: 760px; }
.shop-table { width: 100%; border-collapse: collapse; background: var(--color-surface); border: 1px solid var(--color-divider); border-radius: var(--radius-lg); overflow: hidden; font-variant-numeric: tabular-nums; margin-bottom: 1rem; }
.shop-table th, .shop-table td { padding: .75rem .9rem; border-bottom: 1px solid var(--color-divider); text-align: left; vertical-align: middle; color: var(--color-text); }
.shop-table th { font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--color-text-muted); background: var(--color-surface-2); font-weight: 600; }
.shop-table .num { text-align: right; white-space: nowrap; }
.shop-table tfoot td { border-bottom: 0; padding-block: .45rem; color: var(--color-text-muted); }
.shop-table tfoot tr:first-child td { padding-top: .9rem; }
.shop-table tr.grand td { font-weight: 700; font-size: 1.1rem; color: var(--color-text); padding-bottom: .9rem; }
.shop-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.shop-checkout { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); align-items: start; }
.shop-summary { position: sticky; top: 6rem; background: var(--color-surface-2); border: 1px solid var(--color-divider); border-radius: var(--radius-lg); padding: 1.25rem; display: grid; gap: 1.25rem; }
.shop-summary .shop-table { margin: 0; }
.shop-fieldset { border: 1px solid var(--color-divider); border-radius: var(--radius-md); padding: .75rem 1rem 1rem; margin: 0 0 1rem; display: grid; gap: .6rem; }
.shop-fieldset legend { padding: 0 .4rem; font-weight: 600; color: var(--color-text); }
.shop-radio { display: flex; gap: .6rem; align-items: flex-start; cursor: pointer; color: var(--color-text); }
.shop-main .shop-radio input { width: 1.1rem; height: 1.1rem; min-height: 0; flex: none; margin: .25rem 0 0; padding: 0; accent-color: var(--color-primary); }
.shop-main .shop-table td input[type=number] { width: 5.5rem; text-align: right; }
.shop-alert { border: 1px solid #d9534f; background: rgba(217, 83, 79, .08); color: var(--color-text); border-radius: var(--radius-md); padding: .75rem 1rem; margin-bottom: 1rem; }
.shop-alert p { margin: .2rem 0; }
.shop-ok { border-left: 3px solid #2e9d6a; padding: .5rem .9rem; background: rgba(46, 157, 106, .1); border-radius: var(--radius-sm); }
.shop-bank { background: var(--color-surface); border: 1px solid var(--color-divider); border-left: 4px solid var(--color-primary); border-radius: var(--radius-lg); padding: 1.25rem 1.4rem; margin-bottom: 1.25rem; }
.shop-bank p { margin: 0 0 1rem; }
.shop-bank dl { display: grid; grid-template-columns: max-content 1fr; gap: .45rem 1.25rem; margin: 0; }
.shop-bank dt { color: var(--color-text-muted); }
.shop-bank dd { margin: 0; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; color: var(--color-text); }
.shop-actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; margin: 1rem 0; }
.shop-main .form-row { margin-bottom: 1rem; display: grid; gap: .35rem; }
.shop-main .form-row label { font-weight: 600; font-size: .92rem; color: var(--color-text); }
.shop-main .card-form { max-width: none; }
@media (max-width: 860px) { .shop-checkout { grid-template-columns: 1fr; } .shop-summary { position: static; order: -1; } }
@media (max-width: 520px) {
  .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
  .shop-card-body { padding: .75rem; }
  .shop-card h2 { font-size: .95rem; }
  .shop-add { flex-direction: column; }
  .shop-main .shop-add input[type=number] { width: 100%; }
  .shop-table th, .shop-table td { padding: .6rem .55rem; font-size: .9rem; }
  .shop-bank dl { grid-template-columns: 1fr; gap: .1rem; }
  .shop-bank dd { margin-bottom: .5rem; }
}

@media (max-width: 640px) {
  .shop-portal thead { display: none; }
  .shop-portal, .shop-portal tbody { display: block; }
  .shop-portal tr { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .25rem .5rem; padding: .85rem; border-bottom: 1px solid var(--color-divider); align-items: end; }
  .shop-portal td { border: 0; padding: 0; font-size: .92rem; }
  .shop-portal td:first-child { grid-column: 1 / -1; margin-bottom: .4rem; font-size: 1rem; }
  .shop-portal td[data-label]::before { content: attr(data-label); display: block; font-size: .68rem; text-transform: uppercase; letter-spacing: .04em; color: var(--color-text-muted); margin-bottom: .2rem; text-align: left; white-space: normal; }
  .shop-portal td.num { text-align: left; }
  .shop-main .shop-portal td input[type=number] { width: 100%; text-align: center; }
}
