/* =====================================================================
   FONT LAB — live Google Fonts preview panel (dev tool)
   Deliberately uses system fonts + its own colors so the panel stays
   readable no matter which fonts are being previewed on the page.
   ===================================================================== */

/* Panel chrome is pinned to system fonts so it stays readable while the page
   is being restyled — but the per-role sample lines are exempt, since their
   whole job is to render in the font being previewed. */
.fontlab,
.fontlab *:not(.fontlab__sample) {
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif !important;
  box-sizing: border-box;
}

.fontlab__sample {
  box-sizing: border-box;
}

.fontlab__toggle {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 99998;
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -.02em;
  color: #fff;
  background: #FF3D2E;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, .6);
  transition: transform .2s ease, box-shadow .2s ease;
}

.fontlab__toggle:hover {
  transform: translateY(-2px) scale(1.05);
}

.fontlab__panel {
  position: fixed;
  right: 18px;
  bottom: 80px;
  z-index: 99999;
  width: min(340px, calc(100vw - 36px));
  max-height: min(78vh, 720px);
  overflow-y: auto;
  padding: 16px;
  color: #ECEAE6;
  background: #16161a;
  border: 1px solid #33333c;
  border-radius: 14px;
  box-shadow: 0 24px 60px -18px rgba(0, 0, 0, .8);
  font-size: 13px;
  line-height: 1.4;
}

.fontlab__panel[hidden] {
  display: none;
}

.fontlab__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.fontlab__title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #FF3D2E;
}

.fontlab__close {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  font-size: 16px;
  color: #9a9aa6;
  background: transparent;
  border: 1px solid #33333c;
  border-radius: 6px;
  cursor: pointer;
}

.fontlab__close:hover {
  color: #fff;
  border-color: #FF3D2E;
}

.fontlab__row {
  margin-bottom: 13px;
}

.fontlab__label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 5px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #8e8e9a;
}

.fontlab__sync {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 9px;
  letter-spacing: .06em;
  color: #8e8e9a;
  cursor: pointer;
  text-transform: none;
}

.fontlab__sync input {
  accent-color: #FF3D2E;
  margin: 0;
}

.fontlab__input {
  width: 100%;
  padding: 8px 10px;
  color: #fff;
  background: #0e0e12;
  border: 1px solid #33333c;
  border-radius: 7px;
  font-size: 13px;
}

.fontlab__input:focus {
  outline: none;
  border-color: #FF3D2E;
}

.fontlab__input:disabled {
  opacity: .4;
  cursor: not-allowed;
}

.fontlab__sample {
  margin-top: 5px;
  font-size: 15px;
  color: #6f6f7d;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fontlab__range {
  display: flex;
  align-items: center;
  gap: 9px;
}

.fontlab__range input[type=range] {
  flex: 1;
  accent-color: #FF3D2E;
}

.fontlab__val {
  min-width: 34px;
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: #b9b9c4;
}

.fontlab__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #2a2a33;
}

.fontlab__btn {
  padding: 9px 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: #ECEAE6;
  background: #24242c;
  border: 1px solid #3a3a45;
  border-radius: 7px;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}

.fontlab__btn:hover {
  border-color: #FF3D2E;
  color: #fff;
}

.fontlab__btn--primary {
  background: #FF3D2E;
  border-color: #FF3D2E;
  color: #fff;
}

.fontlab__btn--primary:hover {
  background: #ff5745;
}

.fontlab__note {
  margin-top: 10px;
  font-size: 10.5px;
  line-height: 1.5;
  color: #6f6f7d;
}

.fontlab__note kbd {
  padding: 1px 5px;
  font-size: 10px;
  background: #24242c;
  border: 1px solid #3a3a45;
  border-radius: 4px;
}

@media (max-width: 600px) {
  .fontlab__panel {
    right: 10px;
    left: 10px;
    width: auto;
  }
}
