/* ==========================================================================
   Gonçalo Azevedo · Fotografia
   Tema claro. Um acento (laranja sinal), cantos retos em todo o site.
   ========================================================================== */

:root {
  --bg: #f6f5f1;
  --surface: #ebeae5;
  --surface-2: #e1e0da;
  --line: rgb(17 17 16 / 0.12);
  --text: #111110;
  --muted: #5d5d57;
  --accent: #ef4e12;
  --accent-ink: #ffffff;
  --accent-text: #c2410c;
  --error: #b42318;
  --shadow: 0 30px 70px rgb(60 40 20 / 0.14);

  --font: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --max: 1400px;
  --gutter: clamp(16px, 4vw, 48px);
  --nav-h: 68px;
  color-scheme: light;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; -webkit-user-drag: none; -webkit-touch-callout: none; user-select: none; }

/* Selo "Powered by Netlify" que o Netlify injeta na página (iframe #nl-badge-frame) */
#nl-badge-frame { display: none !important; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--text); color: var(--bg); padding: 10px 16px; font-weight: 700;
}
.skip:focus { top: 12px; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Tipografia ---------- */

.display {
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin: 0;
}

.h-xl { font-size: clamp(2.6rem, 5.4vw, 4.8rem); }
.h-lg { font-size: clamp(2rem, 3.6vw, 3.2rem); }
.h-md { font-size: clamp(1.5rem, 2.2vw, 2rem); }

.lead { color: var(--muted); font-size: clamp(1.05rem, 1.3vw, 1.15rem); max-width: 44ch; margin: 0; }
.body { color: var(--muted); max-width: 60ch; }
.accent { color: var(--accent); }

.eyebrow {
  display: inline-block;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--muted);
}

/* ---------- Botões ---------- */

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  border: 1px solid transparent;
  border-radius: 0;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.25s var(--ease), background-color 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.btn i { font-size: 1.15em; transition: transform 0.3s var(--ease); }
.btn:hover i { transform: translateX(3px); }
.btn:active { transform: translateY(1px) scale(0.98); }

.btn--primary { background: var(--text); color: var(--bg); }
.btn--primary:hover { background: var(--accent); color: var(--text); }

.btn--ghost { color: var(--text); background: transparent; padding-inline: 4px; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 6px; }
.btn--ghost:hover { text-decoration-color: var(--text); }

/* ---------- Navegação ---------- */

.nav {
  position: sticky; top: 0; z-index: 40;
  height: var(--nav-h);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
}
.nav .wrap { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.brand {
  display: flex; align-items: baseline; gap: 10px;
  text-decoration: none; font-weight: 600; letter-spacing: -0.01em; font-size: 1.05rem;
}
.brand__sub { color: var(--muted); font-weight: 400; font-size: 0.9rem; }
@media (max-width: 520px) { .brand__sub { display: none; } }

.nav__links { display: flex; align-items: center; gap: 32px; list-style: none; margin: 0; padding: 0; }
.nav__links a:not(.btn) {
  text-decoration: none; color: var(--muted); font-weight: 500; font-size: 0.95rem;
  transition: color 0.2s;
}
.nav__links a:not(.btn):hover { color: var(--text); }
.nav__links .btn { padding: 10px 18px; }

.nav__toggle {
  display: none;
  background: none; border: 0; width: 44px; height: 44px;
  align-items: center; justify-content: center; font-size: 1.3rem; cursor: pointer;
}

@media (max-width: 767px) {
  .nav__toggle { display: inline-flex; }
  .nav__links {
    position: fixed; inset: var(--nav-h) 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px var(--gutter) 24px;
    transform: translateY(-8px); opacity: 0; visibility: hidden;
    transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), visibility 0.25s;
  }
  .nav__links a:not(.btn) { display: block; padding: 14px 0; font-size: 1.1rem; color: var(--text); }
  .nav__links .btn { justify-content: center; margin-top: 12px; padding: 15px 24px; }
  .nav.is-open .nav__links { opacity: 1; visibility: visible; transform: none; }
}

/* ---------- Hero ---------- */

.hero { padding-block: clamp(24px, 4vw, 56px) clamp(40px, 5vw, 72px); }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.hero__copy { display: grid; gap: 28px; align-content: center; }
.hero__copy .display { max-width: 12ch; font-size: clamp(3rem, 6.6vw, 6.4rem); letter-spacing: -0.045em; line-height: 0.98; }
.hero__copy .display em { font-style: italic; font-weight: 500; color: var(--accent); padding-right: 0.06em; }
.hero__ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }

.hero__media { margin: 0; height: clamp(420px, calc(100dvh - var(--nav-h) - 96px), 720px); overflow: hidden; background: var(--surface); }
.hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 50%; }

@media (max-width: 899px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__media { height: auto; aspect-ratio: 1; max-width: 560px; }
}

/* ---------- Faixa de fotos em movimento (única no site) ---------- */

.strip { overflow: hidden; padding-block: 8px clamp(72px, 9vw, 128px); }
.strip__track { display: flex; gap: 8px; width: max-content; }
.strip__track a { flex: none; height: clamp(180px, 22vw, 300px); overflow: hidden; background: var(--surface); }
.strip__track img { height: 100%; width: auto; transition: transform 0.8s var(--ease); }
.strip__track a:hover img { transform: scale(1.05); }

@media (prefers-reduced-motion: no-preference) {
  .strip__track { animation: strip 70s linear infinite; }
  .strip:hover .strip__track, .strip:focus-within .strip__track { animation-play-state: paused; }
}
@media (prefers-reduced-motion: reduce) {
  .strip { overflow-x: auto; }
}
@keyframes strip { to { transform: translateX(-50%); } }

/* ---------- Secções ---------- */

.section { padding-block: clamp(72px, 10vw, 144px); }
.section--tight { padding-top: 0; }
.section__head { display: grid; gap: 18px; margin-bottom: clamp(36px, 5vw, 64px); }

/* ---------- Trabalhos ---------- */

.filters { display: flex; flex-wrap: wrap; gap: 4px 28px; margin-bottom: 40px; }
.chip {
  border: 0; background: transparent; border-radius: 0;
  padding: 6px 0; font-size: 0.95rem; font-weight: 500; cursor: pointer;
  color: var(--muted);
  border-bottom: 1px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.chip:hover { color: var(--text); }
.chip[aria-pressed="true"] { color: var(--text); border-bottom-color: var(--text); }

.works { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(48px, 6vw, 88px) clamp(24px, 3vw, 40px); }

.work { position: relative; display: grid; gap: 20px; text-decoration: none; }
.work__media { position: relative; display: grid; gap: 4px; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 16 / 11; overflow: hidden; }
.work__media figure { margin: 0; overflow: hidden; background: var(--surface); }
.work__media figure:first-child { grid-row: 1 / 3; }
.work__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease), filter 0.5s var(--ease); }
.work:hover .work__media img { transform: scale(1.045); }

.work__meta { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.work__title { font-size: clamp(1.4rem, 2vw, 1.75rem); }
.work__info { margin: 6px 0 0; color: var(--muted); font-size: 0.95rem; }
.work__go { flex: none; font-size: 1.3rem; color: var(--muted); transition: color 0.3s var(--ease), transform 0.3s var(--ease); }
.work:hover .work__go { color: var(--text); transform: translate(3px, -3px); }

/* Trabalho em destaque (o mais recente) ocupa a largura toda */
.work--featured { grid-column: 1 / -1; }
.work--featured .work__media { aspect-ratio: 21 / 9; grid-template-columns: 3fr 1fr 1fr; grid-template-rows: 1fr; }
.work--featured .work__media figure:first-child { grid-row: auto; }
.work--featured .work__title { font-size: clamp(1.8rem, 3vw, 2.6rem); }

@media (max-width: 767px) {
  .works { grid-template-columns: 1fr; }
  .work--featured .work__media { aspect-ratio: 4 / 3; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; }
  .work--featured .work__media figure:first-child { grid-row: 1 / 3; }
  .work--featured .work__media figure:nth-child(3) { display: block; }
}

.work__cat { margin: 0 0 8px; font-size: 0.9rem; color: var(--muted); display: flex; align-items: center; gap: 10px; }
.work__score { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }

.empty {
  grid-column: 1 / -1;
  border: 1px dashed var(--line); padding: 48px 24px; text-align: center; color: var(--muted);
}

/* ---------- Sobre ---------- */

.about { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: end; }
.about__img { margin: 0; aspect-ratio: 4 / 5; overflow: hidden; background: var(--surface); }
.about__img img { width: 100%; height: 100%; object-fit: cover; }
.about__copy { display: grid; gap: 28px; }
.about__copy p { margin: 0; }
.about__texto { display: grid; gap: 28px; }

.services { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 40px; margin-top: 16px; }
.service { display: grid; gap: 6px; align-content: start; }
.service i { font-size: 1.4rem; color: var(--muted); }
.service h3 { margin: 6px 0 0; font-size: 1.05rem; font-weight: 600; }
.service p { margin: 0; color: var(--muted); font-size: 0.95rem; }

@media (max-width: 899px) {
  .about { grid-template-columns: 1fr; }
  .about__img { max-width: 480px; }
}
@media (max-width: 520px) {
  .services { grid-template-columns: 1fr; }
}

/* ---------- Orçamento ---------- */

.quote .wrap { border-top: 1px solid var(--line); padding-top: clamp(56px, 8vw, 112px); }
.quote { padding-top: 0; }
.quote__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); }
.quote__aside { display: grid; gap: 24px; align-content: start; }
.quote__contacts { display: grid; gap: 12px; margin-top: 8px; }
.quote__contacts a { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; }
.quote__contacts a:hover { color: var(--accent-text); }
.quote__contacts i { font-size: 1.3rem; }

.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 32px; }
.field { display: grid; gap: 6px; align-content: start; }
.field--full { grid-column: 1 / -1; }
.field label, .field legend { font-weight: 500; font-size: 0.9rem; color: var(--muted); padding: 0; }
.field .opt { color: var(--muted); font-weight: 400; opacity: 0.8; }
.field input, .field select, .field textarea {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  padding: 10px 0;
  min-height: 46px;
  transition: border-color 0.2s;
}
.field select option { background: var(--bg); color: var(--text); }
.field textarea { min-height: 110px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: color-mix(in srgb, var(--muted) 85%, transparent); }
.field input:hover, .field select:hover, .field textarea:hover { border-bottom-color: color-mix(in srgb, var(--text) 45%, transparent); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom-color: var(--text); }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 10px) 20px, calc(100% - 4px) 20px; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 28px; }
.field .help { color: var(--muted); font-size: 0.85rem; margin: 0; }
.field .err { color: var(--error); font-size: 0.85rem; margin: 0; min-height: 0; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--error); }

.err--check { grid-column: 1 / -1; color: var(--error); font-size: 0.85rem; margin: -12px 0 0; }
.check { grid-column: 1 / -1; display: flex; gap: 12px; align-items: flex-start; font-size: 0.92rem; color: var(--muted); }
.check input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex: none; }

.form__foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.form__status { margin: 0; font-size: 0.95rem; }
.form__status.is-error { color: var(--error); }
.btn[aria-busy="true"] { opacity: 0.7; pointer-events: none; }

.form-done { grid-column: 1 / -1; display: grid; gap: 14px; }
.form-done i { font-size: 2rem; color: var(--text); }
.form-done h3 { margin: 0; }
.form-done p { margin: 0; color: var(--muted); }

@media (max-width: 899px) {
  .quote__grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .form { grid-template-columns: 1fr; }
}

/* ---------- Rodapé ---------- */

.footer { border-top: 1px solid var(--line); padding-block: 40px; }
.footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; color: var(--muted); font-size: 0.9rem; }
.footer a { text-decoration: none; color: var(--text); display: inline-flex; align-items: center; gap: 8px; }
.footer a:hover { color: var(--accent-text); }
/* Link para a área reservada: de propósito pouco visível, numa linha à parte no fundo */
.footer__fundo { margin-top: 36px; }
.footer .footer__reservada { color: color-mix(in srgb, var(--muted) 45%, var(--bg)); font-size: 0.75rem; }
.footer .footer__reservada:hover, .footer .footer__reservada:focus-visible { color: var(--muted); }

/* ==========================================================================
   Página de jogo
   ========================================================================== */

.game-hero { position: relative; min-height: min(78dvh, 760px); display: grid; align-items: end; overflow: hidden; isolation: isolate; }
.game-hero__img { position: absolute; inset: 0; z-index: -2; }
.game-hero__img img { width: 100%; height: 100%; object-fit: cover; }
.game-hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgb(10 10 10 / 0.15) 0%, rgb(10 10 10 / 0.35) 45%, rgb(10 10 10 / 0.88) 100%);
}
.game-hero__copy { padding-block: 48px clamp(40px, 6vw, 72px); color: #f1f0ec; display: grid; gap: 18px; }
.game-hero__copy .back { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 600; font-size: 0.92rem; opacity: 0.85; width: fit-content; }
.game-hero__copy .back:hover { opacity: 1; }
.game-hero__img img { object-position: 50% 30%; }
.game-hero__meta { display: flex; flex-wrap: wrap; gap: 6px 24px; color: rgb(241 240 236 / 0.82); font-size: 0.98rem; margin: 0; padding: 0; list-style: none; }
.game-hero__meta li { display: inline-flex; align-items: center; gap: 8px; }

.tabs {
  position: sticky; top: var(--nav-h); z-index: 30;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.tabs__list { display: flex; gap: 32px; overflow-x: auto; scrollbar-width: none; list-style: none; margin: 0; padding: 0; }
.tabs__list::-webkit-scrollbar { display: none; }
.tabs__list a {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  padding: 18px 0 16px; text-decoration: none; font-weight: 500; font-size: 0.95rem; color: var(--muted);
  border-bottom: 1px solid transparent; margin-bottom: -1px;
  transition: color 0.2s, border-color 0.2s;
}
.tabs__list a span { opacity: 0.6; font-variant-numeric: tabular-nums; }
.tabs__list a:hover { color: var(--text); }
.tabs__list a.is-active { color: var(--text); border-bottom-color: var(--text); }

.gallery-section { padding-block: clamp(48px, 7vw, 96px) 0; }
.gallery-section__head { display: flex; align-items: baseline; gap: 16px; margin-bottom: 28px; }
.gallery-section__head p { margin: 0; color: var(--muted); }

.masonry { columns: 3 300px; column-gap: 8px; }
.masonry button {
  display: block; width: 100%; padding: 0; border: 0; margin: 0 0 8px; background: var(--surface);
  cursor: zoom-in; overflow: hidden; break-inside: avoid; position: relative;
}
.masonry img { width: 100%; height: auto; transition: transform 0.8s var(--ease), opacity 0.6s var(--ease); }
.masonry img.is-loading { opacity: 0; }
.masonry button:hover img { transform: scale(1.03); }

.game-cta { padding-block: clamp(72px, 10vw, 140px); }
.game-cta__box { display: grid; gap: 24px; justify-items: start; border-top: 1px solid var(--line); padding-top: clamp(40px, 6vw, 72px); }

.more-title { margin: clamp(64px, 8vw, 112px) 0 28px; }
.more-games { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.mini { text-decoration: none; display: grid; gap: 12px; }
.mini figure { margin: 0; aspect-ratio: 3 / 2; overflow: hidden; background: var(--surface); }
.mini img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s var(--ease); }
.mini:hover img { transform: scale(1.04); }
.mini strong { font-weight: 600; font-size: 1.1rem; letter-spacing: -0.01em; line-height: 1.2; }
.mini span { color: var(--muted); font-size: 0.9rem; }
@media (max-width: 767px) { .more-games { grid-template-columns: 1fr; } }

.notfound { min-height: 60dvh; display: grid; align-content: center; gap: 24px; justify-items: start; }

/* ---------- Lightbox ---------- */

.lightbox {
  position: fixed; inset: 0; z-index: 90; width: 100%; height: 100%; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0; background: rgb(8 8 8 / 0.96); color: #f1f0ec;
}
.lightbox::backdrop { background: transparent; }
.lightbox[open] { display: grid; grid-template-rows: auto 1fr auto; }
.lightbox__bar { display: flex; justify-content: space-between; align-items: center; padding: 14px var(--gutter); font-size: 0.92rem; color: rgb(241 240 236 / 0.75); font-variant-numeric: tabular-nums; }
.lightbox__stage { position: relative; display: grid; place-items: center; min-height: 0; padding: 0 clamp(8px, 6vw, 88px); }
.lightbox__stage img { max-width: 100%; max-height: calc(100dvh - 150px); width: auto; height: auto; object-fit: contain; transition: opacity 0.3s var(--ease), transform 0.4s var(--ease); }
.lightbox__stage img.is-swapping { opacity: 0; transform: scale(0.985); }
.lb-btn {
  display: grid; place-items: center; width: 48px; height: 48px; background: rgb(241 240 236 / 0.08); border: 1px solid rgb(241 240 236 / 0.16);
  color: #f1f0ec; font-size: 1.3rem; cursor: pointer; transition: background-color 0.2s;
}
.lb-btn:hover { background: rgb(241 240 236 / 0.18); }
.lb-prev, .lb-next { position: absolute; top: 50%; transform: translateY(-50%); }
.lb-prev { left: clamp(8px, 2vw, 24px); }
.lb-next { right: clamp(8px, 2vw, 24px); }
.lightbox__caption { padding: 14px var(--gutter) 20px; text-align: center; font-size: 0.92rem; color: rgb(241 240 236 / 0.7); }
@media (max-width: 600px) { .lb-prev, .lb-next { top: auto; bottom: -58px; transform: none; } .lightbox__caption { padding-bottom: 76px; } }

/* ---------- Movimento ---------- */

@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); transition-delay: calc(var(--i, 0) * 80ms); }
  .reveal.is-in { opacity: 1; transform: none; }

  .hero__copy > * { animation: rise 0.9s var(--ease) both; }
  .hero__copy > *:nth-child(2) { animation-delay: 0.08s; }
  .hero__copy > *:nth-child(3) { animation-delay: 0.16s; }
  .hero__copy > *:nth-child(4) { animation-delay: 0.24s; }
  .hero__media { animation: unveil 1.3s var(--ease) 0.1s both; }
  .game-hero__img img { animation: settle 1.8s var(--ease) both; }
}

/* Zoom suave das imagens ao entrarem no ecrã (só em browsers com scroll-driven animations) */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .hero__media img, .work__media figure:first-child img, .about__img img {
      animation: zoom-out linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 60%;
    }
  }
}
@keyframes zoom-out { from { transform: scale(1.18); } to { transform: scale(1); } }

@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes unveil { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes settle { from { transform: scale(1.08); } to { transform: scale(1); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ==========================================================================
   Área reservada (admin.html)
   ========================================================================== */

.a-carregar { padding-block: 120px; color: var(--muted); }

.admin { padding-block: clamp(40px, 6vw, 80px) 120px; display: grid; gap: 28px; align-content: start; }
.admin__topo { display: grid; gap: 12px; }
.admin__topo .body { margin: 0; }
.admin__acoes { display: flex; flex-wrap: wrap; gap: 12px; }
.admin__nota { margin: 8px 0 0; }

.nav__links--sempre { position: static !important; flex-direction: row !important; opacity: 1 !important; visibility: visible !important; transform: none !important; background: none !important; border: 0 !important; padding: 0 !important; gap: 24px !important; }
.nav__links--sempre a { padding: 0 !important; font-size: 0.95rem !important; color: var(--muted) !important; }
.nav__sair { background: none; border: 0; padding: 0; cursor: pointer; color: var(--muted); font-weight: 500; font-size: 0.95rem; }
.nav__sair:hover { color: var(--text); }

.form--estreito { max-width: 440px; grid-template-columns: 1fr; }
fieldset.form { border: 0; margin: 0; padding: 0; min-width: 0; }

.aviso { margin: 0; padding: 14px 16px; font-size: 0.95rem; border-left: 3px solid var(--error); background: color-mix(in srgb, var(--error) 8%, transparent); color: var(--error); grid-column: 1 / -1; }
.aviso--ok { border-left-color: #1f7a45; background: color-mix(in srgb, #1f7a45 9%, transparent); color: #1a6a3b; }

.otp { display: grid; gap: 14px; justify-items: start; }
.otp__qr { width: 200px; height: 200px; background: #fff; padding: 8px; }
.otp__chave { font-size: 0.9rem; word-break: break-all; user-select: all; }
.otp__entrada { font-size: 1.6rem !important; letter-spacing: 0.3em; font-variant-numeric: tabular-nums; max-width: 240px; }

.btn:disabled { opacity: 0.55; pointer-events: none; }
.btn--perigo { color: var(--error); }

/* Lista de trabalhos */
.admin-lista { display: grid; gap: 1px; background: var(--line); border-block: 1px solid var(--line); }
.admin-item { display: grid; grid-template-columns: 104px minmax(0, 1fr) auto; gap: 20px; align-items: center; padding: 16px 0; background: var(--bg); }
.admin-item figure { margin: 0; width: 104px; aspect-ratio: 4 / 3; overflow: hidden; background: var(--surface); display: grid; place-items: center; color: var(--muted); font-size: 1.6rem; }
.admin-item img { width: 100%; height: 100%; object-fit: cover; }
.admin-item h2 { margin: 0; font-size: 1.15rem; font-weight: 600; letter-spacing: -0.01em; }
.admin-item p { margin: 4px 0 0; color: var(--muted); font-size: 0.92rem; }
.admin-item__botoes { display: flex; flex-wrap: wrap; gap: 4px 16px; justify-content: flex-end; }
.estado--on { color: #1a6a3b !important; }
.estado--off { color: var(--accent-text) !important; }
@media (max-width: 700px) {
  .admin-item { grid-template-columns: 80px minmax(0, 1fr); }
  .admin-item figure { width: 80px; }
  .admin-item__botoes { grid-column: 1 / -1; justify-content: flex-start; }
}

/* Editor */
.admin-editor { display: grid; gap: clamp(40px, 5vw, 64px); }
.admin-bloco { display: grid; gap: 16px; border-top: 1px solid var(--line); padding-top: 32px; justify-items: start; }
.admin-bloco > * { margin: 0; }
.admin-bloco > .form { justify-self: stretch; }
.admin-retratos { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 28px; width: 100%; }
.admin-retrato { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 20px; align-items: start; }
.admin-retrato__info { display: grid; gap: 10px; justify-items: start; }
.admin-retrato__info h3 { margin: 0; font-size: 1.05rem; font-weight: 600; }
.admin-retrato__info .help { margin: 0; }
.admin-retrato__botoes { display: flex; flex-wrap: wrap; gap: 8px; }
.admin-retrato__botoes .btn { cursor: pointer; }
.admin-bloco h2 .opt { font-size: 1rem; font-weight: 400; color: var(--muted); letter-spacing: 0; }
.admin-bloco--fim { gap: 20px; }
#seccoes { display: grid; gap: 28px; width: 100%; }

.admin-seccao { display: grid; gap: 14px; padding: 20px; background: var(--surface); }
.admin-seccao__topo { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.admin-seccao__nome { flex: 1 1 220px; font: inherit; font-size: 1.2rem; font-weight: 600; background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 6px 0; }
.admin-seccao__nome:focus { outline: none; border-bottom-color: var(--text); }
.admin-seccao__botoes { display: flex; gap: 4px; }
.admin-seccao__estado { margin: 0; min-height: 1.2em; }

.icone { display: inline-grid; place-items: center; min-width: 36px; height: 36px; padding: 0 8px; border: 0; background: var(--bg); color: var(--text); cursor: pointer; font-size: 1.05rem; }
.icone:hover { background: var(--text); color: var(--bg); }
.icone:disabled { opacity: 0.35; pointer-events: none; }
.icone__texto { font-size: 0.85rem; font-weight: 600; color: var(--error); }

.admin-fotos { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; width: 100%; }
.admin-foto { position: relative; margin: 0; aspect-ratio: 1; overflow: hidden; background: var(--bg); }
.admin-foto img { width: 100%; height: 100%; object-fit: cover; }
.admin-foto .icone { position: absolute; top: 6px; min-width: 30px; height: 30px; font-size: 0.95rem; background: rgb(17 17 16 / 0.6); color: #fff; }
.admin-foto .icone:hover { background: rgb(17 17 16 / 0.9); }
.icone--capa { left: 6px; }
.icone--tirar { right: 6px; }
.admin-foto.is-capa { outline: 3px solid var(--accent); outline-offset: -3px; }
.admin-foto.is-capa .icone--capa { background: var(--accent); color: var(--text); }
.admin-foto--por { display: grid; place-content: center; justify-items: center; gap: 6px; border: 1px dashed color-mix(in srgb, var(--text) 30%, transparent); cursor: pointer; color: var(--muted); font-size: 0.9rem; font-weight: 500; transition: color 0.2s, border-color 0.2s; }
.admin-foto--por i { font-size: 1.5rem; }
.admin-foto--por:hover, .admin-foto--por:focus-within { color: var(--text); border-color: var(--text); }

.check--forte { font-size: 1rem; color: var(--text); font-weight: 600; }
