/* ============================================================
   Drive Clientes â€“ Buscador de Fotos | styles.css
   100% responsivo: desktop, tablet, mobile
   ============================================================ */

/* â”€â”€â”€ RESET â”€â”€â”€ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ─── TOKENS (Intima Passion — Drive Interface) ─── */
:root {
  /* Light Mode — Paleta original Intima Passion */
  --bg-base: #F8F7F4;
  --bg-surface: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-hover: #F1EFE9;
  --bg-input: #FFFFFF;
  --border: #E5E1D8;
  --border-focus: rgba(45, 30, 23, 0.4);
  --text-primary: #2D1E17;
  --text-secondary: #2D1E17;
  --text-muted: #827C75;
  --accent-brown: #2D1E17;
  --accent-cream: #F1EFE9;
  --accent-taupe: #B9A392;
  --accent-sage: #728989;
  --accent-pink: #2D1E17;
  --accent-purple: #728989;
  --accent-grad: linear-gradient(135deg, #2D1E17, #728989);
  --accent-grad-h: linear-gradient(135deg, #3D2B22, #859898);
  --card-shadow: 0 4px 24px rgba(45, 30, 23, 0.08);
  --glow-pink: 0 0 40px rgba(45, 30, 23, 0.1);
  --header-bg: rgba(248, 245, 240, 0.85);
  --toolbar-bg: rgba(255, 255, 255, 0.95);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;
  --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  --font: 'Outfit', 'Montserrat', system-ui, sans-serif;
  --lb-topbar: 64px;

  /* Variáveis NEXOS — Paleta Roxo/Chumbo (Global) */
  --nexus-purple: #7C3AED;
  --nexus-purple-dark: #5B21B6;
  --nexus-charcoal: #1C1C2E;
  --nexus-charcoal-2: #2D2D3F;
  --nexus-light: #F8FAFC;
  --nexus-border: #E2E8F0;

  --bg-base: #F8FAFC;
  --bg-surface: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-hover: #F1F5F9;
  --bg-input: #FFFFFF;
  --border: #E2E8F0;
  --border-focus: #7C3AED;
  --text-primary: #1E293B;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  --accent-primary: #7C3AED;
  --accent-grad: linear-gradient(135deg, var(--brand-primary), var(--nexus-purple-dark));
  --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);

  /* Branding Dinâmico (Sobrescrevível via JS) */
  --brand-primary: #7C3AED;
  --primary-rgb: 124, 58, 237;
  --brand-secondary: #1C1C2E;
  --folder-color: #2D1E17;
  --icon-color: #2D1E17;
}

/* Dark Mode — Estilo Premium PassionLife */
body.dark-mode {
  --bg-base: #121212;
  --bg-surface: #1E1E1E;
  --bg-card: #1E1E1E;
  --bg-hover: #2A2A2A;
  --bg-input: #2a2a2a;
  --border: #2A2A2A;
  --border-focus: var(--nexus-purple);
  --text-primary: #F8FAFC;
  --text-secondary: #CBD5E1;
  --text-muted: #827C75;
  --accent-primary: var(--nexus-purple);
  --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  --header-bg: rgba(18, 18, 18, 0.9);
  --toolbar-bg: rgba(30, 30, 30, 0.95);
}

/* Forçar logo branco no Dark Mode */
body.dark-mode .brand-logo,
body.dark-mode .login-logo-img {
  filter: brightness(0) invert(1) !important;
}

/* ─────────────────────────────────────────────
   Gerenciamento de Pastas/Uploads (Admin)
   ───────────────────────────────────────────── */
.new-item-dropdown {
  position: relative;
  display: inline-block;
}

.header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.header-actions .btn-header {
  height: 38px;
  padding: 0 16px;
  border-radius: 100px;
  background: var(--bg-surface);
  border: 1.5px solid var(--border);
  color: var(--text-primary);
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.header-actions .btn-header:hover {
  background: var(--bg-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.header-actions .btn-header i {
  font-size: 1rem;
}

.header-actions .btn-header.btn-share i {
  color: #22C55E;
}

.header-actions .btn-header.btn-sync i {
  color: var(--text-muted);
}

.header-actions .btn-header.btn-logout i {
  color: #EF4444;
  /* Vermelho para sair */
}

@media (max-width: 600px) {
  .header-actions .btn-header span {
    display: none;
    /* Esconde o texto nos botões do header no mobile */
  }

  .header-actions .btn-header {
    padding: 0;
    width: 38px;
    justify-content: center;
  }

  .header-actions {
    gap: 6px;
  }

  .btn-new {
    padding: 0 !important;
    width: 38px;
    height: 38px !important;
    justify-content: center;
    border-radius: 50% !important;
  }

  .btn-new span {
    display: none;
  }

  .dropdown-menu {
    left: auto;
    right: -10px;
    transform: none;
    /* ajusta para não sair da tela no mobile */
  }

  .dropdown-menu::after {
    left: auto;
    right: 20px;
    transform: rotate(45deg);
  }
}

.btn-new {
  height: 42px;
  padding: 0 20px;
  background: var(--bg-surface);
  color: var(--text-primary);
  border: 1.5px solid var(--border);
  border-radius: 100px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all var(--transition);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.btn-new:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  min-width: 220px;
  padding: 8px 0;
  list-style: none;
  z-index: 1000;
  border: 1px solid rgba(0, 0, 0, 0.05);
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.dropdown-menu li {
  padding: 12px 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--text-primary);
  transition: background 0.2s;
}

.dropdown-menu li:hover {
  background: #f5f5f5;
}

.dropdown-menu li i {
  width: 20px;
  font-size: 1.1rem;
  color: var(--brand-primary);
  text-align: center;
}

.dropdown-menu::after {
  content: '';
  position: absolute;
  top: -6px;
  left: 20px;
  width: 12px;
  height: 12px;
  background: #fff;
  transform: rotate(45deg);
  border-left: 1px solid rgba(0, 0, 0, 0.05);
  border-top: 1px solid rgba(0, 0, 0, 0.05);
}

/* Empty State */
.no-folders-empty {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  border: 2px dashed #ddd;
  border-radius: 20px;
  color: var(--text-muted);
  text-align: center;
  margin-top: 20px;
  transition: all 0.3s;
}

.no-folders-empty i {
  font-size: 3rem;
  margin-bottom: 20px;
  opacity: 0.3;
}

.no-folders-empty.drag-over {
  background: rgba(var(--primary-rgb), 0.05);
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

/* Upload Progress */
.upload-progress-card {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 350px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
  z-index: 2000;
  overflow: hidden;
  animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.upload-progress-header {
  background: var(--brand-primary);
  color: #fff;
  padding: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
}

.close-progress {
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
  font-size: 1.1rem;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.close-progress:hover {
  opacity: 1;
}

.upload-progress-body {
  padding: 20px;
}

.progress-bar-container {
  width: 100%;
  height: 8px;
  background: #eee;
  border-radius: 4px;
  margin-bottom: 15px;
  overflow: hidden;
}

.progress-bar {
  width: 0%;
  height: 100%;
  background: var(--accent-grad);
  transition: width 0.3s;
}

.upload-details {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.upload-dragging-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 3000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #fff;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}

.upload-dragging-overlay i {
  font-size: 4rem;
  margin-bottom: 20px;
}

.upload-dragging-overlay.visible {
  opacity: 1;
}

/* Estilo Dark Mode */
body.dark-mode .btn-new {
  background: #252525;
  border-color: #333;
  color: #e2e8f0;
}

body.dark-mode .dropdown-menu {
  background: #252525;
  border-color: #333;
}

body.dark-mode .dropdown-menu li {
  color: #e2e8f0;
}

body.dark-mode .dropdown-menu li:hover {
  background: #333;
}

body.dark-mode .dropdown-menu::after {
  background: #252525;
  border-color: #333;
}

body.dark-mode .upload-progress-card {
  background: #252525;
}

body.dark-mode .progress-bar-container {
  background: #333;
}

body.dark-mode .no-folders-empty {
  border-color: #444;
}




html {
  scroll-behavior: smooth;
  font-size: 16px;
  /* Base 1rem = 16px */
}

body {
  font-family: var(--font);
  background: var(--bg-base);
  color: var(--text-primary);
  min-height: 100vh;
  min-height: 100dvh;
  /* Dynamic viewport height for mobile browsers */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  /* Prevent horizontal scroll */
  width: 100%;
}

.hidden {
  display: none !important;
}

.billing-notice {
  margin: 12px auto 0;
  width: min(1120px, calc(100% - 32px));
  border-radius: 18px;
  border: 1px solid rgba(245, 158, 11, 0.28);
  background: linear-gradient(135deg, rgba(255, 251, 235, 0.96), rgba(254, 243, 199, 0.96));
  color: #92400e;
  box-shadow: 0 16px 30px rgba(146, 64, 14, 0.08);
  padding: 14px 46px 14px 18px;
  position: relative;
}

.billing-notice strong {
  color: #78350f;
}

.billing-notice small {
  display: block;
  margin-top: 4px;
  color: #a16207;
}

.billing-notice-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(146, 64, 14, 0.22);
  background: rgba(255, 255, 255, 0.55);
  color: #78350f;
  display: grid;
  place-items: center;
  cursor: pointer;
  line-height: 1;
  font-size: 18px;
}

.billing-notice-close:hover {
  background: rgba(255, 255, 255, 0.8);
}

.billing-notice-close:active {
  transform: translateY(1px);
}

/* â”€â”€â”€ CONTROLE DE ROLES (Admin vs UsuÃ¡rio) â”€â”€â”€
 * Toda aÃ§Ã£o administrativa tem a classe .admin-only.
 * Por padrÃ£o, esses elementos sÃ£o invisÃ­veis para TODOS.
 * Apenas quando `body` tem a classe `is-admin` eles aparecem.
 * Mesmo que um usuÃ¡rio mude `is-admin` no F12, o servidor
 * ainda vai rejeitar as aÃ§Ãµes com erro 403.
 */
.admin-only {
  display: none !important;
}


body.is-admin .admin-only {
  display: flex !important;
}

body.locked {
  overflow: hidden;
  height: 100vh;
}

/* ─────────────────────────────────────────────────────────────
   Popup de redefinição de senha (MVP)
   ───────────────────────────────────────────────────────────── */
.nexos-overlay {
  position: fixed;
  inset: 0;
  background: rgba(17, 24, 39, 0.55);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 9999;
}

.nexos-modal {
  width: min(520px, 100%);
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid rgba(17, 24, 39, 0.08);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
  padding: 18px 18px 16px 18px;
}

.nexos-modal-header {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 8px;
}

.nexos-modal-logo {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  object-fit: contain;
  background: rgba(17, 24, 39, 0.03);
  border: 1px solid rgba(17, 24, 39, 0.08);
  padding: 6px;
}

.nexos-modal-title {
  margin: 0 0 6px 0;
  font-size: 18px;
  color: #111827;
}

.nexos-modal-subtitle {
  margin: 0 0 14px 0;
  color: #6b7280;
  font-size: 13px;
  line-height: 1.35;
}

.nexos-label {
  display: block;
  font-size: 12px;
  color: #374151;
  margin-bottom: 6px;
}

.nexos-input {
  width: 100%;
  border: 1px solid rgba(17, 24, 39, 0.16);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  outline: none;
}

.nexos-input-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.nexos-eye {
  width: 44px;
  height: 42px;
  border-radius: 10px;
  border: 1px solid rgba(17, 24, 39, 0.16);
  background: #ffffff;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
}

.nexos-input:focus {
  border-color: rgba(var(--primary-rgb, 124, 58, 237), 0.55);
  box-shadow: 0 0 0 4px rgba(var(--primary-rgb, 124, 58, 237), 0.14);
}

.nexos-mt-12 {
  margin-top: 12px;
}

.nexos-error {
  margin-top: 12px;
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(220, 38, 38, 0.22);
  color: #b91c1c;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 13px;
}

.nexos-modal-actions {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
}

.nexos-btn {
  background: var(--brand-primary, #7C3AED);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  cursor: pointer;
}

.nexos-btn:disabled {
  opacity: 0.7;
  cursor: default;
}

/* â”€â”€â”€ HEADER â”€â”€â”€ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

/* Ãrea abaixo do header ocupa o espaÃ§o restante e centraliza */
.hero~.main,
.hero {
  flex-shrink: 0;
}

section.hero,
main.main {
  flex-shrink: 0;
}

/* Wrapper virtual: hero + main centralizados verticalmente */
/* CentralizaÃ§Ã£o vertical removida para eliminar o grande espaÃ§o branco */
body>section.hero,
body>main.main {
  margin-top: 0;
  margin-bottom: 0;
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 12px 24px;
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.btn-back-global {
  display: none !important;
}

.btn-back-global svg {
  width: 20px;
  height: 20px;
}

.brand {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.brand-logo,
.login-logo-img {
  height: 80px !important;
  max-height: 80px !important;
  width: auto;
  max-width: 250px;
  object-fit: contain;
  display: none !important;
  /* BLOQUEIO TOTAL inicial */
  opacity: 0 !important;
  transition: opacity 0.3s ease;
}

.brand-logo.reveal,
.login-logo-img.reveal {
  display: block !important;
  opacity: 1 !important;
}

/* Cortina de Carregamento */
#loadingCurtain {
  background: var(--bg-base, #ffffff) !important;
}

.loader-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid var(--brand-primary, #7C3AED);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

body.dark-mode .brand-logo {
  filter: brightness(0) invert(1);
}

.brand:hover .brand-logo {
  transform: scale(1.05);
}

@media (max-width: 768px) {
  .header-inner {
    padding: 8px 16px;
    min-height: 56px;
  }

  .brand-logo {
    height: 45px;
    max-height: 45px;
    margin: 0;
  }

  .btn-back-global {
    width: 38px;
    height: 38px;
  }
}


.header-stats {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-refresh {
  border-radius: 50%;
  width: 36px;
  height: 36px;
  background: var(--bg-hover);
  border-color: var(--border);
  flex-shrink: 0;
}

.header-refresh:hover {
  background: var(--accent-grad);
  color: white;
  border-color: transparent;
  transform: rotate(30deg);
}


.stat {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: var(--text-secondary);
}

.stat-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
  animation: pulse 2s infinite;
}

.stat-dot.offline {
  background: #f87171;
  box-shadow: 0 0 8px rgba(248, 113, 113, 0.6);
}

.stat-dot.loading {
  background: var(--accent-pink);
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.6;
    transform: scale(0.9);
  }
}

/* â”€â”€â”€ HERO â”€â”€â”€ */
.hero {
  position: relative;
  z-index: 50;
  padding: 40px 24px 30px;
  text-align: center;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 30% 0%, rgba(45, 30, 23, 0.05) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 70% 0%, rgba(114, 137, 137, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
  z-index: 10;
  /* Garante que o conteÃºdo do hero fique sobre o resto */
}

.hero-title {
  font-size: clamp(1.5rem, 7vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

@media (max-width: 480px) {
  .hero {
    padding: 20px 16px;
  }

  .hero-title {
    line-height: 1.1;
  }
}

.hero-subtitle {
  font-size: clamp(0.9rem, 4vw, 1.1rem);
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  font-weight: 400;
  max-width: 90%;
  margin-left: auto;
  margin-right: auto;
}

/* â”€â”€â”€ SEARCH â”€â”€â”€ */
.search-container {
  position: relative;
  /* ReferÃªncia para as sugestÃµes */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  width: 100%;
  max-width: 600px;
  /* Limita a largura do conjunto todo */
  margin: 0 auto;
}

.search-box {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  background: var(--bg-input);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-xl);
  transition: border-color var(--transition), box-shadow var(--transition);
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
  z-index: 2;
  /* Fica acima das sugestÃµes no encaixe */
}

.search-box:focus-within {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 4px rgba(var(--primary-rgb, 124, 58, 237), 0.1);
}

.search-icon {
  padding: 0 1rem 0 1.25rem;
  color: var(--text-muted);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.search-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

.search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font);
  font-size: 16px;
  /* Evita zoom automático no iOS */
  font-weight: 500;
  color: var(--text-primary);
  padding: 1.125rem 0;
  letter-spacing: 0.02em;
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
}

.search-input::-webkit-search-decoration,
.search-input::-webkit-search-cancel-button,
.search-input::-webkit-search-results-button,
.search-input::-webkit-search-results-decoration {
  display: none;
}

.search-input::placeholder {
  color: var(--text-muted);
  font-weight: 400;
}

.search-clear {
  padding: 0 1rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  opacity: 0;
  transition: opacity var(--transition), color var(--transition);
  flex-shrink: 0;
  min-width: 3rem;
  /* Better touch target */
  min-height: 3rem;
  justify-content: center;
}

.search-clear svg {
  width: 18px;
  height: 18px;
}

.search-clear.visible {
  opacity: 1;
}

.search-clear:hover {
  color: var(--text-primary);
}

/* â”€â”€â”€ SEARCH SUGGESTIONS â”€â”€â”€ */
.search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  margin-top: -10px;
  /* SobrepÃµe levemente o fundo da search-box */
  padding-top: 15px;
  box-shadow: 0 10px 40px rgba(45, 30, 23, 0.25);
  z-index: 9999;
  /* Valor altÃ­ssimo para sobrepor tudo */
  max-height: 400px;
  overflow-y: auto;
  text-align: left;
}

.search-suggestions.hidden {
  display: none !important;
}

.suggestion-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 20px;
  cursor: pointer;
  transition: background var(--transition);
  border-bottom: 1px solid rgba(45, 30, 23, 0.03);
}

.suggestion-item:last-child {
  border-bottom: none;
}

.suggestion-item:hover,
.suggestion-item.active {
  background: var(--bg-hover);
}

.suggestion-icon {
  width: 40px;
  height: 40px;
  background: var(--bg-hover);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-primary);
  flex-shrink: 0;
}

.suggestion-info {
  flex: 1;
  min-width: 0;
}

.suggestion-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.suggestion-meta {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* IntegraÃ§Ã£o da barra com as sugestÃµes (Parecer um sÃ³) */
.search-container.has-suggestions .search-box {
  border-radius: var(--radius-xl) var(--radius-xl) 0 0;
  border-bottom-color: transparent;
  box-shadow: none;
}

.search-container.has-suggestions .search-suggestions {
  border-top: 1px solid rgba(45, 30, 23, 0.05);
  margin-top: -1px;
  /* Encaixe perfeito */
  padding-top: 5px;
}


/* â”€â”€â”€ MAIN â”€â”€â”€ */
.main {
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
  padding: 0 1.5rem 2.5rem;
}

@media (max-width: 480px) {
  .main {
    padding: 0 1rem 2rem;
  }
}

/* â”€â”€â”€ ESTADOS â”€â”€â”€ */
.state-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  text-align: center;
  gap: 16px;
  animation: fadeUp 0.5s ease both;
}

.state-container.hidden {
  display: none;
}

.state-icon svg {
  width: 72px;
  height: 72px;
  filter: drop-shadow(0 0 20px rgba(249, 168, 212, 0.2));
}

.state-icon.muted svg {
  filter: none;
}

.state-icon.error svg {
  filter: drop-shadow(0 0 20px rgba(248, 113, 113, 0.2));
}

.state-container h2 {
  font-size: 22px;
  font-weight: 600;
  color: var(--text-primary);
}

.state-container p {
  font-size: 15px;
  color: var(--text-secondary);
  max-width: 400px;
  line-height: 1.6;
}

.loader-ring {
  display: inline-block;
  position: relative;
  width: 64px;
  height: 64px;
}

.loader-ring div {
  box-sizing: border-box;
  display: block;
  position: absolute;
  width: 52px;
  height: 52px;
  margin: 6px;
  border: 4px solid transparent;
  border-radius: 50%;
  animation: spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  border-top-color: var(--accent-pink);
}

.loader-ring div:nth-child(1) {
  animation-delay: -0.45s;
}

.loader-ring div:nth-child(2) {
  animation-delay: -0.3s;
  border-top-color: var(--accent-purple);
}

.loader-ring div:nth-child(3) {
  animation-delay: -0.15s;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.pulse-icon svg {
  width: 72px;
  height: 72px;
  animation: rotatePulse 3s linear infinite;
  filter: drop-shadow(0 0 20px rgba(249, 168, 212, 0.2));
}

@keyframes rotatePulse {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.btn-retry,
.btn-docs {
  margin-top: 8px;
  padding: 10px 24px;
  border-radius: 100px;
  border: 1.5px solid var(--brand-primary);
  background: transparent;
  color: var(--brand-primary);
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition);
  display: inline-block;
}

.btn-retry:hover,
.btn-docs:hover {
  background: var(--brand-primary);
  border-color: transparent;
  color: white;
}

.setup-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  max-width: 480px;
  margin: 40px auto;
  padding: 48px 32px;
}

.setup-icon {
  font-size: 48px;
  margin-bottom: 8px;
}

.setup-card code {
  font-family: 'Courier New', monospace;
  background: rgba(0, 0, 0, 0.06);
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 13px;
  color: var(--accent-pink);
}

/* â”€â”€â”€ RESULTADOS â”€â”€â”€ */
.results-container {
  animation: fadeUp 0.4s ease both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.results-info {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.results-title {
  font-size: 20px;
  font-weight: 700;
}

.results-count {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 400;
}

.results-actions {
  display: flex;
  gap: 8px;
}

.btn-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.btn-icon svg {
  width: 16px;
  height: 16px;
}

.btn-icon:hover {
  border-color: var(--accent-pink);
  color: var(--accent-pink);
  background: rgba(249, 168, 212, 0.06);
}

.btn-icon.spinning svg {
  animation: spin 1s linear infinite;
}

/* â”€â”€â”€ GRUPO DE REFERÃŠNCIA â”€â”€â”€ */
.ref-group {
  margin-bottom: 40px;
}

.ref-group-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.ref-badge {
  padding: 5px 14px;
  border-radius: 100px;
  background: var(--brand-primary);
  font-size: 13px;
  font-weight: 700;
  color: #FFFFFF;
  letter-spacing: 0.5px;
}

.ref-meta {
  font-size: 13px;
  color: var(--text-muted);
}

.ref-meta span {
  color: var(--text-secondary);
  font-weight: 500;
}

/* â”€â”€â”€ MULTI-SELECT â”€â”€â”€ */
.photo-card-select {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 28px;
  height: 28px;
  background: rgba(255, 255, 255, 0.9);
  border: 2px solid var(--border);
  border-radius: 8px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition);
  color: transparent;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.photo-card-select:hover {
  transform: scale(1.1);
  background: white;
  border-color: var(--accent-brown);
}

.photo-card.selected .photo-card-select {
  background: var(--brand-primary);
  border-color: var(--brand-primary);
  color: white;
}

.photo-card.selected {
  outline: 3px solid var(--brand-primary);
  outline-offset: -3px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.2);
}

.photo-card-select i {
  font-size: 14px;
}

.selection-toolbar {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(120px);
  opacity: 0;
  visibility: hidden;
  background: var(--toolbar-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 12px 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  z-index: 1500;
  display: flex;
  align-items: center;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease, visibility 0.3s ease;
}

.selection-toolbar.visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
}

.selection-toolbar-inner {
  display: flex;
  align-items: center;
  gap: 20px;
}

.selection-count {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  border-right: 1px solid var(--border);
  padding-right: 20px;
  white-space: nowrap;
}

.selection-actions {
  display: flex;
  gap: 12px;
}

.btn-selection {
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 100px;
  padding: 10px 20px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn-selection i {
  font-size: 14px;
}

.btn-selection.btn-primary {
  background: var(--brand-primary);
  color: white;
  border-color: var(--brand-primary);
}

.btn-selection.btn-primary:hover {
  background: #4A3226;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(45, 30, 23, 0.2);
}

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

@media (max-width: 768px) {
  .selection-toolbar {
    width: calc(100% - 24px);
    bottom: 12px;
    padding: 8px 12px;
    border-radius: 16px;
    max-width: 480px;
  }

  .selection-toolbar-inner {
    gap: 10px;
    width: 100%;
    justify-content: space-between;
    align-items: center;
  }

  .selection-count {
    padding-right: 10px;
    font-size: 12px;
    border-right: 1px solid var(--border);
    max-width: 70px;
    white-space: normal;
    line-height: 1.2;
    text-align: left;
  }

  .selection-actions {
    gap: 6px;
    flex: 1;
    display: flex;
    justify-content: flex-end;
  }

  .btn-selection {
    padding: 8px 10px;
    font-size: 11px;
    gap: 4px;
  }

  .btn-selection span {
    display: none;
  }

  .btn-selection i {
    font-size: 16px;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .btn-selection span {
    display: inline;
  }

  .selection-count {
    max-width: none;
    font-size: 13px;
  }
}

.ref-folder-name {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
  background: var(--bg-hover);
  padding: 3px 10px;
  border-radius: 100px;
  border: 1px solid var(--border);
  letter-spacing: 0.3px;
}

/* â”€â”€â”€ GRID DE FOTOS â”€â”€â”€ */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(clamp(140px, 20vw, 220px), 1fr));
  gap: clamp(8px, 2vw, 16px);
}

.photo-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  cursor: pointer;
  aspect-ratio: 3/4;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  animation: photoEnter 0.6s cubic-bezier(0.2, 0, 0.2, 1) both;
}

@keyframes photoEnter {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.photo-card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.15), var(--glow-pink);
  border-color: rgba(112, 29, 44, 0.3);
}

.photo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.photo-card:hover img {
  transform: scale(1.05);
}

.photo-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, transparent 40%);
  opacity: 0;
  transition: opacity var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 12px;
}

.photo-card:hover .photo-card-overlay {
  opacity: 1;
}

.photo-card-name {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.photo-card-brand {
  font-size: 11px;
  color: var(--accent-pink);
  font-weight: 600;
  margin-top: 2px;
}

.photo-skeleton {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-hover) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  from {
    background-position: 200% 0;
  }

  to {
    background-position: -200% 0;
  }
}

/* â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•
   LIGHTBOX
   â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•
   DESKTOP  â†’ flex coluna, top-bar absoluta, imagem flex:1
   MOBILE   â†’ grid 3 linhas (top-bar | imagem | footer)
   â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â• */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: stretch;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(18px);
}

/* â”€â”€ DESKTOP: flex coluna â”€â”€ */
.lightbox-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  height: 100%;
  padding: var(--lb-topbar) 20px 16px;
  gap: 10px;
  animation: lightboxIn 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes lightboxIn {
  from {
    opacity: 0;
    transform: scale(0.97);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Top-bar flutua acima tudo no desktop */
.lightbox-top-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: var(--lb-topbar);
  padding: 0 24px;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.65) 0%, transparent 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 20;
}

.lb-file-info {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  min-width: 0;
  flex: 1;
}

#lbFileName {
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 55vw;
  color: white;
}

.lightbox-close {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  backdrop-filter: blur(4px);
}

.lightbox-close svg {
  width: 18px;
  height: 18px;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.22);
  color: white;
  transform: scale(1.08);
}

/* Setas */
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(20, 20, 20, 0.55);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  z-index: 15;
  backdrop-filter: blur(6px);
}

.lightbox-nav svg {
  width: 20px;
  height: 20px;
}

.lightbox-nav.prev {
  left: 20px;
}

.lightbox-nav.next {
  right: 20px;
}

.lightbox-nav:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-50%) scale(1.08);
}

.lightbox-nav:disabled {
  opacity: 0.25;
  cursor: not-allowed;
  pointer-events: none;
}

/* Imagem â€” ocupa espaÃ§o livre */
.lightbox-img-wrapper {
  position: relative;
  width: 100%;
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.lightbox-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: var(--radius-md);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
  transition: opacity 0.2s ease, transform 0.12s ease-out;
  transform-origin: center center;
  user-select: none;
  cursor: grab;
}

.lightbox-img:active {
  cursor: grabbing;
}

.lightbox-img.dragging {
  transition: opacity 0.2s ease, transform 0s !important;
}

.lightbox-video {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
  position: relative;
  z-index: 5;
  /* Garante que os controles fiquem acima do backdrop */
  pointer-events: auto;
  /* Garante que os controles recebam cliques */
}

.lightbox-loader {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

/* Info */
.lightbox-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-align: center;
  flex-shrink: 0;
}

.lightbox-filename {
  font-weight: 700;
  color: white;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: min(600px, 80vw);
}

.lightbox-meta {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

/* AÃ§Ãµes */
.lightbox-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  flex-shrink: 0;
}

.lightbox-download,
.lightbox-drive,
.lightbox-rename {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 100px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all var(--transition);
  cursor: pointer;
  min-height: 42px;
}

.lightbox-download svg,
.lightbox-drive svg,
.lightbox-rename svg,
.lightbox-rename i {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}

.lightbox-download {
  background: #FFFFFF;
  color: #2D1E17;
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.lightbox-download:hover {
  background: #F8F7F4;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.lightbox-rename {
  appearance: none;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.9);
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
}

.lightbox-rename:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
}

.lightbox-download:focus-visible,
.lightbox-rename:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.75);
  outline-offset: 3px;
}


.lightbox-drive {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.75);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
}

.lightbox-drive:hover {
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border-color: rgba(255, 255, 255, 0.3);
}

.lightbox-counter {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.4);
  flex-shrink: 0;
  letter-spacing: 0.5px;
}

/* Zoom toolbar (desktop: absoluta sobre imagem) */
.lightbox-toolbar {
  display: none !important;
}

.zoom-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 50%;
  transition: all 0.15s;
}

.zoom-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: white;
  transform: scale(1.1);
}

.zoom-btn:active {
  transform: scale(0.92);
}

.zoom-btn svg {
  width: 20px;
  height: 20px;
  stroke-width: 2.2;
}

/* â”€â”€â”€ TOAST â”€â”€â”€ */
.toast {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 24px;
  border-radius: 100px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  z-index: 2000;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
  animation: toastIn 0.3s ease, toastOut 0.3s ease 2.7s forwards;
  backdrop-filter: blur(12px);
  white-space: nowrap;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@keyframes toastOut {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

/* â”€â”€â”€ EXPLORER / PASTAS â”€â”€â”€ */
.explorer-container {
  text-align: left;
  align-items: flex-start;
  padding: 20px 0;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
}

.explorer-title {
  display: none;
}

.breadcrumb-container {
  display: flex !important;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  padding: 0 20px;
}

/* --- FILTROS ESTILO GOOGLE DRIVE (MINIMALISTA) --- */
.explorer-filters {
  display: flex !important;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
  padding: 0 20px;
  background: transparent;
  width: 100%;
  animation: fadeUp 0.3s ease both;
}

.explorer-filters.hidden {
  display: none !important;
}

.filter-chip-wrapper {
  display: flex;
  align-items: center;
  gap: 4px;
}

.filter-chip-select {
  padding: 0 14px 0 12px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid #747775;
  background-color: transparent;
  color: #444746;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  transition: all 0.1s ease;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23444746' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 10px;
  padding-right: 32px;
  min-width: 80px;
}

.dark-mode .filter-chip-select {
  border-color: #8e918f;
  color: #e3e3e3;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23e3e3e3' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
}

.filter-chip-select:hover {
  background-color: rgba(68, 71, 70, 0.08);
}

.dark-mode .filter-chip-select:hover {
  background-color: rgba(227, 227, 227, 0.08);
}

.filter-chip-select:focus {
  background-color: rgba(68, 71, 70, 0.12);
}

.filter-clear-btn {
  width: 32px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid #747775;
  background: transparent;
  color: #444746;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.1s ease;
  flex-shrink: 0;
}

.filter-clear-btn i {
  font-size: 12px;
}

.filter-clear-btn:hover {
  background: rgba(68, 71, 70, 0.08);
}

.filter-chip-select.active {
  background-color: #c2e7ff;
  border-color: #c2e7ff;
  color: #001d35;
  font-weight: 600;
}

.filter-chip-select.active+.filter-clear-btn {
  background-color: #c2e7ff;
  border-color: #c2e7ff;
  color: #001d35;
  display: flex !important;
}

.dark-mode .filter-clear-btn {
  border-color: #8e918f;
  color: #e3e3e3;
}

.dark-mode .filter-clear-btn:hover {
  background: rgba(227, 227, 227, 0.08);
}

.dark-mode .filter-chip-select.active+.filter-clear-btn {
  background-color: #004a77;
  border-color: #004a77;
  color: #c2e7ff;
}

@media (max-width: 600px) {
  .explorer-filters {
    padding: 0 16px;
    gap: 8px;
    margin-bottom: 16px;
  }

  .filter-chip-select {
    height: 32px;
    font-size: 13px;
    padding: 0 10px 0 8px;
    padding-right: 28px;
  }
}

.btn-refresh-breadcrumb {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-surface);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  flex-shrink: 0;
}

.btn-refresh-breadcrumb svg {
  width: 18px;
  height: 18px;
}

.btn-refresh-breadcrumb:hover {
  background: var(--bg-hover);
  border-color: var(--accent-taupe);
  transform: rotate(30deg);
}

.btn-refresh-breadcrumb.spinning svg {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}


.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 0;
  font-size: 14px;
  font-weight: 500;
  width: 100%;
}

.crumb {
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
  padding: 6px 14px;
  border-radius: 100px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  font-size: 14px;
}

.crumb:hover {
  background: var(--accent-cream);
  border-color: var(--accent-taupe);
  color: var(--accent-pink);
  transform: translateY(-1px);
}

.crumb.active {
  background: var(--accent-grad);
  color: white;
  border-color: transparent;
  pointer-events: none;
}

.crumb:last-child {
  color: var(--text-primary);
  font-weight: 600;
  pointer-events: none;
}

.breadcrumb-separator,
.crumb-separator {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  opacity: 0.5;
}

.folder-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(clamp(150px, 25vw, 280px), 1fr));
  gap: clamp(10px, 2vw, 16px);
  width: 100%;
}

.folder-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  cursor: pointer;
  transition: all var(--transition);
  user-select: none;
  min-height: 4.5rem;
  position: relative;
  overflow: hidden;
}

.folder-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.folder-card:hover {
  background: var(--bg-hover);
  border-color: var(--accent-taupe);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.folder-icon {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--folder-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.folder-card:hover .folder-icon {
  filter: brightness(0.9);
}

.folder-name {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-align: left;
}

.folder-meta {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.no-folders {
  color: var(--text-muted);
  font-size: 15px;
  padding: 20px 0;
  width: 100%;
}

/* â”€â”€â”€ PHOTOS WITHIN EXPLORER â”€â”€â”€ */
.explorer-photos-header {
  grid-column: 1 / -1;
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.explorer-photos-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
}

.explorer-photos-title i {
  color: var(--accent-taupe);
  font-size: 1rem;
}

.explorer-photos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(clamp(140px, 20vw, 220px), 1fr));
  gap: clamp(8px, 2vw, 16px);
  width: 100%;
  grid-column: 1 / -1;
}

/* â”€â”€â”€ BOTÃƒO VOLTAR â”€â”€â”€ */
.btn-back {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 100px;
  border: 1.5px solid var(--border);
  background: var(--bg-surface);
  color: var(--text-primary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-decoration: none;
}

.btn-back svg {
  width: 14px;
  height: 14px;
}

.btn-back:hover {
  background: var(--bg-hover);
  border-color: var(--accent-brown);
  color: var(--accent-brown);
  transform: scale(1.05);
}

.btn-back:active {
  transform: scale(0.95);
}

.results-header .btn-back {
  margin-right: 16px;
}

/* â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•
   RESPONSIVE â€” TABLET â‰¤ 768px
   â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â• */
@media (max-width: 768px) {
  .hero {
    padding: 2.5rem 1rem 2rem;
  }

  .main {
    padding: 0 1rem 4rem;
  }

  .brand-logo {
    height: 30px;
    margin: -1.5rem 0;
  }

  .header-inner {
    padding: 0.5rem 1rem;
    min-height: 3.5rem;
  }

  .results-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .folder-grid {
    grid-template-columns: 1fr;
    /* Uma pasta por linha no celular */
    gap: 0.75rem;
  }

  /* Em tablets pequenos, permitimos 2 colunas */
  @media (min-width: 500px) {
    .folder-grid {
      grid-template-columns: repeat(2, 1fr);
    }
  }

  .explorer-photos-grid {
    grid-template-columns: repeat(2, 1fr);
    /* Força 2 colunas de fotos no mobile */
    gap: 8px;
  }

  .folder-card {
    padding: 1rem;
    min-height: 4rem;
  }

  .folder-name {
    font-size: 0.9rem;
    line-height: 1.3;
  }

  /* LIGHTBOX MOBILE */
  .lightbox-content {
    display: grid;
    grid-template-rows: 3.5rem 1fr auto;
    width: 100%;
    height: 100dvh;
    padding: 0;
    gap: 0;
  }

  .lightbox-top-bar {
    height: 3.5rem;
    background: rgba(0, 0, 0, 0.95);
    padding: 0 1rem;
    position: relative;
    top: 0;
    backdrop-filter: blur(10px);
  }

  .lightbox-img-wrapper {
    height: 100%;
    background: #000;
  }

  .lightbox-img,
  .lightbox-video {
    max-height: 100% !important;
    border-radius: 0;
    box-shadow: none;
  }

  .lightbox-info {
    padding: 1.25rem 1rem 0.5rem;
    background: #000;
    text-align: left;
  }

  .lightbox-actions {
    padding: 0.5rem 1rem 1rem;
    background: #000;
    flex-direction: column;
    width: 100%;
  }

  .lightbox-download,
  .lightbox-rename {
    width: 100%;
    height: 3.5rem;
    border-radius: 12px;
    font-size: 1rem;
  }
}

@media (min-width: 1200px) {
  .lightbox-nav.prev {
    left: 2rem;
  }

  .lightbox-nav.next {
    right: 2rem;
  }

  .lightbox-filename {
    font-size: 1.125rem;
  }
}

/* â”€â”€â”€ TELA DE LOGIN (BLOQUEIO) â”€â”€â”€ */
/* Seção removida - estilos obsoletos substituídos pelo portal premium no final do arquivo */

/* â”€â”€â”€ MODAL DE COMPARTILHAMENTO â”€â”€â”€ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(45, 30, 23, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3000;
  padding: 20px;
}

.modal-overlay.hidden {
  display: none !important;
}

.modal-card {
  background: var(--bg-surface);
  width: 100%;
  max-width: 500px;
  border-radius: var(--radius-lg);
  box-shadow: 0 32px 80px rgba(45, 30, 23, 0.25);
  overflow: hidden;
  animation: slideUpModal 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid var(--border);
}

@keyframes slideUpModal {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  padding: 24px 28px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.75rem;
  line-height: 1;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition);
  padding: 0;
  display: flex;
  align-items: center;
}

.modal-close:hover {
  color: var(--accent-pink);
}

.modal-body {
  padding: 24px 28px;
}

.modal-body>p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 20px;
  line-height: 1.5;
}

/* Input do link */
.share-link-container {
  display: flex;
  gap: 8px;
  background: var(--bg-base);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  padding: 6px 6px 6px 12px;
  margin-bottom: 24px;
  align-items: center;
  transition: border-color var(--transition);
}

.share-link-container:focus-within {
  border-color: var(--accent-taupe);
}

#shareLinkInput {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--font);
  font-size: 0.8125rem;
  color: var(--text-primary);
  min-width: 0;
}

#copyShareLink {
  background: var(--accent-brown);
  color: white;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition);
  display: flex !important;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

#copyShareLink:hover {
  background: #4A3226;
  transform: scale(1.05);
}

/* ConfiguraÃ§Ãµes */
.share-settings {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.setting-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.setting-item>label:first-child {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* Switch iOS */
.switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #CBD5E1;
  transition: .3s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background: white;
  transition: .3s;
  border-radius: 50%;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

input:checked+.slider {
  background: #22c55e;
}

input:checked+.slider:before {
  transform: translateX(22px);
}

/* OpÃ§Ãµes de permissÃ£o */
.permission-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.radio-option {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.radio-option input[type="radio"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent-brown);
  cursor: pointer;
}

.modal-footer {
  padding: 20px 28px 28px;
  display: flex;
  justify-content: flex-end;
  border-top: 1px solid var(--border);
  gap: 12px;
}

.btn-primary,
.btn-secondary {
  border: none;
  padding: 12px 28px;
  border-radius: 100px;
  font-family: var(--font);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-primary {
  background: var(--brand-primary);
  color: white;
}

.btn-primary:hover {
  opacity: 0.85;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
  background: #f1f3f5;
  color: #495057;
  border: 1px solid transparent;
}

.btn-secondary:hover {
  background: #e9ecef;
  border-color: #dee2e6;
}

.modal-input {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  font-family: var(--font);
  font-size: 1rem;
  color: var(--text-primary);
  transition: var(--transition);
}

.modal-input:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 4px rgba(45, 30, 23, 0.1);
}

body.dark-mode .btn-secondary {
  background: #333;
  color: #e2e8f0;
  border-color: #444;
}

body.dark-mode .btn-secondary:hover {
  background: #444;
  border-color: #555;
}

/* BotÃ£o de Compartilhar no Card de Pasta */
.btn-share-folder {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-surface);
  color: var(--text-muted);
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition);
  margin-left: auto;
  flex-shrink: 0;
  font-size: 13px;
  /* Ã‰ display:none por padrÃ£o via .admin-only. Quando .is-admin, vira flex. */
}

.btn-share-folder:hover {
  border-color: var(--accent-brown);
  color: var(--accent-brown);
  background: var(--bg-hover);
  transform: scale(1.1);
}


/* Estilos do Header Actions */
.header-right {
  margin-left: auto;
}

.header-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

/* ─────────────────────────────────────────────────────────────
   NEXOS LOGIN PORTAL - PREMIUM CHUMBO
   ───────────────────────────────────────────────────────────── */
.login-page {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100vh;
  display: flex;
  z-index: 100000;
  background: #FFFFFF;
  font-family: 'Outfit', sans-serif;
  animation: lp_interFadeIn 0.8s ease;
  overflow-y: auto;
}

@keyframes lp_interFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* LADO ESQUERDO: BRANDING (CHUMBO) */
.login-left-brand {
  flex: 1;
  min-width: 50%;
  position: sticky;
  top: 0;
  height: 100vh;
  background: #1C1C2E;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px;
  color: #FFFFFF;
}

.login-left-brand::before {
  content: '';
  position: absolute;
  top: -10%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

.login-brand-content {
  position: relative;
  z-index: 2;
  max-width: 520px;
}

.brand-badge {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(124, 58, 237, 0.1);
  color: #A78BFA;
  border: 1px solid rgba(124, 58, 237, 0.3);
  border-radius: 100px;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  margin-bottom: 32px;
  text-transform: uppercase;
}

.login-brand-content h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 32px;
  letter-spacing: -0.05em;
}

.login-brand-content h1 span {
  color: var(--nexus-purple);
}

.login-brand-content p {
  font-size: 1.1rem;
  color: #CBD5E1;
  line-height: 1.6;
  margin-bottom: 48px;
}

.login-features {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.feat-item {
  display: flex;
  align-items: center;
  gap: 18px;
  color: #E2E8F0;
}

.feat-item i {
  width: 48px;
  height: 48px;
  background: rgba(124, 58, 237, 0.1);
  border: 1px solid rgba(124, 58, 237, 0.2);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7C3AED;
  font-size: 1.2rem;
}

.feat-item span {
  font-weight: 600;
  font-size: 1.1rem;
}

.whatsapp-support-dark {
  position: absolute;
  bottom: 40px;
  left: 80px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: #25D366;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  transition: all 0.3s;
}

.whatsapp-support-dark:hover {
  transform: translateY(-2px);
  color: #20BA56;
}

.whatsapp-support-dark i {
  font-size: 1.5rem;
}

/* LADO DIREITO: FORMULÁRIO (BRANCO) */
.login-right-form {
  flex: 1;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.login-form-wrapper {
  width: 100%;
  max-width: 380px;
  position: relative;
  z-index: 5;
}

.login-logo-wrapper {
  margin-bottom: 48px;
  text-align: center;
}

.login-logo-img {
  height: 48px;
  width: auto;
}

.login-form-fields {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field-group label {
  font-size: 0.85rem;
  font-weight: 700;
  color: #1A1A2E;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.field-group input {
  width: 100%;
  padding: 16px 20px;
  background: #F8FAFC;
  border: 2px solid #F1F5F9;
  border-radius: 16px;
  font-size: 1rem;
  font-family: inherit;
  color: #1A1A2E;
  font-weight: 500;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.field-group input:focus {
  outline: none;
  border-color: #7C3AED;
  background: #FFFFFF;
  box-shadow: 0 0 0 5px rgba(124, 58, 237, 0.08);
}

.input-with-action {
  position: relative;
  display: flex;
  align-items: center;
}

.btn-toggle-fields {
  position: absolute;
  right: 16px;
  background: transparent;
  border: none;
  color: #94A3B8;
  cursor: pointer;
  padding: 8px;
}

.login-error-msg {
  color: #EF4444;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 16px;
  background: #FEF2F2;
  border-left: 4px solid #EF4444;
  border-radius: 12px;
}

.btn-primary-nexus {
  width: 100%;
  background: var(--nexus-purple);
  color: #FFFFFF;
  border: none;
  padding: 18px;
  border-radius: 8px;
  font-size: 1.05rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 10px 25px rgba(124, 58, 237, 0.25);
  position: relative;
  z-index: 10;
}

.btn-primary-nexus:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
}

.login-footer-links {
  margin-top: 32px;
  text-align: center;
  font-size: 1rem;
  color: #64748B;
}

.login-footer-links a {
  color: #7C3AED;
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 1024px) {
  .login-left-brand {
    display: none;
  }
}

.login-page.fade-out {
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.whatsapp-support {
  width: 52px;
  height: 52px;
  background: #25d366;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.625rem;
  box-shadow: 0 6px 16px rgba(37, 211, 102, 0.35);
  transition: all 0.3s ease;
  text-decoration: none;
}

.whatsapp-support:hover {
  transform: scale(1.12) rotate(8deg);
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.45);
}

/* Right panel — Brand */
.login-brand-content {
  color: white;
  max-width: 480px;
  position: relative;
  z-index: 1;
  animation: lp_fadeInRight 0.9s ease-out;
}

.brand-badge {
  display: inline-block;
  padding: 5px 14px;
  background: rgba(124, 58, 237, 0.2);
  border: 1px solid rgba(124, 58, 237, 0.4);
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  margin-bottom: 28px;
  color: #C4B5FD;
}

.login-brand-content h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 24px;
  color: white;
}

.login-brand-content h1 span {
  color: #A78BFA;
}

.login-brand-content>p {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.7;
  margin-bottom: 48px;
}

.login-features {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.feat-item {
  display: flex;
  align-items: center;
  gap: 14px;
}

.feat-item i {
  color: #A78BFA;
  font-size: 1.125rem;
  width: 22px;
  text-align: center;
}

.feat-item span {
  font-weight: 600;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.9);
}

@keyframes lp_fadeIn {
  from {
    opacity: 0;
    transform: translateY(24px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes lp_fadeInRight {
  from {
    opacity: 0;
    transform: translateX(32px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Responsive: hide brand panel on smaller screens */
/* ─────────────────────────────────────────────────────────────
   RESPONSIVIDADE NEXOS (LOGIN & GLOBAL)
   ───────────────────────────────────────────────────────────── */

/* Tablets e Telas Médias */
@media (max-width: 1100px) {
  .login-left-brand {
    flex: 0.8;
    /* Diminui um pouco o banner para dar espaço ao form */
    padding: 40px;
  }

  .brand-overlay h1 {
    font-size: 2.25rem;
  }
}

/* Celulares e Tablets em Modo Retrato */
@media (max-width: 900px) {
  .login-page.style-inter {
    flex-direction: column;
    overflow-y: auto;
    /* Permite scroll se o teclado do celular for muito grande */
  }

  .login-left-brand {
    display: none;
    /* Esconde o banner lateral no mobile */
  }

  .login-right-form {
    flex: 1;
    width: 100%;
    padding: 32px 24px;
    align-items: flex-start;
    /* Alinha ao topo para facilitar o uso com teclado */
    padding-top: 60px;
  }

  .login-form-wrapper {
    max-width: 100%;
  }

  .login-logo-inter {
    margin-bottom: 32px;
  }
}

/* Celulares Muito Pequenos (iPhone SE, etc) */
@media (max-width: 380px) {
  .login-right-form {
    padding: 24px 16px;
  }

  .field-group input {
    padding: 14px 16px;
    /* Inputs um pouco menores */
  }

  .btn-primary-inter,
  .btn-secondary-inter {
    padding: 16px;
  }

  .login-logo-inter img {
    height: 36px;
  }
}

/* Ajuste para telas muito altas ou zoom */
@media (max-height: 700px) and (min-width: 901px) {
  .brand-overlay h1 {
    font-size: 2rem;
  }

  .login-logo-inter {
    margin-bottom: 24px;
  }
}

.login-page.fade-out {
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

/* ─────────────────────────────────────────────
   Modal de Branding (Personalização) - PREMIUM
   ───────────────────────────────────────────── */
.branding-modal {
  max-width: 650px !important;
  background: var(--bg-surface) !important;
  border-radius: var(--radius-lg) !important;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3) !important;
  border: 1px solid var(--border);
}

.branding-modal .modal-header {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
  padding: 24px;
}

.branding-modal .modal-close {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.04);
  color: var(--text-muted);
  transition: background var(--transition), color var(--transition),
    transform var(--transition);
}

.branding-modal .modal-close:hover {
  background: rgba(15, 23, 42, 0.08);
  color: var(--text-primary);
  transform: translateY(-1px);
}

.branding-modal .modal-close:active {
  transform: translateY(0);
}

.branding-modal .modal-close:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px rgba(var(--primary-rgb, 124, 58, 237), 0.18);
}

body.dark-mode .branding-modal .modal-close {
  background: rgba(255, 255, 255, 0.06);
}

body.dark-mode .branding-modal .modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
}

.branding-modal .modal-body {
  padding: 24px;
  background: var(--bg-surface);
  max-height: 75vh;
  overflow-y: auto;
}

/* Desktop: usa mais largura para reduzir rolagem vertical */
@media (min-width: 900px) {
  .branding-modal {
    width: min(1280px, calc(100vw - 80px)) !important;
    max-width: min(1280px, calc(100vw - 80px)) !important;
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
  }

  .branding-modal .modal-body {
    flex: 1 1 auto;
    max-height: none;
    overflow-y: auto;
    padding-bottom: 96px;
  }

  .branding-modal .modal-header,
  .branding-modal .modal-footer {
    padding: 18px;
  }

  .branding-modal .modal-footer {
    position: sticky;
    bottom: 0;
    z-index: 5;
  }

  .settings-section {
    padding: 16px;
    margin-bottom: 18px;
  }

  .branding-grid {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 18px;
  }

  .form-group.full-width {
    grid-column: span 3;
  }
}

.settings-section {
  background: rgba(0, 0, 0, 0.02);
  padding: 20px;
  border-radius: var(--radius-lg);
  margin-bottom: 24px;
  border: 1px solid var(--border);
}

body.dark-mode .settings-section {
  background: rgba(255, 255, 255, 0.03);
}

.section-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--brand-primary);
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
}

.branding-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group.full-width {
  grid-column: span 2;
}

.input-with-hint small {
  display: block;
  margin-top: 6px;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-style: italic;
}

/* Upload de Logo */
.logo-upload-wrapper {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--bg-surface);
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border);
}

.logo-preview-img {
  height: 50px;
  max-width: 150px;
  object-fit: contain;
  background: #f0f0f0;
  padding: 5px;
  border-radius: 4px;
}

.logo-upload-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.logo-upload-actions small {
  color: var(--text-muted);
  font-size: 0.7rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.branding-modal input[type="text"],
.branding-modal textarea {
  width: 100%;
  padding: 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border);
  background: #fdfdfd;
  color: #1a1a1a;
  font-family: var(--font);
  font-size: 1rem;
  transition: var(--transition);
}

body.dark-mode .branding-modal input[type="text"],
body.dark-mode .branding-modal textarea {
  background: #2a2a2a;
  color: #ffffff;
  border-color: #333;
}

.branding-modal input[type="text"]:focus,
.branding-modal textarea:focus {
  border-color: var(--brand-primary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 4px rgba(var(--primary-rgb, 124, 58, 237), 0.1);
  outline: none;
}

.color-picker-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f5f5f5;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border);
  transition: var(--transition);
}

body.dark-mode .color-picker-wrapper {
  background: #252525;
}

.color-picker-wrapper:focus-within {
  border-color: var(--brand-primary);
}

.color-picker-wrapper input[type="color"] {
  width: 38px;
  height: 38px;
  border: 2px solid #fff;
  border-radius: 8px;
  cursor: pointer;
  background: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.color-picker-wrapper input[type="text"] {
  border: none !important;
  background: none !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 0.9rem !important;
  width: 100% !important;
  padding: 0 !important;
  text-transform: uppercase;
}

.branding-modal .modal-footer {
  padding: 24px;
  background: #f9f9f9;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

body.dark-mode .branding-modal .modal-footer {
  background: #1a1a1a;
}

@media (max-width: 600px) {
  .branding-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .form-group.full-width {
    grid-column: span 1;
  }

  .branding-modal {
    margin: 10px;
    max-height: 90vh;
  }
}

/* ============================================================
   NEXOS DAM — Patch de Responsividade Mobile
   Aplique este bloco no FIM do styles.css
   Cobre: iPhone SE (320px) → Desktop (1440px+)
   ============================================================ */

/* ─────────────────────────────────────────────
   🔴 BUG 1: Logo com margin negativa quebrando
   o alinhamento vertical do header no mobile.
   Arquivo: styles.css L622-625 e L2300-2303
   ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .brand-logo {
    height: 36px !important;
    max-height: 36px !important;
    max-width: 160px !important;
    margin: 0 !important;
    /* Remove margin negativa que causa desalinhamento */
    width: auto;
  }
}

/* ─────────────────────────────────────────────
   🔴 BUG 2: Login — Painel esquerdo visível
   até 1024px mas fica cortado em tablets.
   Em tablets (<900px) o form já está empilhado
   mas o .login-left-brand ainda aparece com
   min-width:50% forçando overflow horizontal.
   ───────────────────────────────────────────── */
@media (max-width: 900px) {
  .login-page {
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
  }

  .login-left-brand {
    display: none !important;
  }

  .login-right-form {
    flex: 1;
    width: 100%;
    min-height: 100dvh;
    padding: 48px 24px 80px;
    /* padding-bottom grande para teclado virtual */
    align-items: center;
    justify-content: flex-start;
    padding-top: 60px;
  }

  .login-form-wrapper {
    max-width: 100%;
    width: 100%;
  }
}

/* ─────────────────────────────────────────────
   🔴 BUG 3: Toast com white-space:nowrap
   transborda em celulares com mensagens longas.
   ───────────────────────────────────────────── */
.toast {
  white-space: normal !important;
  text-align: center;
  max-width: calc(100vw - 32px);
  word-break: break-word;
}

/* ─────────────────────────────────────────────
   🔴 BUG 4: Upload progress card (350px fixo)
   sai da tela em iPhones SE (320px).
   ───────────────────────────────────────────── */
@media (max-width: 400px) {
  .upload-progress-card {
    width: calc(100vw - 24px);
    right: 12px;
    bottom: 12px;
  }
}

/* ─────────────────────────────────────────────
   🔴 BUG 5: Botão de compartilhar da pasta
   (btn-share-folder) tem área de toque 32x32px
   — abaixo do mínimo de 44x44px recomendado.
   ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .btn-share-folder {
    width: 44px !important;
    height: 44px !important;
    font-size: 15px;
  }
}

/* ─────────────────────────────────────────────
   🟡 BUG 6: Botão "Baixar foto" no lightbox
   mobile — quando o nome do arquivo é longo,
   o texto quebra dentro do botão.
   ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .lightbox-download {
    justify-content: center;
    text-align: center;
    padding: 0 16px;
    gap: 10px;
  }

  .lightbox-rename {
    width: 100%;
    min-height: 3.5rem;
    border-radius: 12px;
    font-size: 0.95rem;
    justify-content: center;
    gap: 8px;
    padding: 0 16px;
  }
}

/* ─────────────────────────────────────────────
   🟡 BUG 7: Modal de configurações (branding)
   sem scroll interno no mobile — o botão
   Salvar fica escondido atrás do teclado.
   ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .modal-overlay {
    align-items: flex-start;
    padding: 0;
    overflow-y: auto;
  }

  .modal-content.branding-modal,
  .modal-card {
    border-radius: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    min-height: 100dvh;
    margin: 0;
    border: none;
    overflow-y: auto;
  }

  .modal-body {
    padding: 20px 16px;
    max-height: none;
    /* Remove qualquer max-height que impeça scroll */
    overflow-y: visible;
  }

  .modal-footer {
    position: sticky;
    bottom: 0;
    background: var(--bg-surface);
    z-index: 10;
    border-top: 1px solid var(--border);
    padding: 16px;
    gap: 10px;
  }

  .modal-footer .btn-primary,
  .modal-footer .btn-secondary {
    flex: 1;
    padding: 14px 16px;
    font-size: 1rem;
  }
}

/* ─────────────────────────────────────────────
   🟡 BUG 8: Breadcrumb horizontal com flex-wrap
   ocupa muito espaço em mobile — nomes longos
   vazam. Trunca com ellipsis.
   ───────────────────────────────────────────── */
@media (max-width: 600px) {
  .breadcrumb-container {
    padding: 0 16px;
    gap: 8px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    flex-wrap: nowrap;
    /* Scroll horizontal em vez de quebrar */
  }

  .breadcrumb-container::-webkit-scrollbar {
    display: none;
  }

  .crumb {
    white-space: nowrap;
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 13px;
    padding: 5px 10px;
    flex-shrink: 0;
  }
}

/* ─────────────────────────────────────────────
   🟡 BUG 9: Sugestões de busca com max-height
   400px — em iPhone SE (568px total) isso
   cobre a maior parte da tela útil.
   ───────────────────────────────────────────── */
@media (max-width: 480px) {
  .search-suggestions {
    max-height: 240px;
  }

  .suggestion-item {
    padding: 10px 16px;
    gap: 12px;
  }

  .suggestion-icon {
    width: 34px;
    height: 34px;
  }
}

/* ─────────────────────────────────────────────
   🟡 BUG 10: Lightbox — setas de nav ficam
   em top:50% mas o footer ocupa ~120px,
   deslocando o centro visual. Reposiciona.
   ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .lightbox-nav {
    top: calc(50dvh - 60px);
    /* Compensa o footer do lightbox no mobile */
    width: 44px;
    height: 44px;
  }

  .lightbox-nav.prev {
    left: 8px;
  }

  .lightbox-nav.next {
    right: 8px;
  }
}

/* ─────────────────────────────────────────────
   🟡 BUG 11: Barra de seleção múltipla
   em iPhone SE (320px) fica muito apertada —
   botões ficam invisíveis.
   ───────────────────────────────────────────── */
@media (max-width: 360px) {
  .btn-selection {
    padding: 8px 8px !important;
  }

  .selection-count {
    max-width: 55px !important;
    font-size: 11px;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 1: Inputs de cor no branding
   modal — color picker nativo fica pequeno
   em mobile. Aumenta área de toque.
   ───────────────────────────────────────────── */
@media (max-width: 768px) {
  .color-picker-wrapper input[type="color"] {
    width: 48px;
    height: 48px;
    cursor: pointer;
  }

  .branding-grid {
    grid-template-columns: 1fr !important;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 2: Foto grid em iPhone SE (320px)
   O auto-fill com minmax(140px) força 2 colunas
   em 320px mas fica apertado. Reduz mínimo.
   ───────────────────────────────────────────── */
@media (max-width: 360px) {

  .photo-grid,
  .explorer-photos-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px !important;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 3: Padding lateral mínimo de 16px
   garantido em todos os containers.
   ───────────────────────────────────────────── */
@media (max-width: 480px) {
  .hero {
    padding-left: 16px;
    padding-right: 16px;
  }

  .explorer-container {
    padding-left: 0;
    padding-right: 0;
  }

  .folder-grid,
  .explorer-photos-grid {
    padding: 0 16px;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 4: Landscape mobile —
   Lightbox em paisagem usa 100dvw com
   botões de nav acessíveis lateralmente.
   ───────────────────────────────────────────── */
@media (max-width: 900px) and (orientation: landscape) {
  .lightbox-content {
    grid-template-rows: 3rem 1fr auto !important;
  }

  .lightbox-top-bar {
    height: 3rem !important;
  }

  .lightbox-actions {
    flex-direction: row !important;
    padding: 8px 16px !important;
  }

  .lightbox-download,
  .lightbox-rename {
    width: auto !important;
    height: 2.5rem !important;
    font-size: 0.9rem !important;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 5: Área de toque mínima 44x44px
   para todos os botões interativos críticos.
   ───────────────────────────────────────────── */
@media (max-width: 768px) {

  .lightbox-close,
  .modal-close,
  .btn-back,
  .search-clear,
  .close-progress,
  .btn-toggle-fields {
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Aumenta área de toque do checkbox de seleção */
  .photo-card-select {
    width: 36px !important;
    height: 36px !important;
    top: 8px !important;
    right: 8px !important;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 6: Evita zoom automático em
   inputs no iOS (font-size mínimo de 16px).
   ───────────────────────────────────────────── */
@media (max-width: 768px) {

  input,
  select,
  textarea {
    font-size: 16px !important;
    /* Evita zoom automático do iOS */
  }

  /* Exceção: labels e metadados pequenos */
  .suggestion-meta,
  .folder-meta,
  .ref-meta {
    font-size: 12px !important;
  }
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 7: Compatibilidade Safari/iOS
   — backdrop-filter precisa de -webkit-prefix
   (já existe em alguns lugares, padroniza).
   ───────────────────────────────────────────── */
.header,
.selection-toolbar,
.toast,
.modal-overlay {
  -webkit-backdrop-filter: blur(20px);
  /* Safari iOS */
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 8: Scroll suave e momentum
   para listas no iOS.
   ───────────────────────────────────────────── */
.folder-grid,
.photo-grid,
.explorer-photos-grid,
.search-suggestions,
.modal-body {
  -webkit-overflow-scrolling: touch;
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 9: Previne scroll horizontal
   em qualquer situação (não apenas body).
   ───────────────────────────────────────────── */
html,
body {
  max-width: 100vw;
  overflow-x: hidden;
}

/* ─────────────────────────────────────────────
   🟢 MELHORIA 10: Placeholder visível em todos
   os tamanhos de tela (contraste mínimo).
   ───────────────────────────────────────────── */
.search-input::placeholder {
  color: var(--text-muted);
  opacity: 1;
  /* Firefox reduz opacity por padrão */
}

@media (max-width: 480px) {
  .search-input {
    font-size: 16px;
    /* Evita zoom iOS */
  }

  .search-input::placeholder {
    font-size: 14px;
    /* Placeholder menor para caber sem truncar */
  }
}


/* +--------------------------------------------------------------
   DARK MODE � CORRE��O COMPLETA
   Cobre todos os elementos que ficam com cor escura no dark mode
   --------------------------------------------------------------+ */

/* --- HEADER --- */
body.dark-mode .header {
  background: rgba(18, 18, 18, 0.95);
  border-bottom-color: #2A2A2A;
}

body.dark-mode .header-actions .btn-header {
  background: #1E1E1E;
  border-color: #333;
  color: #F1F5F9;
}

body.dark-mode .header-actions .btn-header:hover {
  background: #2A2A2A;
  border-color: #444;
}

body.dark-mode .header-actions .btn-header i {
  color: #CBD5E1;
}

/* --- HERO / T�TULO --- */
body.dark-mode .hero-title,
body.dark-mode .hero h1,
body.dark-mode .hero h2,
body.dark-mode .hero p,
body.dark-mode .hero-subtitle {
  color: #F1F5F9;
}

/* --- BARRA DE BUSCA --- */
body.dark-mode .search-box {
  background: #3D3D3D !important;
  border-color: #5A5A5A !important;
  box-shadow: 0 0 0 1.5px #5A5A5A, 0 4px 16px rgba(0, 0, 0, 0.4) !important;
}

body.dark-mode .search-box:focus-within {
  background: #424242 !important;
  border-color: var(--brand-primary) !important;
  box-shadow: 0 0 0 1.5px var(--brand-primary), 0 0 0 4px rgba(var(--primary-rgb), 0.15) !important;
}

body.dark-mode .search-input {
  background: transparent !important;
  color: #F1F5F9 !important;
}

body.dark-mode .search-input::placeholder {
  color: #64748B;
}

body.dark-mode .search-icon {
  color: #64748B;
}

body.dark-mode .search-clear {
  color: #94A3B8;
}

body.dark-mode .search-clear:hover {
  color: #F1F5F9;
}

/* --- SUGEST�ES DE BUSCA --- */
body.dark-mode .search-suggestions {
  background: #1E1E1E;
  border-color: #333;
}

body.dark-mode .suggestion-item {
  color: #F1F5F9;
}

body.dark-mode .suggestion-item:hover {
  background: #2A2A2A;
}

body.dark-mode .suggestion-name {
  color: #F1F5F9;
}

body.dark-mode .suggestion-meta {
  color: #94A3B8;
}

body.dark-mode .suggestion-icon {
  background: #2A2A2A;
  color: var(--brand-primary);
}

/* --- FILTROS (CHIPS) --- */
body.dark-mode .explorer-filters {
  background: transparent;
}

/* --- CARDS DE PASTA --- */
body.dark-mode .folder-card {
  background: #1E1E1E;
  border-color: #2A2A2A;
}

body.dark-mode .folder-card:hover {
  background: #252525;
  border-color: #3A3A3A;
}

body.dark-mode .folder-name {
  color: #F1F5F9;
}

body.dark-mode .folder-meta {
  color: #94A3B8;
}

/* --- BREADCRUMB --- */
body.dark-mode .breadcrumb-container {
  background: transparent;
}

body.dark-mode .crumb {
  background: #1E1E1E;
  border-color: #333;
  color: #94A3B8;
}

body.dark-mode .crumb:hover {
  background: #2A2A2A;
  color: #F1F5F9;
}

body.dark-mode .crumb:last-child {
  color: #F1F5F9;
}

body.dark-mode .breadcrumb-separator,
body.dark-mode .crumb-separator {
  color: #555;
}

body.dark-mode .btn-refresh-breadcrumb {
  background: #1E1E1E;
  border-color: #333;
  color: #94A3B8;
}

body.dark-mode .btn-refresh-breadcrumb:hover {
  background: #2A2A2A;
  color: #F1F5F9;
}

/* --- BOT�O VOLTAR --- */
body.dark-mode .btn-back {
  background: #1E1E1E;
  border-color: #333;
  color: #F1F5F9;
}

body.dark-mode .btn-back:hover {
  background: #2A2A2A;
  border-color: #555;
}

/* --- CABE�ALHO DE RESULTADOS --- */
body.dark-mode .results-header {
  border-bottom-color: #2A2A2A;
}

body.dark-mode .results-count {
  color: #F1F5F9;
}

body.dark-mode .results-count span {
  color: #94A3B8;
}

/* --- CABE�ALHO DE FOTOS NO EXPLORER --- */
body.dark-mode .explorer-photos-header {
  border-bottom-color: #2A2A2A;
}

body.dark-mode .explorer-photos-title {
  color: #F1F5F9;
}

/* --- REF BADGE (badge num�rico de refer�ncia) --- */
body.dark-mode .ref-badge {
  /* Cor de fundo definida por --brand-primary, mant�m contraste */
  color: #fff;
}

body.dark-mode .ref-group-header {
  border-bottom-color: #2A2A2A;
}

body.dark-mode .ref-meta {
  color: #94A3B8;
}

body.dark-mode .ref-meta span {
  color: #CBD5E1;
}

/* --- CARDS DE FOTO --- */
body.dark-mode .photo-card {
  background: #1E1E1E;
  border-color: #2A2A2A;
}

body.dark-mode .photo-card:hover {
  border-color: #3A3A3A;
}

body.dark-mode .photo-card-name {
  color: #F1F5F9;
}

body.dark-mode .photo-card-meta {
  color: #94A3B8;
}

body.dark-mode .photo-card-actions {
  background: rgba(18, 18, 18, 0.9);
}

body.dark-mode .photo-card-select {
  background: rgba(30, 30, 30, 0.9);
  border-color: #444;
  color: #F1F5F9;
}

/* --- MODAL (COMPARTILHAR, BRANDING) --- */
body.dark-mode .modal-overlay {
  background: rgba(0, 0, 0, 0.65);
}

body.dark-mode .modal-card {
  background: #1E1E1E;
  border-color: #2A2A2A;
}

body.dark-mode .modal-header {
  border-bottom-color: #2A2A2A;
}

body.dark-mode .modal-header h3 {
  color: #F1F5F9;
}

body.dark-mode .modal-close {
  color: #94A3B8;
}

body.dark-mode .modal-close:hover {
  color: #EF4444;
}

body.dark-mode .modal-body p {
  color: #94A3B8;
}

body.dark-mode .modal-body label,
body.dark-mode .modal-body .setting-item>label:first-child {
  color: #F1F5F9;
}

body.dark-mode .modal-input {
  background: #121212;
  border-color: #333;
  color: #F1F5F9;
}

body.dark-mode .modal-input:focus {
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.15);
}

body.dark-mode .modal-footer {
  border-top-color: #2A2A2A;
  background: #1E1E1E;
}

/* --- LINK DE COMPARTILHAMENTO --- */
body.dark-mode .share-link-container {
  background: #121212;
  border-color: #333;
}

body.dark-mode #shareLinkInput {
  color: #F1F5F9;
}

/* --- RADIO / SWITCH --- */
body.dark-mode .radio-option {
  color: #CBD5E1;
}

/* --- TOAST --- */
body.dark-mode .toast {
  background: #252525;
  border-color: #333;
  color: #F1F5F9;
}

/* --- BARRA DE SELE��O M�LTIPLA --- */
body.dark-mode .selection-toolbar {
  background: rgba(30, 30, 30, 0.97);
  border-color: #333;
}

body.dark-mode .selection-count {
  color: #F1F5F9;
  border-right-color: #333;
}

body.dark-mode .btn-selection {
  background: transparent;
  border-color: #333;
  color: #CBD5E1;
}

body.dark-mode .btn-selection:hover {
  background: #2A2A2A;
  color: #F1F5F9;
}

/* --- BOT�ES DE RETRY / DOCS --- */
body.dark-mode .btn-retry,
body.dark-mode .btn-docs {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
}

body.dark-mode .btn-retry:hover,
body.dark-mode .btn-docs:hover {
  background: var(--brand-primary);
  color: white;
}

/* --- ESTADO VAZIO / ERRO --- */
body.dark-mode .state-container h2 {
  color: #F1F5F9;
}

body.dark-mode .state-container p {
  color: #94A3B8;
}

/* --- PROGRESS DE UPLOAD --- */
body.dark-mode .upload-progress-title,
body.dark-mode .upload-progress-subtitle,
body.dark-mode .upload-file-name {
  color: #F1F5F9;
}

/* --- MODAL DE RENOMEAR --- */
body.dark-mode #renameModal .modal-card {
  background: #1E1E1E;
  border-color: #2A2A2A;
}

body.dark-mode #renameModal input {
  background: #121212;
  border-color: #333;
  color: #F1F5F9;
}

body.dark-mode #renameModal label {
  color: #F1F5F9;
}

/* --- BOT�O COMPARTILHAR PASTA --- */
body.dark-mode .btn-share-folder {
  background: #1E1E1E;
  border-color: #333;
  color: #94A3B8;
}

body.dark-mode .btn-share-folder:hover {
  border-color: var(--brand-primary);
  color: var(--brand-primary);
  background: #2A2A2A;
}

/* --- SETTINGS / CONFIGURA��ES --- */
body.dark-mode .settings-label,
body.dark-mode .settings-section h3,
body.dark-mode .settings-section h4 {
  color: #F1F5F9;
}

body.dark-mode .settings-description {
  color: #94A3B8;
}

body.dark-mode .settings-section {
  background: #1E1E1E;
  border-color: #2A2A2A;
}

/* --- INPUTS GLOBAIS --- */
body.dark-mode input[type="text"],
body.dark-mode input[type="email"],
body.dark-mode input[type="password"],
body.dark-mode textarea,
body.dark-mode select {

  border-color: #333 !important;
  color: #F1F5F9 !important;
}

body.dark-mode input[type="text"]::placeholder,
body.dark-mode input[type="email"]::placeholder,
body.dark-mode input[type="password"]::placeholder,
body.dark-mode textarea::placeholder {
  color: #64748B !important;
}

/* --- BOT�O SECUND�RIO --- (j� existia, refor�a) */
body.dark-mode .btn-secondary {
  background: #252525;
  color: #CBD5E1;
  border-color: #333;
}

body.dark-mode .btn-secondary:hover {
  background: #333;
  border-color: #444;
  color: #F1F5F9;
}