.lang-select {
  font: inherit;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  max-width: 118px;
}

.portal .js-lang {
  margin-bottom: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 7px;
  padding: 10px 14px;
  background: var(--brand);
  color: #fff;
  cursor: pointer;
  text-decoration: none;
  font-weight: 600;
}

.btn:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 3px solid #f5cf45;
  outline-offset: 2px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-ghost {
  background: transparent;
  color: var(--brand-dark);
  border: 1px solid var(--line);
}

.btn-danger {
  background: var(--danger);
}

.btn-block {
  width: 100%;
}

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

input,
select,
textarea {
  max-width: 100%;
  min-width: 0;
}

.product-photo {
  display: block;
  width: 100%;
  max-width: 260px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center;
  border-radius: 10px;
  margin-bottom: 8px;
  background: #edf3ef;
  overflow: hidden;
}

.product-image-button {
  display: block;
  width: 100%;
  max-width: 260px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}

.product-image-button .product-photo {
  max-width: none;
}

.product-photo-placeholder {
  display: grid;
  place-items: center;
  color: var(--muted);
  background: #edf3ef;
}

.btn[aria-disabled="true"] {
  pointer-events: none;
  opacity: 0.5;
}

.notice p {
  margin: 0 0 10px;
}

.image-lightbox {
  width: min(92vw, 900px);
  border: 0;
  padding: 0;
  background: transparent;
}

.image-lightbox::backdrop {
  background: rgb(0 0 0 / 72%);
}

.image-lightbox img {
  display: block;
  max-width: 100%;
  max-height: 85vh;
  margin: auto;
  object-fit: contain;
}

.image-lightbox button {
  position: absolute;
  top: 8px;
  right: 8px;
}

.image-preview {
  max-width: min(220px, 100%);
  margin-top: 10px;
  min-width: 0;
}

.image-preview img,
.image-preview .product-photo {
  max-width: 100%;
}

.product-admin-card {
  min-width: 0;
  overflow-wrap: anywhere;
}

progress {
  width: 100%;
  height: 10px;
  margin-top: 10px;
  accent-color: var(--brand);
}

.grid {
  display: grid;
  gap: 12px;
}

.search {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  margin-bottom: 14px;
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 2px 8px;
  border-radius: 999px;
  background: #ecfdf5;
  color: var(--ok);
}

.badge.off {
  background: #fef2f2;
  color: var(--danger);
}

.badge.sold {
  background: #f5f5f4;
  color: var(--muted);
}

.status {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 8px;
}

.status.pending { background: #fff7ed; color: var(--warn); }
.status.accepted { background: #eff6ff; color: #1d4ed8; }
.status.preparing { background: #fef3c7; color: #92400e; }
.status.ready { background: #e0f2fe; color: var(--ready); }
.status.completed { background: #ecfdf5; color: var(--ok); }
.status.cancelled,
.status.rejected { background: #fef2f2; color: var(--danger); }

.cart-fab {
  position: relative;
  text-decoration: none;
  font-size: 1.2rem;
}

.bottom-nav a {
  position: relative;
}

.cart-count {
  position: absolute;
  top: -6px;
  right: -8px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  line-height: 18px;
  text-align: center;
}

.qty {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qty input[type="number"] {
  width: 72px;
  text-align: center;
  font-size: 1.15rem;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.bell {
  position: relative;
  text-decoration: none;
  font-size: 1.2rem;
}

.name-row {
  display: flex;
  gap: 8px;
  align-items: end;
}

.name-row input,
.name-row select {
  flex: 1;
}

.check-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.check-row label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.order-timeline {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  padding: 12px 0;
  list-style: none;
  font-size: 0.75rem;
  color: var(--muted);
}

.order-timeline li {
  border-top: 3px solid var(--line);
  padding-top: 6px;
}

.order-timeline li.done {
  border-color: var(--brand);
  color: var(--brand-dark);
}

.qty button {
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
  cursor: pointer;
}

.tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 8px;
}

.tabs button {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 6px 12px;
  white-space: nowrap;
  cursor: pointer;
}

.tabs button.on,
.tabs button[aria-pressed="true"] {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
  font-weight: 700;
}

.tabs button:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.login-form label {
  display: block;
  font-size: 0.85rem;
  margin: 10px 0 4px;
}

.login-form input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.login-form .password-show {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 7px 0 2px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

.login-form .password-show input {
  width: 20px;
  min-height: 20px;
  margin: 0;
  padding: 0;
}

.easy-form label {
  font-size: 1.05rem;
  font-weight: 700;
  margin-top: 16px;
}

.easy-form input,
.easy-form textarea,
.easy-form select {
  width: 100%;
  font-size: 1.15rem;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.easy-time-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.easy-chips,
.easy-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.easy-chip,
.easy-icon {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 1rem;
  cursor: pointer;
  min-height: 44px;
}

.easy-icon {
  font-size: 1.6rem;
  min-width: 52px;
}

.easy-icon.on,
.easy-chip:active {
  border-color: var(--brand);
  background: #ecfdf5;
  font-weight: 700;
}

.hint {
  font-size: 0.82rem;
  color: var(--muted);
  background: #fff;
  border: 1px dashed var(--line);
  border-radius: 10px;
  padding: 10px;
  margin-top: 16px;
}

.muted {
  color: var(--muted);
  font-size: 0.88rem;
}

.empty {
  text-align: center;
  color: var(--muted);
  padding: 32px 8px;
}

.notice {
  border-left: 4px solid var(--brand);
  background: #eaf4ee;
  padding: 10px 12px;
}

.notice.error {
  border-color: var(--danger);
  background: #fff1f2;
}

[aria-busy="true"] {
  min-height: 96px;
  opacity: 0.65;
}

.skeleton {
  min-height: 88px;
  background: linear-gradient(90deg, #edf2ef 25%, #f8faf9 50%, #edf2ef 75%);
  background-size: 200% 100%;
  animation: skeleton 1.2s linear infinite;
}

@keyframes skeleton {
  to { background-position: -200% 0; }
}

.toast-host {
  position: fixed;
  z-index: 100;
  right: 16px;
  bottom: 88px;
  display: grid;
  gap: 8px;
  max-width: min(360px, calc(100vw - 32px));
}

.toast {
  translate: 0 12px;
  opacity: 0;
  padding: 11px 14px;
  border-left: 4px solid var(--brand);
  background: #fff;
  box-shadow: 0 8px 24px rgb(0 0 0 / 14%);
  transition: 180ms ease;
}

.toast.error {
  border-color: var(--danger);
}

.toast.show {
  translate: 0;
  opacity: 1;
}

@media (max-width: 360px) {
  .name-row,
  .row-actions {
    align-items: stretch;
  }

  .name-row {
    flex-direction: column;
  }

  .row-actions > .btn {
    flex: 1 1 100%;
  }
}
