/* =========================================================================
   G-Mart skin: gm-row.css (from gm-row.scss) -- compact list row for every
   inner list page (Current Issues, Back Issues, weekly release date, Want
   List, Sale pages, Variants, Trade Paperbacks, Clearance, Key Issues).

   Load after gm-base.css and the theme file:
     g-mart.css -> gm-base.css -> gm-theme-frontpage.css | gm-theme-comicpage.css -> gm-row.css

   From the Claude Design handoff "Compact list row" (gmart-compact-row).
   Local changes from the handoff are marked "LOCAL:".

   Reuses from gm-base.css: tokens, .gm-icon, .gm-price, .gm-price--out,
   .gm-chip--*, .gm-tag, .gm-tag--ratio, .gm-tag--soon.

   SHARED vs THEME-SPECIFIC
   - Everything in sections 2-9 is shared structure. Do not fork it per theme.
   - Section 1 lists the row tokens. The values here are the FRONTPAGE
     (newspaper) choices. The comicpage theme overrides only these tokens
     (in gm-theme-comicpage.scss, as .gm-body.gm-theme-comic).

   LAYOUT
   - Phone (<=479): two lines. Line 1 = title (wraps). Line 2 = price,
     BACK ISSUES. Cart + heart sit at the right, 44x44 each, for the thumb.
   - Tablet (480-999): classic order [cart][heart] [price column] [title];
     BACK ISSUES sits under the title so the title keeps its width.
   - Desktop (>=1000): one line [cart][heart] [price column] [title] [BACK ISSUES].
     The fixed price column is the scanning edge; returning members keep
     the classic left-to-right order they know.

   JS COMPATIBILITY (no change to how ids are found)
   - The legacy script sets .display-none / .display-inline on the four
     icon elements and on description_N. Every one of those elements is a
     child of a flex or grid container here, so the browser "blockifies"
     display:inline automatically: .display-inline needs no replacement and
     .display-none still hides. No new class is needed.
   ========================================================================= */
/* ---------- 1. Row tokens (theme files override these) ------------------ */
.gm-body {
  --gm-row-sep: 1px solid var(--gm-rule-soft);
  /* hairline between rows */
  --gm-row-hover: var(--gm-faint);
  /* desktop pointer hover only */
  --gm-row-mark: #fff27a;
  /* bookmarked-title highlighter */
  --gm-row-note-line: var(--gm-blue);
  /* release-note left bar */
  --gm-row-cat-font: var(--gm-font-display);
  --gm-row-cat-transform: var(--gm-display-transform);
  --gm-row-cat-rule: 3px double var(--gm-ink);
  /* FRONTPAGE: newspaper double rule */
  --gm-row-cat-bg: transparent;
  /* comicpage: a colored band */
  --gm-row-cat-color: var(--gm-ink);
  --gm-row-pub-bg: var(--gm-faint);
  --gm-row-pub-color: var(--gm-text-2);
  --gm-row-price-col: 132px;
  /* 480-999: fixed price column */
  --gm-row-price-col-lg: 144px;
  /* >=1000: [chip][price][tag space] */
  --gm-row-tag-slot: 62px;
  /* >=1000: fixed tag space after the price; must fit "SAVE 20%" (the widest usual tag) */
  --gm-row-cover: 150px;
  /* expanded cover, phone */
  --gm-row-cover-lg: 150px; }

/* LOCAL: handoff has 200px; the medium cover the server sends is 150px wide */
/* ---------- 2. Group headings ------------------------------------------- */
.gm-rowcat {
  /* category, H3: "Graphic Novels" */
  margin: 28px 0 0;
  padding: 10px 0 6px;
  border-top: var(--gm-row-cat-rule);
  background: var(--gm-row-cat-bg);
  color: var(--gm-row-cat-color);
  font-family: var(--gm-row-cat-font);
  text-transform: var(--gm-row-cat-transform);
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2; }

.gm-rowpub {
  /* publisher / subcategory line */
  margin: 14px 0 0;
  padding: 7px 10px;
  background: var(--gm-row-pub-bg);
  border-bottom: 1px solid var(--gm-rule);
  color: var(--gm-row-pub-color);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  line-height: 1.3; }

.gm-rowcat + .gm-rowpub {
  margin-top: 4px; }

/* ---------- 3. List and row grid ---------------------------------------- */
.gm-rowlist {
  list-style: none;
  margin: 0;
  padding: 0; }

.gm-row {
  display: grid;
  /* phone: two lines, actions on the right */
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "title  actions" "meta   actions" "note   note" "panel  panel";
  column-gap: 4px;
  align-items: center;
  padding: 4px 0 4px 10px;
  border-bottom: var(--gm-row-sep);
  font-size: 15px;
  line-height: 1.35; }

.gm-row__actions {
  grid-area: actions; }

.gm-row__title {
  grid-area: title; }

.gm-row__meta {
  grid-area: meta; }

.gm-row__note {
  grid-area: note; }

.gm-row__panel {
  grid-area: panel; }

/* ---------- 4. Quick actions (cart, heart) ------------------------------ */
.gm-row__actions {
  display: flex;
  justify-content: flex-end;
  /* LOCAL: a lone button (cart OR heart) hugs the right edge on phone */
  align-self: center; }

/* One 44px button per toggle. The two legacy state elements sit inside,
   only one visible. The button is flex, so .display-inline is blockified. */
.gm-row__qa {
  width: var(--gm-tap);
  height: var(--gm-tap);
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--gm-text-2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font: inherit; }

.gm-row__qa-state .gm-icon {
  width: 22px;
  height: 22px; }

.gm-row__qa--cart .gm-row__qa-state--full {
  color: var(--gm-blue); }

.gm-row__qa--cart .gm-row__qa-state--full .gm-icon {
  fill: currentColor; }

.gm-row__qa--heart .gm-row__qa-state--full {
  color: var(--gm-red-logo); }

.gm-row__qa--heart .gm-row__qa-state--full .gm-icon {
  fill: currentColor; }

.gm-row__qa:focus-visible,
.gm-row__title:focus-visible,
.gm-row__price a:focus-visible,
.gm-row__more:focus-visible,
.gm-row__panel a:focus-visible {
  outline: 2px solid var(--gm-blue);
  outline-offset: 2px; }

@media (hover: hover) {
  .gm-row__qa:hover {
    background: var(--gm-faint); } }
/* ---------- 5. Title (disclosure button) -------------------------------- */
.gm-row__title {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  min-height: 32px;
  min-width: 0;
  margin: 0;
  padding: 5px 0 1px;
  border: 0;
  background: transparent;
  color: var(--gm-ink);
  font: inherit;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  overflow-wrap: anywhere; }

.gm-row__title-text {
  min-width: 0; }

/* inline span: carries the bookmark highlighter */
.gm-row__title .gm-tag {
  white-space: normal; }

/* a long ratio tag wraps, never widens */
.gm-row__arrow {
  flex: none;
  width: 12px;
  height: 12px;
  margin-top: 4px;
  color: var(--gm-text-3);
  transform: rotate(-90deg);
  /* closed: points right */
  transition: transform .15s ease; }

.gm-row__title[aria-expanded="true"] .gm-row__arrow {
  transform: none; }

/* open: points down */
@media (hover: hover) {
  .gm-row__title:hover .gm-row__title-text {
    color: var(--gm-blue); } }
/* bookmarked / highlighted title: a highlighter stroke, not a full fill */
.gm-row--mark .gm-row__name {
  background: linear-gradient(transparent 55%, var(--gm-row-mark) 55%);
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone; }

/* ---------- 6. Price + BACK ISSUES -------------------------------------- */
.gm-row__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  margin-left: 0;
  padding: 0 0 5px 18px;
  /* phone: lines up under the title text */
  min-width: 0; }

.gm-row__price {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  font-size: 14px; }

.gm-row__price a {
  color: var(--gm-ink);
  text-decoration: none; }

@media (hover: hover) {
  .gm-row__price a:hover {
    color: var(--gm-blue); } }
.gm-row__cond {
  /* condition, e.g. "NM" */
  font-weight: 400;
  color: var(--gm-text-3);
  font-size: 13px; }

/* sale tag: classic yellow sticker with red text. Not the RYGS red, which means almost sold out. */
.gm-row .gm-tag--sale {
  background: var(--gm-yellow);
  color: #b00016; }

/* the price amount: monospace, as in classic, so amounts line up for comparison */
.gm-row__amt {
  font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
  font-variant-numeric: tabular-nums; }

/* LOCAL: tags after the amount; one wrapper so SALE + SOON (preview) stay together */
.gm-row__tags {
  display: inline-flex;
  align-items: center;
  gap: 3px; }

/* LOCAL: sold out = just the faint words SOLD OUT (no box; right aligned with the price on desktop): more an
   absence of content than a label (classic showed asterisks instead of a price).
   It sits inside the price link, after the price-tier chip. */
.gm-row__price .gm-price--out {
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--gm-text-3);
  opacity: .5;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .04em;
  text-align: left; }

/* preview / coming soon: price shown, not linked, muted */
.gm-row--soon .gm-row__price .gm-price {
  color: var(--gm-text-3);
  font-weight: 600; }

.gm-row__more {
  /* BACK ISSUES */
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--gm-blue);
  text-decoration: none;
  white-space: nowrap; }

@media (hover: hover) {
  .gm-row__more:hover {
    text-decoration: underline; } }
/* ---------- 7. Release-highlight note ----------------------------------- */
.gm-row__note {
  margin: 0 10px 8px 18px;
  padding: 2px 0 2px 8px;
  border-left: 2px solid var(--gm-row-note-line);
  color: var(--gm-text-2);
  font-size: 13px;
  font-style: italic; }

/* ---------- 8. Expanded details panel (description_N) ------------------- */
/* The panel is a grid item, so the script's .display-inline is blockified.
   Inner layout lives on .gm-row__panel-in so the script never touches it. */
.gm-row__panel {
  padding: 4px 10px 14px 18px; }

.gm-row__panel-in {
  display: grid;
  grid-template-columns: var(--gm-row-cover) minmax(0, 1fr);
  gap: 12px 14px;
  align-items: start; }

.gm-row__panel-in--nocover {
  /* LOCAL: a comic with no cover image */
  grid-template-columns: minmax(0, 1fr); }

.gm-row__cover {
  display: block;
  line-height: 0; }

.gm-row__cover img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  /* reserves space before the lazy load (LOCAL: the page sets the real ratio inline, so covers are not cropped) */
  object-fit: cover;
  background: var(--gm-faint);
  border: 1px solid var(--gm-rule); }

.gm-row__info {
  min-width: 0;
  font-size: 14px;
  color: var(--gm-text-2);
  overflow-wrap: anywhere; }

.gm-row__info-title {
  display: block;
  margin-bottom: 6px;
  color: var(--gm-ink);
  font-weight: 700;
  text-decoration: none; }

@media (hover: hover) {
  .gm-row__info-title:hover {
    color: var(--gm-blue); } }
.gm-row__info p {
  margin: 0 0 8px; }

.gm-row__date {
  color: var(--gm-text-3);
  font-size: 13px; }

.gm-row__notes {
  font-size: 13px; }

/* ---------- 9. Tablet / desktop: classic order -------------------------- */
/* 480-999: [cart][heart] [price] [title]; BACK ISSUES goes under the title */
@media (min-width: 480px) {
  .gm-row {
    grid-template-columns: auto var(--gm-row-price-col) minmax(0, 1fr);
    grid-template-areas: "actions price title" "actions price more" ".       .     note" "panel   panel panel";
    column-gap: 10px;
    align-items: start;
    /* first lines share one baseline */
    padding: 0 10px 0 2px; }

  .gm-row__actions {
    align-self: start;
    justify-content: flex-start;
    min-width: calc(var(--gm-tap) * 2); }

  /* LOCAL: most rows have only ONE of cart/heart; keep the price column aligned */
  .gm-row__title {
    padding: 11px 0 9px; }

  /* meta's children join the row grid directly */
  .gm-row__meta {
    display: contents; }

  .gm-row__price {
    grid-area: price;
    align-self: start;
    justify-self: start;
    padding: 12px 0 8px; }

  .gm-row__more {
    grid-area: more;
    justify-self: start;
    min-height: 0;
    margin-top: -6px;
    padding: 0 0 8px 18px; }

  .gm-row__note {
    margin: 0 0 8px; }

  .gm-row__panel {
    padding: 6px 10px 16px calc(var(--gm-tap) * 2 + 10px); }

  .gm-row__panel-in {
    grid-template-columns: var(--gm-row-cover-lg) minmax(0, 42em); }

  .gm-row__panel-in--nocover {
    grid-template-columns: minmax(0, 42em); }

  /* rows with no quick actions (static pages) keep the same columns,
     so the price column still lines up with rows above and below */
  .gm-row__actions--none {
    width: calc(var(--gm-tap) * 2); } }
/* >=1000: one line; BACK ISSUES gets its own right-hand column */
@media (min-width: 1000px) {
  .gm-row {
    grid-template-columns: auto var(--gm-row-price-col-lg) minmax(0, 1fr) auto;
    grid-template-areas: "actions price title more" ".       .     note  note" "panel   panel panel panel"; }

  .gm-row__more {
    margin-top: 0;
    padding: 13px 0 0; } }
/* >=1000: compact, one line about 25px tall, as in classic.
   The price column is [chip][price, right-aligned][tag space]. */
@media (min-width: 1000px) {
  .gm-body {
    --gm-row-tap-d: 24px;
    /* button height: sets the row height */
    --gm-row-tap-w: 26px; }

  /* button width: free to be wider */
  .gm-row {
    align-items: center;
    padding: 0 10px 0 2px;
    column-gap: 6px;
    font-size: 14px;
    line-height: 1.25; }

  .gm-row__actions {
    align-self: center;
    gap: 0;
    justify-content: flex-end;
    /* LOCAL: a lone cart or heart sits right next to the price chip */
    min-width: calc(var(--gm-row-tap-w) * 2); }

  /* LOCAL: the 44px min-width above would keep a lone button's column wide */
  .gm-row__qa {
    width: var(--gm-row-tap-w);
    height: var(--gm-row-tap-d);
    border-radius: 4px; }

  .gm-row__qa-state .gm-icon {
    width: 20px;
    height: 20px; }

  .gm-row__title {
    min-height: 0;
    padding: 2px 0;
    gap: 3px; }

  .gm-row__arrow {
    width: 10px;
    height: 10px;
    margin-top: 3px; }

  .gm-row__price {
    display: block;
    align-self: center;
    justify-self: stretch;
    padding: 0; }

  .gm-row__price .gm-price {
    display: grid;
    grid-template-columns: 14px 1fr minmax(var(--gm-row-tag-slot), auto);
    align-items: center;
    column-gap: 4px;
    width: 100%;
    white-space: nowrap;
    font-size: 13px; }

  .gm-row__price .gm-chip {
    grid-column: 1; }

  .gm-row__price .gm-row__amt {
    grid-column: 2;
    justify-self: end; }

  .gm-row__price .gm-row__tags,
  .gm-row__price .gm-tag {
    grid-column: 3;
    justify-self: start; }

  .gm-row__price .gm-price--out {
    grid-column: 2;
    justify-self: end; }

  /* right edge = the price's right edge */
  .gm-row .gm-tag {
    font-size: 10px;
    line-height: 14px;
    padding: 0 3px;
    letter-spacing: 0; }

  .gm-row__price .gm-price--out {
    font-size: 9px;
    line-height: 14px; }

  .gm-row__more {
    align-self: center;
    padding: 0;
    min-height: 0;
    font-size: 11px; }

  .gm-row__note {
    margin: 0 0 3px;
    padding: 0 0 0 6px;
    font-size: 12px;
    line-height: 1.3; }

  .gm-row__panel {
    padding: 4px 10px 10px calc(var(--gm-row-tap-w) * 2 + 6px); }

  .gm-row__actions--none {
    width: calc(var(--gm-row-tap-w) * 2); }

  .gm-rowcat {
    margin-top: 16px;
    padding: 6px 0 2px;
    font-size: 19px; }

  .gm-rowpub {
    margin-top: 6px;
    padding: 2px 8px;
    font-size: 11px; } }
@media (min-width: 480px) and (hover: hover) {
  .gm-row:hover {
    background: var(--gm-row-hover); } }
/* phone: a row without quick actions has no right column */
@media (max-width: 479px) {
  .gm-row__actions--none {
    display: none; }

  .gm-row:has(.gm-row__actions--none) {
    padding-right: 10px; } }
/* reduced motion: the arrow snaps */
@media (prefers-reduced-motion: reduce) {
  .gm-row__arrow {
    transition: none; } }

/*# sourceMappingURL=gm-row.css.map */
