/* ============================================================
   Digital Product Passport — Brand Kick & Rush
   Font: Syne · Primary: #543DE5
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700&display=swap');

:root {
  --primary:      #543DE5;
  --primary-dark: #3a29b8;
  --primary-lt:   #7c67eb;
  --primary-bg:   #f0eeff;
  --accent:       #b3aaff;
  --nav-bg:       #0e0c1e;
  --bg:           #f7f6ff;
  --card:         #ffffff;
  --border:       #e4e0ff;
  --text:         #0e0c1e;
  --muted:        #7b7899;
  --danger:       #e03e3e;
  --success:      #2cb67d;
  --warning:      #f5a623;
  --radius:       12px;
  --shadow:       0 4px 24px rgba(84,61,229,.10);
  --shadow-lg:    0 8px 40px rgba(84,61,229,.16);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Syne', -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ---- NAV ---- */
nav {
  background: var(--nav-bg);
  color: #fff;
  padding: 0 2.5rem;
  display: flex;
  align-items: center;
  gap: 2rem;
  height: 64px;
  position: sticky;
  top: 0;
  z-index: 100;
}
nav .logo {
  color: #fff;
  display: flex;
  align-items: center;
  gap: .75rem;
}
nav .logo img {
  width: auto;
  height: auto;
  display: block;
  flex-shrink: 0;
  max-height: 40px;
}
nav .logo .logo-dot {
  width: 8px; height: 8px;
  background: var(--primary);
  border-radius: 50%;
  display: inline-block;
}
nav .logo .logo-sub {
  font-size: .7rem;
  font-weight: 400;
  color: rgba(255,255,255,.45);
  letter-spacing: .5px;
  border-left: 1px solid rgba(255,255,255,.15);
  padding-left: .6rem;
  margin-left: .2rem;
  text-transform: uppercase;
}
nav a {
  color: rgba(255,255,255,.6);
  text-decoration: none;
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .3px;
  transition: color .15s;
}
nav a:hover { color: #fff; }
nav .spacer { flex: 1; }
nav .nav-btn {
  background: var(--primary);
  color: #fff;
  padding: .45rem 1.1rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: .8rem;
  text-decoration: none;
  letter-spacing: .3px;
  transition: background .15s;
}
nav .nav-btn:hover { background: var(--primary-dark); }

/* ---- LAYOUT ---- */
.container       { max-width: 960px;  margin: 0 auto; padding: 2.5rem 1.5rem; }
.container-wide  { max-width: 1200px; margin: 0 auto; padding: 2.5rem 1.5rem; }

/* ---- PAGE HEADER ---- */
.page-header {
  background: var(--primary);
  padding: 3rem 2.5rem 2.5rem;
  margin-bottom: 0;
}
.page-header .container { padding-top: 0; padding-bottom: 0; }
.page-title {
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
  margin-bottom: .4rem;
}
.page-sub {
  color: rgba(255,255,255,.65);
  font-size: .95rem;
  font-weight: 400;
  margin-bottom: 0;
}

/* ---- CARDS ---- */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.75rem 2rem;
  margin-bottom: 1.25rem;
}
.card-title {
  font-size: .9rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 1.25rem;
  padding-bottom: .7rem;
  border-bottom: 2px solid var(--border);
  display: flex;
  align-items: center;
  gap: .6rem;
  letter-spacing: .3px;
  text-transform: uppercase;
}
.card-title .section-num {
  background: var(--primary);
  color: #fff;
  border-radius: 6px;
  width: 26px; height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  font-weight: 700;
  flex-shrink: 0;
}

/* ---- UPLOAD ZONE ---- */
.upload-zone {
  border: 2.5px dashed var(--accent);
  border-radius: var(--radius);
  padding: 3.5rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: background .2s, border-color .2s;
  background: var(--primary-bg);
}
.upload-zone:hover, .upload-zone.drag-over {
  background: #e8e4ff;
  border-color: var(--primary);
}
.upload-zone .icon { font-size: 2.5rem; margin-bottom: .75rem; }
.upload-zone strong { color: var(--primary); font-size: 1.05rem; font-weight: 700; }
.upload-zone p { color: var(--muted); margin-top: .5rem; font-size: .88rem; }
#file-input { display: none; }

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .65rem 1.4rem;
  border-radius: 8px;
  font-family: 'Syne', sans-serif;
  font-size: .88rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  text-decoration: none;
  letter-spacing: .2px;
  transition: opacity .15s, transform .1s, background .15s;
}
.btn:hover   { opacity: .88; }
.btn:active  { transform: scale(.97); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); opacity: 1; }
.btn-success { background: var(--success); color: #fff; }
.btn-outline {
  background: transparent;
  border: 2px solid var(--primary);
  color: var(--primary);
}
.btn-outline:hover { background: var(--primary-bg); opacity: 1; }
.btn-danger  { background: var(--danger); color: #fff; }
.btn-sm      { padding: .4rem .9rem; font-size: .8rem; border-radius: 6px; }

/* ---- FORM ---- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
.form-grid.cols-3 { grid-template-columns: 1fr 1fr 1fr; }
.form-grid.cols-1 { grid-template-columns: 1fr; }
@media(max-width:680px){
  .form-grid, .form-grid.cols-3 { grid-template-columns: 1fr; }
}

.form-group { display: flex; flex-direction: column; gap: .35rem; }
.form-group.span-2 { grid-column: span 2; }
.form-group label {
  font-size: .75rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .6px;
}
.form-group label .req { color: var(--danger); margin-left: 2px; }
.form-group input,
.form-group select,
.form-group textarea {
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: .65rem .9rem;
  font-size: .92rem;
  font-family: 'Syne', sans-serif;
  color: var(--text);
  background: #fff;
  transition: border-color .2s, box-shadow .2s;
  width: 100%;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(84,61,229,.12);
}
.form-group textarea { resize: vertical; min-height: 80px; }
.form-group select { cursor: pointer; }
.form-group textarea.readonly-default {
  background: var(--primary-bg);
  color: var(--text);
  cursor: default;
}
.form-note { font-size: .78rem; color: var(--muted); font-style: italic; margin-top: -.1rem; }

.supplier-picker {
  position: relative;
}
.supplier-picker input[type="search"] {
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: .65rem .9rem;
  font-size: .92rem;
  font-family: 'Syne', sans-serif;
  color: var(--text);
  background: #fff;
  width: 100%;
}
.supplier-results {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + .35rem);
  z-index: 120;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  max-height: 280px;
  overflow: auto;
}
.supplier-option {
  display: flex;
  flex-direction: column;
  gap: .15rem;
  width: 100%;
  padding: .7rem .9rem;
  border: 0;
  border-bottom: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  font-family: 'Syne', sans-serif;
}
.supplier-option:last-child { border-bottom: 0; }
.supplier-option:hover,
.supplier-option:focus {
  background: var(--primary-bg);
  outline: none;
}
.supplier-name {
  font-size: .9rem;
  font-weight: 700;
}
.supplier-meta,
.supplier-empty {
  color: var(--muted);
  font-size: .74rem;
  line-height: 1.35;
}
.supplier-empty {
  padding: .75rem .9rem;
}

/* ---- SUB-SECTION ---- */
.subsection {
  background: var(--primary-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.1rem 1.25rem;
  margin-top: 1rem;
}
.subsection-title {
  font-size: .73rem;
  font-weight: 700;
  color: var(--primary-lt);
  text-transform: uppercase;
  letter-spacing: .7px;
  margin-bottom: .9rem;
}

/* ---- BADGES ---- */
.badge {
  display: inline-block;
  padding: .2rem .7rem;
  border-radius: 20px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
}
.badge-draft     { background: #fff3cd; color: #856404; }
.badge-validated { background: #d1fae5; color: #065f46; }

/* ---- PASSPORT LIST ---- */
.passport-list { display: flex; flex-direction: column; gap: .75rem; }
.list-tools {
  display: flex;
  gap: .75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.list-tools input,
.list-tools select {
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: .65rem .9rem;
  font-family: 'Syne', sans-serif;
  font-size: .88rem;
  background: #fff;
  color: var(--text);
}
.list-tools input { min-width: 240px; flex: 1; }
.passport-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  transition: box-shadow .2s, border-color .2s;
}
.passport-item:hover {
  box-shadow: var(--shadow);
  border-color: var(--accent);
}
.passport-item .pi-thumb {
  width: 80px;
  min-height: 80px;
  background: var(--primary-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  flex-shrink: 0;
  font-size: 1.25rem;
}
.passport-item .pi-thumb img {
  max-height: 80px;
  max-width: 80px;
  object-fit: contain;
  display: block;
  background: #fff;
}
.passport-item .pi-info { flex: 1; }
.passport-item .pi-name { font-weight: 700; font-size: .95rem; }
.passport-item .pi-meta { font-size: .78rem; color: var(--muted); margin-top: .15rem; }
.passport-item .pi-actions { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: flex-end; }

/* ---- PROGRESS / LOADING ---- */
.spinner {
  width: 44px; height: 44px;
  border: 4px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .7s linear infinite;
  margin: 0 auto 1rem;
  display: none;
}
@keyframes spin { to { transform: rotate(360deg); } }

.loading-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(14,12,30,.85);
  z-index: 500;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: .75rem;
  backdrop-filter: blur(4px);
}
.loading-overlay.active { display: flex; }
.loading-overlay p     { color: #fff; font-weight: 700; font-size: 1.05rem; }
.loading-overlay small { color: rgba(255,255,255,.5); font-size: .85rem; }
.progress-wrap {
  width: min(520px, calc(100vw - 2rem));
  margin-top: .4rem;
  display: flex;
  flex-direction: column;
  gap: .65rem;
}
.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: rgba(255,255,255,.82);
  font-size: .78rem;
  font-weight: 700;
}
.progress-track {
  height: 9px;
  border-radius: 999px;
  background: rgba(255,255,255,.16);
  overflow: hidden;
}
.progress-bar {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--primary-lt);
  transition: width .25s ease;
}
.progress-steps {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
  justify-content: center;
}
.progress-step {
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  padding: .24rem .65rem;
  color: rgba(255,255,255,.55);
  font-size: .72rem;
  font-weight: 700;
}
.progress-step.active {
  background: rgba(124,103,235,.28);
  border-color: rgba(179,170,255,.55);
  color: #fff;
}
.progress-step.done {
  background: rgba(44,182,125,.22);
  border-color: rgba(44,182,125,.5);
  color: #d1fae5;
}
.progress-step.error {
  background: rgba(224,62,62,.2);
  border-color: rgba(224,62,62,.45);
  color: #fee2e2;
}
#progress-elapsed {
  color: rgba(255,255,255,.55);
}

/* ---- ALERTS ---- */
.alert {
  padding: .9rem 1.25rem;
  border-radius: 10px;
  margin-bottom: 1.25rem;
  font-size: .88rem;
  align-items: center;
  gap: .65rem;
  font-weight: 500;
}
.alert-info    { background: var(--primary-bg); color: var(--primary-dark); border: 1.5px solid var(--accent); }
.alert-success { background: #d5f5e3; color: #1e8449; border: 1.5px solid #82e0aa; }
.alert-error   { background: #fdecea; color: #922b21; border: 1.5px solid #f1948a; }

/* ---- CHAMPS DÉDUITS PAR L'IA ---- */
.form-group.inferred input,
.form-group.inferred select,
.form-group.inferred textarea {
  border-color: var(--warning);
  background: #fffbf0;
}
.form-group.inferred label::after {
  content: ' ⚡ déduit';
  font-size: .68rem;
  font-weight: 700;
  color: #92600a;
  background: #fef3c7;
  border: 1px solid var(--warning);
  border-radius: 4px;
  padding: 1px 5px;
  margin-left: 6px;
  text-transform: none;
  letter-spacing: 0;
}

/* ---- VIEW PAGE ---- */
.passport-header {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  margin-bottom: 2rem;
}
.passport-header .product-img {
  width: 160px; height: 160px;
  object-fit: cover;
  border-radius: 12px;
  border: 2px solid var(--border);
  flex-shrink: 0;
  background: var(--primary-bg);
}
.passport-header .product-img.placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--muted);
}
.field-row {
  display: flex;
  gap: .5rem;
  margin-bottom: .5rem;
  font-size: .9rem;
  align-items: baseline;
}
.field-row .fl {
  color: var(--muted);
  font-weight: 700;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .4px;
  min-width: 200px;
  flex-shrink: 0;
}
.field-row .fv { color: var(--text); }
.field-row .fv:empty::after { content: '—'; color: #ccc; }

.compliance-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: .6rem;
  margin-top: .6rem;
}
.compliance-item {
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: .7rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .82rem;
}
.compliance-item .ci-label { font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .3px; }
.compliance-item .ci-val {
  font-size: .74rem;
  font-weight: 700;
  padding: .2rem .6rem;
  border-radius: 12px;
  letter-spacing: .2px;
}
.ci-compliant { background: #d1fae5; color: #065f46; }
.ci-na        { background: #f3f4f6; color: #6b7280; }
.ci-yes       { background: #d1fae5; color: #065f46; }
.ci-no        { background: #fee2e2; color: #991b1b; }

.qr-section {
  text-align: center;
  padding: 1.5rem 1.25rem;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  background: #fff;
}
.qr-section img { display: block; margin: 0 auto .75rem; border-radius: 6px; }
.qr-section .qr-url { font-size: .72rem; color: var(--muted); word-break: break-all; }
.qr-backoffice-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}
.card.qr-backoffice-card {
  display: flex;
  flex-direction: row-reverse;
  justify-content: space-between;
}
.qr-backoffice-card img {
  width: 132px;
  height: 132px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #fff;
  padding: .35rem;
  flex-shrink: 0;
}
@media(max-width:680px){
  .qr-backoffice-card { align-items: flex-start; flex-direction: column; }
}

/* ---- ACTIONS BAR ---- */
.actions-bar {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
  padding: 1rem 1.5rem;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  align-items: center;
  box-shadow: var(--shadow);
}
.actions-bar .ab-title { font-weight: 700; flex: 1; font-size: .95rem; }

/* ---- SUCCESS BANNER ---- */
.success-banner {
  background: var(--primary);
  color: #fff;
  padding: .9rem 2rem;
  display: flex;
  align-items: center;
  gap: .75rem;
  font-size: .9rem;
  font-weight: 600;
}

/* ---- PRINT ---- */
@media print {
  nav, .actions-bar, .btn, .qr-section, .success-banner { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; border: 1px solid #ddd; }
  .page-header { background: #fff; padding: 1rem 0; }
  .page-title { color: #000; }
}

/* ---- MISC ---- */
.page-content { padding-top: 2rem; }
.divider  { height: 1px; background: var(--border); margin: 1.5rem 0; }
.text-center { text-align: center; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.flex  { display: flex; }
.gap-1 { gap: .5rem; }
.gap-2 { gap: 1rem; }
.align-center    { align-items: center; }
.justify-between { justify-content: space-between; }
.empty-state { text-align: center; padding: 3.5rem 2rem; color: var(--muted); }
.empty-state .es-icon  { font-size: 3rem; margin-bottom: 1rem; opacity: .5; }
.empty-state p { font-size: .9rem; }

/* Stat chips on index */
.stat-row {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  margin-top: 1.25rem;
}
.stat-chip {
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: .85rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: .2rem;
  min-width: 120px;
}
.stat-chip .sc-num  { font-size: 1.5rem; font-weight: 700; color: var(--primary); line-height: 1; }
.stat-chip .sc-label{ font-size: .74rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .4px; }

/* ---- LANGUAGE TABS ---- */
.lang-switcher {
  display: flex;
  gap: .4rem;
  background: var(--primary-bg);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: .35rem;
  margin-bottom: 1.5rem;
  width: fit-content;
}
.lang-tab {
  padding: .4rem 1.1rem;
  border-radius: 7px;
  border: none;
  background: transparent;
  font-family: 'Syne', sans-serif;
  font-size: .82rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--muted);
  transition: background .15s, color .15s;
  letter-spacing: .5px;
}
.lang-tab.active {
  background: var(--primary);
  color: #fff;
}
.lang-field { display: none; }
.lang-field.active { display: block; }

/* ---- PDF LANGUAGE SECTIONS ---- */
.pdf-lang-section {
  margin-bottom: 0;
  page-break-before: always;
  break-before: page;
}
.pdf-lang-section:first-child {
  page-break-before: avoid;
  break-before: auto;
}
.pdf-lang-header {
  background: var(--primary);
  color: #fff;
  padding: .65rem 1rem;
  border-radius: 10px 10px 0 0;
  font-size: .88rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  gap: .6rem;
  page-break-after: avoid;
  break-after: avoid;
}
.pdf-lang-body {
  border: 1.5px solid var(--border);
  border-top: none;
  border-radius: 0 0 10px 10px;
  padding: 1rem;
  background: #fff;
  margin-bottom: 0;
}
#passport-content,
#passport-content * {
  overflow-wrap: anywhere;
}
#passport-content .pdf-brand,
#passport-content .pdf-product-header,
#passport-content .card-title,
#passport-content .subsection,
#passport-content .compliance-item,
#passport-content .product-img {
  page-break-inside: avoid;
  break-inside: avoid;
}
#passport-content .pdf-card {
  page-break-before: auto;
  break-before: auto;
  page-break-after: auto;
  break-after: auto;
  page-break-inside: auto;
  break-inside: auto;
}
#passport-content .card-title,
#passport-content .subsection-title {
  page-break-after: avoid;
  break-after: avoid;
}
#passport-content .compliance-grid {
  page-break-inside: auto;
  break-inside: auto;
}
.pdf-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: .65rem;
  margin-bottom: .8rem;
  border-bottom: 1.5px solid var(--border);
}
.pdf-brand img {
  width: 118px;
  max-width: 42%;
  height: auto;
  display: block;
}
.pdf-brand span {
  color: var(--muted);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .6px;
  text-transform: uppercase;
  text-align: right;
}

#passport-content.container {
  padding-top: 1rem;
  padding-bottom: 1rem;
}
#passport-content .pdf-card {
  box-shadow: none;
  padding: .85rem 1rem;
  margin-bottom: .55rem !important;
  border-radius: 8px;
}
#passport-content .card-title {
  font-size: .78rem;
  margin-bottom: .65rem;
  padding-bottom: .42rem;
  border-bottom-width: 1.5px;
  gap: .45rem;
  line-height: 1.25;
}
#passport-content .card-title .section-num {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  font-size: .68rem;
}
#passport-content .field-row {
  gap: .55rem;
  margin-bottom: .28rem;
  font-size: .78rem;
  line-height: 1.4;
}
#passport-content .field-row .fl {
  min-width: 165px;
  max-width: 165px;
  font-size: .66rem;
  letter-spacing: .25px;
}
#passport-content .field-row .fv {
  flex: 1;
}
#passport-content .subsection {
  padding: .7rem .85rem;
  margin-top: .55rem;
  border-radius: 8px;
}
#passport-content .subsection-title {
  font-size: .66rem;
  margin-bottom: .5rem;
}
#passport-content .compliance-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .35rem;
  margin-top: .35rem;
}
#passport-content .compliance-item {
  padding: .45rem .6rem;
  font-size: .72rem;
  gap: .4rem;
}
#passport-content .compliance-item .ci-label {
  font-size: .64rem;
  line-height: 1.25;
}
#passport-content .compliance-item .ci-val {
  font-size: .64rem;
  padding: .15rem .42rem;
  white-space: nowrap;
}
#passport-content .pdf-product-header {
  gap: .9rem !important;
}
#passport-content .pdf-product-header .product-img {
  max-width: 212px !important;
  max-height: 212px;
  object-fit: contain;
}
#passport-content .pdf-product-header > div:last-child > div:first-child {
  font-size: 1rem !important;
  margin-bottom: .35rem !important;
  line-height: 1.25;
}

/* ---- PRODUCT IMAGE CROP ---- */
.crop-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 700;
  background: rgba(14,12,30,.82);
  padding: 2rem;
  overflow: auto;
}
.crop-modal.active { display: flex; align-items: center; justify-content: center; }
.crop-dialog {
  width: min(920px, 100%);
  background: #fff;
  border-radius: 10px;
  border: 1.5px solid var(--border);
  box-shadow: var(--shadow-lg);
}
.crop-header,
.crop-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
}
.crop-actions {
  justify-content: flex-end;
  border-top: 1px solid var(--border);
  border-bottom: none;
}
.crop-header button {
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--muted);
}
.crop-stage {
  position: relative;
  margin: 1.25rem;
  overflow: hidden;
  background: var(--bg);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  touch-action: none;
}
.crop-stage img {
  display: block;
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  user-select: none;
  pointer-events: none;
}
#crop-selection {
  position: absolute;
  display: none;
  border: 2px solid var(--primary);
  background: rgba(84,61,229,.16);
  box-shadow: 0 0 0 9999px rgba(14,12,30,.28);
}
