/* =========================
   OD1 SHOP (SCOPED)
   Uses theme.css tokens:
   --page, --surface, --surface-2, --surface-3,
   --border, --border-2,
   --text, --muted, --muted-2,
   --on-surface, --on-surface-muted (optional but recommended),
   --ring, --accent-soft,
   --shadow-sm, --shadow-md, --shadow-lg,
   --radius-md, --radius-lg,
   --font-sans,
   --btn-primary-bg, --btn-primary-bg-hover, --btn-primary-text, --btn-primary-border, --btn-primary-shadow
========================= */

/* =========================
   ROOT WRAPPER
========================= */
.od1-shop[data-shop]{
  background: transparent;
  color: var(--text);
  min-height: 100%;
  font-family: var(--font-sans, Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif);
}

.od1-shop[data-shop] a{ color: inherit; text-decoration: none; }
.od1-shop[data-shop] img,
.od1-shop[data-shop] video{ display:block; max-width:100%; }

/* =========================
   BUTTONS
========================= */
.od1-shop[data-shop] .btn{
  appearance:none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--on-surface, var(--text));
  padding: 12px 16px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  cursor:pointer;
  transition: transform .15s ease, background .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.od1-shop[data-shop] .btn:active{ transform: translateY(1px); }
.od1-shop[data-shop] .btn:hover{
  background: var(--surface-2);
  border-color: var(--border-2);
}
.od1-shop[data-shop] .btn:focus-visible{
  outline: none;
  box-shadow: 0 0 0 3px var(--ring);
}

/* Primary CTA */
.od1-shop[data-shop] .btn-primary{
  background: var(--btn-primary-bg, var(--surface-3));
  color: var(--btn-primary-text, var(--on-surface, var(--text)));
  border-color: var(--btn-primary-border, var(--border-2));
  box-shadow: var(--btn-primary-shadow, var(--shadow-sm));
}
.od1-shop[data-shop] .btn-primary:hover{
  background: var(--btn-primary-bg-hover, var(--btn-primary-bg, var(--surface-2)));
}
.od1-shop[data-shop] .btn-primary:focus-visible{
  box-shadow: 0 0 0 3px var(--ring), var(--btn-primary-shadow, var(--shadow-sm));
}

/* =========================
   SECTIONS / FILTERS
========================= */
.od1-shop[data-shop] .section-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap: 10px;
  margin: 2px 0 12px;
}
.od1-shop[data-shop] .section-title{
  margin:0;
  font-size: 20px;
  letter-spacing: -0.01em;
}
.od1-shop[data-shop] .section-note{
  margin:0;
  color: var(--muted-2);
  font-size: 13px;
}

.od1-shop[data-shop] .filters{
  display:flex;
  gap: 8px;
  overflow:auto;
  padding: 6px 2px 12px;
  scrollbar-width: none;
}
.od1-shop[data-shop] .filters::-webkit-scrollbar{ display:none; }

.od1-shop[data-shop] .chip{
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--on-surface-muted, var(--muted));
  padding: 10px 12px;
  border-radius: 999px;
  font-size: 13px;
  cursor:pointer;
  white-space: nowrap;
  transition: transform .15s ease, background .15s ease, border-color .15s ease, color .15s ease;
}
.od1-shop[data-shop] .chip:hover{
  transform: translateY(-1px);
  background: var(--surface-2);
  border-color: var(--border-2);
  color: var(--on-surface, var(--text));
}
.od1-shop[data-shop] .chip.is-active{
  background: var(--accent-soft);
  border-color: var(--ring);
  color: var(--text, var(--text));
}

/* =========================
   GRID / CARDS
========================= */
.od1-shop[data-shop] .grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.od1-shop[data-shop] .card{
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius-md);
  overflow:hidden;
  cursor:pointer;
  outline:none;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, box-shadow .18s ease;
  box-shadow: var(--shadow-sm);
  color: var(--on-surface, var(--text));
}
.od1-shop[data-shop] .card:hover{
  transform: translateY(-2px);
  border-color: var(--border-2);
  background: var(--surface-2);
  box-shadow: var(--shadow-md);
}
.od1-shop[data-shop] .card:focus-visible{
  outline: none;
  box-shadow: 0 0 0 3px var(--ring), var(--shadow-md);
}

.od1-shop[data-shop] .card-media{
  aspect-ratio: 4/5;
  background: transparent;
}
.od1-shop[data-shop] .card-media img{
  width:100%;
  height:100%;
  object-fit: cover;
}

.od1-shop[data-shop] .card-body{
  padding: 10px 10px 12px;
  color: inherit;
}
.od1-shop[data-shop] .card-row{
  display:flex;
  justify-content:space-between;
  gap: 10px;
  align-items:baseline;
}
.od1-shop[data-shop] .card-title{
  margin:0;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: inherit;
}
.od1-shop[data-shop] .card-price{
  font-size: 13px;
  color: var(--on-surface-muted, var(--muted));
}
.od1-shop[data-shop] .card-meta{
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--on-surface-muted, var(--muted-2));
}

/* Quick action buttons inside cards */
.od1-shop[data-shop] .card button[data-action]{
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--on-surface, var(--text));
  padding: 10px 12px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 13px;
  cursor:pointer;
  transition: background .15s ease, border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.od1-shop[data-shop] .card button[data-action]:hover{
  background: var(--surface-2);
  border-color: var(--border-2);
  transform: translateY(-1px);
}
.od1-shop[data-shop] .card button[data-action]:focus-visible{
  outline:none;
  box-shadow: 0 0 0 3px var(--ring);
}

/* =========================
   HEADER CART
========================= */
.od1-shop[data-shop] .shop-topbar{
  display:flex;
  justify-content:flex-end;
  margin: 0 0 1rem;
}

.od1-shop[data-shop] .shop-header-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  flex-wrap: wrap;
  row-gap: .5rem;
  margin: 0 0 1rem;
}
.od1-shop[data-shop] .shop-actions{
  display:flex;
  align-items:center;
  gap:.75rem;
  margin-left: auto;
}

.od1-shop[data-shop] .filters{
  flex: 1 1 auto;
  align-items: center;
}

.od1-shop[data-shop] .cart-btn{
  position:relative;
  border:0;
  background:transparent;
  cursor:pointer;
  font-size:1.25rem;
  color: var(--text);
}

.od1-shop[data-shop] .cart-badge{
  position:absolute;
  top:-.35rem;
  right:-.6rem;
  min-width:1.1rem;
  height:1.1rem;
  padding:0 .25rem;
  border-radius:999px;
  display:grid;
  place-items:center;
  font-size:.75rem;
  font-weight:800;
  background: var(--btn-primary-bg, var(--surface-3));
  color: var(--btn-primary-text, var(--on-surface, var(--text)));
  border: 1px solid var(--btn-primary-border, var(--border-2));
}
.od1-shop[data-shop] .cart-badge.is-zero{ display:none; }

/* =========================
   CAROUSEL (Dots)
========================= */
.od1-shop[data-shop] .cc-dots{
  position:absolute;
  left:0;
  right:0;
  bottom:.35rem;
  display:flex;
  justify-content:center;
  gap:.35rem;
}
.od1-shop[data-shop] .cc-dot{
  width:.5rem;
  height:.5rem;
  border-radius:999px;
  border: 1px solid var(--ring);
  cursor:pointer;
  background: var(--accent-soft);
}
.od1-shop[data-shop] .cc-dot.is-active{
  background: var(--page);
  border-color: var(--ring);
}

/* =========================
   MODAL (Order)
========================= */
.od1-shop[data-shop] .orderModal::backdrop{
  /* Backdrop doesn’t need to be theme-tokened */
  background: rgba(0,0,0,.65);
}

.od1-shop[data-shop] .orderModal{
  border: 0;
  padding: 0;
  background: transparent;
  position: fixed;
  width: min(920px, calc(100% - 28px));
  max-height: calc(100vh - 40px);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  overflow: auto;
}

@media (max-width: 760px){
  .od1-shop[data-shop] .orderModal{
    top: auto;
    bottom: 14px;
    left: 50%;
    width: calc(100% - 20px);
    max-height: none;
    transform: translate(-50%, 0);
    overflow: visible;
  }

  .od1-shop[data-shop] .orderModal .modal-inner{
    border-radius: 18px;
    max-height: 90vh;
    overflow: auto;
  }
}

@media (min-width: 761px){
  .od1-shop[data-shop] .orderModal{
    bottom: auto;
    width: min(920px, 90vw);
    max-height: calc(100vh - 80px);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
  }
}

/* If you later add --modal-bg in theme.css, this will use it.
   Otherwise it falls back to --surface-3 (more opaque than --surface). */
.od1-shop[data-shop] .orderModal .modal-inner{
  background: var(--modal-bg, var(--panel-strong));
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
  color: var(--on-surface, var(--text));
}

/* Header */
.od1-shop[data-shop] .orderModal .modal-header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
}
.od1-shop[data-shop] .orderModal .modal-title{
  margin:0;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -.01em;
}
.od1-shop[data-shop] .orderModal [data-modal-item-line]{
  margin-top: 6px;
  font-size: 12px;
  color: var(--on-surface-muted, var(--muted));
}

.od1-shop[data-shop] .orderModal .icon-btn{
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--on-surface, var(--text));
  cursor: pointer;
}
.od1-shop[data-shop] .orderModal .icon-btn:hover{
  background: var(--surface-2);
  border-color: var(--border-2);
}

/* Content layout */
.od1-shop[data-shop] .orderModal .modal-content{
  display:grid;
  grid-template-columns: 320px 1fr;
  gap: 18px;
  padding: 18px 20px;
}
@media (max-width: 760px){
  .od1-shop[data-shop] .orderModal .modal-content{
    grid-template-columns: 1fr;
  }
}

.od1-shop[data-shop] .orderModal .modal-left{
  display:grid;
  grid-template-rows: auto 1fr;
  gap: 12px;
  height: 100%;
  min-height: 0;
}

/* Media */
.od1-shop[data-shop] .orderModal .modal-media{
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  aspect-ratio: 1/1;
  box-shadow: var(--shadow-sm);
}
.od1-shop[data-shop] .orderModal .modal-media img{
  width:100%;
  height:100%;
  object-fit: cover;
}

.od1-shop[data-shop] .orderModal .modalDesc{
  margin: 0;
  padding: 10px 12px;
  background: var(--field-bg);
  border: 1px solid var(--field-border);
  border-radius: 14px;
  font-size: 12px;
  color: var(--on-surface-muted, var(--muted));
  line-height: 1.45;
  height: 100%;
  overflow: auto;
  min-height: 120px;
}

/* Dots */
.od1-shop[data-shop] .orderModal .modalDots{
  position:absolute;
  left:0; right:0;
  bottom: 10px;
  display:flex;
  justify-content:center;
  gap: 6px;
}
/* .od1-shop[data-shop] .orderModal .modalDots .cc-dot{
  width: 7px; height: 7px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--accent-soft);
}
.od1-shop[data-shop] .orderModal .modalDots .cc-dot.is-active{
  background: var(--surface-3);
  border-color: var(--border-2);
} */

/* Form */
.od1-shop[data-shop] .orderModal .modal-form{
  display:flex;
  flex-direction:column;
  gap: 18px;
}

.od1-shop[data-shop] .orderModal .field label{
  display:block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .02em;
  color: var(--on-surface-muted, var(--muted));
  margin-bottom: 7px;
}

.od1-shop[data-shop] .orderModal .field-grid{
  display:grid;
  grid-template-columns: 1fr 120px;
  gap: 16px;
}

.od1-shop[data-shop] .orderModal [data-attrs-container] .field {
  margin-bottom: 10px;
}

.od1-shop[data-shop] .orderModal input,
.od1-shop[data-shop] .orderModal select,
.od1-shop[data-shop] .orderModal textarea{
  width:100%;
  min-height: 44px;
  padding: 12px 12px;

  border-radius: 14px;
  border: 1px solid var(--field-border);
  background: var(--field-bg);
  color: var(--on-surface, var(--text));
  outline: none;
}

.od1-shop[data-shop] .orderModal textarea{
  min-height: 92px;
  resize: vertical;
}

.od1-shop[data-shop] .orderModal input:focus,
.od1-shop[data-shop] .orderModal select:focus,
.od1-shop[data-shop] .orderModal textarea:focus{
  background: var(--field-bg-focus);
  border-color: var(--field-border-focus);
  box-shadow: 0 0 0 3px var(--ring);
}

/* Footer actions */
.od1-shop[data-shop] .orderModal .modal-actions{
  display:flex;
  justify-content:flex-end;
  gap: 10px;
  padding: 14px 18px 16px;
  border-top: 1px solid var(--border);
}

/* Buttons inside modal */
.od1-shop[data-shop] .orderModal .btn{
  border-radius: 999px;
  padding: 12px 16px;
  font-weight: 800;
}

/* =========================
   DESKTOP POLISH
========================= */
@media (min-width: 820px){
  .od1-shop[data-shop] .grid{
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
  }
}
