body.profile-page {
  min-height: 100vh;
  margin: 0;
  background: #f4f9fc;
  color: var(--slate);
  font-family: Lato, Arial, sans-serif;
}

body.profile-page .profile-header {
  background: white;
  box-shadow: 0 2px 12px rgba(0, 59, 113, 0.1);
}

body.profile-page .profile-header-inner {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.profile-header-inner > a img {
  width: 180px;
  height: auto;
}

.profile-header-inner nav {
  display: flex;
  align-items: center;
  gap: 12px;
}

.profile-header-inner nav button,
.profile-home-link {
  border: 1px solid rgba(0, 59, 113, 0.16);
  border-radius: 999px;
  background: white;
  color: var(--navy);
  padding: 10px 16px;
  text-decoration: none;
  font-weight: 700;
}

body.profile-page .profile-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  padding-block: clamp(28px, 4vw, 52px);
}

.profile-sidebar,
.profile-card {
  border: 1px solid #dbe9f1;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 14px 38px rgba(0, 59, 113, 0.08);
}

.profile-sidebar {
  align-self: start;
  text-align: center;
  padding: 28px 18px;
}

.profile-avatar {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: var(--navy);
  color: white;
  font: 800 2rem/1 "Plus Jakarta Sans", Arial, sans-serif;
  box-shadow: 0 10px 24px rgba(0, 59, 113, 0.18);
}

.profile-sidebar h1 {
  margin: 0 0 5px;
  color: var(--navy);
  font: 800 1.35rem/1.2 "Plus Jakarta Sans", Arial, sans-serif;
}

.profile-sidebar p {
  margin: 0;
  color: #587080;
  overflow-wrap: anywhere;
}

.profile-content {
  display: grid;
  gap: 24px;
}

.profile-card {
  padding: clamp(20px, 3vw, 32px);
}

.profile-section-heading p {
  margin: 0 0 4px;
  color: var(--cyan);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
}

.profile-section-heading h2 {
  margin: 0 0 20px;
  color: var(--navy);
  font: 800 1.55rem/1.2 "Plus Jakarta Sans", Arial, sans-serif;
}

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

.profile-fields label {
  display: grid;
  gap: 7px;
  color: var(--navy);
  font-weight: 700;
}

.profile-field-wide {
  grid-column: 1 / -1;
}

.profile-fields input {
  border: 1px solid #bfd3df;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--slate);
  padding: 11px 13px;
  font-weight: 400;
}

.profile-fields input:focus {
  border-color: var(--cyan);
  outline: 3px solid rgba(0, 159, 217, 0.16);
}

.profile-save {
  border: 0;
  border-radius: 999px;
  background: var(--cyan);
  color: white;
  padding: 11px 18px;
  font-weight: 700;
}

.profile-save:disabled {
  opacity: 0.65;
}

.profile-message {
  min-height: 24px;
  margin: 12px 0;
  color: var(--navy);
}

.appointment-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.appointment-tabs button {
  border: 1px solid #bfd3df;
  border-radius: 999px;
  background: white;
  color: var(--navy);
  padding: 8px 14px;
  font-weight: 700;
}

.appointment-tabs button[aria-selected="true"] {
  border-color: var(--cyan);
  background: var(--cyan);
  color: white;
}

.appointment-list {
  display: grid;
  gap: 12px;
}

.appointment-item {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  border: 1px solid rgba(0, 59, 113, 0.08);
  border-radius: 14px;
  background: #f4f9fc;
  padding: 16px;
}

.appointment-date {
  color: var(--navy);
  font-weight: 800;
}

.appointment-details strong,
.appointment-details span {
  display: block;
}

.appointment-status {
  border-radius: 999px;
  background: #e3f2fb;
  color: var(--navy);
  padding: 6px 10px;
  font-size: 0.82rem;
  font-weight: 700;
}

.appointment-side {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.reschedule-toggle,
.reschedule-confirm {
  border: 0;
  border-radius: 8px;
  background: var(--navy);
  color: white;
  cursor: pointer;
  font-weight: 700;
  padding: 8px 10px;
}

.reschedule-toggle:disabled,
.reschedule-confirm:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.reschedule-editor {
  display: grid;
  gap: 8px;
  min-width: 220px;
  margin-top: 4px;
  border-top: 1px solid rgba(0, 59, 113, 0.12);
  padding-top: 10px;
}

.reschedule-editor[hidden] {
  display: none;
}

.reschedule-editor label {
  display: grid;
  gap: 4px;
  color: var(--navy);
  font-size: 0.82rem;
  font-weight: 700;
}

.reschedule-editor select {
  min-height: 38px;
  border: 1px solid rgba(0, 59, 113, 0.18);
  border-radius: 8px;
  background: white;
  padding: 6px 8px;
}

.reschedule-message {
  margin: 0;
  color: #587080;
  font-size: 0.78rem;
}

.appointment-empty {
  margin: 0;
  border-radius: 12px;
  background: #f4f9fc;
  color: #587080;
  padding: 18px;
  text-align: center;
}

@media (max-width: 820px) {
  .profile-layout {
    grid-template-columns: 1fr;
  }

  .profile-fields {
    grid-template-columns: 1fr;
  }

  .profile-field-wide {
    grid-column: auto;
  }

  .appointment-item {
    grid-template-columns: 1fr;
  }

  .appointment-side {
    justify-items: start;
  }
}
