/* An unobtrusive moving index; every command is also available in the searchable directory. */
#faixa-comandos {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  overflow: hidden;
  background: #183e37;
  color: #f3f5e9;
}
.cmd-tape-window {
  align-self: center;
  min-width: 0;
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, #000 24px, #000 calc(100% - 24px), transparent);
}
.cmd-tape-track {
  display: flex;
  width: max-content;
  animation: cmd-ticker var(--cmd-tape-duration, 90s) linear infinite;
}
.cmd-tape-list {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}
.cmd-tape-list li {
  display: inline-flex;
  align-items: center;
  gap: 19px;
  padding-right: 19px;
  font: 550 13px/1.25 var(--sans);
  white-space: nowrap;
  color: #e5eadf;
}
.cmd-tape-list li::before {
  content: "";
  width: 5px;
  height: 5px;
  transform: rotate(45deg);
  background: #98bd89;
}
@keyframes cmd-ticker { to { transform: translateX(-50%); } }
#faixa-comandos.cmd-paused .cmd-tape-track { animation-play-state: paused; }
.cmd-tape-control {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 49px;
  border-left: 1px solid #ffffff26;
  padding: 0 clamp(14px, 2.4vw, 36px);
  font: 650 12px/1 var(--sans);
}
.cmd-tape-control:hover { background: #ffffff0c; }
.cmd-tape-control:focus-visible { outline-offset: -5px; }
.cmd-pause-symbol {
  display: inline-block;
  width: 8px;
  height: 10px;
  border-inline: 2px solid currentColor;
}
.cmd-play-symbol, .cmd-video-symbol {
  display: inline-block;
  width: 0;
  height: 0;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 8px solid currentColor;
}

#galeria-comandos {
  color: var(--ink);
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 14px;
  overflow: hidden;
}
#galeria-comandos [hidden],
#lista-comandos [hidden] { display: none !important; }
.cmd-gallery-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 13px clamp(15px, 2.4vw, 32px);
  border-bottom: 1px solid var(--line);
}
.cmd-filters, .cmd-navigation, .cmd-type, .cmd-filter, .cmd-video-start {
  display: flex;
  align-items: center;
}
.cmd-filters { gap: 3px; flex-wrap: wrap; }
.cmd-filter {
  justify-content: center;
  gap: 7px;
  min-height: 39px;
  border-radius: 6px;
  padding: 8px 13px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
}
.cmd-filter span {
  font: 500 .8em/1 var(--mono);
  opacity: .86;
}
.cmd-filter:hover { background: var(--soft); }
.cmd-filter[aria-pressed="true"] { background: var(--pine); color: #fff; }
.cmd-filter[aria-pressed="true"] span { color: #d5efc8; }
.cmd-type {
  flex-shrink: 0;
  gap: 8px;
  color: var(--muted);
  font: 600 11px/1.3 var(--sans);
}
.cmd-type::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #528464;
}
.cmd-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
}
.cmd-screen {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: clamp(14px, 2.2vw, 30px);
  min-height: 250px;
  background-color: #e4eae2;
  background-image: radial-gradient(#b5c0b1 0.7px, transparent 0.9px);
  background-size: 12px 12px;
  border-right: 1px solid var(--line);
}
.cmd-poster, .cmd-video {
  display: block;
  object-fit: contain;
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: clamp(275px, 27vw, 410px);
  background: #fff;
  box-shadow: 0 10px 25px -13px #092a214a, 0 0 0 1px #0d33251a;
}
.cmd-video { width: 100%; }
.cmd-video-start {
  position: absolute;
  bottom: clamp(20px, 3vw, 40px);
  left: 50%;
  transform: translateX(-50%);
  justify-content: center;
  gap: 10px;
  border: 1px solid #fff9;
  border-radius: 22px;
  color: white;
  background: var(--pine);
  min-height: 40px;
  padding: 10px 19px;
  box-shadow: 0 4px 14px #0c281c29;
  font-size: 13px;
  font-weight: 700;
}
.cmd-video-start:hover { background: #255346; }
.cmd-video-symbol { border-top-width: 4px; border-bottom-width: 4px; border-left-width: 6px; }
.cmd-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  min-width: 0;
  padding: clamp(24px, 3.7vw, 56px);
}
.cmd-sequence {
  margin-bottom: 14px;
  color: var(--teal);
  font: 600 12px/1.3 var(--mono);
  letter-spacing: .1em;
}
.cmd-title {
  font-size: clamp(27px, 3vw, 48px);
  font-weight: 570;
  letter-spacing: -.055em;
  line-height: 1.04;
  text-wrap: balance;
  overflow-wrap: break-word;
}
.cmd-description {
  margin-top: 14px;
  max-width: 43ch;
  color: var(--muted);
  font-size: clamp(14px, 1.1vw, 17px);
  line-height: 1.6;
}
.cmd-navigation { gap: 8px; margin-top: clamp(20px, 2.5vw, 36px); }
.cmd-arrow {
  display: grid;
  place-items: center;
  width: 41px;
  height: 41px;
  padding: 0;
  border: 1px solid #c5d0c4;
  border-radius: 50%;
  font: 500 21px/1 var(--sans);
}
.cmd-arrow:hover { background: var(--soft); border-color: var(--teal); }
.cmd-rail {
  display: flex;
  align-items: stretch;
  gap: 10px;
  overflow-x: auto;
  padding: 14px clamp(15px, 2.4vw, 32px);
  border-top: 1px solid var(--line);
  scrollbar-width: thin;
  scrollbar-color: #a5b7a8 transparent;
  overscroll-behavior-x: contain;
}
.cmd-thumb {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  flex: 0 0 clamp(96px, 9.4vw, 140px);
  overflow: hidden;
  padding: 4px 4px 6px;
  border: 1px solid transparent;
  border-radius: 6px;
  text-align: left;
}
.cmd-thumb:hover { border-color: #bdc9ba; }
.cmd-thumb[aria-pressed="true"] { background: #e7f2e3; border-color: #54715b; }
.cmd-thumb img {
  object-fit: cover;
  width: 100%;
  aspect-ratio: 1.85;
  border: 1px solid var(--line);
  border-radius: 3px;
}
.cmd-thumb span {
  margin: 0 2px;
  font-size: 11px;
  font-weight: 680;
  line-height: 1.27;
}
.cmd-directory {
  margin-top: 18px;
  background: #f0f3eb;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.cmd-directory summary { cursor: pointer; list-style: none; }
.cmd-directory summary::-webkit-details-marker { display: none; }
.cmd-index-summary {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 18px clamp(16px, 2.5vw, 34px);
  font-size: clamp(15px, 1.5vw, 20px);
  font-weight: 660;
  letter-spacing: -.025em;
}
.cmd-index-summary small {
  margin-left: auto;
  color: var(--muted);
  font: 500 12px/1.3 var(--sans);
}
.cmd-disclosure-icon, .cmd-panel summary::after {
  display: inline-block;
  width: 9px;
  height: 9px;
  flex: none;
  margin-right: 4px;
  transform: rotate(45deg) translateY(-2px);
  border: solid currentColor;
  border-width: 0 1.7px 1.7px 0;
}
.cmd-directory[open] .cmd-disclosure-icon,
.cmd-panel[open] summary::after { transform: rotate(225deg) translate(-1px, -1px); }
.cmd-directory-body {
  padding: 15px clamp(16px, 2.5vw, 34px) 26px;
  border-top: 1px solid var(--line);
}
.cmd-search {
  display: flex;
  flex-direction: column;
  max-width: 495px;
  gap: 7px;
  margin: 8px 0 18px;
}
.cmd-search span { font-size: 13px; font-weight: 690; }
.cmd-search input {
  min-height: 44px;
  width: 100%;
  padding: 9px 13px;
  color: var(--ink);
  background: white;
  border: 1px solid #bdc8bb;
  border-radius: 6px;
  font-size: 14px;
}
.cmd-result-status { color: var(--muted); font-size: 13px; }
.cmd-panel-group + .cmd-panel-group { margin-top: 20px; }
.cmd-panel-group h4 { margin: 10px 0 8px; color: var(--muted); font-size: 13px; }
.cmd-panel-list { columns: 2; column-gap: 25px; }
.cmd-panel {
  break-inside: avoid;
  margin: 0 0 5px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 5px;
}
.cmd-panel summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 650;
}
.cmd-panel summary::after { content: ""; width: 7px; height: 7px; }
.cmd-panel ul { margin: 0; padding: 0 15px 11px; list-style: none; font-size: 14px; }
.cmd-panel li { margin: 0; padding: 10px 0; border-top: 1px solid var(--line); }
.cmd-panel li strong { display: block; line-height: 1.35; }
.cmd-panel li p { margin: 4px 0; color: var(--muted); }
.cmd-panel li a, .cmd-origin { color: var(--teal); font-size: 12px; }
.cmd-panel li a { text-decoration: underline; text-underline-offset: .2em; }
.cmd-directory-description { margin: 0 0 13px; color: var(--muted); max-width: 72ch; font-size: 14px; }

@media (max-width: 750px) {
  .cmd-stage { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
  .cmd-info { padding: 22px; }
  .cmd-title { font-size: 28px; }
  .cmd-type { display: none; }
  .cmd-gallery-head { padding: 10px 12px; }
}
@media (max-width: 570px) {
  .cmd-tape-control { width: 45px; min-height: 43px; }
  .cmd-tape-control-text { display: none; }
  .cmd-tape-list li { font-size: 12px; }
  .cmd-gallery-head { padding: 8px; }
  .cmd-filter { padding: 6px 7px; gap: 4px; font-size: 11px; min-height: 36px; }
  .cmd-filters { gap: 1px; }
  .cmd-stage { display: flex; flex-direction: column; }
  .cmd-screen { min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); padding: 13px; }
  .cmd-poster, .cmd-video { max-height: 245px; }
  .cmd-info { display: grid; grid-template-columns: minmax(0, 1fr) auto; padding: 17px; column-gap: 12px; }
  .cmd-sequence { margin-bottom: 7px; font-size: 10px; }
  .cmd-title { grid-column: 1; font-size: 27px; }
  .cmd-description { grid-column: 1 / -1; margin-top: 9px; font-size: 13px; }
  .cmd-navigation { grid-column: 2; grid-row: 1 / 3; align-self: center; margin: 0; gap: 5px; }
  .cmd-arrow { width: 33px; height: 33px; font-size: 17px; }
  .cmd-thumb { flex-basis: 94px; }
  .cmd-panel-list { columns: 1; }
  .cmd-index-summary { gap: 10px; }
  .cmd-index-summary small { font-size: 10px; }
}
.cmd-panel .cmd-count { margin-left: auto; color: var(--muted); font: 500 11px/1 var(--mono); }
