/* * Vídeo ampliado (ProjectLightbox): janela modal com a troca desktop/celular, capítulos e controles próprios. * Carrega sob demanda, na primeira vez que alguém amplia um projeto. */ html.ds-lb-open { overflow: hidden; /* a barra de rolagem clássica some junto: devolve o espaço dela para a página não pular */ padding-right: var(--ds-scrollbar, 0px); } .ds-lb { --accent: var(--slash); color-scheme: dark; position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: clamp(12px, 3vw, 32px); border: 0; color: #fff; background: rgba(5, 5, 5, 0.88); backdrop-filter: blur(8px); overscroll-behavior: contain; opacity: 0; transition: opacity 180ms var(--ease-in), overlay 180ms allow-discrete, display 180ms allow-discrete; &[open] { display: flex; align-items: center; justify-content: center; opacity: 1; transition-duration: 280ms; transition-timing-function: var(--ease-out); @starting-style { /* biome-ignore lint/suspicious/noDuplicateProperties: dentro de @starting-style é o estado inicial da entrada, não uma repetição */ opacity: 0; } } &::backdrop { background: transparent; } } @media (prefers-reduced-motion: reduce) { .ds-lb, .ds-lb[open] { transition: none; } } .ds-lb-panel { display: flex; flex-direction: column; gap: var(--sp-4); width: min(1180px, 100%); height: min(100%, 900px); min-height: 0; padding: clamp(14px, 2.4vw, 24px); overflow: auto; background: #0c0c0c; border: 1px solid rgba(255, 255, 255, 0.12); box-shadow: 0 0 120px -30px color-mix(in srgb, var(--accent) 55%, transparent); } .ds-lb-head { display: flex; align-items: center; flex-wrap: wrap; gap: var(--sp-3) var(--sp-4); } .ds-lb-heading { flex: 1 1 200px; min-width: 0; } .ds-lb-count { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; color: var(--slash); } .ds-lb-title { font-family: var(--font-display); font-size: clamp(20px, 2.6vw, 30px); font-weight: var(--fw-card); line-height: 1.05; letter-spacing: -0.03em; } .ds-lb-toggle { display: inline-flex; min-width: 0; margin: 0; padding: 0; border: 1px solid rgba(255, 255, 255, 0.16); } .ds-lb-toggle button { min-height: 44px; padding: 0 16px; font-family: var(--font-display); font-size: 15px; font-weight: 500; color: rgba(255, 255, 255, 0.72); background: transparent; border: 0; cursor: pointer; transition: background 0.2s ease, color 0.2s ease; /* a versão escolhida: fundo claro e sublinhado em lima (a lima só marca, não preenche o botão) */ &[aria-pressed="true"] { color: #fff; background: rgba(255, 255, 255, 0.12); box-shadow: inset 0 -2px 0 var(--slash); } } .ds-lb-nav { display: flex; gap: 6px; } .ds-lb-nav button { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; color: #fff; background: transparent; border: 1px solid rgba(255, 255, 255, 0.16); cursor: pointer; transition: border-color 0.2s ease; @media (hover: hover) { &:hover:not(:disabled) { border-color: rgba(255, 255, 255, 0.5); } } &:disabled { opacity: 0.3; cursor: default; } } /* o palco mede a si mesmo: o aparelho cresce até o limite da largura ou da altura que sobrar */ .ds-lb-stage { flex: 1 1 0; min-height: 200px; display: flex; align-items: center; justify-content: center; container-type: size; } .ds-lb-frame { width: min(100cqw, calc((100cqh - 30px) * 1.6)); } .ds-lb-screen { position: relative; aspect-ratio: 16 / 10; overflow: hidden; background: #0a0a0a center top / cover no-repeat; } .ds-lb-video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; } .ds-lb-phone { height: min(100cqh, calc(100cqw * 866 / 390)); } .ds-lb-controls { display: flex; align-items: center; gap: var(--sp-3); } .ds-lb-play { display: grid; flex: none; place-items: center; width: 44px; height: 44px; padding: 0; color: #fff; background: transparent; border: 1px solid rgba(255, 255, 255, 0.5); cursor: pointer; @media (hover: hover) { &:hover { border-color: #fff; } } & svg { width: 16px; height: 16px; fill: currentColor; } } .ds-lb-nav button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; } .ds-lb-time { flex: none; min-width: 72px; font-family: var(--font-mono); font-size: 12px; font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, 0.7); } .ds-lb-range { flex: 1 1 auto; min-width: 0; height: 44px; margin: 0; background: transparent; appearance: none; -webkit-appearance: none; cursor: pointer; &::-webkit-slider-runnable-track { height: 3px; background: rgba(255, 255, 255, 0.22); } &::-moz-range-track { height: 3px; background: rgba(255, 255, 255, 0.22); } &::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; margin-top: -5.5px; border: 0; border-radius: 0; background: var(--slash); } &::-moz-range-thumb { width: 14px; height: 14px; border: 0; border-radius: 0; background: var(--slash); } } .ds-lb-chapters { display: flex; flex: none; /* é filha de coluna flex: sem isto a fileira rolável encolhe a quase nada em celular baixo */ flex-wrap: wrap; gap: 8px; list-style: none; } .ds-lb-chapters button { min-height: 40px; padding: 0 14px; font-family: var(--font-display); font-size: 15px; white-space: nowrap; color: rgba(255, 255, 255, 0.76); background: transparent; border: 1px solid rgba(255, 255, 255, 0.14); cursor: pointer; transition: color 0.2s ease, border-color 0.2s ease; @media (hover: hover) { &:hover { color: #fff; border-color: rgba(255, 255, 255, 0.4); } } &[aria-current="true"] { color: #fff; border-color: rgba(255, 255, 255, 0.7); } } .ds-lb-chapters button span { font-family: var(--font-mono); font-size: 12px; color: var(--slash); } @media (pointer: coarse) { .ds-lb-chapters button { min-height: 44px; } } .ds-lb-links { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-3); & .ds-link.ds-link-muted { --block: rgba(255, 255, 255, 0.12); padding: 8px 16px; color: #fff; border-color: rgba(255, 255, 255, 0.38); background: transparent; } & .ds-link.ds-link-muted:focus-visible { border-color: rgba(255, 255, 255, 0.55); } @media (hover: hover) { & .ds-link.ds-link-muted:hover { border-color: rgba(255, 255, 255, 0.55); } } & .ds-link.ds-link-text { color: rgba(255, 255, 255, 0.84); } } /* tamanhos do degradê da fileira de etapas (celular): sem rolagem a fileira não anima e os dois ficam em 0 */ @property --ds-fade-start { syntax: ""; inherits: false; initial-value: 0px; } @property --ds-fade-end { syntax: ""; inherits: false; initial-value: 0px; } /* o progresso é o da rolagem da própria fileira: sem rolar, só a borda direita esmaece; no meio, as duas; no fim, só a esquerda */ @keyframes ds-lb-edges { 0% { --ds-fade-start: 0px; --ds-fade-end: 28px; } 10% { --ds-fade-start: 28px; } 90% { --ds-fade-end: 28px; } 100% { --ds-fade-start: 28px; --ds-fade-end: 0px; } } @media (max-width: 639px) { .ds-lb { padding: 0; } .ds-lb-panel { width: 100%; height: 100%; border: 0; } .ds-lb-chapters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; /* degradê na borda que ainda tem etapas escondidas: some sozinho quando a fileira cabe ou chega ao fim */ mask-image: linear-gradient( to right, transparent, #000 var(--ds-fade-start), #000 calc(100% - var(--ds-fade-end)), transparent ); @supports (animation-timeline: scroll()) { animation: ds-lb-edges linear both; animation-timeline: scroll(self inline); } } .ds-lb-chapters::-webkit-scrollbar { display: none; } .ds-lb-time { display: none; } } /* telas muito estreitas: nome, versão e setas não cabem na mesma linha; o alternador de versão ocupa uma só */ @media (max-width: 389px) { .ds-lb-panel { gap: var(--sp-3); } .ds-lb-heading { flex-basis: 0; } .ds-lb-toggle { order: 3; flex: 1 1 100%; } .ds-lb-toggle button { flex: 1; } } /* celular deitado e janela de desktop curta: vídeo grande ao lado, controles em coluna (empilhado, o vídeo ficava com 200px de altura) */ @media ((max-height: 520px) and (min-width: 640px)) or ( (max-height: 700px) and (min-width: 900px) ) { .ds-lb { padding: 0; } .ds-lb-panel { display: grid; grid-template-columns: minmax(260px, 320px) minmax(0, 1fr); grid-template-rows: auto auto minmax(0, 1fr) auto; grid-template-areas: "head stage" "ctrl stage" "chap stage" "links stage"; gap: var(--sp-3) var(--sp-4); width: 100%; height: 100%; border: 0; } .ds-lb-head { grid-area: head; } .ds-lb-controls { grid-area: ctrl; } .ds-lb-chapters { grid-area: chap; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; } .ds-lb-chapters::-webkit-scrollbar { display: none; } .ds-lb-links { grid-area: links; } .ds-lb-stage { grid-area: stage; min-height: 0; } } /* ─────────────────────────── Foco ─────────────────────────── */ /* Lima, por dentro, nos botões que ficam dentro de contêineres que cortam o que passa da borda; por fora, nos soltos. Sem o halo do anel duplo global (globals.css): ele é para fundos claros. */ :is(.ds-lb-toggle button, .ds-lb-chapters button):focus-visible { outline: 2px solid var(--slash); outline-offset: -4px; box-shadow: none; } :is(.ds-lb-nav button, .ds-lb-play, .ds-lb-range):focus-visible { outline: 2px solid var(--slash); outline-offset: 2px; box-shadow: none; }