* {
  box-sizing: border-box;
}

:root {
  --sidebar-width: 250px;
  --background: #f4f6f8;
  --panel: #ffffff;
  --border: #e2e6ea;
  --text: #17202a;
  --muted: #6b7280;
  --green: #16a34a;
  --blue: #2563eb;
  --red: #dc2626;
}

html,
body {
  margin: 0;
  padding: 0;
  width: 100%;
  min-height: 100%;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--background);
  color: var(--text);
}

body {
  display: flex;
  width: 100%;
  min-height: 100vh;
  height: 100vh;
  overflow: hidden;
}

/* SIDEBAR */

.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--sidebar-width);
  background: #111827;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-height: 0;
  z-index: 100;
}

.brand {
  height: 82px;
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  color: #111827;
  font-weight: 800;
  font-size: 14px;
}

.brand strong {
  display: block;
  font-size: 15px;
  letter-spacing: 0.5px;
}

.brand span {
  display: block;
  margin-top: 3px;
  font-size: 10px;
  color: #9ca3af;
  letter-spacing: 1.5px;
}

.sidebar nav {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px 10px;
  scrollbar-width: thin;
}

.menu-item {
  width: 100%;
  min-height: 46px;
  margin-bottom: 5px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #d1d5db;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  cursor: pointer;
  text-align: left;
  font-size: 14px;
}

.menu-item span {
  width: 20px;
  text-align: center;
  font-size: 17px;
}

.menu-item:hover {
  background: rgba(255,255,255,0.07);
  color: #ffffff;
}

.menu-item.active {
  background: #ffffff;
  color: #111827;
  font-weight: 600;
}

.sidebar-footer {
  flex: 0 0 auto;
  padding: 14px;
  border-top: 1px solid rgba(255,255,255,0.08);
}

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

.connection strong {
  display: block;
  font-size: 12px;
}

.connection small {
  display: block;
  margin-top: 3px;
  color: #9ca3af;
  font-size: 11px;
}

.status-dot {
  width: 9px;
  height: 9px;
  background: var(--green);
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(22,163,74,0.15);
}

/* MAIN */

.main {
  margin-left: var(--sidebar-width);
  width: calc(100% - var(--sidebar-width));
  min-width: 0;
  min-height: 0;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
}

/* TOPBAR */

.topbar {
  min-height: 82px;
  padding: 18px 28px;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.topbar h1 {
  margin: 0;
  font-size: 23px;
}

.topbar p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 22px;
  color: var(--muted);
  font-size: 12px;
}

.user-menu {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  font-weight: 600;
}

.avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #111827;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
}

/* CONTENT */

.section {
  display: none;
  padding: 28px;
}

.section.active {
  display: block;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  min-height: 130px;
}

.card-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.card-value {
  margin-top: 12px;
  font-size: 30px;
  font-weight: 700;
}

.card-value.green {
  color: var(--green);
}

.card-value.blue {
  color: var(--blue);
}

.card-value.red {
  color: var(--red);
}

.card-info {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
}

/* PANEL */

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
}

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

.panel-header h2 {
  margin: 0;
  font-size: 17px;
}

.panel-header p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.refresh-button {
  border: 1px solid var(--border);
  background: #ffffff;
  border-radius: 7px;
  padding: 9px 13px;
  cursor: pointer;
  font-size: 12px;
}

.refresh-button:hover {
  background: #f3f4f6;
}

/* TABLE */

.table-wrapper {
  width: 100%;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

th,
td {
  padding: 15px 18px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: 12px;
}

th {
  background: #f9fafb;
  color: var(--muted);
  font-weight: 600;
}

tr:last-child td {
  border-bottom: 0;
}

.empty {
  text-align: center;
  color: var(--muted);
  padding: 35px;
}

/* CHARGER */

.charger-id {
  font-weight: 700;
  color: var(--text);
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
}

.status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #9ca3af;
}

.status.available::before {
  background: var(--green);
}

.status.charging::before {
  background: var(--blue);
}

.status.faulted::before {
  background: var(--red);
}

.connected {
  color: var(--green);
  font-weight: 600;
}

.disconnected {
  color: var(--red);
  font-weight: 600;
}

.actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.action-button {
  border: 1px solid var(--border);
  background: #ffffff;
  border-radius: 6px;
  padding: 7px 9px;
  font-size: 11px;
  cursor: pointer;
}

.action-button:hover {
  background: #f3f4f6;
}

.action-button.primary {
  background: #111827;
  color: #ffffff;
  border-color: #111827;
}

.action-button.danger {
  color: var(--red);
}

.action-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* PLACEHOLDER */

.placeholder {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 30px;
}

.placeholder h2 {
  margin-top: 0;
}

/* RESPONSIVE */

@media (max-width: 1100px) {
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  :root {
    --sidebar-width: 210px;
  }

  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .topbar-right {
    width: 100%;
    justify-content: space-between;
  }

  .section {
    padding: 18px;
  }
}

@media (max-width: 560px) {
  .sidebar {
    width: 70px;
  }

  .main {
    margin-left: 70px;
    width: calc(100% - 70px);
  }

  .brand {
    justify-content: center;
    padding: 12px;
  }

  .brand > div:not(.brand-logo) {
    display: none;
  }

  .menu-item {
    justify-content: center;
    padding: 0;
  }

  .menu-item {
    font-size: 0;
  }

  .menu-item span {
    font-size: 18px;
  }

  .sidebar-footer {
    padding: 12px;
  }

  .connection div {
    display: none;
  }

  .cards {
    grid-template-columns: 1fr;
  }
}

.charger-model {
  margin-top: 4px;
  font-size: 12px;
  color: #6b7280;
}

.charger-serial {
  margin-top: 3px;
  font-size: 11px;
  color: #9ca3af;
}


.charger-clickable {
  cursor: pointer;
  transition: color 0.2s ease;
}

.charger-clickable:hover {
  color: #2563eb;
  text-decoration: underline;
}

.charger-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.charger-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.62);
  backdrop-filter: blur(3px);
}

.charger-modal-card {
  position: relative;
  z-index: 1;
  width: min(760px, 100%);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
}

.charger-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px;
  border-bottom: 1px solid #e5e7eb;
}

.charger-modal-title {
  font-size: 20px;
  font-weight: 700;
  color: #111827;
}

.charger-modal-subtitle {
  margin-top: 5px;
  font-size: 13px;
  color: #6b7280;
}

.charger-modal-close {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  background: #f3f4f6;
  color: #374151;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.charger-modal-close:hover {
  background: #e5e7eb;
}

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


.session-details-grid {
  display: grid;
  gap: 18px;
}

.session-details-section {
  padding: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #ffffff;
}

.session-details-section-title {
  margin-bottom: 14px;
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}

.session-details-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.session-details-fields > div {
  padding: 11px 12px;
  border: 1px solid #eef0f2;
  border-radius: 8px;
  background: #f9fafb;
}

.session-details-label {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  color: #6b7280;
}

.session-details-fields strong {
  display: block;
  font-size: 13px;
  color: #111827;
  word-break: break-word;
}


.charge-status-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
}

.charge-status-badge.pending {
  background: #fef3c7;
  color: #92400e;
}

.charge-status-badge.paid {
  background: #dcfce7;
  color: #166534;
}

.charge-status-badge.cancelled {
  background: #f3f4f6;
  color: #4b5563;
}

.charge-status-badge.refunded {
  background: #dbeafe;
  color: #1d4ed8;
}

.charge-status-badge.failed {
  background: #fee2e2;
  color: #b91c1c;
}

.charge-status-badge.unknown {
  background: #f3f4f6;
  color: #6b7280;
}


@media (max-width: 640px) {
  .session-details-fields {
    grid-template-columns: 1fr;
  }
}


.charger-detail-section {
  margin-bottom: 24px;
}

.charger-detail-section:last-child {
  margin-bottom: 0;
}

.charger-detail-section h3 {
  margin: 0 0 14px;
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}

.charger-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.charger-detail-item {
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f9fafb;
}

.charger-detail-item span {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  color: #6b7280;
}

.charger-detail-item strong {
  display: block;
  font-size: 13px;
  color: #111827;
  word-break: break-word;
}

@media (max-width: 640px) {
  .charger-modal {
    padding: 12px;
  }

  .charger-modal-card {
    max-height: calc(100vh - 24px);
  }

  .charger-modal-header,
  .charger-modal-body {
    padding: 18px;
  }

  .charger-detail-grid {
    grid-template-columns: 1fr;
  }
}

.charger-operational-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.charger-operational-status {
  padding: 14px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f9fafb;
}

.charger-operational-status span {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  color: #6b7280;
}

.charger-operational-status strong {
  display: block;
  font-size: 14px;
  color: #111827;
}

.charger-tariff-list { display:grid; gap:12px; }
.charger-tariff-card { border:1px solid var(--border); border-radius:8px; padding:16px; background:#fff; }
.charger-tariff-header { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; margin-bottom:14px; }
.charger-tariff-name { font-size:14px; font-weight:700; color:#111827; }
.charger-tariff-code { margin-top:4px; font-size:11px; color:#6b7280; }
.charger-tariff-badges { display:flex; flex-wrap:wrap; gap:6px; justify-content:flex-end; }
.charger-tariff-badge { display:inline-flex; align-items:center; border-radius:999px; padding:4px 8px; font-size:10px; font-weight:700; text-transform:uppercase; }
.charger-tariff-badge.active { background:#ecfdf3; color:#166534; }
.charger-tariff-badge.inactive { background:#f3f4f6; color:#6b7280; }
.charger-tariff-badge.default { background:#eff6ff; color:#1d4ed8; }
.charger-tariff-values { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; }
.charger-tariff-value { padding:10px; border:1px solid #eef0f2; border-radius:6px; background:#f9fafb; }
.charger-tariff-value span { display:block; font-size:10px; color:#6b7280; margin-bottom:4px; }
.charger-tariff-value strong { display:block; font-size:12px; color:#111827; }
@media (max-width:700px) { .charger-tariff-values { grid-template-columns:repeat(2,minmax(0,1fr)); } .charger-tariff-header { flex-direction:column; } .charger-tariff-badges { justify-content:flex-start; } }
.charger-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.charger-modal-actions .btn {
  min-width: 110px;
}

@media (max-width: 640px) {
  .charger-operational-summary {
    grid-template-columns: 1fr;
  }

  .charger-modal-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .charger-modal-actions .btn {
    width: 100%;
  }
}

/* USER MANAGEMENT */

.section-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 20px;
}

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

.section-header h2 {
  margin: 0;
}

.section-header p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.form-field label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
}

.form-field input,
.form-field select {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 10px 12px;
  font-size: 13px;
  background: #ffffff;
  color: var(--text);
  outline: none;
}

.form-field input:focus,
.form-field select:focus {
  border-color: var(--blue);
}

.form-field small {
  color: var(--muted);
  font-size: 11px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 22px;
}

@media (max-width: 760px) {
  .form-grid {
    grid-template-columns: 1fr;
  }

  .section-header {
    align-items: flex-start;
    flex-direction: column;
  }
}


/* =========================================================
   LOGIN
   ========================================================= */

.login-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: #f4f7fb;
}

body.login-required .login-screen {
  display: flex;
}

body.login-required > .sidebar,
body.login-required > .main {
  display: none;
}

.login-card {
  width: 100%;
  max-width: 420px;
  padding: 36px;
  background: #ffffff;
  border: 1px solid #e5eaf0;
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.10);
}

.login-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 32px;
}

.login-logo {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: #111827;
  color: #ffffff;
  font-size: 18px;
  font-weight: 700;
}

.login-brand strong,
.login-brand span {
  display: block;
}

.login-brand strong {
  font-size: 16px;
  letter-spacing: 0.04em;
}

.login-brand span {
  margin-top: 2px;
  font-size: 12px;
  color: #64748b;
  letter-spacing: 0.08em;
}

.login-header {
  margin-bottom: 24px;
}

.login-header h1 {
  margin: 0;
  font-size: 26px;
  color: #111827;
}

.login-header p {
  margin: 7px 0 0;
  color: #64748b;
  font-size: 14px;
}

.login-card .form-group {
  margin-bottom: 18px;
}

.login-card label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
}

.login-card input {
  width: 100%;
  box-sizing: border-box;
  height: 46px;
  padding: 0 13px;
  border: 1px solid #d8dee8;
  border-radius: 8px;
  background: #ffffff;
  color: #111827;
  font-size: 14px;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.login-card input:focus {
  border-color: #64748b;
  box-shadow: 0 0 0 3px rgba(100, 116, 139, 0.12);
}

.login-button {
  width: 100%;
  height: 46px;
  margin-top: 4px;
  border: 0;
  border-radius: 8px;
  background: #111827;
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.login-button:hover {
  opacity: 0.92;
}

.login-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.login-error {
  min-height: 20px;
  margin-top: 14px;
  color: #dc2626;
  font-size: 13px;
  text-align: center;
}

@media (max-width: 480px) {
  .login-card {
    padding: 28px 22px;
  }
}


/* Modal de edição de associação de tarifa - camada superior */
#charger-edit-tariff-modal {
  z-index: 10000 !important;
}
#charger-edit-tariff-modal .charger-modal-backdrop {
  z-index: 10001;
}
#charger-edit-tariff-modal .charger-modal-card {
  position: relative;
  z-index: 10002;
}

/* SESSIONS TABLE */
#sessions .table-card {
  background: #ffffff;
  overflow: hidden;
}

#sessions .table-wrapper {
  display: block;
  width: 100%;
  overflow-x: auto;
  overflow-y: visible;
}

#sessions .data-table {
  display: table;
  width: 100%;
  min-width: 1100px;
  table-layout: auto;
  border-collapse: collapse;
}

#sessions .data-table thead {
  display: table-header-group;
}

#sessions .data-table tbody {
  display: table-row-group;
}

#sessions .data-table tr {
  display: table-row;
}

#sessions .data-table th,
#sessions .data-table td {
  display: table-cell;
  visibility: visible;
  opacity: 1;
  color: #17202a;
  background: transparent;
  white-space: nowrap;
}

#sessions .data-table thead th {
  background: #f9fafb;
  color: #6b7280;
}

#sessions .data-table tbody tr:hover {
  background: #f8fafc;
}

#sessions .status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}


/* Editor de tarifa comercial */
.tariff-edit-card {
  width: min(900px, 100%);
}

.tariff-edit-section {
  padding: 18px;
  margin-bottom: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #fff;
}

.tariff-edit-section:last-child {
  margin-bottom: 0;
}

.tariff-edit-section-title {
  margin-bottom: 16px;
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}

.tariff-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.tariff-edit-full {
  grid-column: 1 / -1;
}

.tariff-edit-pricing-grid {
  margin-top: 14px;
}

.tariff-price-highlight {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #eff6ff;
}

.tariff-price-highlight span {
  display: block;
  margin-bottom: 4px;
  font-size: 12px;
  font-weight: 600;
  color: #2563eb;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.tariff-price-highlight strong {
  display: block;
  font-size: 15px;
  color: #1e3a8a;
}

.tariff-edit-actions {
  justify-content: flex-end;
  padding-top: 18px;
  border-top: 1px solid #e5e7eb;
}

.tariff-edit-actions .btn {
  min-width: 130px;
}

@media (max-width: 700px) {
  .tariff-edit-grid {
    grid-template-columns: 1fr;
  }

  .tariff-edit-full {
    grid-column: auto;
  }

  .tariff-edit-actions {
    flex-direction: column-reverse;
  }

  .tariff-edit-actions .btn {
    width: 100%;
  }
}


/* Associação de tarifa */
.tariff-association-current {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.tariff-association-current > div {
  padding: 14px 16px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f9fafb;
}

.tariff-association-current span {
  display: block;
  margin-bottom: 5px;
  font-size: 11px;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.tariff-association-current strong {
  display: block;
  font-size: 14px;
  color: #111827;
}

.tariff-association-default {
  display: flex;
  align-items: center;
}

.tariff-association-check {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f9fafb;
  cursor: pointer;
}

.tariff-association-check input {
  width: 17px;
  height: 17px;
  margin-top: 2px;
  flex: 0 0 auto;
}

.tariff-association-check span {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.tariff-association-check strong {
  font-size: 13px;
  color: #111827;
}

.tariff-association-check small {
  font-size: 11px;
  line-height: 1.4;
  color: #6b7280;
}

@media (max-width: 700px) {
  .tariff-association-current {
    grid-template-columns: 1fr;
  }

  .tariff-association-default {
    align-items: stretch;
  }
}


/* =========================================================
   CONECTORES / PLUGS DO CARREGADOR
   ========================================================= */

.charger-section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.charger-section-heading h3 {
  margin: 0;
}

.charger-section-description {
  margin: 5px 0 0;
  color: #6b7280;
  font-size: 13px;
  line-height: 1.5;
}

.charger-connectors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
}

.charger-connector-card {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px;
  background: #ffffff;
}

.charger-connector-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.charger-connector-name {
  font-size: 16px;
  font-weight: 700;
  color: #111827;
}

.charger-connector-id {
  margin-top: 4px;
  color: #6b7280;
  font-size: 12px;
}

.charger-connector-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.charger-connector-status.active {
  background: #dcfce7;
  color: #166534;
}

.charger-connector-status.inactive {
  background: #f3f4f6;
  color: #6b7280;
}

.charger-loading-state,
.charger-empty-state {
  padding: 20px;
  border: 1px dashed #d1d5db;
  border-radius: 10px;
  text-align: center;
  color: #6b7280;
  font-size: 14px;
  background: #f9fafb;
}

@media (max-width: 640px) {
  .charger-connectors-grid {
    grid-template-columns: 1fr;
  }

  .charger-connector-header {
    flex-direction: column;
  }
}


.charger-connector-header-actions {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .charger-connector-header-actions {
    justify-content: flex-start;
  }
}

.charger-connector-operational-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.charger-connector-operational-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex: 0 0 7px;
}

.charger-connector-operational-status.available {
  background: #dcfce7;
  color: #166534;
}

.charger-connector-operational-status.available .charger-connector-operational-dot {
  background: #16a34a;
}

.charger-connector-operational-status.charging {
  background: #dbeafe;
  color: #1d4ed8;
}

.charger-connector-operational-status.charging .charger-connector-operational-dot {
  background: #2563eb;
}

.charger-connector-operational-status.faulted {
  background: #fee2e2;
  color: #b91c1c;
}

.charger-connector-operational-status.faulted .charger-connector-operational-dot {
  background: #dc2626;
}

.charger-connector-operational-status.unavailable {
  background: #f3f4f6;
  color: #4b5563;
}

.charger-connector-operational-status.unavailable .charger-connector-operational-dot {
  background: #6b7280;
}

.charger-connector-operational-status.neutral {
  background: #f3f4f6;
  color: #374151;
}

.charger-connector-operational-status.neutral .charger-connector-operational-dot {
  background: #6b7280;
}

.charger-connector-operational-status.unknown {
  background: #f9fafb;
  color: #6b7280;
  border: 1px solid #e5e7eb;
}

.charger-connector-operational-status.unknown .charger-connector-operational-dot {
  background: #9ca3af;
}

