/* MIRA Admin — chique, como o site: preto e verde-escuro, cartões escuros, serif nos títulos, respiro. Sem vídeo. */
[hidden] { display: none !important; }
* { box-sizing: border-box; }
:root {
  --bg: #0b0b0b;
  --panel: #141414;
  --panel2: #1a1a1a;
  --line: #2b2b2b;
  --text: #ffffff;
  --muted: #bbbbbb;
  --green: #0b3d2e;
  --green2: #145a44;
  --lime: #c6f16d;
  --danger: #7a1f1f;
}
body {
  margin: 0;
  background: linear-gradient(to bottom, #000000 0%, #0b3d2e 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Inter", ui-sans-serif, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
}
.topbar, .wrap { position: relative; z-index: 1; }
.topbar {
  display: flex; flex-wrap: wrap; gap: 1rem;
  align-items: center; justify-content: space-between;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #222222;
  background: #0b0b0b;
  color: #ffffff;
  position: sticky; top: 0; z-index: 10;
}
.brand { font-size: 1.6rem; letter-spacing: .32em; color: #ffffff; text-decoration: none; }
.brand-sub { margin-left: .75rem; color: #bbbbbb; }
.topbar-actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.session-email { color: #c6f16d; font-size: .9rem; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 1.5rem 1rem 4rem; }
.card, .panel {
  background: var(--panel);
  color: #ffffff;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 2rem;
  margin-bottom: 1.5rem;
}
h1, h2, h3 { font-family: "Source Serif 4", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif; line-height: 1.2; }
h1 { font-size: 2rem; margin-top: 0; }
h2 { font-size: 1.7rem; margin-top: 0; }
h3 { font-size: 1.2rem; margin-top: 2rem; }
.lead { font-size: 1.05rem; }
.help { color: var(--muted); font-size: .95rem; }
label { display: block; font-weight: 600; margin: 1rem 0 .35rem; }
input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
input[type="number"], input[type="date"], textarea, select {
  width: 100%;
  background: #1a1a1a; color: #ffffff;
  border: 1px solid #333333;
  border-radius: 12px;
  padding: .7rem .9rem;
  font: inherit;
}
input[type="file"] { font: inherit; color: #ffffff; max-width: 100%; }
input[type="checkbox"] { width: auto; accent-color: #22c55e; }
.inline-form { display: grid; gap: .25rem; }
.inline-form label { margin-top: .6rem; }
/* Botões: secundário cinzento por omissão; um único primário verde por formulário; vermelho sólido só para apagar. */
.btn {
  display: inline-block;
  background: #1a1a1a; color: #ffffff;
  border: 1px solid #333333;
  border-radius: 999px;
  padding: .55rem 1.1rem;
  font: inherit; font-weight: 600;
  cursor: pointer; text-decoration: none; text-align: center;
  box-shadow: none;
}
.btn:hover, .btn:focus-visible { background: #222222; outline: none; }
.btn-secondary { background: #1a1a1a; color: #ffffff; border-color: #333333; }
.btn-primary {
  background: linear-gradient(135deg, #0b3d2e, #22c55e); color: #ffffff;
  border-color: transparent;
  box-shadow: 0 8px 24px rgba(34, 197, 94, .35);
}
.btn-primary:hover, .btn-primary:focus-visible { filter: brightness(1.1); }
.btn-danger { background: #c81e1e; color: #ffffff; border-color: #c81e1e; box-shadow: none; }
.btn-danger:hover, .btn-danger:focus-visible { background: #a31717; }
.btn-small { padding: .4rem .9rem; font-size: .9rem; }
/* Navegação: um botão "Secções" que abre uma lista agrupada; nunca 17 botões de uma vez. */
.admin-nav { margin-bottom: 1.5rem; }
.nav-menu-btn {
  width: 100%;
  background: #141414; color: #ffffff;
  border: 1px solid #2b2b2b; border-radius: 12px;
  padding: .8rem 1.1rem; font: inherit; font-weight: 700; cursor: pointer; text-align: left;
}
.admin-nav-list {
  background: #141414; border: 1px solid #2b2b2b; border-radius: 12px;
  padding: .75rem; margin-top: .5rem;
}
.nav-group { margin-bottom: .75rem; }
.nav-group h3 { color: #a3e635; font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; margin: .5rem 0 .35rem; }
.nav-item {
  display: block; width: 100%; text-align: left;
  background: #1a1a1a; color: #ffffff;
  border: 1px solid #2b2b2b; border-radius: 10px;
  padding: .6rem .9rem; margin-bottom: .35rem;
  font: inherit; font-weight: 600; cursor: pointer;
}
.nav-item:hover, .nav-item:focus-visible { background: #222222; outline: none; }
.nav-item.active { background: linear-gradient(135deg, #0b3d2e, #22c55e); color: #ffffff; border-color: transparent; }
.back-to-sections { margin-bottom: 1rem; }
.backup-row { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1rem 0; }
.steps li { margin-bottom: .7rem; }
.summary { display: flex; flex-wrap: wrap; gap: .75rem; }
.summary span {
  background: #1a1a1a; color: #ffffff; border: 1px solid var(--line);
  border-radius: 999px; padding: .45rem 1rem;
}
/* Tabelas a sério: cabeçalho, linhas, bordas, botões de ação. */
.table-wrap { overflow-x: auto; margin: 1rem 0; }
table { width: 100%; border-collapse: collapse; min-width: 640px; }
th, td {
  text-align: left; vertical-align: middle;
  padding: .7rem .8rem;
  border-bottom: 1px solid var(--line);
}
thead th {
  background: #0b3d2e;
  color: #fff; font-size: .85rem;
  letter-spacing: .08em; text-transform: uppercase;
}
tbody tr:hover { background: #1f1f1f; }
td .btn { margin: .15rem .25rem .15rem 0; }
td img.thumb, img.thumb {
  width: 110px; height: auto; max-height: 80px;
  object-fit: contain; background: #000000;
  border: 1px solid var(--line); border-radius: 8px; display: block;
}
td video.thumb, video.thumb {
  width: 140px; height: auto; max-height: 90px;
  background: #000000; border: 1px solid var(--line); border-radius: 8px; display: block;
}
.preview-row { display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-start; }
.preview-row img { width: 100%; max-width: 420px; height: auto; border: 1px solid var(--line); border-radius: 12px; }
.empty { color: var(--muted); padding: 1.25rem 0; }
.badge {
  display: inline-block; border-radius: 999px; padding: .2rem .8rem;
  font-size: .85rem; font-weight: 700; background: var(--panel2);
  border: 1px solid var(--line);
}
.badge.new { background: var(--green); border-color: var(--green); }
.chat-box { border: 1px solid var(--line); border-radius: 12px; padding: 1rem; margin: 1rem 0; background: #1a1a1a; color: #ffffff; }
.chat-msg { margin: .5rem 0; }
.chat-msg .who { font-weight: 700; color: #a3e635; }
.chat-msg.reply { margin-left: 1.5rem; }
.chat-msg.reply .who { color: #a3e635; }
.chat-reply-row { display: flex; gap: .5rem; margin-top: .75rem; }
.chat-reply-row input { flex: 1; }
.toast {
  position: fixed; left: 50%; bottom: 1.5rem; transform: translateX(-50%);
  background: var(--green); color: #fff; font-weight: 700;
  padding: .8rem 1.5rem; border-radius: 999px;
  box-shadow: 0 8px 30px rgba(0,0,0,.6);
  opacity: 0; pointer-events: none; transition: opacity .25s;
  max-width: 92vw; text-align: center; z-index: 50;
}
.toast.show { opacity: 1; }
@media (max-width: 768px) {
  .wrap { padding: 1rem .75rem 3rem; }
  .card, .panel { padding: 1rem; }
  .brand-sub { display: block; margin-left: 0; }
  .topbar-actions { width: 100%; }
  .topbar-actions .btn { flex: 1 1 auto; padding: .6rem 1rem; }
  .nav-menu-btn { padding: .8rem 1rem; }
  table { min-width: 560px; }
}

/* Rodapé do painel: um botão principal, o resto secundário. */
.admin-footer { margin-top: 1.5rem; }
.admin-footer h2 { font-family: "Source Serif 4", ui-serif, Georgia, Cambria, "Times New Roman", Times, serif; }
.footer-actions { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; margin: 1rem 0; }
.btn-big { padding: .9rem 1.8rem; font-size: 1.05rem; }
@media (max-width: 768px) {
  .footer-actions .btn, .footer-actions .btn-big { width: 100%; text-align: center; }
  .service .body .cta, .service .body .btn-orcamento { width: 100%; }
}

/* Computador: a lista de secções fica como barra lateral à esquerda; no telemóvel fica escondida até tocar em "Secções". */
@media (min-width: 900px) {
  .admin-layout { display: grid; grid-template-columns: 240px 1fr; gap: 1.5rem; align-items: start; }
  .admin-nav { position: sticky; top: 76px; }
  .nav-menu-btn { display: none; }
  .admin-nav-list { display: block !important; margin-top: 0; }
}

/* Porta de entrada chique: cartão escuro centrado, título serif, campos e botão a largura total. */
#gate{max-width:440px;margin:3rem auto;padding:2.5rem 2rem;text-align:left}
#gate .gate-eyebrow{color:#a3e635;font-size:.8rem;letter-spacing:.32em;text-transform:uppercase;font-weight:700;margin:0 0 .75rem}
#gate h1{font-size:2.2rem;margin-bottom:.5rem}
#gate p{color:#bbbbbb}
#gateForm .btn-primary{width:100%;padding:.95rem;font-size:1.05rem;margin-top:1.5rem}
#gate .help{font-size:.85rem;color:#888888;margin-top:1rem}

/* Botões bonitos de cada área, na secção Início: sem texto, só botões bem feitos. */
.area-grid{display:grid;grid-template-columns:1fr 1fr;gap:.75rem;margin:1rem 0 1.5rem}
.area-btn{background:linear-gradient(135deg,#0b3d2e,#22c55e);color:#ffffff;border:0;border-radius:16px;padding:1rem .75rem;font:inherit;font-weight:700;cursor:pointer;text-align:center;box-shadow:0 8px 24px rgba(34,197,94,.25)}
.area-btn:hover,.area-btn:focus-visible{filter:brightness(1.1);outline:none}
@media (max-width:480px){.area-grid{grid-template-columns:1fr 1fr}}
