@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@500;600;700&display=swap");

:root {
  --bg: #edf3f9;
  --card: #ffffff;
  --text: #1b2a40;
  --muted: #5f708a;
  --primary: #0f766e;
  --primary-dark: #115e59;
  --border: #dbe5f2;
  --danger: #b91c1c;
  --warning: #b45309;
  --success: #166534;
  --shadow: 0 12px 30px rgba(15, 23, 42, 0.07);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Manrope", "Segoe UI", Tahoma, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 80% 12%, rgba(15, 118, 110, 0.12), transparent 35%),
    radial-gradient(circle at 12% 88%, rgba(37, 99, 235, 0.08), transparent 32%),
    var(--bg);
  line-height: 1.5;
}

.container {
  width: min(100%, 1050px);
  margin: 0 auto;
  padding: 24px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 24px;
}

.center-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}

.center-card {
  width: min(100%, 520px);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  font-family: "Plus Jakarta Sans", "Manrope", sans-serif;
  letter-spacing: -0.01em;
}

p {
  color: var(--muted);
}

label {
  display: block;
  font-size: 14px;
  margin-bottom: 6px;
  font-weight: 600;
}

input,
select,
button {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 11px 13px;
  font-size: 14px;
  font-family: inherit;
}

input:focus,
select:focus {
  outline: 2px solid #99f6e4;
  border-color: var(--primary);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.field {
  margin-bottom: 14px;
}

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

button {
  background: linear-gradient(135deg, #0f766e, #0d9488);
  color: #fff;
  border: 0;
  cursor: pointer;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  box-shadow: 0 8px 16px rgba(13, 148, 136, 0.26);
}

button:hover {
  transform: translateY(-1px);
  background: linear-gradient(135deg, var(--primary-dark), #0f8d82);
}

button.secondary {
  background: #fff;
  color: var(--text);
  border: 1px solid var(--border);
  box-shadow: none;
}

button.secondary:hover {
  background: #f8fbff;
  transform: translateY(0);
}

.actions {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

.actions button {
  width: auto;
  min-width: 120px;
}

.small-note {
  font-size: 12px;
}

.error {
  color: var(--danger);
  font-size: 13px;
  min-height: 20px;
}

.success {
  color: var(--success);
  font-size: 13px;
}

header.topbar {
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(6px);
}

.topbar .inner {
  width: min(100%, 1050px);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  font-weight: 800;
  color: var(--primary);
  font-family: "Plus Jakarta Sans", sans-serif;
  letter-spacing: -0.01em;
}

.profile-top {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 16px;
}

.avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #ccfbf1;
}

.badge {
  display: inline-block;
  margin-top: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}

.badge-active {
  background: #dcfce7;
  color: #166534;
}

.badge-inactive {
  background: #fef3c7;
  color: var(--warning);
}

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

.user-list {
  margin-top: 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.user-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
  gap: 10px;
  padding: 12px;
  border-bottom: 1px solid var(--border);
  align-items: center;
}

.user-row:last-child {
  border-bottom: 0;
}

.user-row.header {
  background: #f3f7fc;
  font-weight: 700;
}

.user-row .actions {
  margin: 0;
  flex-wrap: wrap;
}

.user-row .actions button {
  min-width: 72px;
  padding: 8px 10px;
}

.link {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
}

.progress {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.progress span {
  flex: 1;
  height: 7px;
  border-radius: 999px;
  background: #e5e7eb;
}

.progress span.active {
  background: var(--primary);
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: none;
  place-items: center;
  padding: 20px;
}

.modal.show {
  display: grid;
}

.modal .card {
  width: min(100%, 480px);
}

.tab-strip {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.tab-btn {
  width: auto;
  min-width: 120px;
  background: #e6fffa;
  color: #0f766e;
  border: 1px solid #99f6e4;
}

.tab-btn.active {
  background: var(--primary);
  color: #ffffff;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.service-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.service-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.service-head h3 {
  margin: 0;
  font-size: 16px;
}

.service-price {
  margin-top: 12px;
  font-weight: 700;
  color: #0f766e;
}

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

.check-item {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 14px;
  margin: 0;
}

.check-item input {
  width: auto;
}

.stack {
  display: grid;
  gap: 18px;
}

.topbar .actions {
  margin: 0;
  align-items: center;
}

.topbar .actions button,
.topbar .actions .btn-link {
  width: auto;
}

.btn-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  color: var(--text);
  background: #fff;
  text-decoration: none;
  font-weight: 700;
}

.btn-link:hover {
  background: #f8fbff;
}

.space-top {
  margin-top: 18px;
}

.compact-table-wrap {
  overflow: auto;
  margin-top: 10px;
}

.compact-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.compact-table th,
.compact-table td {
  text-align: left;
  padding: 10px;
  border: 1px solid var(--border);
}

.compact-table thead tr {
  background: #f3f7fc;
}

.muted-note {
  margin: 0;
}

@media (max-width: 768px) {
  .form-grid,
  .profile-grid,
  .user-row,
  .check-grid {
    grid-template-columns: 1fr;
  }

  .actions {
    flex-direction: column;
  }

  .actions button {
    width: 100%;
  }

  .topbar .actions .btn-link,
  .topbar .actions button {
    width: 100%;
  }
}
