.hl-page {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.hl-tabs {
  display: flex;
  gap: 0.4rem;
}

.hl-tabs button.is-active {
  font-weight: 700;
}

.hl-card {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding: 1rem;
  border: 1px solid rgba(16, 35, 58, 0.08);
  border-radius: 0.9rem;
  background: white;
}

.hl-card label,
.hl-drop {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.hl-thumb,
.hl-flyer {
  max-width: 100%;
  height: auto;
  border-radius: 0.6rem;
}

.hl-list {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.hl-list button,
.hl-actions {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
}

.hl-status {
  padding: 0.9rem 1rem;
  border-radius: 0.8rem;
  background: #10233a;
  color: #fff;
}

.hl-status p {
  margin: 0.35rem 0 0;
}

.hl-status.is-working strong::after {
  content: '';
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  margin-left: 0.45rem;
  border-radius: 50%;
  background: #7dcea0;
  animation: hl-pulse 1.2s ease-in-out infinite;
}

@keyframes hl-pulse {
  50% { opacity: 0.35; }
}

.hl-note,
.hl-banner {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.hl-banner {
  padding: 0.7rem 0.85rem;
  border-radius: 0.8rem;
  background: rgba(232, 215, 181, 0.45);
  border: 1px solid rgba(16, 35, 58, 0.08);
}

.hl-error {
  color: var(--alert);
  margin: 0;
}

.hl-editor {
  display: grid;
  grid-template-columns: 11rem minmax(0, 1fr) 18rem;
  grid-template-rows: auto minmax(28rem, 1fr) auto;
  gap: 0.7rem;
  min-height: calc(100dvh - 8.5rem);
}

.hl-header,
.hl-footer,
.hl-editor > .hl-banner,
.hl-editor > .hl-error {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  align-items: center;
  justify-content: space-between;
}

.hl-identity {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: end;
}

.hl-identity label,
.hl-inspector label,
.hl-form label {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  font-size: 0.78rem;
  color: var(--ink-soft);
}

.hl-identity input,
.hl-identity select,
.hl-inspector input,
.hl-inspector select,
.hl-inspector textarea,
.hl-form input,
.hl-form select,
.hl-form textarea {
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0.55rem;
  padding: 0.4rem 0.5rem;
  min-width: 0;
}

.hl-tools,
.hl-inspector,
.hl-footer,
.hl-header,
.hl-card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 0.9rem;
  padding: 0.7rem;
}

.hl-tools {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.hl-tools button,
.hl-tool {
  text-align: left;
  min-height: 2.4rem;
}

.hl-tool.is-active {
  background: var(--sea);
  color: white;
  border-color: var(--sea-deep);
}

.hl-stage {
  position: relative;
  min-height: 28rem;
  border-radius: 0.9rem;
  overflow: hidden;
  background: #10233a;
}

.hl-stage canvas {
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
  cursor: crosshair;
}

.hl-illustration {
  position: absolute;
  left: 0.6rem;
  bottom: 0.6rem;
  color: white;
  background: rgba(8, 20, 36, 0.72);
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.75rem;
}

.hl-inspector {
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.hl-inspector h2,
.hl-card h2 {
  margin: 0;
  font-size: 1rem;
}

.hl-footer strong {
  font-size: 1.05rem;
}

.hl-actions,
.hl-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.hl-list {
  display: grid;
  gap: 0.5rem;
}

.hl-list a {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0.85rem;
  border-radius: 0.8rem;
  border: 1px solid var(--line);
  background: white;
  color: inherit;
  text-decoration: none;
}

.hl-proposal {
  display: grid;
  gap: 0.35rem;
}

.hl-proposal .hl-internal {
  border-top: 1px dashed var(--line);
  padding-top: 0.5rem;
}

@media (max-width: 980px) {
  .hl-editor {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto minmax(24rem, 60dvh) auto auto;
  }

  .hl-tools {
    flex-direction: row;
    overflow-x: auto;
  }

  .hl-tool {
    flex: 0 0 auto;
  }
}

@media print {
  .sidebar,
  .topbar,
  .hl-tools,
  .hl-footer,
  .hl-actions,
  .mobile-topbar {
    display: none !important;
  }

  .hl-editor {
    display: block;
  }
}
