/* campuspc — design language ported from the Verada family (ruigo /
 * jweather / uktrends). Same Inter + Noto Sans JP typography, same card
 * vocabulary. Mouse Computer red primary; purple accent retained for
 * Verada-family continuity.
 *
 * v0.3 layout: two-column page. Left sidebar = sticky university list.
 * Right pane = product recommendations (or a "pick a school" prompt).
 * Hero stacks the Mouse Computer logo directly above the Verada logo.
 */

:root {
  /* Brand — Mouse Computer red as primary */
  --c-primary:        #E60012;
  --c-primary-hover:  #C8000F;
  --c-primary-soft:   #FCE7E9;
  --c-accent:         #5B3FBB;
  --c-accent-hover:   #4A30A2;
  --c-accent-soft:    #ECE5FF;

  /* Neutrals — warm cream, family-consistent */
  --c-bg:             #F7F5F0;
  --c-surface:        #FFFFFF;
  --c-surface-2:      #FAF8F4;
  --c-border:         #E8E3DA;
  --c-border-strong:  #D7D0C3;
  --c-text:           #1A1F2E;
  --c-text-muted:     #6B7180;
  --c-text-subtle:    #9AA0AC;

  /* Status / accent tags */
  --c-tag-text:       #E60012;
  --c-tag-bg:         rgba(230, 0, 18, 0.07);
  --c-success:        #2BB673;
  --c-warning:        #E0902B;
  --c-error:          #D83A3A;
  --c-error-bg:       rgba(216, 58, 58, 0.06);

  /* University-type accents */
  --c-type-national:  #2B5BD8;
  --c-type-private:   #8E94A6;
  --c-type-public:    #2BB673;

  /* Typography */
  --ff-sans: 'Inter', 'Noto Sans JP', -apple-system, BlinkMacSystemFont,
             'Segoe UI', Roboto, sans-serif;
  --ff-jp:   'Noto Sans JP', 'Inter', -apple-system, sans-serif;

  /* Geometry */
  --r-sm: 6px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;

  /* Layout */
  --sidebar-w: 320px;
  --topnav-h: 60px;

  /* Shadows */
  --sh-card: 0 1px 2px rgba(20, 25, 40, 0.04), 0 4px 12px rgba(20, 25, 40, 0.04);
  --sh-card-hover: 0 4px 12px rgba(20, 25, 40, 0.06), 0 12px 28px rgba(20, 25, 40, 0.08);
  --sh-toast: 0 8px 24px rgba(20, 25, 40, 0.18);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--ff-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Contain horizontal overflow from .why-popover when it extends past
   * the card edge near the viewport boundary. position:sticky still
   * works because overflow-x doesn't affect sticky positioning. */
  overflow-x: hidden;
}

[lang="ja"] body, [data-lang="ja"] body { font-family: var(--ff-jp); }

button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select { font-family: inherit; }
a { color: inherit; text-decoration: none; }

/* ─── TOP NAV ─────────────────────────────────────────────────────── */

.topnav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 28px;
  background: var(--c-surface);
  border-bottom: 1px solid var(--c-border);
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--topnav-h);
}

.brand { display: flex; align-items: center; gap: 10px; }

.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--c-primary), #FF4F5C);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--ff-sans);
  font-weight: 700;
  font-size: 16px;
}

.brand-name {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.06em;
  color: var(--c-text);
}

.topnav-center {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.topnav-center a {
  font-size: 14px;
  font-weight: 500;
  color: var(--c-text-muted);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.topnav-center a.is-active,
.topnav-center a:hover {
  color: var(--c-text);
  border-bottom-color: var(--c-primary);
}

.topnav-right { display: flex; align-items: center; gap: 10px; }

.cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  font-size: 13px;
  color: var(--c-text);
  transition: background 0.15s ease, border-color 0.15s ease;
}
.cart-btn:hover { background: var(--c-surface-2); border-color: var(--c-border-strong); }
.cart-icon { font-size: 14px; }
.cart-count {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--c-primary);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Language switch — wrapped with a visible "Language" / "言語" label
 * and a primary-red border on the switch. Sized larger than the cart
 * button so it reads as the primary right-side control. Both languages
 * always visible, active one filled red. */
.lang-switch-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.lang-switch-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  white-space: nowrap;
}
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 999px;
  border: 2px solid var(--c-primary);
  background: var(--c-surface);
  box-shadow: 0 0 0 4px rgba(230, 0, 18, 0.08);
}
.lang-option {
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 999px;
  color: var(--c-text-muted);
  transition: background 0.15s ease, color 0.15s ease;
  border: none;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
}
.lang-option:hover { color: var(--c-primary); }
.lang-option[aria-pressed="true"] {
  background: var(--c-primary);
  color: #fff;
}
.lang-option[aria-pressed="true"]:hover {
  background: var(--c-primary-hover);
  color: #fff;
}

/* ─── PARTNER BANNER (white, above the dark Verada hero) ──────────── */

.partner-banner {
  background: var(--c-surface);
  border-bottom: 1px solid var(--c-border);
  padding: 16px 28px;
}
.partner-banner-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.partner-banner-label {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
  font-weight: 600;
}
.partner-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
}
.partner-logo:hover { transform: translateY(-1px); }
.partner-logo-img {
  display: block;
  height: 32px;
  width: auto;
}

/* ─── HERO (dark Verada section, directly below partner banner) ─────
 * Horizontal layout matching the rest of the Verada family:
 * [Verada logo]  [Tagline]                       [Status pill]
 */

.hero {
  background: linear-gradient(135deg, #0D0836 0%, #1A1158 60%, #2B1A6E 100%);
  color: #fff;
  padding: 28px 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.hero-inner {
  max-width: 1340px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
}
.hero-verada {
  display: inline-block;
  flex-shrink: 0;
}
.hero-logo {
  height: 64px;
  width: auto;
  display: block;
  flex-shrink: 0;
}

.hero-tagline {
  flex: 1 1 320px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.hero-tagline strong {
  font-size: 18px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  font-weight: 700;
  color: #fff;
}
.hero-tagline span {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.55;
}
.hero-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 12px;
  font-weight: 500;
  color: #fff;
  white-space: nowrap;
}
.hero-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #2BB673;
  box-shadow: 0 0 0 3px rgba(43, 182, 115, 0.18);
}

/* ─── TWO-COLUMN PAGE LAYOUT ──────────────────────────────────────── */

.page-layout {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
  gap: 24px;
  padding: 24px 28px 64px;
}

/* ─── SIDEBAR (universities) ──────────────────────────────────────── */

.sidebar {
  position: sticky;
  top: calc(var(--topnav-h) + 16px);
  align-self: start;
  max-height: calc(100vh - var(--topnav-h) - 32px);
  display: flex;
  flex-direction: column;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-card);
  overflow: hidden;
}
.sidebar-header {
  padding: 16px 16px 12px;
  border-bottom: 1px solid var(--c-border);
}
.sidebar-header h2 {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 700;
  color: var(--c-text);
}
.sidebar-subtitle {
  margin: 0;
  font-size: 12px;
  color: var(--c-text-muted);
  line-height: 1.5;
}
.sidebar-controls {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--c-border);
  background: var(--c-surface-2);
}

.universities-search-wrap {
  position: relative;
}
.universities-search-wrap .search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--c-text-subtle);
  font-size: 14px;
  pointer-events: none;
}
#university-search {
  width: 100%;
  padding: 7px 10px 7px 30px;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  font-size: 13px;
  color: var(--c-text);
  transition: border-color 0.15s ease;
}
#university-search:focus {
  outline: none;
  border-color: var(--c-primary);
}

.universities-filter { display: block; }
.region-select {
  width: 100%;
  padding: 7px 28px 7px 10px;
  border-radius: var(--r-md);
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  font-size: 13px;
  color: var(--c-text);
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M3 4.5l3 3 3-3' stroke='%236B7180' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 8px center;
}

.uni-list {
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overflow-x: hidden;
  /* Inset the scrollbar from card edges */
  padding: 6px 8px;
  flex: 1 1 auto;
  scrollbar-width: thin;
  scrollbar-color: var(--c-border-strong) transparent;
}
.uni-list::-webkit-scrollbar { width: 8px; }
.uni-list::-webkit-scrollbar-thumb { background: var(--c-border-strong); border-radius: 4px; }
.uni-list::-webkit-scrollbar-track { background: transparent; }

/* uni-row is a container holding (button + anchor) siblings. The button
 * selects the university for the right pane; the anchor opens that
 * school's official prep page in a new tab. */
.uni-row {
  display: flex;
  align-items: stretch;
  border-radius: var(--r-md);
  background: transparent;
  border: 1px solid transparent;
  position: relative;
  transition: background 0.12s ease, border-color 0.12s ease;
  margin: 1px 0;
}
.uni-row::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 12px;
  bottom: 12px;
  width: 3px;
  border-radius: 2px;
  background: var(--c-border-strong);
  transition: background 0.12s ease;
}
.uni-row[data-type="national"]::before { background: var(--c-type-national); }
.uni-row[data-type="private"]::before  { background: var(--c-type-private); }
.uni-row[data-type="public"]::before   { background: var(--c-type-public); }

.uni-row:hover {
  background: var(--c-surface-2);
  border-color: var(--c-border);
}
.uni-row.is-selected {
  background: var(--c-primary-soft);
  border-color: var(--c-primary);
}
.uni-row.is-selected::before { background: var(--c-primary); }

.uni-row-button {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 6px 10px 14px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  border-radius: var(--r-md) 0 0 var(--r-md);
}
.uni-row-button:focus-visible {
  outline: 2px solid var(--c-primary);
  outline-offset: -2px;
}

.uni-row-prep {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 30px;
  margin: 8px 6px 8px 0;
  padding: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--c-text-subtle);
  font-size: 13px;
  font-weight: 700;
  transition: background 0.12s ease, color 0.12s ease;
  border: 1px solid transparent;
}
.uni-row-prep:hover {
  background: var(--c-primary-soft);
  color: var(--c-primary);
  border-color: var(--c-primary);
}
.uni-row-prep:focus-visible {
  outline: 2px solid var(--c-primary);
  outline-offset: 1px;
}

.uni-row-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--c-text);
  font-family: var(--ff-jp);
  line-height: 1.35;
}
.uni-row-name-secondary {
  font-size: 11px;
  color: var(--c-text-muted);
  font-weight: 500;
  font-family: var(--ff-sans);
  line-height: 1.3;
}
.uni-row-meta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
  margin-top: 2px;
}
.uni-row-meta-type {
  font-weight: 600;
}

/* ─── MAIN PANE ───────────────────────────────────────────────────── */

.main-pane {
  display: flex;
  flex-direction: column;
  gap: 28px;
  min-width: 0; /* prevents grid blowout on long product names */
}

/* Default "select a school" empty state */
.select-prompt {
  background: var(--c-surface);
  border: 1px dashed var(--c-border-strong);
  border-radius: var(--r-lg);
  padding: 36px 32px;
  text-align: center;
  color: var(--c-text-muted);
}
.select-prompt-icon {
  font-size: 28px;
  color: var(--c-primary);
  margin-bottom: 8px;
}
.select-prompt h2 {
  font-size: 18px;
  color: var(--c-text);
  margin: 0 0 10px;
  font-weight: 700;
}
.select-prompt p {
  font-size: 13px;
  margin: 0 0 16px;
  max-width: 48ch;
  margin-inline: auto;
  line-height: 1.55;
}
.select-prompt-bullets {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}
.select-prompt-bullets li {
  display: inline-block;
  padding: 4px 10px;
  background: var(--c-tag-bg);
  color: var(--c-tag-text);
  font-size: 11px;
  font-weight: 600;
  border-radius: 999px;
}

/* Product results header */
.products-section { display: flex; flex-direction: column; gap: 16px; }
.products-header { display: flex; flex-direction: column; gap: 8px; }
.products-header-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.products-header h2 {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
  color: var(--c-text);
}
.products-uni-name {
  color: var(--c-primary);
  font-family: var(--ff-jp);
}
.products-subtitle {
  font-size: 13px;
  color: var(--c-text-muted);
  margin: 0;
}
.products-subtitle a {
  color: var(--c-primary);
  font-weight: 500;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease;
}
.products-subtitle a:hover { border-bottom-color: var(--c-primary); }

.requirements-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.req-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--c-tag-bg);
  color: var(--c-tag-text);
  font-size: 11px;
  font-weight: 600;
  max-width: 100%;
}
.req-chip strong { font-weight: 700; }

.faculty-notes {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.faculty-notes-details {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  padding: 10px 14px;
  font-size: 12px;
  color: var(--c-text-muted);
}
.faculty-notes-details summary {
  cursor: pointer;
  color: var(--c-text);
  font-weight: 600;
  font-size: 12px;
  list-style: none;
}
.faculty-notes-details summary::-webkit-details-marker { display: none; }
.faculty-notes-details summary::before {
  content: '▸';
  display: inline-block;
  margin-right: 6px;
  color: var(--c-primary);
  transition: transform 0.15s ease;
}
.faculty-notes-details[open] summary::before { transform: rotate(90deg); }
.faculty-notes-details ul {
  margin: 8px 0 0;
  padding-left: 22px;
  line-height: 1.6;
}
.faculty-notes-details li { padding: 1px 0; }

.specs-source-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: var(--r-md);
  background: rgba(224, 144, 43, 0.08);
  color: var(--c-warning);
  font-size: 11px;
  font-weight: 600;
}

/* ─── PRODUCT GRID ────────────────────────────────────────────────── */

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.product-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  box-shadow: var(--sh-card);
  transition: box-shadow 0.15s ease, transform 0.15s ease;
  position: relative; /* anchors the .why-popover */
}
.product-card:hover { box-shadow: var(--sh-card-hover); transform: translateY(-1px); }

/* ── Why-this-match popover (hover on desktop, tap-to-toggle mobile) ── */
.why-trigger {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--c-tag-bg);
  color: var(--c-tag-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  border: 1px solid transparent;
  cursor: help;
  z-index: 3;
  transition: background 0.15s ease, transform 0.15s ease;
}
.why-trigger:hover,
.why-trigger:focus,
.why-trigger[aria-expanded="true"] {
  background: var(--c-primary);
  color: #fff;
  border-color: var(--c-primary);
  transform: scale(1.05);
  outline: none;
}

.why-popover {
  position: absolute;
  top: 44px;
  right: 10px;
  width: 320px;
  max-width: calc(100vw - 40px);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 14px 16px;
  box-shadow: 0 12px 32px rgba(20, 25, 40, 0.18), 0 4px 8px rgba(20, 25, 40, 0.08);
  z-index: 20;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.why-trigger:hover ~ .why-popover,
.why-trigger:focus ~ .why-popover,
.why-popover:hover,
.why-popover[data-state="open"] {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.why-popover-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 8px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--c-border);
}
.why-popover-header strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--c-text);
}
.why-popover-fit {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(43, 182, 115, 0.12);
  color: var(--c-success);
}
.why-popover-fit[data-fit="partial"] {
  background: rgba(224, 144, 43, 0.12);
  color: var(--c-warning);
}

.why-section {
  margin-bottom: 10px;
}
.why-section:last-child { margin-bottom: 0; }
.why-section h5 {
  margin: 0 0 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
}
.why-section-pros h5 { color: var(--c-success); }
.why-section-cons h5 { color: var(--c-warning); }
.why-section-notes h5 { color: var(--c-accent); }
.why-section ul {
  margin: 0;
  padding-left: 14px;
  font-size: 12px;
  color: var(--c-text);
  line-height: 1.55;
}
.why-section li {
  padding: 2px 0;
}
.why-section-pros li::marker { color: var(--c-success); }
.why-section-cons li::marker { color: var(--c-warning); }
.why-section-notes li::marker { color: var(--c-accent); }

/* Popovers near the right edge of the grid would overflow the page.
 * For cards in the last column (heuristic via :nth-last-child), flip
 * the popover to open leftward. */
@media (min-width: 880px) {
  .products-grid .product-card:nth-child(3n) .why-popover,
  .products-grid .product-card:nth-child(3n - 1) .why-popover {
    /* default position works for most viewports */
  }
}

.product-card-image {
  aspect-ratio: 4 / 3;
  background: var(--c-surface-2);
  border-radius: var(--r-md);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--c-border);
}
.product-card-image img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.product-card-image-fallback {
  font-size: 11px;
  color: var(--c-text-subtle);
}

.product-card-tag {
  display: inline-flex;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
}
.product-card-tag[data-line="daiv"]     { color: #5B3FBB; }
.product-card-tag[data-line="g-tune"]   { color: #E0902B; }
.product-card-tag[data-line="mouse"]    { color: var(--c-primary); }
.product-card-tag[data-line="mousepro"] { color: #2B5BD8; }
.product-card-tag[data-line="nextgear"] { color: #2BB673; }

.product-card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--c-text);
  line-height: 1.35;
  margin: 0;
}
.product-card-specs {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--c-text-muted);
}
.product-card-spec {
  display: flex;
  gap: 6px;
  align-items: flex-start;
}
.product-card-spec-label {
  flex: 0 0 56px;
  color: var(--c-text-subtle);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding-top: 1px;
}
.product-card-spec-value { color: var(--c-text); }

.product-card-fitness {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--c-success);
  font-weight: 600;
}
.product-card-fitness[data-fit="partial"] { color: var(--c-warning); }
.product-card-fitness-dot {
  width: 7px; height: 7px; border-radius: 999px;
  background: currentColor;
}

.product-card-price {
  font-size: 20px;
  font-weight: 700;
  color: var(--c-text);
  font-variant-numeric: tabular-nums;
}
.product-card-price-yen {
  font-size: 12px;
  font-weight: 500;
  color: var(--c-text-muted);
  margin-right: 2px;
}
/* Bundle-variants chip — shown when the same model has multiple SKUs
   (option / warranty packages) and the matcher kept the cheapest. */
.product-card-variants {
  display: inline-block;
  margin-top: 4px;
  font-size: 11px;
  font-weight: 500;
  color: var(--c-text-muted);
  text-decoration: none;
  border-bottom: 1px dotted var(--c-text-subtle, #9aa0a6);
  font-variant-numeric: tabular-nums;
}
.product-card-variants:hover {
  color: var(--c-text);
  border-bottom-style: solid;
}

.product-card-footer {
  display: flex;
  gap: 8px;
  margin-top: auto;
  padding-top: 8px;
}

/* ─── BUTTONS ─────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  border: 1px solid transparent;
}
.btn-primary {
  background: var(--c-primary);
  color: #fff;
  flex: 1;
}
.btn-primary:hover { background: var(--c-primary-hover); }
.btn-ghost {
  background: var(--c-surface);
  color: var(--c-text-muted);
  border-color: var(--c-border);
}
.btn-ghost:hover {
  background: var(--c-surface-2);
  color: var(--c-text);
  border-color: var(--c-border-strong);
}
.btn-secondary {
  background: var(--c-surface);
  color: var(--c-text);
  border-color: var(--c-border);
}
.btn-secondary:hover {
  background: var(--c-surface-2);
  border-color: var(--c-primary);
  color: var(--c-primary);
}

/* ─── EMPTY STATES ────────────────────────────────────────────────── */

.results-empty {
  text-align: center;
  padding: 28px 16px;
  color: var(--c-text-muted);
  font-size: 13px;
}
.results-empty-compact { padding: 16px 12px; font-size: 12px; }

/* ─── ENTRY: spinner shown while /api/extract-title is fetching ───── */

.entry-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: entry-spinner-rot 0.7s linear infinite;
  margin-right: 6px;
  vertical-align: -2px;
}
@keyframes entry-spinner-rot { to { transform: rotate(360deg); } }

/* ─── TAB SWITCH (search ↔ entry ↔ mockup) ────────────────────────── */

/* Hidden by default — body class controls which one is visible */
.mockup-view, .entry-view, .checklist-view { display: none; }

/* Default visible: Name Search (page-layout) */
body.view-search .entry-view     { display: none; }
body.view-search .mockup-view    { display: none; }
body.view-search .checklist-view { display: none; }

/* Mock-Up view */
body.view-mockup .page-layout    { display: none; }
body.view-mockup .entry-view     { display: none; }
body.view-mockup .checklist-view { display: none; }
body.view-mockup .mockup-view {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 1340px;
  margin: 0 auto;
  padding: 28px;
}

/* University Entry view */
body.view-entry .page-layout     { display: none; }
body.view-entry .mockup-view     { display: none; }
body.view-entry .checklist-view  { display: none; }
body.view-entry .entry-view {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 1340px;
  margin: 0 auto;
  padding: 28px;
}

/* Checklist view */
body.view-checklist .page-layout { display: none; }
body.view-checklist .entry-view  { display: none; }
body.view-checklist .mockup-view { display: none; }
body.view-checklist .checklist-view {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px;
}

/* ─── UNIVERSITY ENTRY VIEW ───────────────────────────────────────── */

.entry-header h1 {
  margin: 0 0 6px;
  font-size: 22px;
  color: var(--c-text);
}
.entry-header p {
  margin: 0;
  color: var(--c-text-muted);
  line-height: 1.55;
  max-width: 80ch;
}

.entry-methods {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
@media (max-width: 720px) { .entry-methods { grid-template-columns: 1fr; } }

.entry-method {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 18px 20px;
  box-shadow: var(--sh-card);
}
.entry-method-label {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.entry-method-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--c-primary);
  color: #fff;
  font-weight: 700;
  font-size: 11px;
  align-self: center;
}
.entry-method-label strong { font-size: 14px; color: var(--c-text); }
.entry-method-hint {
  color: var(--c-text-muted);
  font-size: 12px;
}

.entry-url-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.entry-url-row input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-surface);
  color: var(--c-text);
  transition: border-color 0.15s ease;
}
.entry-url-row input:focus {
  outline: none;
  border-color: var(--c-primary);
}
.entry-url-row .btn { flex-shrink: 0; }
.entry-url-suggestions {
  margin-top: 8px;
  font-size: 11px;
  color: var(--c-text-subtle);
  line-height: 1.5;
}

.entry-pdf-drop {
  border: 2px dashed var(--c-border-strong);
  border-radius: var(--r-md);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
  background: var(--c-surface-2);
}
.entry-pdf-drop:hover,
.entry-pdf-drop:focus-visible {
  border-color: var(--c-primary);
  outline: none;
}
.entry-pdf-drop.is-dragover {
  border-color: var(--c-primary);
  background: var(--c-primary-soft);
}
.entry-pdf-drop p {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--c-text-muted);
}
.entry-pdf-drop-icon { font-size: 28px; display: block; }
.entry-pdf-drop-filename {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  color: var(--c-primary);
  font-weight: 600;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.entry-error {
  padding: 12px 16px;
  background: var(--c-error-bg);
  color: var(--c-error);
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 500;
}

.entry-result {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: var(--sh-card);
}
.entry-result-header h2 {
  margin: 0 0 4px;
  font-size: 18px;
  color: var(--c-text);
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.entry-result-header p {
  margin: 0;
  color: var(--c-text-muted);
  font-size: 13px;
}
.entry-result-source {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-primary);
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--c-primary-soft);
}
.entry-result-source[data-source="known"] {
  color: var(--c-success);
  background: rgba(43, 182, 115, 0.12);
}
.entry-result-source[data-source="unknown"],
.entry-result-source[data-source="pdf"] {
  color: var(--c-warning);
  background: rgba(224, 144, 43, 0.12);
}

.entry-result-grid,
.entry-req-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.entry-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.entry-field label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
}
.entry-field input,
.entry-field select {
  padding: 8px 12px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-surface);
  color: var(--c-text);
  transition: border-color 0.15s ease;
}
.entry-field input:focus,
.entry-field select:focus {
  outline: none;
  border-color: var(--c-primary);
}
.entry-field-wide { grid-column: 1 / -1; }

.entry-result h3 {
  margin: 4px 0 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
}

.entry-products-carousel {
  margin-top: 4px;
}

.entry-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--c-border);
}
.entry-actions .btn-primary { flex: 0 0 auto; }

/* User-added flag on sidebar uni rows */
.uni-row[data-user-added="true"] .uni-row-name::after {
  content: ' ★';
  color: #E0902B;
  font-size: 11px;
  vertical-align: super;
}
.uni-row-remove {
  display: none;
  position: absolute;
  top: 6px;
  right: 6px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--c-error-bg);
  color: var(--c-error);
  border: none;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.uni-row[data-user-added="true"] .uni-row-remove {
  display: inline-flex;
}
.uni-row-remove:hover {
  background: var(--c-error);
  color: #fff;
}

.card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 22px;
  box-shadow: var(--sh-card);
}
.card-tag {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--c-tag-bg);
  color: var(--c-tag-text);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
}

/* ─── MOCKUP: intro card above the framed mouse-jp page ───────────── */

.mockup-intro {
  padding: 22px 26px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-card);
}
.mockup-intro h2 {
  margin: 10px 0 6px;
  font-size: 22px;
  color: var(--c-text);
}
.mockup-intro p {
  margin: 0;
  color: var(--c-text-muted);
  line-height: 1.55;
  max-width: 78ch;
}

/* ─── MOCKUP: browser-chrome frame ────────────────────────────────── */

.mockup-frame {
  background: var(--c-surface);
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--c-border-strong);
  box-shadow: 0 20px 48px rgba(20, 25, 40, 0.12), 0 4px 12px rgba(20, 25, 40, 0.06);
}
.mockup-frame-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: #ECEDF0;
  border-bottom: 1px solid var(--c-border);
}
.mockup-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
}
.mockup-dot-r { background: #FF5F57; }
.mockup-dot-y { background: #FEBC2E; }
.mockup-dot-g { background: #28C840; }
.mockup-frame-url {
  flex: 1;
  margin-left: 12px;
  padding: 5px 14px;
  background: var(--c-surface);
  border-radius: var(--r-sm);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
  font-size: 11px;
  color: var(--c-text-muted);
  border: 1px solid var(--c-border);
}

/* ─── MOCKUP: inner page styled like mouse-jp.co.jp ───────────────── */

.mockup-page {
  background: #fff;
  font-size: 13px;
  color: #1A1F2E;
}

.mockup-mc-header {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 14px 24px;
  border-bottom: 1px solid #E5E5E5;
}
.mockup-mc-logo img {
  height: 26px;
  width: auto;
  display: block;
}
.mockup-mc-nav {
  display: flex;
  gap: 22px;
  flex: 1;
}
.mockup-mc-nav a {
  font-size: 12px;
  font-weight: 600;
  color: #1A1F2E;
  cursor: default;
}
.mockup-mc-caret { color: #999; font-size: 10px; }
.mockup-mc-search {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid #DDD;
  border-radius: 4px;
  background: #F8F8F8;
}
.mockup-mc-search input {
  border: none;
  background: transparent;
  font-size: 12px;
  width: 180px;
  outline: none;
  color: #888;
  cursor: not-allowed;
}

.mockup-mc-yellowbar {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 10px 24px;
  background: #FFF200;
  font-size: 12px;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}
.mockup-mc-yellowbar strong { font-weight: 700; color: #1A1F2E; }
.mockup-mc-yellowbar span { color: #555; font-size: 11px; }

.mockup-mc-breadcrumb {
  padding: 14px 24px 6px;
  font-size: 11px;
  color: #666;
  display: flex;
  align-items: center;
  gap: 6px;
}
.mockup-mc-breadcrumb a { color: #1A4FBA; cursor: default; }
.mockup-mc-crumb-sep { color: #BBB; font-size: 10px; }
.mockup-mc-crumb-current { color: #1A1F2E; font-weight: 500; }

/* ─── MOCKUP: mouse-jp hero section ───────────────────────────────── */

.mockup-mc-hero {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  margin: 12px 24px 0;
  border-radius: 8px;
  overflow: hidden;
  background: #F5F5F0;
  min-height: 200px;
}
.mockup-mc-hero-text {
  padding: 30px 32px;
  align-self: center;
}
.mockup-mc-hero-text h1 {
  margin: 0 0 14px;
  font-size: 22px;
  font-weight: 500;
  color: #1A1F2E;
  line-height: 1.5;
}
.mockup-mc-hero-text h1 strong {
  display: block;
  font-size: 30px;
  font-weight: 700;
  margin-top: 4px;
  letter-spacing: 0.02em;
}
.mockup-mc-hero-text p {
  margin: 0;
  font-size: 12px;
  color: #444;
  line-height: 1.7;
}
.mockup-mc-hero-img {
  position: relative;
  background:
    radial-gradient(circle at 70% 30%, rgba(255,255,255,0.4) 0%, transparent 60%),
    linear-gradient(135deg, #C7BFB0 0%, #948B7C 100%);
  min-height: 220px;
  overflow: hidden;
}
.mockup-mc-hero-laptop {
  position: absolute;
  inset: 30% 12% 14% 18%;
  background:
    linear-gradient(170deg, #2A2D38 0%, #1A1D26 100%);
  border-radius: 2px 2px 8px 8px;
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(255,255,255,0.05) inset;
  transform: perspective(600px) rotateX(8deg) rotateY(-10deg);
}
.mockup-mc-hero-laptop::before {
  content: '';
  position: absolute;
  inset: 4px;
  background: #0D0D12;
  border-radius: 2px;
}
.mockup-mc-hero-laptop::after {
  content: 'mouse';
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff100;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.02em;
}

/* ─── MOCKUP: the embedded campuspc widget ───────────────────────── */

.mockup-mc-widget {
  margin: 24px;
  padding: 24px;
  background: linear-gradient(135deg, #FFFAFA 0%, #FFF4F5 50%, #FFEEF0 100%);
  border: 2px solid var(--c-primary);
  border-radius: 12px;
  position: relative;
  box-shadow: 0 4px 16px rgba(230, 0, 18, 0.08);
}
.mockup-mc-widget-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.mockup-mc-widget-new {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  background: var(--c-primary);
  color: #fff;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
}
.mockup-mc-widget-tag {
  font-size: 12px;
  color: #1A1F2E;
}
.mockup-mc-widget-tag strong { font-weight: 700; }
.mockup-mc-widget-by {
  color: var(--c-text-muted);
  font-weight: 500;
}
.mockup-mc-widget h2 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 700;
  color: #1A1F2E;
  letter-spacing: 0.01em;
}
.mockup-mc-widget > p {
  margin: 0 0 18px;
  color: #444;
  font-size: 13px;
  line-height: 1.65;
  max-width: 72ch;
}

.mockup-mc-selector {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px 18px;
  background: #fff;
  border: 1px solid var(--c-border);
  border-radius: 8px;
}
.mockup-mc-selector label {
  font-size: 13px;
  color: #1A1F2E;
}
.mockup-mc-select {
  flex: 1 1 320px;
  padding: 10px 14px;
  border: 1px solid #C8C8C8;
  border-radius: 4px;
  background: #fff;
  font-size: 14px;
  color: #1A1F2E;
  font-family: inherit;
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M3 4.5l3 3 3-3' stroke='%231A1F2E' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
  cursor: pointer;
}
.mockup-mc-select:focus { outline: 2px solid var(--c-primary); outline-offset: 1px; }
.mockup-mc-clear {
  padding: 8px 14px;
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  color: var(--c-text-muted);
  cursor: pointer;
}
.mockup-mc-clear:hover { color: var(--c-primary); border-color: var(--c-primary); }

.mockup-mc-summary {
  margin-top: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
  color: #1A1F2E;
}
.mockup-mc-summary strong { color: var(--c-primary); font-size: 15px; }
.mockup-mc-summary a {
  font-size: 12px;
  color: var(--c-primary);
  font-weight: 600;
  border-bottom: 1px solid currentColor;
}

/* Carousel — horizontal scroll with snap + arrow buttons. Sized so
 * 3–5 cards are visible at a time on a typical desktop, the rest reachable
 * by arrow click, swipe, or the thin scrollbar at the bottom. */
.mockup-mc-carousel {
  position: relative;
  margin-top: 16px;
}
.mockup-mc-carousel-arrow {
  position: absolute;
  top: calc(50% - 6px);            /* nudge above the scrollbar */
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--c-border-strong);
  box-shadow: 0 4px 12px rgba(20, 25, 40, 0.12);
  font-size: 26px;
  line-height: 1;
  color: var(--c-text);
  z-index: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0 0 4px 0;              /* visually centre the ‹ ›  glyphs */
  transition: border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.mockup-mc-carousel-arrow[data-dir="prev"] { left: -18px; }
.mockup-mc-carousel-arrow[data-dir="next"] { right: -18px; }
.mockup-mc-carousel-arrow:hover {
  border-color: var(--c-primary);
  color: var(--c-primary);
  transform: translateY(-50%) scale(1.04);
}
.mockup-mc-carousel-arrow:focus-visible {
  outline: 2px solid var(--c-primary);
  outline-offset: 2px;
}
.mockup-mc-carousel-arrow:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  transform: translateY(-50%);
}

.mockup-mc-carousel-track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 2px 4px 12px;            /* 12px below to leave room for the scrollbar */
  scrollbar-width: thin;
  scrollbar-color: var(--c-border-strong) transparent;
}
.mockup-mc-carousel-track::-webkit-scrollbar { height: 6px; }
.mockup-mc-carousel-track::-webkit-scrollbar-thumb {
  background: var(--c-border-strong);
  border-radius: 3px;
}
.mockup-mc-carousel-track::-webkit-scrollbar-thumb:hover {
  background: var(--c-primary);
}
.mockup-mc-carousel-track::-webkit-scrollbar-track { background: transparent; }
.mockup-mc-product {
  background: #fff;
  border: 1px solid #E5E5E5;
  border-radius: 6px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
  /* Carousel: fixed-width cards with snap points */
  flex: 0 0 220px;
  scroll-snap-align: start;
  position: relative;
}

/* "Why this match?" trigger — small question-mark pill anchored to
 * the card's top-right corner. Mirrors the main app's `.why-trigger`
 * but sized down for the compact mockup card. */
.mockup-mc-product-why-trigger {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: var(--c-tag-bg);
  color: var(--c-tag-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 11px;
  border: 1px solid transparent;
  cursor: help;
  z-index: 2;
  transition: background 0.15s ease, transform 0.15s ease;
}
.mockup-mc-product-why-trigger:hover,
.mockup-mc-product-why-trigger:focus,
.mockup-mc-product-why-trigger[aria-expanded="true"] {
  background: var(--c-primary);
  color: #fff;
  border-color: var(--c-primary);
  transform: scale(1.08);
  outline: none;
}

/* Shared popover — position:fixed so it escapes the carousel's
 * overflow clipping. JS positions it next to the active trigger. */
.mockup-why-popover {
  position: fixed;
  width: 320px;
  max-width: calc(100vw - 24px);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 14px 16px;
  box-shadow: 0 12px 32px rgba(20, 25, 40, 0.18), 0 4px 8px rgba(20, 25, 40, 0.08);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  top: 0;
  left: 0;
}
.mockup-why-popover[data-state="open"] {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

/* Popover internals — reuse the .why-section vocabulary from the
 * main app's popover so the same headings and bullet colors apply. */
.mockup-why-popover .why-popover-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 8px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--c-border);
}
.mockup-why-popover .why-popover-header strong {
  font-size: 13px;
  font-weight: 700;
  color: var(--c-text);
}
.mockup-why-popover .why-popover-fit {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(43, 182, 115, 0.12);
  color: var(--c-success);
}
.mockup-why-popover .why-popover-fit[data-fit="partial"] {
  background: rgba(224, 144, 43, 0.12);
  color: var(--c-warning);
}
.mockup-why-popover .why-section { margin-bottom: 10px; }
.mockup-why-popover .why-section:last-child { margin-bottom: 0; }
.mockup-why-popover .why-section h5 {
  margin: 0 0 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
}
.mockup-why-popover .why-section-pros h5 { color: var(--c-success); }
.mockup-why-popover .why-section-cons h5 { color: var(--c-warning); }
.mockup-why-popover .why-section-notes h5 { color: var(--c-accent); }
.mockup-why-popover .why-section ul {
  margin: 0;
  padding-left: 14px;
  font-size: 12px;
  color: var(--c-text);
  line-height: 1.55;
}
.mockup-why-popover .why-section li { padding: 2px 0; }
.mockup-why-popover .why-section-pros li::marker { color: var(--c-success); }
.mockup-why-popover .why-section-cons li::marker { color: var(--c-warning); }
.mockup-why-popover .why-section-notes li::marker { color: var(--c-accent); }
.mockup-mc-product:hover {
  border-color: var(--c-primary);
  box-shadow: 0 4px 12px rgba(230, 0, 18, 0.08);
}
.mockup-mc-product-img {
  aspect-ratio: 4/3;
  background: #F8F8F8;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.mockup-mc-product-img img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.mockup-mc-product-line {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--c-text-subtle);
}
.mockup-mc-product-line[data-line="daiv"]     { color: #5B3FBB; }
.mockup-mc-product-line[data-line="g-tune"]   { color: #E0902B; }
.mockup-mc-product-line[data-line="mouse"]    { color: var(--c-primary); }
.mockup-mc-product-line[data-line="mousepro"] { color: #2B5BD8; }
.mockup-mc-product-line[data-line="nextgear"] { color: #2BB673; }
.mockup-mc-product-title {
  font-size: 12px;
  font-weight: 700;
  color: #1A1F2E;
  line-height: 1.35;
}
.mockup-mc-product-meta {
  font-size: 11px;
  color: #666;
  line-height: 1.5;
}
.mockup-mc-product-fit {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  font-weight: 700;
  color: var(--c-success);
}
.mockup-mc-product-fit[data-fit="partial"] { color: var(--c-warning); }
.mockup-mc-product-fit::before {
  content: '●';
  font-size: 8px;
}
.mockup-mc-product-price {
  font-size: 16px;
  font-weight: 700;
  color: #1A1F2E;
  font-variant-numeric: tabular-nums;
}
.mockup-mc-product-price-yen {
  font-size: 11px;
  font-weight: 500;
  color: #666;
}
.mockup-mc-product-variants {
  display: inline-block;
  margin: 2px 0 4px;
  font-size: 10px;
  font-weight: 500;
  color: #666;
  text-decoration: none;
  border-bottom: 1px dotted #999;
  font-variant-numeric: tabular-nums;
}
.mockup-mc-product-variants:hover {
  color: #1A1F2E;
  border-bottom-style: solid;
}
.mockup-mc-product-cta {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 7px 10px;
  background: var(--c-primary);
  color: #fff;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  margin-top: auto;
  cursor: pointer;
  transition: background 0.12s ease;
}
.mockup-mc-product-cta:hover { background: var(--c-primary-hover); }

.mockup-mc-empty {
  margin-top: 14px;
  padding: 18px;
  background: #fff;
  border: 1px dashed var(--c-border-strong);
  border-radius: 6px;
  text-align: center;
  color: var(--c-text-muted);
  font-size: 12px;
}

.mockup-mc-widget-footer {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid rgba(230, 0, 18, 0.18);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--c-text-muted);
}
.mockup-mc-widget-stat {
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--c-primary);
}

/* ─── MOCKUP: existing-content stub below the widget ──────────────── */

.mockup-mc-existing {
  margin: 24px;
  padding: 22px 24px;
  background: #F8F8F8;
  border-radius: 6px;
}
.mockup-mc-existing-tag {
  display: inline-flex;
  padding: 4px 10px;
  background: #1A4FBA;
  color: #fff;
  font-size: 11px;
  border-radius: 4px;
  margin-bottom: 12px;
  font-weight: 600;
}
.mockup-mc-existing h2 {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 700;
  color: #1A1F2E;
}
.mockup-mc-existing p {
  margin: 0 0 12px;
  font-size: 13px;
  color: #444;
  line-height: 1.65;
  max-width: 72ch;
}
.mockup-mc-cta {
  font-size: 13px;
  color: var(--c-primary);
  font-weight: 600;
  cursor: default;
}

/* ─── MOCKUP: integration callouts under the frame ────────────────── */

.mockup-callouts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.mockup-callout {
  padding: 16px 18px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  box-shadow: var(--sh-card);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.mockup-callout strong {
  font-size: 13px;
  color: var(--c-text);
  font-weight: 700;
}
.mockup-callout span {
  font-size: 12px;
  color: var(--c-text-muted);
  line-height: 1.55;
}

/* Mobile tweaks for the mockup */
@media (max-width: 720px) {
  body.view-mockup .mockup-view { padding: 18px; }
  .mockup-mc-hero { grid-template-columns: 1fr; }
  .mockup-mc-hero-text { padding: 22px; }
  .mockup-mc-hero-img { min-height: 160px; }
  .mockup-mc-widget { margin: 18px; padding: 18px; }
  .mockup-mc-existing { margin: 18px; padding: 18px; }
  .mockup-mc-nav { display: none; }
}

/* ─── FOOTER ──────────────────────────────────────────────────────── */

.page-footer {
  margin-top: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--c-border);
  text-align: center;
  font-size: 12px;
  color: var(--c-text-subtle);
}

/* ─── TOAST ───────────────────────────────────────────────────────── */

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: var(--c-text);
  color: #fff;
  padding: 12px 18px;
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--sh-toast);
  z-index: 100;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}
.toast[data-show="1"] {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}
.toast[hidden] { display: none; }

/* ─── CHECKLIST VIEW ──────────────────────────────────────────────── */

.checklist-header .card-tag { margin-bottom: 10px; }
.checklist-header h1 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--c-text);
}
.checklist-header p {
  margin-top: 8px;
  max-width: 720px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--c-text-muted);
}

/* Org-type switch */
.cl-orgtype {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.cl-orgtype-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--r-md);
  background: var(--c-surface);
  cursor: pointer;
  text-align: left;
  font-family: var(--ff-sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--c-text);
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}
.cl-orgtype-btn:hover { border-color: var(--c-border-strong); }
.cl-orgtype-btn.is-active {
  border-color: var(--c-primary);
  background: var(--c-primary-soft);
  box-shadow: 0 0 0 1px var(--c-primary) inset;
}
.cl-orgtype-ic { font-size: 20px; }
.cl-orgtype-btn small {
  font-size: 11px;
  font-weight: 600;
  color: var(--c-text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cl-orgtype-btn.is-active small { color: var(--c-primary); }

/* Cards */
.cl-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 20px 22px;
  box-shadow: var(--sh-card);
}
.cl-step {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}
.cl-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: var(--c-primary);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}
.cl-step strong { font-size: 16px; color: var(--c-text); }
.cl-step-hint {
  flex-basis: 100%;
  padding-left: 34px;
  font-size: 12.5px;
  color: var(--c-text-muted);
  line-height: 1.5;
}

/* Import row */
.cl-import-row {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 14px;
  align-items: stretch;
}
.cl-import-url { display: flex; gap: 8px; }
.cl-import-url input {
  flex: 1;
  min-width: 0;
  padding: 11px 13px;
  border: 1px solid var(--c-border-strong);
  border-radius: var(--r-md);
  font-family: var(--ff-sans);
  font-size: 13.5px;
  color: var(--c-text);
  background: var(--c-surface-2);
}
.cl-import-url input:focus {
  outline: none;
  border-color: var(--c-primary);
  box-shadow: 0 0 0 3px var(--c-primary-soft);
}
.cl-import-url .btn { flex-shrink: 0; }
.cl-pdf-drop {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 12px;
  border: 1.5px dashed var(--c-border-strong);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  color: var(--c-text-muted);
  font-size: 12.5px;
  cursor: pointer;
  text-align: center;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.cl-pdf-drop:hover, .cl-pdf-drop:focus-visible,
.cl-pdf-drop.is-dragover {
  border-color: var(--c-primary);
  background: var(--c-primary-soft);
  outline: none;
}
.cl-pdf-drop-ic { font-size: 22px; }
.cl-pdf-drop-filename { font-weight: 600; color: var(--c-text); }

.cl-samples {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.cl-samples-label { font-size: 12px; font-weight: 600; color: var(--c-text-subtle); }
.cl-samples-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cl-sample-chip {
  padding: 6px 12px;
  border: 1px solid var(--c-border-strong);
  border-radius: 999px;
  background: var(--c-surface);
  font-family: var(--ff-sans);
  font-size: 12px;
  font-weight: 500;
  color: var(--c-text);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.cl-sample-chip:hover { border-color: var(--c-primary); color: var(--c-primary); }
.cl-sample-chip .cl-sample-qty { color: var(--c-text-subtle); font-weight: 400; }

.cl-import-note {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: var(--r-md);
  background: var(--c-accent-soft);
  border: 1px solid rgba(91, 63, 187, 0.2);
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--c-text);
}

.cl-autofill-banner {
  margin-bottom: 14px;
  padding: 9px 14px;
  border-radius: var(--r-md);
  background: rgba(43, 182, 115, 0.09);
  border: 1px solid rgba(43, 182, 115, 0.3);
  font-size: 12.5px;
  font-weight: 500;
  color: #1c7a4f;
}

/* Checklist facet grid */
.cl-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.cl-cat {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 18px;
  padding: 16px 0;
  border-top: 1px solid var(--c-border);
}
.cl-cat:first-child { border-top: none; padding-top: 4px; }
.cl-cat-label {
  font-size: 14px;
  font-weight: 700;
  color: var(--c-text);
  padding-top: 2px;
}
.cl-cat-groups { display: flex; flex-direction: column; gap: 16px; }
.cl-group-title {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--c-text-muted);
  margin-bottom: 8px;
}
.cl-facets {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 6px 14px;
}
.cl-facet {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: var(--c-text);
  cursor: pointer;
  padding: 3px 0;
  user-select: none;
}
.cl-facet input { width: 15px; height: 15px; accent-color: var(--c-primary); cursor: pointer; flex-shrink: 0; }
.cl-facet.is-auto { font-weight: 600; }
.cl-facet-count { color: var(--c-text-subtle); font-size: 11.5px; }
.cl-facet.is-empty { opacity: 0.4; }
.cl-facet-autotag {
  font-size: 10px;
  font-weight: 700;
  color: var(--c-success);
  border: 1px solid rgba(43, 182, 115, 0.4);
  border-radius: 4px;
  padding: 0 4px;
  line-height: 1.5;
  white-space: nowrap;   /* keep "自動" horizontal; never stack its glyphs */
  flex-shrink: 0;
}
.cl-facet-count { flex-shrink: 0; }
/* Compliance facets read as toggles, not catalog counts */
.cl-cat[data-cat="compliance"] .cl-facet-count { display: none; }
/* A requirement worth showing but not filtering on (e.g. a screen-size
   minimum every model already clears) — a quiet note, not a ticked band. */
.cl-group-note {
  margin-top: 8px;
  font-size: 11.5px;
  font-style: italic;
  color: var(--c-text-subtle);
  border-left: 2px solid var(--c-border);
  padding-left: 8px;
}

/* Order params */
.cl-order-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.cl-field { display: flex; flex-direction: column; gap: 5px; }
.cl-field label { font-size: 12px; font-weight: 600; color: var(--c-text-muted); }
.cl-field input, .cl-field select {
  padding: 9px 11px;
  border: 1px solid var(--c-border-strong);
  border-radius: var(--r-sm);
  font-family: var(--ff-sans);
  font-size: 13.5px;
  color: var(--c-text);
  background: var(--c-surface-2);
}
.cl-field input:focus, .cl-field select:focus {
  outline: none;
  border-color: var(--c-primary);
  box-shadow: 0 0 0 3px var(--c-primary-soft);
}
/* Commercial fields dimmed for the university flow */
body:not(.cl-commercial) .cl-field-commercial { opacity: 0.5; }

/* Curate action */
.cl-curate-row { display: flex; gap: 12px; align-items: center; }
.cl-curate-btn { font-size: 15px; padding: 13px 26px; }

/* Result */
.cl-result { display: flex; flex-direction: column; gap: 0; }
.cl-result-inner {
  background: var(--c-surface);
  border: 2px solid var(--c-primary);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-card-hover);
}
.cl-result-banner {
  background: var(--c-primary);
  color: #fff;
  padding: 12px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.cl-result-banner strong { font-size: 15px; font-weight: 700; }
.cl-result-banner-sub { font-size: 12px; opacity: 0.9; }
.cl-result-body {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 22px;
  padding: 22px;
}
.cl-result-product { display: flex; flex-direction: column; gap: 10px; }
.cl-result-img {
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.cl-result-img img { max-width: 100%; max-height: 100%; object-fit: contain; }
.cl-result-line {
  align-self: flex-start;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--c-accent-soft);
  color: var(--c-accent);
}
.cl-result-title { font-size: 16px; font-weight: 700; color: var(--c-text); line-height: 1.4; }
.cl-result-specs { display: flex; flex-direction: column; gap: 3px; margin-top: 2px; }
.cl-result-spec { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; padding: 3px 0; border-bottom: 1px dotted var(--c-border); }
.cl-result-spec span:first-child { color: var(--c-text-muted); }
.cl-result-spec span:last-child { color: var(--c-text); font-weight: 500; text-align: right; }

.cl-result-right { display: flex; flex-direction: column; gap: 18px; }

/* Batch pricing block */
.cl-pricing {
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  padding: 16px 18px;
}
.cl-pricing-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--c-text-muted); margin-bottom: 10px; }
.cl-pricing-rows { display: flex; flex-direction: column; gap: 6px; }
.cl-pricing-row { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; }
.cl-pricing-row span:first-child { color: var(--c-text-muted); }
.cl-pricing-row span:last-child { font-weight: 600; color: var(--c-text); }
.cl-pricing-row.is-discount span:last-child { color: var(--c-success); }
.cl-pricing-total {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--c-border-strong);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.cl-pricing-total-label { font-size: 13px; font-weight: 700; color: var(--c-text); }
.cl-pricing-total-val { font-size: 22px; font-weight: 700; color: var(--c-primary); }
.cl-pricing-note { margin-top: 8px; font-size: 11px; color: var(--c-text-subtle); line-height: 1.5; }

/* "Why this configuration" — factual reason chips */
.cl-scorecard-title, .cl-req-title {
  font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--c-text-muted); margin-bottom: 10px;
}
.cl-reasons { display: flex; flex-wrap: wrap; gap: 8px; }
.cl-reason {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid rgba(43, 182, 115, 0.28);
  background: rgba(43, 182, 115, 0.08);
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--c-text);
  line-height: 1.3;
}
.cl-reason-ic { color: var(--c-success); font-weight: 700; }

/* Requirements satisfied */
.cl-reqs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px 16px; }
.cl-req {
  display: flex; align-items: flex-start; gap: 7px;
  font-size: 12.5px; color: var(--c-text); line-height: 1.45; padding: 2px 0;
}
.cl-req-ic { color: var(--c-success); font-weight: 700; flex-shrink: 0; }
.cl-req-ic.is-warn { color: var(--c-warning); }

/* Clickable "relaxed" flag → explanation popover */
.cl-relaxed-flag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 2px;
}
.cl-relaxed-flag:hover { text-decoration-style: solid; }
.cl-relaxed-flag-banner { font-weight: 500; }
.cl-relaxed-i { font-size: 11px; opacity: 0.85; text-decoration: none; }
.cl-relaxed-pop {
  position: fixed;
  z-index: 200;
  max-width: 300px;
  background: var(--c-text);
  color: #fff;
  padding: 12px 14px;
  border-radius: var(--r-md);
  font-size: 12.5px;
  line-height: 1.55;
  box-shadow: var(--sh-toast);
}
.cl-relaxed-pop[hidden] { display: none; }
.cl-req strong { font-weight: 600; }
.cl-req em { font-style: normal; color: var(--c-text-muted); }

.cl-result-actions { display: flex; gap: 12px; align-items: center; padding: 0 22px 22px; flex-wrap: wrap; }
.cl-result-considered { font-size: 12px; color: var(--c-text-subtle); }

.cl-result-empty {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: 28px;
  text-align: center;
  color: var(--c-text-muted);
  font-size: 14px;
}

/* ─── RESPONSIVE ──────────────────────────────────────────────────── */

@media (max-width: 1080px) {
  .topnav-center { display: none; }
}

@media (max-width: 860px) {
  .cl-orgtype { grid-template-columns: 1fr; }
  .cl-import-row { grid-template-columns: 1fr; }
  .cl-order-grid { grid-template-columns: repeat(2, 1fr); }
  .cl-cat { grid-template-columns: 1fr; gap: 8px; }
  .cl-result-body { grid-template-columns: 1fr; }
  .cl-reqs { grid-template-columns: 1fr; }
  .cl-score-row { grid-template-columns: 100px 1fr auto; }
}

@media (max-width: 880px) {
  .page-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .sidebar {
    position: static;
    max-height: none;
  }
  .uni-list {
    max-height: 360px;
  }
}

@media (max-width: 640px) {
  .topnav { padding: 12px 18px; }
  .partner-banner { padding: 14px 18px; }
  .hero { padding: 24px 18px; }
  .page-layout { padding: 18px 18px 56px; }
  .products-grid { grid-template-columns: 1fr; }
  .partner-logo-img { height: 26px; }
  .hero-logo { height: 48px; }
  .lang-switch-label { display: none; }
  .lang-switch { padding: 2px; }
  .lang-option { padding: 6px 10px; font-size: 12px; }
}

/* ── Checklist: three curated options as full-width tabs ───────────── */
.cl-result-caption {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--c-text-muted);
  margin: 0 2px 8px;
}
.cl-result-inner {
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-card-hover);
  background: var(--c-surface);
}
/* Three equal-width tab segments occupying the top bar. */
.cl-tabs { display: flex; }
.cl-tab {
  appearance: none;
  flex: 1 1 0;
  min-width: 0;
  text-align: left;
  border: none;
  border-right: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
  background: var(--c-surface-2);
  padding: 12px 20px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  cursor: pointer;
  color: var(--c-text-muted);
  transition: background 0.15s ease, color 0.15s ease;
}
.cl-tab:last-child { border-right: none; }
.cl-tab:hover:not(.is-active) { background: var(--c-surface); color: var(--c-text); }
.cl-tab.is-active {
  background: var(--c-primary);
  color: #fff;
  border-bottom-color: var(--c-primary);
}
.cl-tab-name { font-weight: 700; font-size: 14.5px; }
.cl-tab-price { font-size: 12.5px; font-weight: 600; opacity: 0.92; }
.cl-tab-rec { font-size: 10px; font-weight: 700; letter-spacing: 0.02em; color: var(--c-primary); }
.cl-tab.is-active .cl-tab-rec { color: rgba(255, 255, 255, 0.95); }
.cl-tabpanel { position: relative; background: var(--c-surface); }
.cl-config { position: relative; }
.cl-cta { font-size: 15px; padding: 12px 22px; }
@media (max-width: 620px) {
  .cl-tabs { flex-direction: column; }
  .cl-tab { border-right: none; }
}
