/* Warm brown / gold palette unchanged; lighter styling (no backdrop blur / heavy shadows / webfonts) for faster UI. */

:root {
  --background: 30 15% 12%;
  --foreground: 40 30% 90%;
  --card: 30 12% 16%;
  --primary: 40 65% 55%;
  --primary-foreground: 30 15% 10%;
  --secondary: 30 10% 22%;
  --muted-bg: 30 8% 20%;
  --muted-foreground: 30 10% 55%;
  --accent: 40 65% 55%;
  --border: 30 10% 25%;
  --input: 30 10% 25%;
  --ring: 40 65% 55%;
  --gold: 40 65% 55%;
  --gold-glow: 40 80% 65%;
  --radius: 0.75rem;
  /* Legacy aliases */
  --text: hsl(var(--foreground));
  --border-hsl: hsl(var(--border));
  --surface: hsla(30, 12%, 14%, 0.75);
  --accent-legacy: hsl(var(--primary));
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  font-family: system-ui, -apple-system, "PingFang TC", "Microsoft JhengHei", sans-serif;
  color: hsl(var(--foreground));
  line-height: 1.5;
}

.global-back-btn {
  position: fixed;
  top: 0.8rem;
  left: 0.8rem;
  z-index: 220;
  border: 1px solid hsl(var(--border));
  background: hsl(var(--secondary));
  color: hsl(var(--foreground));
  border-radius: 999px;
  padding: 0.35rem 0.72rem;
  font-size: 0.8rem;
  cursor: pointer;
}

.global-logout-btn {
  position: fixed;
  top: max(0.8rem, env(safe-area-inset-top, 0px));
  right: max(0.8rem, env(safe-area-inset-right, 0px));
  z-index: 220;
  border: 1px solid hsl(0 45% 38% / 0.45);
  background: hsl(0 35% 18% / 0.92);
  color: hsl(0 60% 88%);
  border-radius: 999px;
  padding: 0.35rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 10px hsl(0 0% 0% / 0.35);
}

.global-logout-btn:hover {
  background: hsl(0 40% 22% / 0.96);
  border-color: hsl(0 50% 45% / 0.55);
}

.global-logout-btn:disabled {
  opacity: 0.65;
  cursor: wait;
}

.font-serif-cn {
  font-family: "Songti SC", "STSong", "SimSun", "PingFang TC", serif;
}

/* Shell (matches Client_selection App + Index) */
.app-root {
  position: relative;
  min-height: 100%;
  overflow-x: hidden;
}

.app-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background-color: hsl(30 18% 8%);
  /* Layered: optional photo + splash-style wash + deep warmth (place splash-bg.png in static/ to match React app) */
  background-image:
    linear-gradient(
      145deg,
      rgba(45, 32, 22, 0.42) 0%,
      rgba(60, 48, 36, 0.52) 50%,
      rgba(35, 28, 20, 0.48) 100%
    ),
    radial-gradient(ellipse 120% 80% at 50% -20%, rgba(120, 90, 50, 0.25) 0%, transparent 55%),
    linear-gradient(180deg, hsl(28 16% 14%) 0%, hsl(25 18% 9%) 45%, hsl(22 20% 7%) 100%);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Drop ``static/splash-bg.png`` beside this project if you want the same photo layer as Client_selection; then add:
   .app-bg { background-image: url("/static/splash-bg.png"), linear-gradient(...); background-size: cover, cover; }
*/

.app-overlay {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: hsl(var(--background) / 0.75);
}

.app-content {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.app-map {
  position: relative;
  z-index: 2;
  width: min(880px, calc(100% - 5rem));
  max-width: 880px;
  margin: 0 auto;
  padding: 3rem 4.75rem 1.25rem 0.85rem;
}

.app-map[hidden],
.app-content[hidden],
#panel-saved[hidden] {
  display: none !important;
}

.app-map__panel {
  border-radius: 0.75rem;
  border: 1px solid hsla(40, 65%, 55%, 0.24);
  background: hsl(30 12% 14%);
  padding: 0.65rem;
}

.app-map__hint {
  margin: 0 0 0.55rem;
  font-size: 0.8rem;
  color: hsl(var(--muted-foreground));
}

.app-map__route {
  position: relative;
  min-height: min(46vh, 420px);
  max-height: min(46vh, 420px);
  border-radius: 0.7rem;
  border: 1px solid hsla(40, 65%, 55%, 0.15);
  background:
    radial-gradient(circle at 10% 10%, rgba(212, 170, 92, 0.16), transparent 24%),
    radial-gradient(circle at 90% 20%, rgba(163, 121, 58, 0.14), transparent 30%),
    linear-gradient(0deg, transparent 34px, rgba(94, 70, 42, 0.22) 35px),
    linear-gradient(90deg, transparent 34px, rgba(94, 70, 42, 0.22) 35px),
    hsl(28 18% 11%);
  background-size: auto, auto, 35px 35px, 35px 35px, auto;
  overflow: hidden;
}

.app-map__stats {
  position: absolute;
  top: 0.65rem;
  left: 0.65rem;
  display: flex;
  gap: 0.45rem;
  z-index: 5;
}

.app-map__chip {
  border: 1px solid hsl(var(--border));
  border-radius: 999px;
  padding: 0.25rem 0.55rem;
  font-size: 0.74rem;
  color: hsl(var(--foreground));
  background: hsla(30, 12%, 14%, 0.9);
}

.app-map__tile {
  position: absolute;
  width: 92px;
  height: 92px;
  border: 1px solid hsla(40, 50%, 65%, 0.22);
  border-radius: 0.75rem;
  background:
    linear-gradient(180deg, hsla(38, 28%, 34%, 0.28), transparent 38%),
    linear-gradient(180deg, hsla(32, 20%, 22%, 0.96), hsla(30, 18%, 15%, 0.96));
  color: hsl(var(--foreground));
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: transform 160ms ease, border-color 140ms ease, box-shadow 160ms ease;
}

.app-map__tile:hover {
  transform: translateY(-2px);
  border-color: hsla(40, 65%, 65%, 0.42);
}

.app-map__tile.active {
  transform: translateY(-1px) scale(1.05);
  border-color: hsl(40 65% 55%);
  box-shadow: 0 0 0 3px hsla(40, 65%, 55%, 0.24), 0 16px 26px rgba(0, 0, 0, 0.3);
}

.app-map__tile-icon {
  width: 30px;
  height: 30px;
  border-radius: 0.6rem;
  border: 1px solid hsla(40, 40%, 75%, 0.28);
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.2), transparent 58%),
    linear-gradient(145deg, hsla(40, 35%, 48%, 0.32), hsla(35, 22%, 24%, 0.3));
  display: flex;
  align-items: center;
  justify-content: center;
}

.app-map__tile-icon svg {
  width: 18px;
  height: 18px;
  stroke: hsl(var(--foreground));
  stroke-width: 2;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.app-map__character {
  position: absolute;
  width: 44px;
  height: 44px;
  left: 120px;
  top: 120px;
  transform-origin: 50% 50%;
  transition: left 120ms linear, top 120ms linear, transform 180ms ease;
  z-index: 6;
}

.app-map__glow {
  position: absolute;
  inset: -12px;
  border-radius: 50%;
  background: hsla(40, 65%, 55%, 0.18);
  animation: pulse-ring 1.7s ease-out infinite;
}

.app-map__toast {
  position: absolute;
  left: 50%;
  bottom: 0.9rem;
  transform: translateX(-50%);
  border-radius: 999px;
  border: 1px solid hsla(40, 65%, 55%, 0.36);
  background: hsla(28, 20%, 14%, 0.95);
  color: hsl(var(--foreground));
  font-size: 0.8rem;
  padding: 0.42rem 0.78rem;
  opacity: 0;
  transition: opacity 180ms ease, transform 180ms ease;
}

.app-map__toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(-4px);
}

@media (max-width: 640px) {
  .app-map {
    width: calc(100% - 1.25rem);
    padding: 2.75rem 3.5rem 1rem 0.65rem;
  }

  .app-map__route {
    min-height: min(42vh, 340px);
    max-height: min(42vh, 340px);
  }

  .app-map__stats {
    flex-wrap: wrap;
    max-width: calc(100% - 0.5rem);
  }
}

.export-upload-group {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.export-wrap {
  position: relative;
  display: inline-flex;
}

.export-popover {
  position: absolute;
  right: 0;
  top: 100%;
  margin-top: 0.55rem;
  width: 320px;
  max-width: min(360px, calc(100vw - 1.2rem));
  z-index: 30;
  border: 1px solid hsla(40, 65%, 55%, 0.3);
  border-radius: 0.8rem;
  background: hsl(30 12% 14%);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.42);
  padding: 0.9rem;
}

.export-popover__title {
  margin: 0 0 0.7rem;
  color: hsl(var(--gold));
  font-size: 1rem;
}

.export-popover__actions {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}

/* Collect timeframe — matches notice-editor / glass-panel gold theme */
.collect-panel {
  margin: 0 0 1rem;
  padding: 0;
  border: 1px solid hsla(40, 65%, 55%, 0.32);
  border-radius: var(--radius);
  background: linear-gradient(
    165deg,
    hsla(40, 35%, 18%, 0.55) 0%,
    hsla(30, 12%, 12%, 0.92) 48%
  );
  box-shadow: inset 0 1px 0 hsla(40, 80%, 75%, 0.08);
  overflow: hidden;
}

.collect-panel[hidden] {
  display: none !important;
}

.collect-panel__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem 0.65rem;
  border-bottom: 1px solid hsla(40, 65%, 55%, 0.18);
  background: hsla(30, 12%, 10%, 0.35);
}

.collect-panel__heading {
  flex: 1;
  min-width: 0;
  text-align: center;
}

.collect-panel__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: hsl(var(--gold));
}

.collect-panel__line {
  margin: 0.45rem auto 0.5rem;
  height: 1px;
  width: 4.5rem;
  background: linear-gradient(90deg, transparent, hsl(var(--primary)), transparent);
  opacity: 0.85;
}

.collect-panel__hint {
  margin: 0;
  max-width: 28rem;
  margin-inline: auto;
  font-size: 0.8rem;
  color: hsl(var(--muted-foreground));
  line-height: 1.45;
}

.collect-panel__hint code {
  font-size: 0.88em;
  color: hsl(var(--gold-glow));
}

.collect-panel__close {
  flex: 0 0 auto;
  min-width: 2rem;
  margin-top: 0.1rem;
  border-radius: 999px;
  border-color: hsla(40, 65%, 55%, 0.35);
  color: hsl(var(--muted-foreground));
}

.collect-panel__close:hover:not(:disabled) {
  border-color: hsl(var(--primary));
  color: hsl(var(--gold-glow));
}

.collect-panel__body {
  padding: 0.75rem 0.85rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.collect-range-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.75rem;
  width: 100%;
  max-width: 22rem;
  margin-bottom: 0.5rem;
}

.collect-range-summary__item {
  flex: 1 1 7.5rem;
  min-width: 0;
  text-align: center;
}

.collect-range-summary__arrow {
  flex: 0 0 auto;
  color: hsl(var(--gold));
  font-size: 1.1rem;
  opacity: 0.85;
}

.collect-cal__pick-hint {
  margin: 0 0 0.55rem;
  font-size: 0.78rem;
  color: hsl(var(--gold-glow));
  text-align: center;
}

.collect-cal--range {
  max-width: 15.5rem;
  width: 100%;
}

.collect-range__badge {
  display: inline-block;
  margin-bottom: 0.35rem;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  border: 1px solid hsla(40, 65%, 55%, 0.45);
  background: hsla(40, 65%, 55%, 0.12);
  color: hsl(var(--gold-glow));
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.collect-range__badge--end {
  border-color: hsla(40, 50%, 45%, 0.4);
  background: hsla(30, 10%, 22%, 0.8);
  color: hsl(var(--foreground));
}

.collect-range__date {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  color: hsl(var(--foreground));
  line-height: 1.35;
}

.collect-cal {
  width: 100%;
  padding: 0.5rem 0.45rem 0.4rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid hsl(var(--border));
  background: hsla(30, 12%, 8%, 0.65);
}

.collect-cal__nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  margin-bottom: 0.4rem;
}

.collect-cal__nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  padding: 0;
  border-radius: 999px;
  border: 1px solid hsla(40, 65%, 55%, 0.35);
  background: hsla(40, 40%, 22%, 0.35);
  color: hsl(var(--gold));
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.collect-cal__nav-btn:hover {
  border-color: hsl(var(--primary));
  background: hsla(40, 65%, 55%, 0.18);
  color: hsl(var(--gold-glow));
}

.collect-cal__title {
  font-size: 0.84rem;
  font-weight: 600;
  color: hsl(var(--gold));
  letter-spacing: 0.02em;
}

.collect-cal__weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.12rem;
  margin-bottom: 0.2rem;
}

.collect-cal__weekday {
  text-align: center;
  font-size: 0.68rem;
  font-weight: 600;
  color: hsl(var(--muted-foreground));
}

.collect-cal__days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.15rem;
}

.collect-cal__day {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  min-height: 1.65rem;
  padding: 0;
  border-radius: 0.4rem;
  border: 1px solid transparent;
  background: transparent;
  color: hsl(var(--foreground));
  font: inherit;
  font-size: 0.76rem;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease, color 0.12s ease;
}

.collect-cal__day--blank {
  visibility: hidden;
  pointer-events: none;
}

.collect-cal__day--today:not(.collect-cal__day--selected) {
  border-color: hsla(40, 65%, 55%, 0.4);
  background: hsla(40, 50%, 30%, 0.12);
}

.collect-cal__day--in-range {
  background: hsla(40, 65%, 55%, 0.14);
  border-color: hsla(40, 65%, 55%, 0.2);
}

.collect-cal__day--range-start,
.collect-cal__day--range-end {
  border-color: hsl(var(--primary));
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  font-weight: 700;
  box-shadow: 0 0 0 1px hsla(40, 80%, 65%, 0.25);
}

.collect-cal__day--range-start.collect-cal__day--in-range,
.collect-cal__day--range-end.collect-cal__day--in-range {
  background: hsl(var(--primary));
}

.collect-cal__day:hover:not(.collect-cal__day--range-start):not(.collect-cal__day--range-end):not(.collect-cal__day--blank) {
  border-color: hsla(40, 65%, 55%, 0.45);
  background: hsla(40, 50%, 30%, 0.22);
}

.collect-times-grid {
  display: grid;
  gap: 0.65rem;
  width: 100%;
  max-width: 15.5rem;
  margin-top: 0.65rem;
}

@media (min-width: 28rem) {
  .collect-times-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
  }
}

.collect-time-group {
  padding: 0.45rem 0.5rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid hsla(40, 65%, 55%, 0.15);
  background: hsla(30, 12%, 10%, 0.45);
}

.collect-time-group__label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: hsl(var(--muted-foreground));
  text-align: center;
}

.collect-time-row {
  display: flex;
  gap: 0.5rem;
  width: 100%;
}

.collect-time-row__label {
  display: grid;
  gap: 0.25rem;
  flex: 1;
  min-width: 0;
  font-size: 0.72rem;
  font-weight: 600;
  color: hsl(var(--muted-foreground));
  letter-spacing: 0.06em;
}

.collect-panel__input {
  box-sizing: border-box;
  width: 100%;
  padding: 0.4rem 0.5rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid hsl(var(--border));
  background: hsla(30, 15%, 8%, 0.95);
  color: hsl(var(--foreground));
  font: inherit;
  font-size: 0.84rem;
  font-variant-numeric: tabular-nums;
}

.collect-panel__input:focus {
  outline: none;
  border-color: hsl(var(--primary));
  box-shadow: 0 0 0 2px hsla(40, 65%, 55%, 0.2);
}

.collect-panel__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  padding: 0.65rem 1rem 0.85rem;
  border-top: 1px solid hsla(40, 65%, 55%, 0.18);
  background: hsla(30, 12%, 10%, 0.35);
}

@media (min-width: 28rem) {
  .collect-panel__actions {
    justify-content: flex-end;
  }
}

.app-hero.page-header {
  position: relative;
  width: 100%;
  text-align: center;
  padding: 0.5rem 0 1.25rem;
  border-bottom: none;
}

.btn-back-map {
  position: absolute;
  top: 0;
  right: 0;
  padding: 0.35rem 0.72rem;
  font-size: 0.78rem;
}

.app-title {
  margin: 0;
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: hsl(var(--gold));
}

.app-user-badge {
  margin: 0.55rem auto 0;
  max-width: 36rem;
  padding: 0.38rem 0.95rem;
  border-radius: 999px;
  border: 1px solid hsla(40, 65%, 55%, 0.35);
  background: hsla(40, 50%, 45%, 0.1);
  color: hsl(var(--gold-glow));
  font-size: 0.84rem;
  font-weight: 500;
}

.app-title-en {
  margin: 0.35rem 0 0;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: hsl(var(--muted-foreground));
}

.hero-line {
  margin: 1rem auto 0;
  height: 1px;
  width: 6rem;
  background: linear-gradient(
    90deg,
    transparent,
    hsl(var(--primary)),
    transparent
  );
  opacity: 0.85;
}

.sub {
  margin: 1rem auto 0;
  max-width: 52rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.88rem;
}

.glass-panel {
  background: hsl(30 12% 14%);
  border: 1px solid hsla(40, 65%, 55%, 0.18);
}

.app-panel {
  width: 100%;
  border-radius: 0.5rem;
  padding: 1rem 1rem 1.25rem;
}

.app-panel main {
  margin: 0;
  padding: 0;
  max-width: none;
}

.app-footer {
  margin-top: auto;
  padding-top: 1.5rem;
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: hsl(var(--muted-foreground) / 0.45);
}

.btn {
  background: hsl(var(--secondary));
  color: hsl(var(--foreground));
  border: 1px solid hsl(var(--border));
  padding: 0.45rem 1rem;
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 0.875rem;
  font-family: inherit;
}

.btn:hover:not(:disabled) {
  border-color: hsl(var(--primary));
  color: hsl(var(--gold-glow));
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 1rem;
}

.btn-read {
  border-color: hsl(var(--primary));
  color: hsl(var(--gold));
  background: hsla(40, 65%, 55%, 0.08);
}

.btn-collect {
  border-color: hsla(40, 65%, 55%, 0.45);
  color: hsl(var(--gold-glow));
  background: hsla(40, 50%, 40%, 0.12);
}

.btn-collect-xiehui {
  border-color: hsla(200, 70%, 60%, 0.5);
  color: #bae6fd;
  background: hsla(200, 50%, 35%, 0.15);
}

.btn-collect-xiehui:hover:not(:disabled) {
  border-color: #7dd3fc;
  color: #e0f2fe;
  background: hsla(200, 55%, 40%, 0.22);
}

.collect-xiehui-panel .collect-xiehui-step[hidden] {
  display: none !important;
}

.collect-xiehui-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: hsl(var(--gold-glow));
}

.collect-xiehui-textarea {
  width: 100%;
  min-height: 12rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: 1px solid hsla(40, 40%, 50%, 0.35);
  background: hsla(220, 20%, 12%, 0.6);
  color: inherit;
  font-family: inherit;
  font-size: 0.92rem;
  line-height: 1.5;
  resize: vertical;
}

.collect-xiehui-summary {
  margin: 0 0 0.75rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.95rem;
}

.collect-xiehui-summary--warn {
  color: hsl(32 90% 38%);
  font-weight: 600;
}

.collect-xiehui-select-all-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.collect-xiehui-table-wrap {
  overflow: auto;
  max-height: min(50vh, 420px);
  margin-bottom: 1rem;
  border: 1px solid hsla(40, 30%, 45%, 0.25);
  border-radius: 8px;
}

.collect-xiehui-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.collect-xiehui-table th,
.collect-xiehui-table td {
  padding: 0.45rem 0.55rem;
  border-bottom: 1px solid hsla(40, 20%, 40%, 0.2);
  text-align: left;
  vertical-align: top;
}

.collect-xiehui-table th {
  position: sticky;
  top: 0;
  background: hsl(220 18% 14%);
  z-index: 1;
}

.collect-xiehui-table.table-delete-select tbody.is-drag-selecting tr:hover {
  background: hsla(160, 45%, 42%, 0.14);
}
  display: inline-block;
  padding: 0.1rem 0.45rem;
  border-radius: 4px;
  font-size: 0.78rem;
  white-space: nowrap;
}

.xiehui-tag--ok {
  background: hsla(140, 40%, 40%, 0.25);
  color: #bbf7d0;
}

.xiehui-tag--warn {
  background: hsla(35, 80%, 50%, 0.2);
  color: #fde68a;
}

.xiehui-old {
  opacity: 0.55;
}

.btn-delete {
  border-color: #f87171;
  color: #fca5a5;
  background: hsla(0, 60%, 40%, 0.1);
}

.btn-delete:hover:not(:disabled) {
  border-color: #fca5a5;
  color: #fecaca;
}

.btn-repeated {
  border-color: #7dd3fc;
  color: #e0f2fe;
  background: hsla(199, 89%, 88%, 0.2);
}

.btn-repeated:hover:not(:disabled) {
  border-color: #bae6fd;
  color: #f0f9ff;
}

.delete-actions {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  background: hsla(0, 55%, 40%, 0.12);
}

.delete-hint {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  color: hsl(var(--muted-foreground));
}

.btn-delete-confirm {
  background: hsla(0, 62%, 35%, 0.35);
  border-color: #ef4444;
  color: #fecaca;
}

.btn-delete-confirm:hover:not(:disabled) {
  border-color: #f87171;
  color: #fff;
}

table tbody tr.row-expired td {
  color: #f87171;
}

table tbody tr.row-bingzhe-timestamp td {
  color: #fb923c;
}

table tbody td.cell-repeated {
  color: #0369a1;
  background: hsl(199, 100%, 96%);
  box-shadow: inset 0 0 0 1px hsla(199, 80%, 78%, 0.9);
  border-radius: 0.4rem;
}

.table-delete-select tbody tr:hover td.cell-repeated {
  background: hsl(199, 100%, 98%);
}

th.col-check,
td.col-check {
  width: 2.5rem;
  text-align: center;
}

.col-check input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  cursor: pointer;
  accent-color: hsl(var(--primary));
}

.table-delete-select tbody.is-drag-selecting {
  user-select: none;
  cursor: crosshair;
  touch-action: none;
}

.table-delete-select tbody tr {
  cursor: pointer;
}

.table-delete-select tbody.is-drag-selecting tr:hover {
  background: hsla(0, 72%, 55%, 0.12);
}

.btn-top {
  border-color: #a78bfa;
  color: #c4b5fd;
  background: hsla(260, 45%, 45%, 0.12);
}

.btn-top:hover:not(:disabled) {
  border-color: #c4b5fd;
  color: #ddd6fe;
}

.top-actions {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  background: hsla(260, 40%, 45%, 0.1);
}

.top-hint {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  color: hsl(var(--muted-foreground));
}

.btn-top-confirm {
  background: hsla(260, 50%, 45%, 0.3);
  border-color: #8b5cf6;
  color: #ddd6fe;
}

.btn-top-confirm:hover:not(:disabled) {
  border-color: #a78bfa;
  color: #fff;
}

.table-reorder tbody tr[draggable="true"] {
  cursor: grab;
}

.table-reorder tbody tr.row-dragging {
  opacity: 0.55;
  cursor: grabbing;
}

.table-reorder tbody tr.row-drag-over {
  outline: 2px solid #8b5cf6;
  outline-offset: -2px;
}

.table-reorder tbody tr.row-drag-over-before td {
  box-shadow: inset 0 3px 0 0 #8b5cf6;
}

.table-reorder tbody tr.row-drag-over-after td {
  box-shadow: inset 0 -3px 0 0 #8b5cf6;
}

.table-reorder tbody tr.row-drag-shift-up {
  transform: translateY(-4px);
  transition: transform 120ms ease;
}

.table-reorder tbody tr.row-drag-shift-down {
  transform: translateY(4px);
  transition: transform 120ms ease;
}

th.col-drag,
td.col-drag {
  width: 2.25rem;
  text-align: center;
  user-select: none;
  color: hsl(var(--muted-foreground));
}

td.cell-drag-handle {
  cursor: grab;
}

.btn-value {
  border-color: #34d399;
  color: #6ee7b7;
  background: hsla(152, 45%, 40%, 0.12);
}

.btn-value:hover:not(:disabled) {
  border-color: #6ee7b7;
  color: #a7f3d0;
}

.btn-export {
  border-color: #60a5fa;
  color: #93c5fd;
  background: hsla(217, 70%, 52%, 0.12);
}

.btn-export:hover:not(:disabled) {
  border-color: #93c5fd;
  color: #dbeafe;
}

.btn-upload {
  border-color: #34d399;
  color: #6ee7b7;
  background: hsla(160, 55%, 40%, 0.12);
}

.btn-upload:hover:not(:disabled) {
  border-color: #6ee7b7;
  color: #a7f3d0;
}

.value-toolbar {
  margin-top: 0.5rem;
  padding: 0 0.25rem 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.value-toolbar[hidden] {
  display: none !important;
}

.btn-notice-board {
  width: 100%;
  border-color: #fbbf24;
  color: #fde68a;
  background: hsla(45, 70%, 42%, 0.12);
}

.btn-notice-board:hover:not(:disabled) {
  border-color: #fde68a;
  color: #fef3c7;
  background: hsla(45, 70%, 42%, 0.22);
}

.btn-notice-board-save {
  border-color: #fbbf24;
  color: #1c1917;
  background: #fbbf24;
}

.btn-notice-board-save:hover:not(:disabled) {
  border-color: #fde68a;
  background: #fde68a;
}

.btn-notice-remove {
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  border-color: hsl(var(--border));
  color: hsl(var(--muted-foreground));
}

/* Inline notice rows (HackMD-style), always above CSV data rows */
tr.row-notice td.notice-cell {
  padding: 0;
  border-bottom: 1px solid hsl(var(--border));
}

.notice-banner {
  display: flex;
  align-items: stretch;
  min-height: 2.75rem;
}

.notice-banner__bar {
  width: 4px;
  flex-shrink: 0;
}

.notice-banner__body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  padding: 0.55rem 0.85rem;
  font-size: 0.875rem;
  line-height: 1.45;
  flex: 1;
}

.notice-banner__icon {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.notice-banner__label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.75;
}

.notice-banner__sep {
  opacity: 0.45;
}

.notice-banner__text {
  font-weight: 500;
}

.notice-banner__sort {
  font-size: 0.72rem;
  opacity: 0.65;
  margin-left: 0.15rem;
}

.row-notice--info .notice-banner__bar {
  background: #0ea5e9;
}
.row-notice--info .notice-banner__body {
  background: hsl(199 89% 94%);
  color: #0c4a6e;
}

.row-notice--warn .notice-banner__bar {
  background: #f59e0b;
}
.row-notice--warn .notice-banner__body {
  background: hsl(48 96% 93%);
  color: #78350f;
}

.row-notice--success .notice-banner__bar {
  background: #10b981;
}
.row-notice--success .notice-banner__body {
  background: hsl(152 76% 93%);
  color: #064e3b;
}

.row-notice--announce .notice-banner__bar {
  background: #8b5cf6;
}
.row-notice--announce .notice-banner__body {
  background: hsl(263 89% 95%);
  color: #4c1d95;
}

.notice-editor-panel {
  margin-top: 0.75rem;
  padding: 1rem;
  border: 1px solid hsla(45, 65%, 55%, 0.35);
  border-radius: var(--radius);
  background: hsla(45, 35%, 14%, 0.45);
}

.notice-editor-panel[hidden] {
  display: none !important;
}

.notice-editor-panel__title {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  color: hsl(var(--gold));
}

.notice-editor-panel__sub {
  margin: 0 0 0.85rem;
  font-size: 0.82rem;
  color: hsl(var(--muted-foreground));
  line-height: 1.45;
}

.notice-editor-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.notice-editor-card {
  padding: 0.75rem;
  border: 1px solid hsl(var(--border));
  border-radius: calc(var(--radius) - 2px);
  background: hsla(30, 12%, 10%, 0.75);
}

.notice-editor-card__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.notice-editor-card__num {
  font-size: 0.85rem;
  font-weight: 600;
  color: #fde68a;
}

.notice-editor-field {
  display: block;
  margin-bottom: 0.5rem;
}

.notice-editor-field__label {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.72rem;
  color: hsl(var(--muted-foreground));
}

.notice-editor-field select,
.notice-editor-field input,
.notice-editor-field textarea {
  box-sizing: border-box;
  width: 100%;
  padding: 0.4rem 0.5rem;
  border: 1px solid hsl(var(--border));
  border-radius: calc(var(--radius) - 2px);
  background: hsla(30, 15%, 8%, 0.9);
  color: hsl(var(--foreground));
  font: inherit;
  font-size: 0.85rem;
}

.notice-editor-field-row {
  display: grid;
  grid-template-columns: 1fr 6rem;
  gap: 0.5rem;
}

.notice-editor-panel__actions {
  margin-top: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.btn-value-add {
  width: 100%;
  border-style: dashed;
  border-color: #34d399;
  color: #6ee7b7;
  background: hsla(152, 45%, 40%, 0.08);
}

.btn-value-add:hover:not(:disabled) {
  border-color: #6ee7b7;
  color: #a7f3d0;
  background: hsla(152, 45%, 40%, 0.16);
}

.value-actions {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius);
  background: hsla(152, 40%, 40%, 0.1);
}

.value-hint {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  color: hsl(var(--muted-foreground));
}

.btn-value-confirm {
  background: hsla(152, 50%, 38%, 0.3);
  border-color: #10b981;
  color: #a7f3d0;
}

.btn-value-confirm:hover:not(:disabled) {
  border-color: #34d399;
  color: #fff;
}

.table-edit {
  font-size: 0.8125rem;
}

.table-edit td {
  white-space: normal;
  vertical-align: middle;
  min-width: 5rem;
}

.table-edit input.cell-edit {
  box-sizing: border-box;
  width: 100%;
  min-width: 4rem;
  margin: 0;
  padding: 0.35rem 0.45rem;
  border: 1px solid hsl(var(--border));
  border-radius: calc(var(--radius) - 2px);
  background: hsla(30, 15%, 10%, 0.85);
  color: hsl(var(--foreground));
  font: inherit;
}

.table-edit input.cell-edit:focus {
  outline: none;
  border-color: hsl(var(--primary));
}

.panel-single .table-wrap {
  margin-top: 0.5rem;
}

code {
  font-size: 0.85em;
  color: hsl(var(--muted-foreground));
}

.panel h2 {
  margin: 0 0 0.5rem;
  font-size: 1.15rem;
  color: hsl(var(--gold));
}

.status {
  font-size: 0.85rem;
  color: hsl(var(--muted-foreground));
  margin-bottom: 0.5rem;
  min-height: 1.25rem;
}

.table-wrap {
  overflow: auto;
  border: 1px solid hsla(40, 65%, 55%, 0.12);
  border-radius: var(--radius);
  background: hsla(30, 12%, 10%, 0.65);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

th,
td {
  padding: 0.5rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid hsl(var(--border));
  white-space: nowrap;
}

th {
  background: hsl(30 10% 18%);
  font-weight: 600;
  position: sticky;
  top: 0;
  z-index: 1;
  color: hsl(var(--foreground));
}

/* Voice challenge gate (AI_Study NeonWave-inspired bars) */
.challenge-gate {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: radial-gradient(ellipse 120% 80% at 50% -10%, rgba(120, 90, 50, 0.35) 0%, transparent 55%),
    linear-gradient(180deg, hsl(28 16% 11%) 0%, hsl(22 20% 7%) 100%);
}

.challenge-gate__scroll-hint {
  display: none;
  width: 100%;
  max-width: min(36rem, 100%);
  margin: 0 auto 0.45rem;
  padding: 0 0.25rem;
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: hsla(40, 45%, 65%, 0.85);
}

.challenge-gate__layout {
  display: grid;
  grid-template-columns: minmax(0, 36rem) minmax(18rem, 22rem);
  gap: 0.95rem;
  align-items: stretch;
  width: min(62rem, 100%);
}

.challenge-gate--hidden {
  display: none !important;
}

/* Full-screen step between 念佛堂 gate and map: account / 身分登入 */
.account-login-page {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  box-sizing: border-box;
}

.account-login-page[hidden] {
  display: none !important;
}

.account-login-page__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.account-login-page__sheet {
  position: relative;
  z-index: 1;
  width: min(26rem, 100%);
  max-height: min(90vh, 32rem);
  overflow: auto;
  padding: 1.15rem 1.25rem 1.35rem;
  border-radius: var(--radius);
  border: 1px solid hsla(40, 65%, 55%, 0.35);
  background: hsl(30 12% 14%);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.5);
}

.account-login-page__title {
  margin: 0 0 0.5rem;
  text-align: center;
  font-size: clamp(1.35rem, 4vw, 1.85rem);
  font-weight: 700;
  letter-spacing: 0.12em;
  color: hsl(var(--gold));
}

.account-login-page__sub {
  margin: 0 0 0.85rem;
  font-size: 0.8rem;
  line-height: 1.5;
  color: hsl(var(--muted-foreground));
  text-align: center;
}

.account-login-page__sub .filepath {
  word-break: break-all;
}

.account-login-page__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 0.75rem;
}

.account-login-page__error {
  margin: 0.55rem 0 0;
  min-height: 1.25rem;
  font-size: 0.82rem;
  text-align: center;
  color: hsl(0 70% 58%);
}

.challenge-gate__panel {
  position: relative;
  width: 100%;
  min-width: 0;
  height: 100%;
  max-height: min(92vh, 46rem);
  overflow: auto;
  box-sizing: border-box;
  padding: 1.35rem 1.35rem 1.5rem;
  border-radius: var(--radius);
  border: 1px solid hsla(40, 65%, 55%, 0.28);
  background: hsl(30 12% 14%);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}

.gate-chat {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
  height: 100%;
  max-height: min(92vh, 46rem);
  box-sizing: border-box;
  border-radius: var(--radius);
  border: 1px solid hsla(40, 65%, 55%, 0.28);
  background: hsl(30 12% 14%);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}

.gate-chat__header {
  flex: 0 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid hsl(var(--border));
  color: hsl(var(--gold));
  font-size: 0.8rem;
  font-weight: 600;
}

.gate-chat__model {
  color: hsl(var(--muted-foreground));
  font-weight: 500;
  font-size: 0.72rem;
}

.gate-chat__messages {
  flex: 1 1 auto;
  min-height: 0;
  max-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
  padding: 0.65rem;
  font-size: 0.8rem;
  line-height: 1.4;
  color: hsl(var(--foreground));
}

.gate-chat__messages::-webkit-scrollbar {
  width: 8px;
}

.gate-chat__messages::-webkit-scrollbar-track {
  background: hsla(28, 16%, 11%, 0.45);
  border-radius: 999px;
}

.gate-chat__messages::-webkit-scrollbar-thumb {
  background: hsla(40, 65%, 55%, 0.5);
  border-radius: 999px;
  border: 2px solid hsla(28, 16%, 11%, 0.3);
}

.gate-chat__messages::-webkit-scrollbar-thumb:hover {
  background: hsla(40, 75%, 62%, 0.62);
}

.gate-chat__msg {
  margin-bottom: 0.52rem;
}

.gate-chat__msg--user {
  color: hsl(var(--gold-glow));
}

.gate-chat__form {
  flex: 0 0 auto;
  border-top: 1px solid hsl(var(--border));
  padding: 0.5rem;
}

.gate-chat__row {
  display: flex;
  gap: 0.4rem;
}

.gate-chat__row input {
  flex: 1;
  min-width: 0;
  border-radius: 0.5rem;
  border: 1px solid hsl(var(--border));
  background: hsl(30 15% 10%);
  color: hsl(var(--foreground));
  padding: 0.45rem 0.6rem;
  /* ≥16px stops iOS Safari auto-zoom on focus */
  font-size: 1rem;
}

.gate-chat__mic {
  min-width: 2.3rem;
  height: 2.3rem;
  padding: 0;
  line-height: 1;
  border-radius: 999px;
  border: 1px solid hsla(40, 65%, 55%, 0.5);
  background: radial-gradient(circle at 28% 24%, hsla(42, 90%, 78%, 0.95) 0%, hsla(34, 66%, 48%, 0.88) 56%, hsla(24, 58%, 32%, 0.86) 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 140ms ease, filter 140ms ease, box-shadow 140ms ease;
}

.gate-chat__mic-icon {
  width: 1.2rem;
  height: 1.2rem;
  fill: none;
  stroke: hsl(26 32% 12%);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.gate-chat__mic:hover:not(:disabled) {
  transform: translateY(-1px) scale(1.03);
  filter: saturate(1.05) brightness(1.03);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.32);
}

.gate-chat__mic.is-recording {
  border-color: hsla(36, 88%, 65%, 0.95);
  background: radial-gradient(circle at 30% 25%, hsla(48, 98%, 84%, 0.98) 0%, hsla(25, 88%, 56%, 0.92) 52%, hsla(8, 72%, 43%, 0.88) 100%);
  animation: gateMicNudge 0.9s ease-in-out infinite;
  box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.42);
}

.gate-chat__mic.is-recording .gate-chat__mic-icon {
  stroke: #fff7ed;
}

.gate-chat__thinking {
  margin: 0.4rem 0 0;
  font-size: 0.72rem;
  color: hsl(var(--muted-foreground));
}

@keyframes gateMicNudge {
  0% {
    transform: translateY(0) scale(1);
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4);
  }
  35% {
    transform: translateY(-1px) scale(1.04) rotate(-3deg);
    box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.2);
  }
  70% {
    transform: translateY(0) scale(1) rotate(3deg);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.14);
  }
  100% {
    transform: translateY(0) scale(1);
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.4);
  }
}

.challenge-tutorial-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  padding: 0.32rem 0.68rem;
  border-radius: 999px;
  border: 1px solid hsla(40, 65%, 55%, 0.5);
  background: hsla(40, 65%, 55%, 0.12);
  color: hsl(var(--gold-glow));
  font-size: 0.8rem;
  cursor: pointer;
}

.challenge-tutorial-btn:hover {
  border-color: hsl(var(--gold-glow));
}

.tutorial-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
}

.tutorial-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.tutorial-modal__panel {
  position: relative;
  width: min(44rem, calc(100% - 2rem));
  max-height: calc(100vh - 4rem);
  margin: 2rem auto;
  overflow: auto;
  border-radius: var(--radius);
  border: 1px solid hsla(40, 65%, 55%, 0.28);
  background: hsl(30 12% 14%);
  padding: 0.85rem 1rem 1rem;
}

.tutorial-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.55rem;
}

.tutorial-modal__title {
  margin: 0;
  color: hsl(var(--gold));
  font-size: 1.05rem;
}

.tutorial-modal__close {
  border: 1px solid hsl(var(--border));
  background: hsl(var(--secondary));
  color: hsl(var(--foreground));
  border-radius: 999px;
  width: 1.7rem;
  height: 1.7rem;
  line-height: 1.5rem;
  cursor: pointer;
}

.tutorial-modal__body {
  color: hsl(var(--muted-foreground));
  font-size: 0.85rem;
  line-height: 1.55;
}

.tutorial-modal__body p {
  margin: 0 0 0.7rem;
}

.delete-warn-modal,
.repeated-delete-modal {
  position: fixed;
  inset: 0;
  z-index: 130;
}

.delete-warn-modal__backdrop,
.repeated-delete-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.58);
}

.delete-warn-modal__panel,
.repeated-delete-modal__panel {
  position: relative;
  width: min(40rem, calc(100% - 1.5rem));
  max-height: calc(100vh - 2rem);
  margin: 1rem auto;
  overflow: auto;
  border-radius: var(--radius);
  border: 1px solid hsla(40, 65%, 55%, 0.35);
  background: hsl(30 12% 14%);
  padding: 1rem 1rem 1.1rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.delete-warn-modal__title,
.repeated-delete-modal__title {
  margin: 0 0 0.55rem;
  color: hsl(0 75% 72%);
  font-size: 1.05rem;
}

.delete-warn-modal__warn,
.repeated-delete-modal__warn {
  margin: 0 0 0.85rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.88rem;
  line-height: 1.55;
}

.delete-warn-modal__body,
.repeated-delete-modal__body {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.delete-warn-group__title,
.repeated-delete-group__title {
  margin: 0 0 0.35rem;
  color: hsl(var(--gold));
  font-size: 0.92rem;
  font-weight: 600;
}

.delete-warn-group__table,
.repeated-delete-group__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}

.delete-warn-group__table th,
.delete-warn-group__table td,
.repeated-delete-group__table th,
.repeated-delete-group__table td {
  padding: 0.45rem 0.55rem;
  border: 1px solid hsl(var(--border));
  text-align: left;
  white-space: nowrap;
}

.delete-warn-group__table th,
.repeated-delete-group__table th {
  background: hsl(var(--secondary));
  color: hsl(var(--foreground));
}

.delete-warn-group__table tbody tr:nth-child(even) td,
.repeated-delete-group__table tbody tr:nth-child(even) td {
  background: hsl(30 10% 12%);
}

.delete-warn-modal__actions,
.repeated-delete-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  justify-content: flex-end;
}

.challenge-gate__title {
  margin: 0.25rem 0 0.85rem;
  font-size: clamp(2.2rem, 8vw, 3.4rem);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-align: center;
  color: hsl(var(--gold));
  line-height: 1.1;
}


.challenge-wave {
  margin: 0.5rem 0 0.75rem;
  filter: drop-shadow(0 0 8px rgba(15, 122, 201, 0.45));
  transition: filter 180ms ease;
}

.challenge-wave--idle {
  filter: none;
}

.challenge-wave--idle .challenge-wave__bar {
  stroke: #1f1f1f;
  animation-duration: 2.8s;
}

.challenge-wave--user .challenge-wave__bar {
  stroke: #0f7ac9;
  animation-duration: 1.15s;
}

.challenge-wave__bar {
  stroke: #1f1f1f;
  animation-name: challengeWavePulse;
  animation-timing-function: ease-in-out;
  animation-iteration-count: infinite;
  transform-box: fill-box;
  transform-origin: center;
}

@keyframes challengeWavePulse {
  0%,
  100% {
    opacity: 0.72;
    transform: translateY(0) scaleY(1);
  }
  50% {
    opacity: 1;
    transform: translateY(0) scaleY(1.38);
  }
}

.challenge-gate__progress {
  margin: 0.35rem 0 0.25rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: hsl(var(--foreground));
  text-align: center;
}

.challenge-gate__live {
  margin: 0 0 0.65rem;
  min-height: 1.35rem;
  font-size: 0.8rem;
  color: hsl(var(--muted-foreground));
  text-align: center;
}

.challenge-gate__password-block {
  margin: 0.5rem 0 0.75rem;
  padding: 0.65rem 0.75rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid hsla(40, 65%, 55%, 0.35);
  background: hsla(40, 50%, 45%, 0.08);
}

.challenge-gate__pass-block {
  margin: 0.45rem 0 0.65rem;
  padding: 0.65rem 0.75rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid hsla(158, 45%, 42%, 0.35);
  background: hsla(158, 35%, 22%, 0.2);
}

.challenge-gate__pass-hint {
  margin: 0.45rem 0 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: hsl(var(--muted-foreground));
}

.challenge-gate__login-block {
  margin: 0.5rem 0 0.85rem;
  padding: 0.75rem 0.85rem;
  border-radius: calc(var(--radius) - 2px);
  border: 1px solid hsla(40, 65%, 55%, 0.35);
  background: hsla(40, 50%, 45%, 0.08);
}

.challenge-gate__login-intro {
  margin: 0 0 0.65rem;
  font-size: 0.82rem;
  color: hsl(var(--muted-foreground));
  line-height: 1.45;
}

.challenge-gate__login-intro .filepath {
  word-break: break-all;
}

.gate-login-role {
  display: flex;
  gap: 0.55rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 0.65rem;
}

.gate-login-role__btn {
  flex: 1;
  min-width: 7rem;
  max-width: 12rem;
  min-height: 2.55rem;
  border-radius: var(--radius);
  border: 1px solid hsla(40, 65%, 55%, 0.45);
  background: hsl(30 10% 18%);
  color: hsl(var(--foreground));
  font-size: 0.95rem;
  cursor: pointer;
}

.gate-login-role__btn:hover {
  border-color: hsl(var(--gold));
}

.gate-login-role__btn--active {
  border-color: hsl(var(--primary));
  background: hsla(40, 65%, 45%, 0.22);
  color: hsl(var(--gold-glow));
  font-weight: 600;
}

.challenge-gate__visible-label {
  display: block;
  margin: 0 0 0.28rem;
  font-size: 0.8rem;
  color: hsl(var(--muted-foreground));
}

.challenge-gate__input--text {
  letter-spacing: normal;
  text-align: left;
  font-variant-numeric: normal;
  font-size: 16px;
}

.challenge-gate__input--otp {
  letter-spacing: 0.35em;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-size: 1.15rem;
}

.challenge-gate__password-label {
  margin: 0 0 0.35rem;
  font-size: 0.82rem;
  color: hsl(var(--muted-foreground));
}

.challenge-gate__password-digits {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.35em;
  text-align: center;
  color: hsl(var(--gold));
}

.challenge-gate__field-label {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.challenge-gate__input {
  box-sizing: border-box;
  display: block;
  width: 100%;
  margin: 0 0 0.85rem;
  padding: 0.65rem 0.85rem;
  font-size: 1.1rem;
  letter-spacing: 0.25em;
  text-align: center;
  font-variant-numeric: tabular-nums;
  color: #1a1a1a;
  background: #ffffff;
  border: 2px solid hsla(40, 65%, 55%, 0.45);
  border-radius: var(--radius);
  font-family: inherit;
}

.challenge-gate__input:focus {
  outline: none;
  border-color: hsl(var(--primary));
  box-shadow: 0 0 0 3px hsla(40, 65%, 55%, 0.25);
}

.challenge-gate__input:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.challenge-gate__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

@media (max-width: 36rem) {
  .challenge-gate__actions {
    flex-direction: column;
  }

  .challenge-gate__btn {
    width: 100%;
    min-height: 2.75rem;
    font-size: 1rem;
  }
}

@media (max-width: 60rem) {
  .challenge-gate {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    box-sizing: border-box;
    width: 100%;
    /* inset:0 from base gives full screen; avoid fixed 100dvh so keyboard does not fight layout */
    max-height: none;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: contain;
    touch-action: pan-y;
    scrollbar-gutter: stable;
    padding-top: env(safe-area-inset-top);
    padding-right: env(safe-area-inset-right);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
  }

  .challenge-gate::-webkit-scrollbar {
    width: 10px;
  }

  .challenge-gate::-webkit-scrollbar-track {
    background: hsla(28, 16%, 11%, 0.5);
    border-radius: 999px;
  }

  .challenge-gate::-webkit-scrollbar-thumb {
    background: hsla(40, 65%, 55%, 0.45);
    border-radius: 999px;
    border: 2px solid hsla(28, 16%, 11%, 0.35);
  }

  .challenge-gate::-webkit-scrollbar-thumb:hover {
    background: hsla(40, 75%, 62%, 0.55);
  }

  .challenge-gate__scroll-hint {
    display: block;
    flex: 0 0 auto;
    width: 100%;
    max-width: none;
    margin-bottom: 0.35rem;
    padding-top: 0.35rem;
  }

  .challenge-gate__layout {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    grid-template-columns: unset;
    width: 100%;
    max-width: none;
    margin: 0;
    min-height: 0;
    gap: 0.65rem;
  }

  .challenge-gate__panel {
    width: 100%;
    max-width: none;
    max-height: none;
    overflow: visible;
    flex: 0 0 auto;
    border-radius: var(--radius);
  }

  .gate-chat {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    width: 100%;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: hidden;
  }

  .gate-chat__messages {
    flex: 1 1 auto;
    min-height: 0;
    max-height: none;
    overflow-y: auto;
  }

  /* Stop mobile browsers zooming the whole page when focusing inputs (needs ≥16px) */
  input[type='text'],
  input[type='search'],
  input[type='tel'],
  input[type='number'],
  input[type='password'],
  input[type='email'],
  input[type='url'],
  textarea,
  select {
    font-size: 16px;
  }

  .challenge-gate__input {
    font-size: max(1.05rem, 16px);
  }

  input.cell-edit {
    font-size: 16px;
  }
}

.challenge-gate__btn {
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid hsl(var(--border));
  background: hsl(var(--secondary));
  color: hsl(var(--foreground));
}

.challenge-gate__btn:hover:not(:disabled) {
  border-color: hsl(var(--primary));
  color: hsl(var(--gold-glow));
}

.challenge-gate__btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.challenge-gate__btn--primary {
  border-color: hsl(var(--primary));
  color: hsl(var(--gold));
  background: hsla(40, 65%, 55%, 0.12);
}

.challenge-gate__btn--secondary {
  border-style: dashed;
  opacity: 0.9;
}

.challenge-gate__error {
  margin: 0.75rem 0 0;
  min-height: 1.25rem;
  font-size: 0.82rem;
  color: #f87171;
  text-align: center;
}

/* skip row hover fill — fewer repaints on large tables */

/* 迴向文 PPT panel */
.ppt-status {
  font-size: 0.85rem;
  color: hsl(var(--muted-foreground));
  align-self: center;
}

.ppt-msg {
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
}

.ppt-msg--ok {
  background: hsla(158, 60%, 40%, 0.15);
  border: 1px solid hsla(158, 60%, 45%, 0.35);
  color: hsl(158 70% 75%);
}

.ppt-msg--error {
  background: hsla(0, 60%, 40%, 0.12);
  border: 1px solid hsla(0, 55%, 45%, 0.35);
  color: #fca5a5;
}

.ppt-msg--warn {
  background: hsla(38, 80%, 45%, 0.12);
  border: 1px solid hsla(38, 70%, 50%, 0.35);
  color: hsl(38 90% 75%);
}

.ppt-result__title {
  margin: 0 0 0.25rem;
  font-size: 1rem;
  font-weight: 600;
  color: hsl(158 70% 80%);
}

.ppt-result__file {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  color: hsl(var(--muted-foreground));
  word-break: break-all;
}

.ppt-result__stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr));
  gap: 0.5rem 0.75rem;
  margin: 0 0 0.85rem;
}

.ppt-result__stat {
  margin: 0;
  padding: 0.45rem 0.55rem;
  border-radius: 6px;
  background: hsla(40, 40%, 20%, 0.35);
  border: 1px solid hsla(40, 65%, 55%, 0.12);
}

.ppt-result__stat dt {
  margin: 0;
  font-size: 0.72rem;
  color: hsl(var(--muted-foreground));
}

.ppt-result__stat dd {
  margin: 0.15rem 0 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: hsl(var(--gold-glow));
}

.ppt-result__sections {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
}

.ppt-result__sections > strong {
  display: block;
  margin-bottom: 0.35rem;
  color: hsl(var(--gold));
  font-size: 0.8rem;
}

.ppt-result__sections ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ppt-result__sections li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  padding: 0.35rem 0;
  border-bottom: 1px dashed hsla(40, 65%, 55%, 0.1);
}

.ppt-result__sections li:last-child {
  border-bottom: none;
}

.ppt-result__sec-name {
  color: hsl(var(--foreground));
  min-width: 10rem;
}

.ppt-result__sec-meta {
  color: hsl(var(--muted-foreground));
}

.ppt-result__removed {
  margin: 0 0 0.75rem;
  padding: 0.5rem 0.65rem;
  border-radius: 6px;
  background: hsla(35, 70%, 45%, 0.1);
  border: 1px solid hsla(35, 65%, 50%, 0.25);
  font-size: 0.85rem;
}

.ppt-result__removed strong {
  display: block;
  margin-bottom: 0.2rem;
  color: hsl(35 80% 72%);
  font-size: 0.78rem;
}

.ppt-result__cta {
  margin: 0;
  font-size: 0.85rem;
  color: hsl(158 65% 72%);
}

.ppt-section {
  margin-bottom: 1rem;
  border: 1px solid hsla(40, 65%, 55%, 0.15);
  border-radius: var(--radius);
  overflow: hidden;
  background: hsl(30 10% 12%);
}

.ppt-section-head {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid hsla(40, 65%, 55%, 0.12);
  background: hsla(40, 40%, 30%, 0.08);
}

.ppt-section-head h2 {
  margin: 0;
  font-size: 1rem;
  color: hsl(var(--gold-glow));
}

.ppt-section-head p {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  color: hsl(var(--muted-foreground));
}

.ppt-layout-note {
  margin-top: 0.35rem !important;
  color: hsl(var(--gold)) !important;
}

.ppt-slides-preview {
  padding: 0.75rem 1rem;
  font-size: 0.82rem;
  color: hsl(var(--muted-foreground));
  border-top: 1px dashed hsla(40, 65%, 55%, 0.15);
}

.ppt-slides-preview strong {
  color: hsl(var(--gold-glow));
}

.ppt-tag-h {
  display: inline-block;
  background: hsla(40, 65%, 55%, 0.12);
  color: hsl(var(--gold));
  border-radius: 4px;
  padding: 0 0.35rem;
  font-size: 0.75rem;
}

.ppt-name-col {
  white-space: normal;
  min-width: 8rem;
}

.ppt-hide-col {
  width: 4.5rem;
  text-align: center;
  white-space: nowrap;
}

.ppt-btn-hide {
  font-size: 0.78rem;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  border: 1px solid hsla(40, 45%, 50%, 0.4);
  background: hsla(40, 30%, 25%, 0.35);
  color: hsl(40 40% 85%);
  cursor: pointer;
}

.ppt-btn-hide:hover {
  background: hsla(40, 40%, 32%, 0.5);
}

/* Marked to omit from PPT — keep row; only button turns active */
.ppt-btn-hide.is-hidden {
  border-color: hsla(0, 65%, 50%, 0.75);
  background: hsla(0, 55%, 38%, 0.55);
  color: hsl(0 100% 95%);
  box-shadow: 0 0 0 1px hsla(0, 70%, 55%, 0.35);
}

.ppt-btn-hide.is-hidden:hover {
  background: hsla(0, 60%, 42%, 0.7);
}

.ppt-row--omitted {
  background: hsla(0, 40%, 20%, 0.18);
}

.ppt-row--omitted td:not(.ppt-hide-col) {
  opacity: 0.72;
}

#ppt-btn-download:not(:disabled) {
  border-color: hsl(var(--primary));
  color: hsl(var(--gold-glow));
}

/* Collect guide modal ([教學] button on function map) */
.collect-guide-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.collect-guide-modal[hidden] {
  display: none !important;
}

.collect-guide-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.collect-guide-modal__panel {
  position: relative;
  z-index: 1;
  width: min(32rem, 100%);
  max-height: min(85vh, 640px);
  display: flex;
  flex-direction: column;
  border-radius: 0.85rem;
  border: 1px solid hsla(40, 65%, 55%, 0.28);
  background: hsl(30 12% 14%);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

.collect-guide-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid hsla(40, 65%, 55%, 0.15);
}

.collect-guide-modal__title {
  margin: 0;
  font-size: 1.05rem;
  color: hsl(var(--gold));
}

.collect-guide-modal__close {
  appearance: none;
  border: 0;
  background: transparent;
  color: hsl(var(--muted-foreground));
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.15rem 0.4rem;
}

.collect-guide-modal__body {
  overflow: auto;
  padding: 0.75rem 1rem 1rem;
}

.collect-guide__sections {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.collect-guide__item {
  border-radius: 8px;
  background: hsla(40, 30%, 10%, 0.45);
  border: 1px solid hsla(40, 50%, 45%, 0.12);
}

.collect-guide__summary {
  cursor: pointer;
  padding: 0.55rem 0.65rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: hsl(158 70% 78%);
  list-style: none;
  user-select: none;
}

.collect-guide__summary::-webkit-details-marker {
  display: none;
}

.collect-guide__summary::before {
  content: "▸ ";
  color: hsl(var(--gold));
  display: inline-block;
  transition: transform 0.15s ease;
}

.collect-guide__item[open] > .collect-guide__summary::before {
  transform: rotate(90deg);
}

.collect-guide__body {
  padding: 0 0.65rem 0.65rem;
  font-size: 0.78rem;
  line-height: 1.55;
  color: hsl(var(--foreground));
}

.collect-guide__body p {
  margin: 0 0 0.45rem;
}

.collect-guide__body p:last-child {
  margin-bottom: 0;
}

.collect-guide__body ul,
.collect-guide__body ol {
  margin: 0 0 0.45rem;
  padding-left: 1.15rem;
}

.collect-guide__body li {
  margin-bottom: 0.25rem;
}

.collect-guide__body code {
  font-size: 0.72rem;
  padding: 0.05rem 0.25rem;
  border-radius: 4px;
  background: hsla(220, 40%, 12%, 0.6);
}

.collect-guide__warn {
  color: #fcd34d !important;
}

/* —— PPT 程式覆核：hacker terminal (scoped; does not affect rest of app) —— */
.ppt-hack {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
  padding: 1.25rem;
}

.ppt-hack[hidden] {
  display: none !important;
}

.ppt-hack__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(3px);
}

.ppt-hack__window {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
  max-height: min(86vh, 820px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(0, 255, 120, 0.35);
  border-radius: 10px;
  background: #020805;
  box-shadow:
    0 0 0 1px rgba(0, 255, 120, 0.08),
    0 0 40px rgba(0, 255, 100, 0.12),
    0 24px 60px rgba(0, 0, 0, 0.65);
  font-family: "SF Mono", "Menlo", "Consolas", "Courier New", monospace;
  color: #7dffb0;
}

.ppt-hack__rain {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.28;
  z-index: 0;
}

.ppt-hack__bar,
.ppt-hack__meta,
.ppt-hack__status,
.ppt-hack__checks,
.ppt-hack__footer {
  position: relative;
  z-index: 1;
}

.ppt-hack__bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid rgba(0, 255, 120, 0.2);
  background: linear-gradient(180deg, rgba(0, 40, 18, 0.95), rgba(0, 16, 8, 0.92));
}

.ppt-hack__dots {
  display: inline-flex;
  gap: 0.35rem;
}

.ppt-hack__dots i {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #334;
  display: block;
}

.ppt-hack__dots i:nth-child(1) { background: #ff5f57; }
.ppt-hack__dots i:nth-child(2) { background: #febc2e; }
.ppt-hack__dots i:nth-child(3) { background: #28c840; }

.ppt-hack__title {
  flex: 1;
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #b8ffd0;
  text-shadow: 0 0 10px rgba(0, 255, 140, 0.35);
}

.ppt-hack__close {
  border: 1px solid rgba(0, 255, 120, 0.3);
  background: transparent;
  color: #7dffb0;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
}

.ppt-hack__close:hover {
  background: rgba(0, 255, 120, 0.1);
}

.ppt-hack__meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.4rem;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid rgba(0, 255, 120, 0.12);
  font-size: 0.72rem;
  color: #5fbb84;
}

.ppt-hack__meta span {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ppt-hack__meta b {
  color: #d7ffe6;
  font-weight: 600;
}

.ppt-hack__status {
  padding: 0.55rem 0.9rem;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: #9dffc0;
  border-bottom: 1px solid rgba(0, 255, 120, 0.1);
  min-height: 2.2rem;
}

.ppt-hack__status--run::after {
  content: "▍
  animation: ppt-hack-blink 1s steps(1, end) infinite;
}

@keyframes ppt-hack-blink {
  50% { opacity: 0; }
}

.ppt-hack__checks {
  list-style: none;
  margin: 0;
  padding: 0.75rem 0.9rem 1rem;
  overflow: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.ppt-hack__check {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.65rem;
  align-items: start;
  padding: 0.55rem 0.65rem;
  border: 1px solid rgba(0, 255, 120, 0.12);
  border-radius: 6px;
  background: rgba(0, 20, 10, 0.55);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.06s ease, transform 0.06s ease, border-color 0.08s ease, box-shadow 0.08s ease;
}

.ppt-hack__check.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ppt-hack__check.is-running {
  border-color: rgba(0, 255, 180, 0.45);
  box-shadow: 0 0 12px rgba(0, 255, 140, 0.15);
}

.ppt-hack__check.is-pass {
  border-color: rgba(0, 255, 120, 0.4);
}

.ppt-hack__check.is-fail {
  border-color: rgba(255, 80, 80, 0.55);
  color: #ffb0b0;
}

.ppt-hack__check-id {
  font-size: 0.68rem;
  color: #3d8f5e;
  letter-spacing: 0.04em;
  min-width: 4.5rem;
}

.ppt-hack__check-detail {
  font-size: 0.8rem;
  line-height: 1.35;
  color: inherit;
}

.ppt-hack__check-mark {
  font-size: 0.85rem;
  font-weight: 700;
  min-width: 1.2rem;
  text-align: right;
}

.ppt-hack__check.is-pass .ppt-hack__check-mark {
  color: #39ff88;
  text-shadow: 0 0 8px rgba(57, 255, 136, 0.55);
}

.ppt-hack__check.is-fail .ppt-hack__check-mark {
  color: #ff5555;
  text-shadow: 0 0 8px rgba(255, 85, 85, 0.45);
}

.ppt-hack__check.is-running .ppt-hack__check-mark {
  color: #ffe566;
  animation: ppt-hack-blink 0.7s steps(1, end) infinite;
}

.ppt-hack__check.ppt-hack__part {
  border-color: rgba(0, 255, 180, 0.55);
  background: rgba(0, 40, 22, 0.75);
  margin-top: 0.35rem;
}

.ppt-hack__check.ppt-hack__part .ppt-hack__check-detail {
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #b8ffd0;
}

.ppt-hack__footer {
  padding: 0.7rem 0.9rem 0.85rem;
  border-top: 1px solid rgba(0, 255, 120, 0.18);
  background: rgba(0, 12, 6, 0.88);
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  min-height: 2.6rem;
}

.ppt-hack__footer.is-pass {
  color: #39ff88;
  text-shadow: 0 0 12px rgba(57, 255, 136, 0.35);
}

.ppt-hack__footer.is-fail {
  color: #ff8888;
}

.ppt-hack__footer.is-error {
  color: #ff6666;
}

@media (max-width: 640px) {
  .ppt-hack__meta {
    grid-template-columns: 1fr;
  }
}
