/* Ops Layer — Boot · Share / Cite / Short links */

.ops-toast {
  position: fixed;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  z-index: 12000;
  transform: translateX(-50%) translateY(120%);
  max-width: min(92vw, 420px);
  padding: 0.55rem 0.9rem;
  border: 1px solid rgba(0, 255, 136, 0.4);
  border-radius: 10px;
  background: rgba(4, 12, 8, 0.94);
  color: #b8ffd0;
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  opacity: 0;
  pointer-events: none;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.ops-toast.is-on {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.ops-boot {
  position: fixed;
  inset: 0;
  z-index: 12500;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.88);
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.35s ease;
}

.ops-boot.is-out {
  opacity: 0;
}

.ops-boot__inner {
  text-align: center;
  padding: 1rem;
}

.ops-boot__line {
  margin: 0.2rem 0;
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  letter-spacing: 0.12em;
}

.ops-boot__line--dim {
  color: rgba(0, 255, 136, 0.45);
  font-size: 0.62rem;
}

.ops-boot__line--main {
  color: #00ff88;
  font-size: clamp(0.95rem, 3.5vw, 1.25rem);
  font-weight: 800;
  min-height: 1.4em;
  text-shadow: 0 0 18px rgba(0, 255, 136, 0.35);
}

body.is-ops-booting .site-build-banner__text.is-glitching,
.site-build-banner__text.is-glitching {
  animation: ops-glitch 0.35s steps(2, end) infinite;
}

@keyframes ops-glitch {
  0% { transform: translate(0, 0); text-shadow: 1px 0 #f0f, -1px 0 #0ff; }
  50% { transform: translate(-1px, 1px); text-shadow: -1px 0 #f0f, 1px 0 #0ff; }
  100% { transform: translate(1px, -1px); text-shadow: 1px 0 #0ff, -1px 0 #f0f; }
}

.ops-detail-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.28rem;
  margin-left: auto;
}

.ops-chip {
  appearance: none;
  min-height: 28px;
  padding: 0.15rem 0.55rem;
  border: 1px solid rgba(0, 255, 136, 0.3);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.35);
  color: var(--text-muted, #9ab0a0);
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}

.ops-chip:hover,
.ops-chip:focus-visible {
  color: #00ff88;
  border-color: rgba(0, 255, 136, 0.55);
  outline: none;
}

.ops-share-pair {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
}

.ops-chip--icon,
.ops-chip--native-share {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  min-width: 28px;
  padding: 0;
}

.ops-chip--icon .ops-share-icon,
.ops-chip--icon .ops-copy-icon,
.ops-chip--native-share .ops-share-icon {
  display: block;
  width: 14px;
  height: 14px;
  pointer-events: none;
}

.ops-share-sheet {
  position: fixed;
  inset: 0;
  z-index: 12650;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 1rem;
  background: rgba(0, 0, 0, 0.72);
}

.ops-share-sheet.is-on {
  display: flex;
}

.ops-share-sheet__card {
  width: min(100%, 420px);
  padding: 1rem 1.1rem 1rem;
  border: 1px solid rgba(0, 255, 136, 0.4);
  border-radius: 14px 14px 12px 12px;
  background: #07140e;
  box-shadow: 0 0 40px rgba(0, 255, 136, 0.12);
}

.ops-share-sheet__title {
  margin: 0 0 0.75rem;
  color: #00ff88;
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.35;
  word-break: break-word;
}

.ops-share-sheet__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
  margin-bottom: 0.75rem;
}

.ops-share-sheet__app {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.4rem 0.5rem;
  border: 1px solid rgba(0, 255, 136, 0.35);
  border-radius: 10px;
  background: rgba(0, 255, 136, 0.08);
  color: #b8ffd0;
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 0.72rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.ops-share-sheet__app:hover,
.ops-share-sheet__app:focus-visible {
  background: rgba(0, 255, 136, 0.18);
  outline: none;
}

.ops-share-sheet__close {
  appearance: none;
  width: 100%;
  min-height: 36px;
  border: 1px solid rgba(0, 255, 136, 0.35);
  border-radius: 999px;
  background: transparent;
  color: #8ab0a0;
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 0.7rem;
  font-weight: 700;
  cursor: pointer;
}

.doc-detail-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
}

.pick-card-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.pick-card-wrap.is-hidden,
.pick-card-wrap[hidden] {
  display: none !important;
}

.pick-card-wrap > a {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
}

.pick-card-wrap__share {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.28rem;
  flex-shrink: 0;
}

/* Arquivo: canto inferior direito da capa */
.arquivo-pick-card__media {
  position: relative;
  overflow: hidden;
}

.pick-card-wrap__share--on-cover {
  position: absolute;
  right: 0.35rem;
  bottom: 0.35rem;
  z-index: 8;
  margin: 0;
  padding: 0;
  pointer-events: none;
}

.pick-card-wrap__share--on-cover .ops-share-pair,
.pick-card-wrap__share--on-cover .ops-chip {
  pointer-events: auto;
}

.pick-card-wrap__share--on-cover .ops-chip {
  min-height: 28px;
  min-width: 28px;
  border-color: #00ff88;
  background: rgba(0, 12, 6, 0.92);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

/* Barra sob o card (filmes / PDF / etc.) */
.pick-card-wrap__share--bar {
  position: relative;
  z-index: 2;
  width: 100%;
  box-sizing: border-box;
  padding: 0.35rem 0.4rem 0.4rem;
  border-top: 1px solid rgba(0, 255, 136, 0.22);
  background: rgba(0, 18, 10, 0.95);
  pointer-events: auto;
}

.pick-card-wrap__share--bar .ops-share-pair {
  width: 100%;
  justify-content: flex-end;
}

.pick-card-poster-anchor {
  position: relative;
  display: block;
  width: 100%;
}

.pick-card-poster-anchor > img {
  display: block;
  width: 100%;
}

.pick-card-wrap__share .ops-chip {
  font-size: 0.55rem;
  min-height: 28px;
  min-width: 28px;
  padding: 0 0.55rem;
  border-color: rgba(0, 255, 136, 0.75);
  background: #003d22;
  color: #00ff88;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.45);
}

.pick-card-wrap__share .ops-chip--icon {
  width: 28px;
  padding: 0;
}

/* Lista: bar à direita do card (não-arquivo) */
.hub-panel.pick-layout-list .pick-card-wrap {
  flex-direction: row;
  align-items: stretch;
}

.hub-panel.pick-layout-list .pick-card-wrap__share--bar {
  width: auto;
  border-top: 0;
  border-left: 1px solid rgba(0, 255, 136, 0.22);
  padding: 0.35rem;
  align-items: center;
}

.hub-panel.pick-layout-list .pick-card-wrap__share--bar .ops-share-pair {
  flex-direction: column;
  width: auto;
}

/* Arquivo em lista: overlay na thumb pequena */
.hub-panel.pick-layout-list .pick-card-wrap__share--on-cover {
  right: 0.2rem;
  bottom: 0.2rem;
}

.hub-panel.pick-layout-list .pick-card-wrap__share--on-cover .ops-chip {
  min-height: 24px;
  min-width: 24px;
}

.hub-panel.pick-layout-grid .pick-card-wrap {
  flex-direction: column;
}
