/* FBOS Flota — Vertical overrides ONLY
   Objetivo: NO pisar el estilo global (/styles.css).
   Aquí solo van estilos específicos de Flota.
*/

/* ----------------------------
   Header / Tabs (premium)
-----------------------------*/

.header-block {
  margin-bottom: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding: 2px 2px 0;
}

.logo-box {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  border: 1px solid #d9e2ec;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  display: block;
  overflow: hidden;
  font-size: 10px;
  line-height: 1.1;
  letter-spacing: 0.04em;
  color: #64748b;
  text-transform: uppercase;
  font-weight: 700;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.05);
}
.logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.brand-title {
  font-weight: 700;
  font-size: 17px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.brand-subtitle {
  margin-top: 3px;
  font-size: 13px;
  color: #64748b;
  line-height: 1.3;
  font-weight: 500;
}

.tabs {
  display: flex;
  gap: 8px;
  padding: 6px;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  background: #f8fafc;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.tab {
  flex: 1;
  text-align: center;
  padding: 11px 0;
  border-radius: 12px;
  border: 1px solid transparent;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  background: transparent;
  transition: all 0.2s ease;
}

.tab:hover {
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
  border-color: #e2e8f0;
}

.tab.active {
  background: #ffffff;
  color: #0a2540;
  border-color: #dbe4ee;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 20px rgba(15, 23, 42, 0.06);
}

/* ----------------------------
   Vehículo — preview/verificación
-----------------------------*/

.vehicle-preview {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.02);
  display: none;
}

.vehicle-preview h3 {
  margin: 0 0 10px 0;
  font-size: 14px;
  opacity: 0.8;
}

.vehicle-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.readonly-field label {
  display: block;
  font-size: 12px;
  opacity: 0.75;
  margin-bottom: 4px;
}

.readonly-field input {
  width: 100%;
  padding: 10px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 10px;
  background: #f7f7f7;
}

@media (min-width: 560px) {
  .vehicle-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.hint {
  font-size: 12px;
  opacity: 0.7;
  margin-top: 6px;
}

/* ----------------------------
   Ajustes del form
-----------------------------*/

.container form input,
.container form select,
.container form textarea {
  display: block;
  margin: 10px 0 0;
}

.container form label {
  display: block;
  margin-top: 14px;
}

.container form .hint,
.container form small {
  display: block;
  margin-top: 8px;
}

.container form h2 {
  margin-top: 22px;
  margin-bottom: 10px;
}

.container form button,
.container form .btn {
  margin-top: 16px;
}

/* ----------------------------
   Confirmación estilo Stripe / Ding Repairs
-----------------------------*/

.confirm-card {
  margin-top: 14px;
  padding: 14px 16px;
  border: 1px solid #dfe3e8;
  border-radius: 12px;
  background: #f8fafc;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.confirm-card:hover {
  border-color: #b9c3cf;
  background: #ffffff;
}

.confirm-check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
  user-select: none;
}

.confirm-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.confirm-box {
  width: 20px;
  height: 20px;
  margin-top: 1px;
  border: 1.5px solid #c7d0d9;
  border-radius: 6px;
  background: #fff;
  flex: 0 0 20px;
  position: relative;
  transition: all 0.2s ease;
}

.confirm-text {
  font-size: 14px;
  line-height: 1.45;
  color: #0f172a;
}

.confirm-check input:checked + .confirm-box {
  background: #0a2540;
  border-color: #0a2540;
}

.confirm-check input:checked + .confirm-box::after {
  content: "";
  position: absolute;
  left: 6px;
  top: 2px;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.confirm-check input:focus + .confirm-box {
  box-shadow: 0 0 0 4px rgba(10, 37, 64, 0.12);
}

/* ----------------------------
   Evidencia visual — multi preview
-----------------------------*/

.evidence-preview-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.evidence-preview-item {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  border-radius: 12px;
  background: #ffffff;
}

.evidence-preview-remove {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 24px;
  height: 24px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
  font-size: 16px;
  line-height: 1;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.evidence-preview-remove:hover {
  border-color: rgba(15, 23, 42, 0.24);
  background: #ffffff;
}

.evidence-preview-media-wrap {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: #e2e8f0;
}

.evidence-preview-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.evidence-preview-file {
  font-size: 12px;
  line-height: 1.35;
  font-weight: 700;
  color: #0f172a;
  word-break: break-word;
}

.evidence-preview-meta {
  font-size: 11px;
  line-height: 1.3;
  color: #64748b;
}

@media (min-width: 640px) {
  .evidence-preview-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 980px) {
  .page .container {
    max-width: 1120px;
  }

  .header-block {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 24px;
  }

  .brand {
    margin-bottom: 0;
  }

  .tabs {
    width: auto;
    min-width: 360px;
  }

  .card {
    padding: 24px 28px;
  }

  #surfForm {
    max-width: 860px;
  }
}

/* Surf Synergy specific additions */
.flow-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.flow-column {
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #f8fafc;
  overflow: hidden;
}

.flow-column-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid #e2e8f0;
  background: #ffffff;
}

.flow-column-head h3 {
  margin: 0;
  font-size: 14px;
  color: #0f172a;
}

.flow-column-body {
  padding: 10px;
  display: grid;
  gap: 10px;
}

.action-card {
  cursor: pointer;
}

.action-header-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid #dbe4ee;
  background: #ffffff;
  color: #334155;
  font-size: 11px;
  font-weight: 700;
}

.chip-state {
  background: #e8f0f8;
  border-color: #d3deeb;
}

.chip-success {
  background: #ecfdf3;
  border-color: #b7ebcc;
  color: #0a7c3a;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 50;
}

.modal.open {
  display: flex;
}

.modal-card {
  width: min(680px, 100%);
  max-height: 92vh;
  overflow: auto;
  border-radius: 16px;
  border: 1px solid #dbe4ee;
  background: #ffffff;
  padding: 14px;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.modal-body {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px;
  background: #f8fafc;
}

.modal-actions {
  margin-top: 12px;
}

.btn-ghost {
  border: 1px solid #dbe4ee;
  background: #f8fafc;
  color: #334155;
}

.history-grid {
  display: grid;
  gap: 10px;
}

@media (min-width: 760px) {
  .flow-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
