/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS (and SCSS, if configured) file within this directory, lib/assets/stylesheets, or any plugin's
 * vendor/assets/stylesheets directory can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the bottom of the
 * compiled file so the styles you add here take precedence over styles defined in any other CSS
 * files in this directory. Styles in this file should be added after the last require_* statement.
 * It is generally better to create a new file per style scope.
 *


 */

/* Custom ZenCrowd Styles */

:root {
  --primary-dark: #0b3d52;
  --primary: #117a65;
  --accent: #a4c400;

  --neutral-dark: #4e4f45;
  --neutral-medium: #8f8a7c;
  --neutral-light: #a6a6a6;

  --secondary-dark: #014d3a;
  --secondary: #0f7a5c;
  --secondary-olive: #5f6b1f;
  --neutral-olive: #55564b;

  /* Bridge palette tokens with Bootstrap semantic colors */
  --bs-primary: var(--primary-dark);
  --bs-primary-rgb: 11, 61, 82;
  --bs-secondary: var(--neutral-olive);
  --bs-secondary-rgb: 85, 86, 75;
  --bs-success: var(--secondary);
  --bs-success-rgb: 15, 122, 92;
  --bs-warning: var(--accent);
  --bs-warning-rgb: 164, 196, 0;
  --bs-info: var(--primary);
  --bs-info-rgb: 17, 122, 101;
  --bs-body-color: var(--neutral-dark);
  --bs-secondary-color: var(--neutral-olive);
  --bs-secondary-color-rgb: 85, 86, 75;
  --bs-border-color: var(--neutral-light);
  --bs-link-color: var(--secondary-dark);
  --bs-link-hover-color: var(--primary-dark);
  --bs-tertiary-bg: #e6e2d8;
}

body {
  color: var(--neutral-dark);
}

/* Standard page header/title sizing across internal screens */
.page-header {
  margin-bottom: 1.5rem;
}

.page-title {
  font-size: 1.75rem;
  line-height: 1.2;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.page-header .btn,
.page-header .btn-group {
  margin-bottom: 0.25rem;
}

.navbar.bg-primary {
  background-color: var(--primary-dark) !important;
}

.btn-primary {
  --bs-btn-bg: var(--primary);
  --bs-btn-border-color: var(--primary);
  --bs-btn-hover-bg: var(--secondary-dark);
  --bs-btn-hover-border-color: var(--secondary-dark);
  --bs-btn-active-bg: var(--secondary-dark);
  --bs-btn-active-border-color: var(--secondary-dark);
  --bs-btn-disabled-bg: var(--neutral-light);
  --bs-btn-disabled-border-color: var(--neutral-light);
}

.btn-outline-primary {
  --bs-btn-color: #0d6efd;
  --bs-btn-border-color: #0d6efd;
  --bs-btn-hover-bg: #0d6efd;
  --bs-btn-hover-border-color: #0d6efd;
  --bs-btn-active-bg: #0b5ed7;
  --bs-btn-active-border-color: #0a58ca;
}

/* Forca o botao de categoria "direita" para azul escuro, independente do tema. */
.evento-categoria-direita {
  background-color: #0a2f8f !important;
  border-color: #0a2f8f !important;
  color: #fff !important;
}

.evento-categoria-direita:hover,
.evento-categoria-direita:focus,
.evento-categoria-direita:active {
  background-color: #082571 !important;
  border-color: #082571 !important;
  color: #fff !important;
}

/* Accent should stay sparing for high-signal CTAs */
.btn-accent {
  --bs-btn-color: var(--neutral-dark);
  --bs-btn-bg: var(--accent);
  --bs-btn-border-color: var(--accent);
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: var(--secondary-olive);
  --bs-btn-hover-border-color: var(--secondary-olive);
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: var(--secondary-olive);
  --bs-btn-active-border-color: var(--secondary-olive);
}

.bg-brand-surface {
  background-color: var(--neutral-medium) !important;
}

.text-brand-muted {
  color: var(--neutral-olive) !important;
}

/* Smooth transitions */
.card, .btn, .nav-link {
  transition: all 0.3s ease;
}

/* Card hover effect */
.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
}

/* Keep ZenPlot card stable; transform on ancestor breaks fixed zoom panel positioning. */
.card.zen-plot-card:hover {
  transform: none;
}

.zen-plot-card .minimal-controls .points-count-group {
  margin-left: 0;
}

.zen-plot-card .minimal-controls .submit-group.submit-group-end {
  margin-left: auto;
  gap: 0.5rem;
  align-items: center;
}

.zen-plot-card .minimal-controls .submit-group.submit-group-end .btn {
  min-height: 2.5rem;
  line-height: 1.2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1rem;
  white-space: nowrap;
}

/* Navbar custom styling */
.navbar-brand {
  font-weight: bold;
  font-size: 1.5rem;
}

/* Footer styling */
footer {
  border-top: 1px solid var(--neutral-light);
}

/* Button loading state */
.btn-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.65;
}

.btn-loading::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -8px;
  border: 2px solid currentColor;
  border-radius: 50%;
  border-right-color: transparent;
  animation: spinner-border 0.75s linear infinite;
}


/* Custom badge colors */
.badge-custom {
  padding: 0.35em 0.65em;
  font-weight: 500;
}

/* Image preview */
.image-preview {
  max-width: 100%;
  border: 1px solid var(--neutral-light);
  border-radius: 0.25rem;
  padding: 0.25rem;
}

.grid-overlay-preview {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--neutral-light);
  border-radius: 0.5rem;
  background-color: #f8f9fa;
}

.mosaic-zoom-frame {
  overflow: auto;
  max-height: 75vh;
  cursor: grab;
}

.mosaic-zoom-frame:focus-visible {
  outline: 2px solid rgba(11, 61, 82, 0.5);
  outline-offset: 2px;
}

.mosaic-zoom-frame.is-panning {
  cursor: grabbing;
}

.mosaic-zoom-canvas {
  position: relative;
  width: 100%;
  min-width: 100%;
  transition: width 0.2s ease;
}

.mosaic-zoom-canvas img {
  user-select: none;
  -webkit-user-drag: none;
}

.grid-overlay-preview img {
  display: block;
  width: 100%;
  height: auto;
}

.grid-overlay-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  background-size: 100% 100%;
  box-shadow: inset 0 0 0 1px rgba(17, 122, 101, 0.55);
}

.grid-overlay-counts {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
}

.grid-overlay-count-badge {
  position: absolute;
  transform: translate(-50%, -50%);
  min-width: 3.1rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background-color: rgba(11, 61, 82, 0.88);
  color: #fff;
  font-size: 1.3rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.grid-picker {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: 50%;
  gap: 0.35rem;
}

.grid-picker-mosaic {
  grid-template-columns: repeat(8, minmax(0, 1fr));
  width: 25%;
  min-width: 240px;
}

.grid-picker-cell {
  appearance: none;
  aspect-ratio: 1 / 1;
  border: 1px solid #cad0c7;
  background-color: #eef1ea;
  border-radius: 0.25rem;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  cursor: pointer;
  padding: 0;
}

.grid-picker-cell:hover {
  transform: scale(1.04);
}

/* Public homepage: dataset and reports landing */
@import url('https://fonts.googleapis.com/css2?family=Sora:wght@400;500;600;700&family=Source+Sans+3:wght@400;500;600&display=swap');

.home-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 85% 10%, rgba(164, 196, 0, 0.18), transparent 35%),
    radial-gradient(circle at 10% 85%, rgba(17, 122, 101, 0.22), transparent 45%),
    linear-gradient(130deg, #0a3348 0%, #0f7a5c 45%, #6f8b1b 100%);
  color: #fff;
}

.home-hero::before,
.home-hero::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.home-hero::before {
  width: 420px;
  height: 420px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  top: -190px;
  right: -120px;
}

.home-hero::after {
  width: 280px;
  height: 280px;
  border-radius: 42px;
  background: rgba(255, 255, 255, 0.08);
  filter: blur(1px);
  bottom: -130px;
  left: -60px;
  transform: rotate(18deg);
}

.home-kicker {
  display: inline-flex;
  margin-bottom: 0.85rem;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background-color: rgba(255, 255, 255, 0.1);
}

.home-hero h1,
.home-content h2,
.home-content h3,
.home-proof-band h2 {
  font-family: "Sora", sans-serif;
}

.home-hero .lead,
.home-content p,
.home-content li,
.home-proof-band p {
  font-family: "Source Sans 3", sans-serif;
}

.btn-home-ghost {
  --bs-btn-color: #fff;
  --bs-btn-border-color: rgba(255, 255, 255, 0.65);
  --bs-btn-hover-color: #083244;
  --bs-btn-hover-bg: #fff;
  --bs-btn-hover-border-color: #fff;
}

.home-hero-panel {
  border-radius: 1.25rem;
  background: rgba(6, 44, 60, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.home-hero-panel-intro {
  color: rgba(239, 248, 244, 0.9);
  font-size: 0.97rem;
  line-height: 1.45;
}

.home-hero-metric-grid {
  display: grid;
  gap: 0.85rem;
}

.home-hero-metric-card {
  display: grid;
  gap: 0.1rem;
  padding: 0.8rem 0.95rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.08);
}

.home-hero-metric-label {
  display: block;
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(225, 243, 236, 0.88);
}

.home-hero-metric-value {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: clamp(1.55rem, 2.5vw, 2rem);
  font-weight: 700;
  line-height: 1.12;
  color: #ffffff;
}

.home-hero-metric-foot {
  display: block;
  font-size: 0.88rem;
  color: rgba(235, 246, 241, 0.9);
}

.home-content {
  position: relative;
}

.home-content::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(rgba(11, 61, 82, 0.08) 0.75px, transparent 0.75px);
  background-size: 20px 20px;
  opacity: 0.45;
}

.home-card {
  border-radius: 1rem;
  border: 1px solid rgba(11, 61, 82, 0.12);
  background: linear-gradient(180deg, #ffffff 0%, #f6faf7 100%);
  box-shadow: 0 14px 30px rgba(6, 31, 44, 0.08);
}

.home-card-accent {
  background: linear-gradient(155deg, #0b3d52 0%, #0f7a5c 100%);
  color: #fff;
}

.home-card-accent .text-brand-muted {
  color: rgba(255, 255, 255, 0.84) !important;
}

.home-card-partners {
  color: #123746;
}

.home-partner-list {
  display: grid;
  gap: 0.75rem;
}

.home-partner-item {
  display: grid;
  grid-template-columns: 6.2rem minmax(0, 1fr);
  align-items: center;
  column-gap: 0.85rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(11, 61, 82, 0.16);
  border-radius: 0.85rem;
  background: rgba(11, 61, 82, 0.03);
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.home-partner-item:hover {
  transform: translateY(-2px);
  background: rgba(11, 61, 82, 0.07);
}

.home-partner-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.7rem;
  height: 2.25rem;
  padding: 0 0.45rem;
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.9);
  color: #0b3d52;
  font-family: "Sora", sans-serif;
  font-size: 0.83rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  justify-self: center;
}

.home-partner-logo-image {
  width: 3.7rem;
  height: 2.25rem;
  max-width: 100%;
  object-fit: contain;
  justify-self: center;
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.home-partner-logo-image-wide {
  width: 5.8rem;
}

.home-partner-logo-image-rounded {
  border-radius: 0.5rem;
}

.home-partner-logo-wide {
  min-width: 5.8rem;
  font-size: 0.73rem;
  letter-spacing: 0.025em;
}

.home-partner-name {
  display: block;
  font-size: 0.95rem;
  line-height: 1.3;
  font-weight: 600;
  text-align: left;
  color: #123746;
}

.home-stat-grid {
  display: grid;
  gap: 0.9rem;
}

.home-stat-number {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
}

.home-stat-label {
  display: block;
  font-size: 0.94rem;
  opacity: 0.88;
}

.home-section-header {
  max-width: 780px;
}

.home-step-card {
  border-radius: 1rem;
  padding: 1.25rem;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbfa 100%);
  border: 1px solid rgba(11, 61, 82, 0.14);
  box-shadow: 0 12px 24px rgba(8, 46, 64, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.home-step-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 28px rgba(8, 46, 64, 0.14);
}

.home-step-card h3 {
  font-family: "Sora", sans-serif;
  font-size: 1rem;
  margin-bottom: 0.45rem;
  color: #0b3d52;
}

.home-step-card p {
  color: #2f4c59;
  font-size: 0.92rem;
  line-height: 1.45;
}

.home-step-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.8rem;
  height: 2.8rem;
  margin-bottom: 0.8rem;
  border-radius: 999px;
  font-size: 1.15rem;
  color: #fff;
  background: linear-gradient(145deg, #0f7a5c 0%, #0b3d52 100%);
  box-shadow: 0 8px 16px rgba(11, 61, 82, 0.25);
}

.home-step-index i {
  line-height: 1;
}

#estrutura .col-md-6:nth-child(1) .home-step-index {
  background: linear-gradient(145deg, #0b3d52 0%, #106487 100%);
}

#estrutura .col-md-6:nth-child(2) .home-step-index {
  background: linear-gradient(145deg, #0f7a5c 0%, #1f965d 100%);
}

#estrutura .col-md-6:nth-child(3) .home-step-index {
  background: linear-gradient(145deg, #6f8b1b 0%, #0f7a5c 100%);
}

.home-proof-band {
  border-radius: 1.25rem;
  background:
    linear-gradient(165deg, rgba(164, 196, 0, 0.16) 0%, rgba(17, 122, 101, 0.16) 100%),
    #fbfcf8;
  border: 1px solid rgba(11, 61, 82, 0.14);
}

.home-reveal {
  opacity: 0;
  transform: translateY(14px);
  animation: home-fade-up 0.65s ease forwards;
}

.home-reveal-1 {
  animation-delay: 0.05s;
}

.home-reveal-2 {
  animation-delay: 0.18s;
}

.home-reveal-3 {
  animation-delay: 0.32s;
}

@keyframes home-fade-up {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 991.98px) {
  .home-hero h1 {
    font-size: 2.15rem;
  }

  .home-hero .lead {
    font-size: 1.05rem;
  }
}

@media (max-width: 575.98px) {
  .home-hero {
    padding-top: 2.5rem !important;
    padding-bottom: 2.5rem !important;
  }

  .home-hero h1 {
    font-size: 1.85rem;
  }

  .home-kicker {
    font-size: 0.74rem;
  }

  .home-step-index {
    width: 2.4rem;
    height: 2.4rem;
    font-size: 1rem;
  }

  .grid-picker-mosaic {
    width: 50%;
  }
}

.grid-picker-cell.is-selected {
  border-color: rgba(17, 122, 101, 0.7);
  background-color: rgba(17, 122, 101, 0.2);
}

.grid-picker-cell.is-anchor {
  border-color: var(--primary-dark);
  background-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(11, 61, 82, 0.2);
}

/* Status badges */
.status-badge {
  font-size: 0.875rem;
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
}

.progress-icon-sprite {
  display: inline-block;
  width: 18px;
  height: 18px;
  background-image: url('https://cdn-icons-png.flaticon.com/512/18645/18645453.png');
  background-repeat: no-repeat;
  background-size: 100% 300%;
  background-position: center 0%;
}

.progress-icon-sprite--low {
  background-position: center 0%;
}

.progress-icon-sprite--mid {
  background-position: center 50%;
}

.progress-icon-sprite--high {
  background-position: center 100%;
}

/* Responsive utilities */
@media (max-width: 768px) {
  .card {
    margin-bottom: 1rem;
  }
  
  .navbar-brand {
    font-size: 1.25rem;
  }
}

/* Pagination spacing and visual polish */
.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.pagination > * {
  margin: 0;
  border: 0;
  background: transparent;
}

.pagination .page-item:not(:first-child) .page-link {
  margin-left: 0;
}

.pagination a,
.pagination .current,
.pagination .disabled,
.pagination .gap,
.pagination .page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.35rem;
  height: 2.35rem;
  padding: 0 0.8rem;
  border: 1px solid #d5d9de;
  border-radius: 0.5rem;
  background-color: #fff;
  color: #495057;
  font-weight: 500;
  text-decoration: none;
  line-height: 1;
  box-shadow: none;
}

.pagination > a:hover,
.pagination > * > a:hover,
.pagination a:hover,
.pagination .page-link:hover {
  background-color: #f1f3f5;
  border-color: #c7cdd4;
  color: #212529;
}

.pagination .page-link:focus,
.pagination .page-link:focus-visible,
.pagination a:focus,
.pagination > a:focus,
.pagination > * > a:focus {
  box-shadow: none;
  outline: none;
}

.pagination .current,
.pagination .current > span,
.pagination .current > a,
.pagination .active > .page-link {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
  color: #fff;
}

.pagination .disabled > span,
.pagination .disabled > a,
.pagination .disabled > .page-link,
.pagination .gap {
  background-color: #f8f9fa;
  border-color: #e6e9ec;
  color: #9aa1a9;
}

