@font-face {
  font-family: 'Quicksand';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('/fonts/quicksand-variable.ttf') format('truetype');
}

:root {
  color-scheme: light;
  --background: #f6f7f9;
  --surface: #fff;
  --surface-solid: #fff;
  --text: #1d1d1f;
  --muted: #6e6e73;
  --line: rgba(29, 29, 31, .1);
  --accent: #a52e65;
  --pink: #ff66d1;
  --coral: #f86358;
  --brand-orange: #ff9a3c;
  --accent-soft: #fff0f5;
  --accent-focus: #dc5188;
  --green: #28a745;
  --red: #d92d20;
  --orange: #b45309;
  --shadow: 0 2px 10px rgba(0, 0, 0, .045);
  --radius-xl: 14px;
  --radius-lg: 12px;
  font-family: 'Quicksand', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--text);
  background: var(--background);
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { color: inherit; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 54px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 max(22px, calc((100vw - 900px) / 2));
  border-bottom: 1px solid rgba(29, 29, 31, .07);
  background: rgba(246, 247, 249, .94);
  backdrop-filter: blur(12px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  color: var(--text);
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -.4px;
}
.brand-mark {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  background: transparent;
}
.brand-mark img { width: 28px; height: 28px; display: block; }
.desktop-nav { display: flex; gap: 6px; padding: 4px; border-radius: 12px; background: rgba(118, 118, 128, .08); }
.nav-link, .mobile-tab {
  border: 0;
  background: transparent;
  cursor: pointer;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}
.nav-link { padding: 6px 12px; border-radius: 8px; }
.nav-link.active { color: var(--accent); background: var(--accent-soft); box-shadow: 0 1px 5px rgba(0,0,0,.08); }
.api-status {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
}
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #30d158; box-shadow: 0 0 0 4px rgba(48, 209, 88, .12); }

main { width: min(100% - 32px, 820px); margin: 0 auto; }
.hero { padding: 46px 0 24px; text-align: left; }
.eyebrow { margin: 0 0 16px; color: var(--accent); font-size: 12px; font-weight: 750; letter-spacing: 1.6px; }
.hero h1 { margin: 0; font-size: 30px; line-height: 1.15; letter-spacing: -.8px; }
.hero h1 span { color: #86868b; }
.hero-copy { max-width: 650px; margin: 8px 0 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.glass-card { border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.view { display: none; padding-bottom: 52px; }
.view.active { display: block; animation: enter .35s ease both; }
@keyframes enter { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.mobile-tabs { display: none; }

.search-card { padding: 18px; border-radius: var(--radius-xl); }
.token-row, .search-footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.token-row label, .ean-label { color: #515154; font-size: 12px; font-weight: 700; letter-spacing: .3px; text-transform: uppercase; }
.token-tools { display: flex; align-items: center; gap: 16px; }
.remember-token { display: flex; align-items: center; gap: 7px; color: var(--muted) !important; font-size: 12px !important; font-weight: 500 !important; letter-spacing: 0 !important; text-transform: none !important; cursor: pointer; }
.remember-token input { accent-color: var(--accent); }
.text-button { padding: 4px 10px; border: 0; color: var(--accent); background: var(--accent-soft); font-size: 12px; cursor: pointer; }
.token-field, .ean-field {
  display: flex;
  align-items: center;
  border: 1px solid rgba(29,29,31,.12);
  background: rgba(255,255,255,.86);
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.token-field:focus-within, .ean-field:focus-within { border-color: var(--accent-focus); background: #fff; box-shadow: 0 0 0 4px rgba(220,81,136,.14); }
.token-field { height: 38px; margin: 7px 0 15px; padding: 0 11px; border-radius: 8px; }
.token-field svg, .ean-field svg { width: 16px; height: 16px; flex: 0 0 auto; fill: none; stroke: #86868b; stroke-width: 1.7; }
.token-field input, .ean-field input { width: 100%; height: 100%; border: 0; outline: 0; color: var(--text); background: transparent; }
.token-field input { padding: 0 11px; font-size: 13px; }
.ean-label { display: block; margin: 0 0 9px; }
.search-row { display: flex; gap: 12px; }
.ean-field { height: 42px; flex: 1; padding: 0 12px; border-radius: 8px; }
.ean-field input { padding: 0 9px; font-size: 15px; font-weight: 500; letter-spacing: .2px; }
.primary-button {
  min-width: 112px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 0;
  border-radius: 8px;
  color: #421b2a;
  background: linear-gradient(110deg, var(--pink), var(--coral) 56%, var(--brand-orange));
  box-shadow: none;
  cursor: pointer;
  font-size: 13px;
  font-weight: 650;
  transition: transform .15s, box-shadow .15s, opacity .15s;
}
.primary-button:hover { filter: brightness(.95); }
.primary-button:active { transform: scale(.98); }
.primary-button:disabled { cursor: wait; opacity: .65; transform: none; }
.primary-button svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; }
.search-footer { margin-top: 11px; padding: 0 2px; }
.search-footer p { margin: 0; color: #929296; font-size: 12px; }
.examples { display: flex; align-items: center; gap: 7px; color: #929296; font-size: 11px; }
.examples button { padding: 5px 8px; border: 0; border-radius: 7px; color: #515154; background: rgba(118,118,128,.09); cursor: pointer; font-size: 11px; }
.examples button:hover { color: var(--accent); background: var(--accent-soft); }

.result-area { margin-top: 14px; }
.empty-state { min-height: 160px; display: grid; place-content: center; justify-items: center; border-radius: var(--radius-xl); text-align: center; }
.empty-icon { width: 42px; height: 42px; display: grid; place-items: center; margin-bottom: 10px; border-radius: 10px; color: #86868b; background: rgba(118,118,128,.08); }
.empty-icon svg { width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.4; }
.empty-state h3 { margin: 0 0 5px; font-size: 15px; }
.empty-state p { margin: 0; color: var(--muted); font-size: 12px; }
.loading-card { padding: 28px; border-radius: var(--radius-xl); }
.skeleton { border-radius: 8px; background: linear-gradient(90deg, #ececef 25%, #f7f7f9 50%, #ececef 75%); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.skeleton-title { width: 56%; height: 28px; margin-bottom: 17px; }
.skeleton-line { width: 100%; height: 13px; margin: 10px 0; }
.skeleton-line.short { width: 68%; }
.error-card { padding: 38px 28px; border-radius: var(--radius-xl); text-align: center; }
.error-symbol { width: 48px; height: 48px; display: grid; place-items: center; margin: 0 auto 14px; border-radius: 50%; color: var(--red); background: rgba(217,45,32,.09); font-size: 23px; font-weight: 700; }
.error-card h3 { margin: 0 0 7px; }
.error-card p { margin: 0; color: var(--muted); font-size: 14px; }

.product-card { overflow: hidden; border-radius: var(--radius-xl); }
.product-hero { display: grid; grid-template-columns: 88px 1fr auto; gap: 17px; align-items: center; padding: 18px; background: #fff; border-bottom: 1px solid var(--line); }
.product-image { width: 88px; height: 88px; display: grid; place-items: center; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.product-image img { width: 100%; height: 100%; object-fit: contain; padding: 8px; }
.image-placeholder { color: #b0b0b5; }
.image-placeholder svg { width: 48px; height: 48px; fill: none; stroke: currentColor; stroke-width: 1.3; }
.product-type { display: inline-flex; width: max-content; margin-bottom: 8px; padding: 5px 9px; border-radius: 999px; color: var(--accent); background: var(--accent-soft); font-size: 11px; font-weight: 700; }
.product-title { margin: 0; font-size: 20px; line-height: 1.2; letter-spacing: -.35px; }
.ean-display { display: flex; align-items: center; gap: 8px; margin-top: 12px; color: var(--muted); font: 13px ui-monospace, SFMono-Regular, Consolas, monospace; }
.icon-copy { width: 27px; height: 27px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 8px; color: var(--accent); background: var(--accent-soft); cursor: pointer; }
.icon-copy svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.confidence {
  min-width: max-content;
  height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0 11px;
  border: 1px solid #ffd1e2;
  border-radius: 999px;
  color: var(--accent);
  background: var(--accent-soft);
  white-space: nowrap;
}
.confidence::before {
  content: "";
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--pink), var(--brand-orange));
}
.confidence strong { font-size: 12px; line-height: 1; }
.confidence span { color: #875168; font-size: 9px; line-height: 1; text-transform: uppercase; letter-spacing: .35px; }
.product-body { padding: 18px; }
.data-section + .data-section { margin-top: 20px; }
.section-title { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; font-size: 13px; font-weight: 750; letter-spacing: .2px; text-transform: uppercase; }
.section-title svg { width: 17px; height: 17px; fill: none; stroke: var(--accent); stroke-width: 1.7; }
.field-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.field-item { min-width: 0; padding: 10px; border-radius: 8px; background: rgba(118,118,128,.055); }
.field-item span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .55px; }
.field-item strong { display: block; overflow-wrap: anywhere; font-size: 13px; font-weight: 620; line-height: 1.35; }
.description-block { padding: 18px; border-radius: 16px; color: #3a3a3c; background: rgba(118,118,128,.055); font-size: 14px; line-height: 1.65; }
.description-block + .description-block { margin-top: 9px; }
.description-block strong { display: block; margin-bottom: 5px; color: var(--text); font-size: 12px; }
.source-list { display: flex; flex-wrap: wrap; gap: 8px; }
.source-pill { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: #515154; font-size: 11px; font-weight: 600; }
.source-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.source-pill.official::after { content: "Oficial"; color: var(--accent); font-size: 9px; }
.raw-details { margin-top: 25px; border-top: 1px solid var(--line); }
.raw-details summary { padding: 18px 0 0; color: var(--accent); cursor: pointer; font-size: 12px; font-weight: 650; }
.raw-toolbar { display: flex; justify-content: flex-end; margin: 10px 0 6px; }
.raw-details pre { max-height: 480px; margin: 0; padding: 18px; overflow: auto; border-radius: 14px; color: #f0dce5; background: #17191d; font-size: 11px; line-height: 1.55; }
.notice { margin-top: 14px; padding: 12px 14px; border-radius: 12px; color: var(--orange); background: rgba(245,158,11,.09); font-size: 12px; line-height: 1.45; }

.docs-heading { padding: 38px 0 20px; text-align: left; }
.docs-heading h2 { margin: 0; font-size: 28px; letter-spacing: -.7px; }
.docs-heading > p:last-child { margin: 7px 0 0; color: var(--muted); font-size: 14px; }
.endpoint-card { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px 16px; border-radius: var(--radius-lg); }
.endpoint-card > div { display: flex; align-items: center; gap: 13px; min-width: 0; }
.method { padding: 6px 9px; border-radius: 8px; color: #08743c; background: rgba(40,167,69,.11); font-size: 11px; font-weight: 800; }
.endpoint-card code { overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.copy-button { padding: 7px 11px; border: 0; border-radius: 9px; color: var(--accent); background: var(--accent-soft); cursor: pointer; font-size: 11px; font-weight: 650; }
.copy-button.dark { color: #ffb3d9; background: rgba(255,102,209,.13); }
.docs-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 16px; }
.doc-card { padding: 17px; border-radius: var(--radius-lg); }
.step-number { display: block; margin-bottom: 14px; color: var(--accent); font-size: 11px; font-weight: 750; }
.doc-card h3 { margin: 0 0 9px; font-size: 18px; letter-spacing: -.3px; }
.doc-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.doc-card p code { color: #515154; font-size: 12px; }
.header-line { margin: 13px 0 9px; padding: 9px 10px; overflow: auto; border: 1px solid var(--line); border-radius: 7px; background: rgba(118,118,128,.06); font-size: 11px; white-space: nowrap; }
.doc-note { font-size: 11px !important; }
.code-card { margin-top: 16px; overflow: hidden; border-radius: var(--radius-lg); background: #17191d; border-color: #272a30; }
.code-header { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 11px 14px; border-bottom: 1px solid rgba(255,255,255,.08); }
.code-tabs { display: flex; gap: 4px; overflow-x: auto; }
.code-tab { padding: 7px 10px; border: 0; border-radius: 8px; color: #92969d; background: transparent; cursor: pointer; font-size: 11px; }
.code-tab.active { color: #ffb3d9; background: rgba(255,102,209,.13); }
.code-card pre { min-height: 150px; margin: 0; padding: 18px; overflow: auto; color: #f0dce5; font-size: 11px; line-height: 1.65; }
.response-grid { align-items: stretch; }
.response-list, .status-list { margin: 18px 0 0; padding: 0; list-style: none; }
.response-list li { display: grid; grid-template-columns: 130px 1fr; gap: 8px; padding: 10px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.4; }
.response-list code { color: var(--accent); }
.status-list li { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.http-code { min-width: 40px; padding: 4px 6px; border-radius: 7px; text-align: center; font: 700 10px ui-monospace, monospace; }
.http-code.success { color: #08743c; background: rgba(40,167,69,.1); }
.http-code.warning { color: var(--orange); background: rgba(245,158,11,.1); }
.http-code.danger { color: var(--red); background: rgba(217,45,32,.09); }
.security-note { display: flex; gap: 14px; margin-top: 16px; padding: 20px 22px; border: 1px solid rgba(220,81,136,.18); border-radius: var(--radius-lg); background: #fff7f5; }
.security-note svg { width: 23px; height: 23px; flex: 0 0 auto; fill: none; stroke: var(--accent); stroke-width: 1.7; }
.security-note strong { font-size: 13px; }
.security-note p { margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }

footer { width: min(100% - 32px, 820px); display: flex; justify-content: space-between; gap: 20px; margin: 0 auto; padding: 20px 0 28px; border-top: 1px solid var(--line); color: #929296; font-size: 11px; }

@media (max-width: 760px) {
  .site-header { height: 52px; grid-template-columns: 1fr auto; padding: 0 14px; }
  .desktop-nav { display: none; }
  .api-status { font-size: 0; }
  main { width: min(100% - 24px, 1040px); }
  .hero { padding: 30px 2px 18px; }
  .hero h1 { font-size: 25px; letter-spacing: -.6px; }
  .hero-copy { font-size: 13px; }
  .mobile-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-bottom: 14px; padding: 4px; border-radius: 13px; background: rgba(118,118,128,.09); }
  .mobile-tab { padding: 9px; border-radius: 10px; }
  .mobile-tab.active { color: var(--accent); background: var(--accent-soft); box-shadow: 0 1px 5px rgba(0,0,0,.08); }
  .search-card { padding: 14px; border-radius: 12px; }
  .token-row { align-items: flex-start; }
  .token-tools { gap: 10px; }
  .search-row { flex-direction: column; }
  .primary-button { width: 100%; }
  .search-footer { align-items: flex-start; flex-direction: column; }
  .examples { width: 100%; flex-wrap: wrap; }
  .product-hero { grid-template-columns: 82px 1fr; gap: 16px; padding: 20px; }
  .product-image { width: 82px; height: 82px; border-radius: 16px; }
  .confidence { display: none; }
  .product-body { padding: 20px; }
  .field-grid { grid-template-columns: 1fr 1fr; }
  .docs-heading { padding: 38px 0 24px; }
  .docs-grid { grid-template-columns: 1fr; }
  .endpoint-card { align-items: flex-start; }
  .endpoint-card > div { align-items: flex-start; flex-direction: column; }
  .code-header { align-items: flex-start; flex-direction: column; }
  .code-card pre { padding: 19px; font-size: 11px; }
  footer { flex-direction: column; padding-bottom: 28px; }
}

@media (max-width: 430px) {
  .remember-token { display: none; }
  .field-grid { grid-template-columns: 1fr; }
  .product-title { font-size: 20px; }
  .response-list li { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* Compact pill controls share the icon's warm palette. */
.desktop-nav, .mobile-tabs,
button.nav-link, button.mobile-tab, button.primary-button,
button.text-button, .examples button, button.copy-button,
button.icon-copy, button.code-tab { border-radius: 999px; }
button:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent-focus);
  outline-offset: 3px;
}
.examples button { color: var(--accent); background: var(--accent-soft); }
.examples button:hover, .copy-button:hover, .text-button:hover { background: #ffe0ec; }
.copy-button.dark:hover { background: rgba(255,102,209,.22); }
.brand-mark, .brand-mark img { width: 32px; height: 32px; }
