.ltq-root {
  --ltq-accent: #b42318;
  --ltq-accent-strong: #8f1d14;
  --ltq-accent-soft: rgba(180, 35, 24, 0.08);
  --ltq-bg: #fffaf8;
  --ltq-panel: #ffffff;
  --ltq-text: #1f2937;
  --ltq-muted: #6b7280;
  --ltq-border: rgba(180, 35, 24, 0.18);
  --ltq-border-soft: rgba(180, 35, 24, 0.1);
  --ltq-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
  --ltq-shadow-strong: 0 18px 44px rgba(15, 23, 42, 0.16);
  --ltq-radius: 22px;
  --ltq-dock-gap: 10px;
  --ltq-safe-bottom: env(safe-area-inset-bottom, 0px);

  position: relative;
  color: var(--ltq-text);
  font: inherit;
  background:
    linear-gradient(180deg, rgba(180, 35, 24, 0.04), rgba(180, 35, 24, 0.01) 220px),
    var(--ltq-bg);
  border: 2px solid var(--ltq-border);
  border-radius: var(--ltq-radius);
  box-shadow: var(--ltq-shadow);
  padding: 22px;
  overflow: visible;
}

.ltq-header {
  display: grid;
  gap: 14px;
  margin-bottom: 16px;
}

.ltq-cover-wrap {
  position: relative;
  margin-bottom: 6px;
}

.ltq-cover-wrap.ltq-coverless {
  min-height: 0;
  margin-bottom: 0;
}

.ltq-label {
  position: absolute;
  top: -14px;
  left: 24px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  background: linear-gradient(180deg, #c9372c, var(--ltq-accent));
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.16em;
  box-shadow: 0 10px 22px rgba(180, 35, 24, 0.2);
}

.ltq-cover-wrap.ltq-coverless .ltq-label {
  position: static;
  margin-bottom: 4px;
}

.ltq-cover {
  width: 100%;
  height: auto;
  max-height: 300px;
  object-fit: cover;
  border-radius: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  display: block;
}

.ltq-title {
  margin: 0;
  font-size: 30px;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-align: center;
}

.ltq-title-divider {
  width: min(180px, 45%);
  height: 3px;
  margin: -4px auto 0;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(180, 35, 24, 0.14),
    var(--ltq-accent),
    rgba(180, 35, 24, 0.14)
  );
}

.ltq-meta {
  color: var(--ltq-muted);
  font-size: 15px;
  text-align: center;
}

.ltq-sticky-bar {
  display: grid;
  gap: 12px;
  position: relative;
  width: 100%;
  box-sizing: border-box;
}

.ltq-sticky-placeholder {
  display: none !important;
  height: 0 !important;
}

.ltq-floating-dock {
  position: fixed;
  z-index: 999999;
  pointer-events: none;
  display: none;
  bottom: 0;
  left: 0;
  width: auto;
  padding-bottom: calc(var(--ltq-safe-bottom) + var(--ltq-dock-gap));
}

.ltq-floating-dock.is-active {
  display: block;
}

.ltq-floating-dock .ltq-sticky-bar {
  pointer-events: auto;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 12px;
  border-radius: 22px;
  background: linear-gradient(180deg, #fff8f6, #fffdfc);
  border: 2px solid rgba(180, 35, 24, 0.2);
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.18);
  position: relative;
}

.ltq-floating-dock .ltq-sticky-bar::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 5px;
  border-radius: 22px 22px 0 0;
  background: linear-gradient(90deg, var(--ltq-accent), #d94a38);
}

.ltq-global-input {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  display: block;
  box-sizing: border-box;
  padding: 15px 18px;
  border-radius: 16px;
  border: 1px solid #d8dee6;
  background: #ffffff;
  font: inherit;
  font-size: 17px;
  line-height: 1.2;
  color: var(--ltq-text);
  outline: none;
  transition: box-shadow 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.ltq-global-input:focus {
  border-color: rgba(180, 35, 24, 0.38);
  box-shadow: 0 0 0 4px rgba(180, 35, 24, 0.08);
}

.ltq-global-input:disabled {
  background: rgba(0, 0, 0, 0.03);
  color: rgba(0, 0, 0, 0.45);
}

.ltq-controls {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.ltq-btn {
  border: 1px solid #d8dee6;
  background: #ffffff;
  color: var(--ltq-text);
  padding: 11px 16px;
  border-radius: 999px;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.06s ease, box-shadow 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.ltq-btn:hover {
  background: #f9fafb;
  border-color: #cfd6df;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
}

.ltq-btn:active {
  transform: translateY(1px);
}

.ltq-btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}

.ltq-btn-start {
  min-width: min(100%, 320px);
  padding: 16px 28px;
  border: none;
  background: linear-gradient(180deg, #c9372c, var(--ltq-accent));
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(180, 35, 24, 0.18);
}

.ltq-btn-start:hover {
  background: linear-gradient(180deg, #d94a38, var(--ltq-accent-strong));
}

.ltq-root.ltq-has-started .ltq-btn-start {
  min-width: auto;
  padding: 11px 16px;
  font-size: 14px;
  box-shadow: none;
  background: #ffffff;
  color: var(--ltq-text);
  border: 1px solid #d8dee6;
}

.ltq-btn-danger {
  background: #fff6f4;
  border-color: rgba(180, 35, 24, 0.2);
  color: #9f271d;
}

.ltq-btn-danger:hover {
  background: rgba(180, 35, 24, 0.07);
  border-color: rgba(180, 35, 24, 0.3);
}

.ltq-btn-pin {
  border-color: rgba(180, 35, 24, 0.16);
  background: #fff8f6;
  color: var(--ltq-text);
}

.ltq-btn-pin[aria-pressed="true"] {
  background: rgba(180, 35, 24, 0.08);
  border-color: rgba(180, 35, 24, 0.28);
  box-shadow: inset 0 0 0 1px rgba(180, 35, 24, 0.06);
}

.ltq-timer {
  padding: 9px 13px;
  border-radius: 999px;
  border: 1px solid #d8dee6;
  background: #ffffff;
  color: #111827;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 15px;
  font-weight: 700;
}

.ltq-table-wrap {
  overflow-x: visible;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  background: var(--ltq-panel);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.ltq-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  min-width: 0;
}

.ltq-table th,
.ltq-table td {
  padding: 13px 14px;
  border-bottom: 1px solid #eef1f4;
  vertical-align: middle;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.ltq-table th {
  text-align: left;
  font-size: 13px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #374151;
  background: #f3f4f6;
  font-weight: 800;
}

.ltq-table tbody tr:nth-child(odd) td {
  background: #ffffff;
}

.ltq-table tbody tr:nth-child(even) td {
  background: #fafafa;
}

.ltq-table tbody tr:hover td {
  background: #f9fafb;
}

.ltq-table tbody tr:last-child td {
  border-bottom: none;
}

.ltq-answer-cell,
.ltq-correct {
  font-weight: 800;
  letter-spacing: -0.01em;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.ltq-answer-cell.ltq-ok {
  background: #e7f6ee !important;
  color: #166534;
}

.ltq-answer-cell.ltq-bad {
  background: #fdecec !important;
  color: #b42318;
}

.ltq-results {
  margin-top: 14px;
  display: grid;
  gap: 6px;
}

.ltq-score {
  font-size: 17px;
  font-weight: 800;
  color: #111827;
}

.ltq-avg,
.ltq-note {
  color: #4b5563;
  font-size: 14px;
}

.ltq-error {
  color: #b42318;
  font-weight: 700;
}

@media (max-width: 900px) {
  .ltq-root {
    padding: 16px;
  }

  .ltq-title {
    font-size: 28px;
  }

  .ltq-meta {
    font-size: 14px;
  }

  .ltq-floating-dock .ltq-sticky-bar {
    border-radius: 18px;
    padding: 10px;
  }

  .ltq-floating-dock .ltq-sticky-bar::before {
    border-radius: 18px 18px 0 0;
  }

  .ltq-table th,
  .ltq-table td {
    padding: 10px 12px;
  }
}

@media (max-width: 640px) {
  .ltq-root {
    padding: 12px;
    border-radius: 18px;
  }

  .ltq-label {
    left: 12px;
    top: -10px;
    min-height: 32px;
    padding: 0 13px;
    font-size: 11px;
  }

  .ltq-title {
    font-size: 22px;
  }

  .ltq-meta {
    font-size: 12px;
  }

  .ltq-global-input {
    font-size: 14px;
    padding: 13px 14px;
  }

  .ltq-btn {
    font-size: 11px;
    padding: 9px 12px;
  }

  .ltq-btn-start {
    width: 100%;
    font-size: 16px;
  }

  .ltq-timer {
    font-size: 13px;
    padding: 8px 11px;
  }

  .ltq-controls {
    gap: 7px;
  }

  .ltq-table th,
  .ltq-table td {
    padding: 9px 10px;
    font-size: 12px;
  }

  .ltq-table th {
    font-size: 11px;
  }
}