/* Motion scale from the local Design Skill reference; no blurred data states. */
:root {
  --duration-quick: 150ms;
  --duration-fast: 250ms;
  --duration-medium: 350ms;
  --duration-very-slow: 500ms;
  --ease-smooth-out: cubic-bezier(.22, 1, .36, 1);
  --ht-sand-cycle: 1400ms;
}
.ht-load-state {
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 40px 24px;
  text-align: left;
  border: 1px solid var(--hairline, rgba(215, 180, 90, .18));
  border-radius: 14px;
  background: var(--surface-1, rgba(215, 180, 90, .025));
}
.ht-loading-icon, .ht-state-icon > svg {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  color: #b89b4b;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ht-sand-top, .ht-sand-base { fill: currentColor; stroke: none; opacity: .45; }
.ht-loading-grain { fill: currentColor; stroke: none; animation: ht-sand-drop var(--ht-sand-cycle) linear infinite; }
.grain-two { animation-delay: -700ms; }
@keyframes ht-sand-drop {
  0% { transform: translateY(0); opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { transform: translateY(10px); opacity: 0; }
}
.ht-state-title { margin: 0; color: var(--text-primary, #e7e8de); font: 600 15px/1.45 'Manrope', sans-serif; }
.ht-state-copy { margin: 6px 0 0; max-width: 48ch; color: var(--ink-secondary, #9ba098); font: 400 13px/1.6 'DM Sans', sans-serif; }
.ht-state-action { margin-top: 15px; border: 1px solid currentColor; border-radius: 8px; background: transparent; padding: 8px 14px; color: #b89b4b; font: inherit; cursor: pointer; }
.ht-state-action:focus-visible { outline: 2px solid #d7b45a; outline-offset: 3px; }
.ht-state-error .ht-loading-grain { animation: none; }
.ht-state-error .ht-loading-icon { color: var(--negative, #c96e61); }
.ht-state-locked { min-height: 280px; }
#tools-access-status { grid-column: 1 / -1; margin-bottom: 16px; }
#tools-access-status .ht-load-state { min-height: 76px; padding: 15px 22px; justify-content: flex-start; }
#tools-access-status .ht-state-copy { display: none; }
#tools-access-status .ht-loading-icon { width: 28px; height: 28px; }
#tools-access-status[hidden] { display: none; }
body.tools-locked .panel:not(.panel-free) .footnote,
body.tools-locked .panel:not(.panel-free) .rotate-hint,
body.tools-locked .panel:not(.panel-free) .statstrip,
body.tools-locked .panel:not(.panel-free) .viewtoggle,
body.tools-locked .panel:not(.panel-free) .stoggle,
body.tools-locked .panel:not(.panel-free) .section-gap { display: none; }
.ht-auth-feedback {
  position: fixed;
  z-index: 10000;
  left: 50%;
  bottom: max(32px, env(safe-area-inset-bottom));
  width: min(430px, calc(100vw - 32px));
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  border: 1px solid rgba(215, 180, 90, .42);
  border-radius: 18px;
  background: linear-gradient(135deg, #171b14, #0d100c);
  box-shadow: 0 20px 64px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255, 255, 255, .05);
  transform: translateX(-50%);
  animation: ht-confirm-in var(--duration-medium) var(--ease-smooth-out) both;
}
.ht-success-seal { flex: 0 0 42px; color: #d7b45a; }
.ht-success-seal svg { display: block; width: 42px; height: 42px; stroke: currentColor; stroke-width: 1.5; }
.ht-success-seal circle { opacity: .4; }
.ht-success-seal path { stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; stroke-dashoffset: 1; animation: ht-confirm-check var(--duration-very-slow) var(--ease-smooth-out) var(--duration-quick) forwards; }
.ht-success-title { margin: 0 0 5px; color: #f2eedf; font: 600 16px/1.35 'Manrope', sans-serif; }
.ht-success-message { margin: 0; color: #b1b6a9; font: 400 13px/1.55 'DM Sans', sans-serif; }
@keyframes ht-confirm-in { from { opacity: 0; transform: translate(-50%, 12px) scale(.97); } to { opacity: 1; transform: translate(-50%, 0) scale(1); } }
@keyframes ht-confirm-check { to { stroke-dashoffset: 0; } }
@media (max-width: 600px) {
  .ht-load-state { min-height: 200px; padding: 28px 18px; gap: 14px; }
  .ht-auth-feedback { bottom: max(18px, env(safe-area-inset-bottom)); padding: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .ht-loading-grain, .ht-auth-feedback, .ht-success-seal path { animation: none; }
  .ht-success-seal path { stroke-dashoffset: 0; }
}
