.client-dashboard {
  padding: 132px 0 72px;
}

.dashboard-intro {
  padding: 30px;
  border-radius: 28px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.dashboard-intro h1 {
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  margin-bottom: 10px;
}

.dashboard-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 12px;
  width: min(500px, 100%);
}

.dashboard-menu-wrap {
  margin-top: 20px;
}

.dashboard-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.dashboard-menu-item {
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: #d9f0ff;
  border-radius: 999px;
  padding: 9px 14px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.86rem;
}

.dashboard-menu-item:hover,
.dashboard-menu-item:focus-visible {
  border-color: rgba(225, 126, 255, 0.3);
}

.dashboard-menu-item.is-active {
  border-color: rgba(141, 84, 255, 0.45);
  background: linear-gradient(130deg, rgba(141, 84, 255, 0.24), rgba(225, 126, 255, 0.16));
  color: #f4fcff;
}

.kpi-card {
  padding: 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.kpi-card strong {
  display: block;
  font-family: 'Poppins', sans-serif;
  font-size: 1.08rem;
  margin-bottom: 3px;
  color: var(--highlight);
}

.kpi-card span {
  color: var(--muted);
  font-size: 0.9rem;
}

.dashboard-grid {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  align-items: start;
}

.dashboard-menu-panels {
  grid-template-columns: 1fr;
}

.dashboard-panel[hidden] {
  display: none;
}

.dashboard-card {
  padding: 24px;
  border-radius: 24px;
}

.support-card {
  grid-column: 1 / -1;
}

.dashboard-card h2 {
  font-size: 1.6rem;
  margin-bottom: 8px;
}

.card-note {
  margin-bottom: 16px;
  font-size: 0.95rem;
}

.subsection-title {
  margin-top: 18px;
  margin-bottom: 12px;
  font-size: 1.1rem;
  color: #eadfff;
}

.dashboard-form {
  display: grid;
  gap: 10px;
}

.dashboard-form label {
  color: #e6d7ff;
  font-weight: 700;
  font-size: 0.92rem;
}

.dashboard-form input,
.dashboard-form select,
.dashboard-form textarea,
.message-form input {
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border-radius: 14px;
  padding: 12px 14px;
  width: 100%;
}

.dashboard-form textarea {
  resize: vertical;
}

.dashboard-form input::placeholder,
.dashboard-form textarea::placeholder,
.message-form input::placeholder {
  color: #b9a0d1;
}

.dashboard-form .btn {
  margin-top: 6px;
}

.service-list {
  display: grid;
  gap: 12px;
}

.service-item {
  border-radius: 16px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.service-item.service-item-usage-alert {
  border-color: rgba(255, 94, 94, 0.38);
  background: linear-gradient(145deg, rgba(58, 13, 13, 0.46), rgba(255, 97, 97, 0.08));
}

.service-item header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.service-item p {
  font-size: 0.95rem;
}

.service-usage-warning {
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 99, 99, 0.38);
  background: rgba(116, 23, 23, 0.28);
  color: #ffd9d9;
  font-size: 0.88rem;
  line-height: 1.4;
}

.service-usage-warning strong {
  color: #ffe7a8;
}

.service-usage-alert-summary {
  margin-top: 8px;
  margin-bottom: 10px;
  border-radius: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(122, 214, 255, 0.34);
  background: rgba(20, 62, 98, 0.24);
  color: #d9f1ff;
}

.service-usage-alert-summary.is-over {
  border-color: rgba(255, 101, 101, 0.34);
  background: rgba(118, 23, 23, 0.24);
  color: #ffd7d7;
}

.service-usage-alert-summary.is-error {
  border-color: rgba(255, 170, 92, 0.38);
  background: rgba(109, 61, 20, 0.26);
  color: #ffe2b8;
}

.service-usage-alert-summary.is-ok {
  border-color: rgba(79, 216, 151, 0.36);
  background: rgba(20, 88, 61, 0.24);
  color: #d8ffe9;
}

.service-item-actions {
  margin-top: 10px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.service-item-actions-controls {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.linode-config-panel {
  margin-top: 10px;
  border-radius: 14px;
  border: 1px solid rgba(147, 201, 255, 0.24);
  background: linear-gradient(145deg, rgba(9, 28, 52, 0.62), rgba(4, 16, 31, 0.72));
  padding: 12px;
  display: grid;
  gap: 10px;
}

.linode-config-note {
  margin: 0;
  font-size: 0.86rem;
  color: rgba(204, 231, 247, 0.92);
}

.linode-config-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.linode-config-row {
  display: grid;
  gap: 6px;
}

.linode-config-row label {
  font-size: 0.82rem;
  color: rgba(216, 236, 250, 0.95);
  font-weight: 700;
}

.linode-config-row select,
.linode-config-row input {
  border: 1px solid rgba(180, 223, 255, 0.28);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border-radius: 12px;
  padding: 10px 12px;
}

.linode-output {
  border-radius: 12px;
  border: 1px solid rgba(172, 209, 236, 0.32);
  background: rgba(255, 255, 255, 0.04);
  padding: 10px;
  display: grid;
  gap: 4px;
}

.linode-output.info {
  border-color: rgba(122, 214, 255, 0.34);
}

.linode-output.success {
  border-color: rgba(39, 227, 142, 0.4);
}

.linode-output.error {
  border-color: rgba(255, 94, 94, 0.45);
}

.linode-output p {
  margin: 0;
  font-size: 0.84rem;
  color: #dff3ff;
}

.linode-bandwidth-chart {
  margin-top: 8px;
  border-radius: 12px;
  border: 1px solid rgba(132, 209, 255, 0.3);
  background: radial-gradient(circle at 20% 10%, rgba(87, 183, 255, 0.16), rgba(6, 20, 35, 0.68));
  padding: 8px;
}

.linode-bandwidth-chart svg {
  width: 100%;
  height: auto;
  display: block;
}

.linode-bandwidth-plot {
  fill: rgba(4, 15, 26, 0.76);
  stroke: rgba(128, 198, 245, 0.24);
  stroke-width: 1;
}

.linode-bandwidth-grid-line {
  stroke: rgba(160, 218, 255, 0.2);
  stroke-width: 1;
}

.linode-bandwidth-axis-label {
  fill: rgba(210, 238, 255, 0.8);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.linode-bandwidth-axis-label.x-axis {
  fill: rgba(228, 247, 255, 0.94);
  font-size: 10px;
  font-weight: 700;
}

.linode-bandwidth-area {
  fill: rgba(77, 216, 255, 0.22);
}

.linode-bandwidth-line {
  fill: none;
  stroke: #58dcff;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 420;
  stroke-dashoffset: 420;
  animation: linodeBandwidthLineDraw 0.9s ease-out forwards;
}

.linode-bandwidth-point {
  fill: #61e2ff;
  stroke: #102434;
  stroke-width: 2;
}

.linode-bandwidth-point-value {
  fill: #eaf8ff;
  font-size: 9px;
  font-weight: 700;
}

@keyframes linodeBandwidthLineDraw {
  to {
    stroke-dashoffset: 0;
  }
}

.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.76rem;
  font-weight: 800;
  border: 1px solid transparent;
  white-space: nowrap;
}

.status-active {
  background: rgba(39, 227, 142, 0.14);
  color: #c5fbe0;
  border-color: rgba(39, 227, 142, 0.24);
}

.status-pending {
  background: rgba(255, 196, 68, 0.15);
  color: #ffe2a4;
  border-color: rgba(255, 196, 68, 0.24);
}

.status-paid {
  background: rgba(141, 84, 255, 0.16);
  color: #d9c0ff;
  border-color: rgba(225, 126, 255, 0.24);
}

.status-due {
  background: rgba(255, 94, 94, 0.16);
  color: #ffd0d0;
  border-color: rgba(255, 94, 94, 0.24);
}

.status-warning {
  background: rgba(255, 196, 68, 0.2);
  color: #ffe3a8;
  border-color: rgba(255, 196, 68, 0.32);
}

.status-expired {
  background: rgba(255, 84, 84, 0.24);
  color: #ffd0d0;
  border-color: rgba(255, 84, 84, 0.42);
}

.billing-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.summary-chip {
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.summary-chip span {
  display: block;
  color: var(--muted);
  font-size: 0.86rem;
}

.summary-chip strong {
  display: block;
  margin-top: 4px;
  color: var(--text);
}

.table-wrap {
  overflow-x: auto;
}

.invoice-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
}

.invoice-table th,
.invoice-table td {
  text-align: left;
  padding: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.92rem;
}

.invoice-table th {
  color: #e6d7ff;
  font-size: 0.84rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.table-action {
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
  font-weight: 700;
}

.table-action:hover,
.table-action:focus-visible {
  border-color: rgba(225, 126, 255, 0.25);
}

.table-action.danger {
  border-color: rgba(255, 94, 94, 0.35);
  color: #ffd0d0;
}

.table-action.danger:hover,
.table-action.danger:focus-visible {
  border-color: rgba(255, 94, 94, 0.55);
}

.table-action.success {
  border-color: rgba(39, 227, 142, 0.32);
  color: #cbffe5;
}

.table-action.success:hover,
.table-action.success:focus-visible {
  border-color: rgba(39, 227, 142, 0.5);
}

.support-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.95fr) minmax(320px, 1.05fr);
  gap: 18px;
  align-items: start;
}

.support-grid > section {
  min-width: 0;
}

.ticket-list {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  max-height: 360px;
  overflow-y: auto;
  padding-right: 2px;
}

.ticket-list li {
  list-style: none;
  border-radius: 14px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.ticket-item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.ticket-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.ticket-item-head strong {
  margin-bottom: 0;
}

.ticket-item {
  cursor: pointer;
}

.ticket-item.active {
  border-color: rgba(225, 126, 255, 0.28);
  background: linear-gradient(135deg, rgba(141, 84, 255, 0.18), rgba(225, 126, 255, 0.08));
}

.ticket-list li strong {
  display: inline-block;
  margin-right: 8px;
  margin-bottom: 6px;
}

.ticket-list li p {
  margin-top: 8px;
  font-size: 0.93rem;
  overflow-wrap: anywhere;
}

.message-thread {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  max-height: 360px;
  overflow-y: auto;
  padding-right: 2px;
}

.message-bubble {
  border-radius: 14px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.message-bubble.incoming {
  background: rgba(255, 255, 255, 0.05);
}

.message-bubble.outgoing {
  background: rgba(141, 84, 255, 0.14);
  border-color: rgba(225, 126, 255, 0.24);
}

.message-bubble strong {
  display: block;
  margin-bottom: 5px;
  color: #dff6ff;
}

.message-bubble p {
  margin-bottom: 6px;
}

.message-bubble time {
  color: #bba5d7;
  font-size: 0.8rem;
}

.message-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

#profileEmail:disabled {
  opacity: 0.75;
  cursor: not-allowed;
}

.client-status {
  min-height: 28px;
  margin-top: 16px;
  font-weight: 700;
  color: #dcc8ff;
}

.client-status.success {
  color: #9df8c8;
}

.client-status.error {
  color: #ffb4b4;
}

.client-status.info {
  color: #d2b8ff;
}

.confirm-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1300;
  padding: 18px;
  background: rgba(10, 4, 22, 0.78);
  display: none;
  align-items: center;
  justify-content: center;
}

.confirm-modal-backdrop.visible {
  display: flex;
}

.confirm-modal {
  width: min(440px, 100%);
  border-radius: 22px;
  padding: 22px;
}

.confirm-modal h3 {
  margin-bottom: 8px;
}

.confirm-modal-actions {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.renew-contact-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1200;
  padding: 18px;
  background: rgba(2, 11, 20, 0.78);
  display: none;
  align-items: center;
  justify-content: center;
}

.renew-contact-backdrop.visible {
  display: flex;
}

.renew-contact-modal {
  width: min(460px, 100%);
  border-radius: 22px;
  padding: 22px;
}

.renew-contact-modal h3 {
  margin-bottom: 8px;
}

.renew-contact-target {
  margin-top: 8px;
  font-size: 0.93rem;
  color: #eadfff;
}

.renew-contact-actions {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.renew-contact-cancel {
  width: 100%;
  margin-top: 12px;
}

@media (max-width: 1080px) {
  .dashboard-grid,
  .support-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .client-dashboard {
    padding-top: 122px;
  }

  .dashboard-menu {
    gap: 8px;
    padding: 10px;
  }

  .dashboard-menu-item {
    flex: 1 1 calc(50% - 8px);
    text-align: center;
  }

  .dashboard-intro,
  .dashboard-card {
    padding: 20px;
  }

  .dashboard-kpis,
  .billing-summary {
    grid-template-columns: 1fr;
  }

  .message-form {
    grid-template-columns: 1fr;
  }

  .renew-contact-actions {
    grid-template-columns: 1fr;
  }

  .confirm-modal-actions {
    flex-direction: column;
  }

  .ticket-item-head {
    align-items: stretch;
  }
}
