/* HEY CARTELES - identidad visual sobre Bootstrap 5
   Paleta: carbón + celeste/azul */
:root {
  --hc-carbon:   #1d2228;
  --hc-carbon-2: #2a313a;
  --hc-blue:     #38bdf8;
  --hc-blue-d:   #0ea5e9;
  --hc-blue-deep:#1b6fad;
  --hc-bg:       #f3f4f6;
  --hc-ok:       #1e9e5a;
  --hc-bad:      #d23b3b;
  --hc-map-fill: #38bdf8;
  --hc-map-edge: #1b6fad;
}

body { background: var(--hc-bg); }

/* Marca */
.hc-brand {
  font-family: "Anton", Impact, "Arial Black", sans-serif;
  font-size: 1.45rem;
  letter-spacing: .06em;
  color: var(--hc-blue);
  text-transform: uppercase;
  line-height: 1;
}
.hc-brand span { color: #fff; }

.hc-navbar {
  background: var(--hc-carbon);
  border-bottom: 4px solid var(--hc-blue);
}
.hc-navbar .hc-userchip {
  color: #cfd6de;
  font-size: .85rem;
}
.hc-navbar .hc-userchip strong { color: #fff; }

.btn-hc {
  background: var(--hc-blue);
  border: none;
  color: #0f172a;
  font-weight: 600;
}
.btn-hc:hover { background: var(--hc-blue-d); color: #0f172a; }

.btn-outline-hc {
  border-color: var(--hc-blue-d);
  color: var(--hc-blue-deep);
}
.btn-outline-hc:hover,
.btn-outline-hc.active {
  background: var(--hc-blue);
  border-color: var(--hc-blue);
  color: #0f172a;
}

/* Login */
.hc-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(135deg, rgba(29,34,40,.96), rgba(42,49,58,.96)),
    repeating-linear-gradient(45deg, #38bdf8 0 18px, #1d2228 18px 36px);
}
.hc-login-card {
  width: 100%;
  max-width: 380px;
  background: #fff;
  border-radius: 14px;
  padding: 2rem;
  box-shadow: 0 18px 50px rgba(0,0,0,.4);
}
.hc-login-card .hc-brand { color: var(--hc-blue-d); font-size: 2rem; }
.hc-login-card .hc-brand span { color: var(--hc-carbon); }

/* Mapas */
.hc-map-shell {
  position: relative;
}
.hc-map {
  width: 100%;
  height: 380px;
  border-radius: 10px;
  border: 1px solid #d8dce1;
}
#mapaAdmin.hc-map { height: 520px; }
#mapaAdmin.hc-map--solo {
  height: calc(100vh - 260px);
  min-height: 420px;
}

.hc-map-fs-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 500;
  border: none;
  border-radius: 8px;
  padding: .45rem .75rem;
  font-size: .82rem;
  font-weight: 600;
  background: rgba(255, 255, 255, .95);
  color: var(--hc-carbon);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .18);
}
.hc-map-fs-btn:hover { background: #fff; }

.hc-map-shell.is-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: #fff;
  padding: 0;
}
.hc-map-shell.is-fullscreen .hc-map {
  height: 100% !important;
  border-radius: 0;
  border: none;
}
.hc-map-shell.is-fullscreen .hc-map-fs-btn {
  top: 12px;
  right: 12px;
}
.hc-map-shell.is-fullscreen .hc-map-legend {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 500;
  margin: 0;
  padding: .5rem .75rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}
body.hc-map-fs-active { overflow: hidden; }

/* Leyenda del mapa */
.hc-legend {
  font-size: .82rem;
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: .4rem;
  color: #555;
  flex-wrap: wrap;
}
.hc-map-shell:not(.is-fullscreen) .hc-map-legend {
  margin-top: .4rem;
}
.hc-dot { display:inline-block; width:12px; height:12px; border-radius:50%; margin-right:4px; vertical-align:-1px; }
.hc-dot-punto { background: var(--hc-blue-deep); }
.hc-dot-rel   { background: var(--hc-map-fill); }

/* Cards de relevamientos */
.hc-rel-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 8px 8px 0 0;
  cursor: pointer;
  background: #e7e9ec;
}
.hc-badge-pend { background:#8b94a1; }
.hc-badge-ok   { background:var(--hc-ok); }
.hc-badge-bad  { background:var(--hc-bad); }

.hc-fav {
  border: none;
  background: transparent;
  font-size: 1.35rem;
  line-height: 1;
  color: #c4c9cf;
  cursor: pointer;
}
.hc-fav.on { color: var(--hc-blue-d); }

/* Estado GPS promotor */
.hc-gps {
  font-size: .85rem;
  padding: .35rem .6rem;
  border-radius: 6px;
  background: #eef1f4;
}
.hc-gps.ok  { background:#e3f6ec; color:#13703d; }
.hc-gps.err { background:#fdebea; color:#9c2727; }

/* Input file oculto + vista previa foto (promotor) */
.hc-file-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.hc-foto-preview img {
  display: block;
  max-width: 100%;
  max-height: 220px;
  width: auto;
  border-radius: 10px;
  border: 2px solid #d8dce1;
  object-fit: contain;
  background: #e7e9ec;
}

.hc-foto-slot.processing .btn {
  pointer-events: none;
  opacity: 0.65;
}

.photo-slot-processing-overlay {
  position: absolute;
  inset: 0;
  z-index: 25;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 0.5rem;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(2px);
  border-radius: 10px;
}
.photo-slot-processing-overlay.is-visible { display: flex; }
.photo-slot-processing-box {
  text-align: center;
  max-width: 18rem;
  padding: 1rem 1.15rem;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.12);
  border: 1px solid #e9ecef;
}
.photo-slot-processing-spinner {
  width: 2.25rem;
  height: 2.25rem;
  margin: 0 auto 0.65rem;
  color: var(--hc-blue-d);
}
.photo-slot-processing-title { font-size: 0.95rem; line-height: 1.35; }
.photo-slot-processing-hint { font-size: 0.78rem; line-height: 1.3; }
.photo-slot-processing-overlay.has-error .photo-slot-processing-spinner { display: none; }

/* Lista de relevamientos (promotor) */
.hc-rel-lista .list-group-item {
  cursor: pointer;
  border-left: none;
  border-right: none;
  padding: .75rem 1rem;
  transition: background .15s;
}
.hc-rel-lista .list-group-item:first-child { border-top: none; }
.hc-rel-lista .list-group-item:hover,
.hc-rel-lista .list-group-item:focus {
  background: #f8f9fb;
  z-index: 1;
}
.hc-rel-item-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  min-width: 0;
}
.hc-rel-item-dir {
  font-weight: 600;
  color: var(--hc-carbon);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex: 1;
}
.hc-rel-item-meta {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-shrink: 0;
}
.hc-rel-item-fecha {
  font-size: .8rem;
  color: #6c757d;
  white-space: nowrap;
}
.hc-rel-detalle-foto {
  width: 100%;
  max-height: 320px;
  object-fit: contain;
  border-radius: 8px;
  background: #e7e9ec;
}
.hc-rel-detalle-dl dt {
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6c757d;
  margin-bottom: .15rem;
}
.hc-rel-detalle-dl dd {
  margin-bottom: .85rem;
}
.hc-rel-detalle-dl dd:last-child { margin-bottom: 0; }

/* Panel admin / control: tarjetas de resumen */
.hc-panel-stats {
  margin-top: 10px;
}
.hc-panel-stats .hc-stat-card {
  border: none;
  border-radius: 12px;
  overflow: hidden;
}
.hc-panel-stats .hc-stat-card .card-body {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  padding: 1rem 1.15rem;
}
.hc-stat-label {
  font-size: .78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: #6c757d;
}
.hc-stat-value {
  font-family: "Anton", Impact, "Arial Black", sans-serif;
  font-size: 2rem;
  line-height: 1;
  letter-spacing: .02em;
}
.hc-stat-card--total {
  background: linear-gradient(135deg, #fff 0%, #f3f5f8 100%);
  border-left: 4px solid var(--hc-carbon-2);
}
.hc-stat-card--total .hc-stat-value { color: var(--hc-carbon); }
.hc-stat-card--ok {
  background: linear-gradient(135deg, #fff 0%, #edf9f2 100%);
  border-left: 4px solid var(--hc-ok);
}
.hc-stat-card--ok .hc-stat-value { color: var(--hc-ok); }
.hc-stat-card--fav {
  background: linear-gradient(135deg, #fff 0%, #eef8ff 100%);
  border-left: 4px solid var(--hc-blue);
}
.hc-stat-card--fav .hc-stat-value { color: var(--hc-blue-deep); }

/* Panel admin / control: navegación y listado compacto */
.hc-admin-nav .nav-link {
  color: var(--hc-carbon);
  font-weight: 600;
}
.hc-admin-nav .nav-link.active {
  background: var(--hc-blue);
  color: #0f172a;
}
.hc-admin-lista-wrap {
  border-radius: 10px;
  overflow: hidden;
}
.hc-admin-rel-item {
  border-left: none;
  border-right: none;
  padding: .85rem 1rem;
  text-align: left;
  width: 100%;
}
.hc-admin-rel-item:first-child { border-top: none; }
.hc-admin-rel-item:hover,
.hc-admin-rel-item:focus {
  background: #f8f9fb;
  z-index: 1;
}
.hc-admin-rel-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  min-width: 0;
}
.hc-admin-rel-main {
  display: flex;
  flex-direction: column;
  gap: .2rem;
  min-width: 0;
  flex: 1;
}
.hc-admin-rel-dir {
  font-weight: 600;
  color: var(--hc-carbon);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hc-admin-rel-meta {
  font-size: .8rem;
  color: #6c757d;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hc-admin-rel-side {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-shrink: 0;
}
.hc-admin-rel-fav {
  color: var(--hc-blue-d);
  font-size: 1.1rem;
  line-height: 1;
}

/* Referencias de zona (promotor) */
.hc-zona-ref-modal .modal-header {
  border-bottom-color: #e9ecef;
}
.hc-zona-ref-modal .modal-title {
  font-weight: 600;
  color: var(--hc-carbon);
}
.hc-zona-ref-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid #d8dce1;
  background: #e7e9ec;
}
.hc-zona-ref-text {
  background: linear-gradient(135deg, #fff 0%, #eef8ff 100%);
  border: 1px solid #d8e8f4;
  border-left: 4px solid var(--hc-blue);
  border-radius: 12px;
  padding: 1.25rem 1.35rem;
}
.hc-zona-ref-titulo {
  font-family: "Anton", Impact, "Arial Black", sans-serif;
  font-size: 1.35rem;
  letter-spacing: .04em;
  color: var(--hc-blue-deep);
  text-transform: uppercase;
  margin-bottom: 0;
}
.hc-zona-ref-rango {
  font-size: .9rem;
  font-weight: 600;
  color: var(--hc-carbon);
  text-transform: uppercase;
  letter-spacing: .03em;
}
.hc-zona-ref-lista li {
  position: relative;
  padding: .45rem 0 .45rem 1.1rem;
  border-bottom: 1px solid rgba(27, 111, 173, .12);
  color: var(--hc-carbon);
  font-weight: 500;
}
.hc-zona-ref-lista li:last-child { border-bottom: none; }
.hc-zona-ref-lista li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--hc-blue);
}

@media (max-width: 576px) {
  .hc-rel-item-main { flex-wrap: wrap; }
  .hc-rel-item-meta { width: 100%; justify-content: space-between; }
  .hc-map { height: 300px; }
  #mapaAdmin.hc-map--solo {
    height: calc(100vh - 300px);
    min-height: 280px;
  }
  .hc-admin-rel-row { flex-wrap: wrap; }
  .hc-admin-rel-side { width: 100%; }
}
