*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --tzd-portal-bg: #ffffff;
  --tzd-portal-surface: #ffffff;
  --tzd-portal-border: #e4e7ec;
  --tzd-portal-primary: #1f232b;
  --tzd-portal-accent: #bfc3cb;
  --tzd-portal-text: #0f172a;
  --tzd-portal-muted: #6b7280;
  --tzd-portal-radius: 22px;
  --tzd-portal-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
  --tzd-portal-highlight: rgba(15, 23, 42, 0.06);
}

@keyframes tzdFadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

body.tzd-portal {
  margin: 0;
  font-family: "Inter", "Segoe UI", sans-serif;
  background: var(--tzd-portal-bg);
  color: var(--tzd-portal-text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 24px clamp(12px, 5vw, 48px);
  position: relative;
  z-index: 1;
  overflow-x: hidden;
}

.tzd-portal-header {
  width: 100%;
  max-width: 1080px;
  display: flex;
  justify-content: center;
  margin-bottom: 32px;
}

.tzd-portal-logo {
  display: flex;
  align-items: center;
  gap: 16px;
  font-weight: 600;
  font-size: 20px;
  color: #0f172a;
}

.tzd-portal-nav {
  width: 100%;
  max-width: 1600px;
  background: #ffffff;
  border-radius: var(--tzd-portal-radius);
  padding: 6px;
  border: 1px solid var(--tzd-portal-border);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
  position: sticky;
  top: 12px;
  z-index: 5;
}

.tzd-portal-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  justify-content: center;
}

.tzd-portal-nav-item a {
  display: block;
  padding: 10px 18px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 500;
  color: #1f2937;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.tzd-portal-nav-item.is-active a,
.tzd-portal-nav-item a:hover,
.tzd-portal-nav-item a:focus {
  background: rgba(15, 23, 42, 0.08);
  color: var(--tzd-portal-primary);
}

@media (max-width: 900px) {
  .tzd-portal-nav ul {
    flex-direction: column;
  }
  .tzd-portal-nav {
    position: static;
  }
  .tzd-portal-page {
    padding: 0 4px;
  }
}

.tzd-portal-logo img {
  height: 56px;
  width: auto;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(15, 31, 53, 0.12);
}

.tzd-portal-shell {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 18px 72px;
  gap: 32px;
  position: relative;
  z-index: 1;
}

.tzd-portal-auth-card {
  max-width: 420px;
  width: 100%;
  margin-inline: auto;
  padding: 36px 32px;
  border-radius: 20px;
  box-shadow: 0 20px 50px rgba(15, 31, 53, 0.15);
}

.tzd-portal-page {
  width: 100%;
  max-width: 1080px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  animation: tzdFadeSlideUp 340ms ease-out;
  min-width: 0;
}

.tzd-portal-shell.tzd-portal-route-dashboard > .tzd-portal-dashboard,
.tzd-portal-shell.tzd-portal-route-patients > .tzd-portal-page {
  width: 100%;
  max-width: none;
  align-self: stretch;
}

.tzd-portal-page-head {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
}

.tzd-portal-dashboard-status > * {
  width: 100%;
}

.tzd-portal-dashboard-status .tzd-portal-slab {
  height: 100%;
  min-width: 0;
}

.tzd-portal-page-title h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-page-title p {
  margin: 0;
  font-size: 15px;
  color: #475569;
}

.tzd-portal-page-title {
  flex: 1 1 260px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tzd-portal-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.tzd-portal-page-body {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.tzd-portal-two-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.tzd-portal-split {
  display: flex;
  flex-direction: row;
  gap: 24px;
}

.tzd-portal-split .tzd-portal-card {
  height: 100%;
}

.tzd-portal-treatment-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  align-items: start;
}

.tzd-portal-treatment-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tzd-treatment-column-primary .tzd-portal-form-grid,
.tzd-treatment-column-primary .tzd-portal-dual,
.tzd-treatment-column-primary > .tzd-portal-field {
  width: 100%;
}

.tzd-portal-treatment-stack {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.tzd-treatment-card-primary,
.tzd-treatment-card-services,
.tzd-additional-card,
.tzd-treatment-card-financial {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tzd-treatment-financial-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px 24px;
}

@media (min-width: 600px) {
  .tzd-treatment-financial-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.tzd-portal-form-grid.tzd-portal-selected-patient {
  gap: 18px 24px;
}

.tzd-treatment-card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px 24px;
}

@media (min-width: 768px) {
  .tzd-treatment-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.tzd-treatment-share {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px 24px;
}

@media (min-width: 600px) {
  .tzd-treatment-share {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.tzd-treatment-services {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tzd-treatment-service-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  align-items: flex-end;
}

.tzd-treatment-service-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tzd-treatment-service-select-label {
  display: block;
}

span.tzd-treatment-service-inline-label{
  font-weight: bold;
}

.tzd-treatment-service-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
  align-items: center;
}

.tzd-treatment-service-inline-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tzd-treatment-service-inline-label {
  font-size: 0.85rem;
  color: var(--tzd-text-muted);
}

.tzd-treatment-service-qty-label {
  width: auto;
}

.tzd-treatment-service-remove {
  display: flex;
  align-items: center;
  justify-content: center;
}

.tzd-treatment-service-remove .button {
  margin: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  color: #be123c;
}

.wp-core-ui .tzd-treatment-service-remove .button {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  color: #be123c;
}

.tzd-treatment-service-remove .button:hover,
.tzd-treatment-service-remove .button:focus,
.wp-core-ui .tzd-treatment-service-remove .button:hover,
.wp-core-ui .tzd-treatment-service-remove .button:focus {
  background: transparent;
  border: none;
  box-shadow: none;
  color: #991b1b;
}

@media (min-width: 768px) {
  .tzd-treatment-service-inline {
    flex-wrap: nowrap;
  }

  .tzd-treatment-service-inline-item {
    flex-direction: row;
    gap: 8px;
    align-items: center;
  }

  .tzd-treatment-service-qty-label {
    min-width: 110px;
  }

  .tzd-treatment-service-price-item,
  .tzd-treatment-service-total-item {
    min-width: 120px;
  }
}

.tzd-treatment-service-actions-row {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  justify-self: flex-end;
}

.tzd-treatment-service-actions-row .button {
  margin-top: 4px;
}

.tzd-treatment-service-row + .tzd-treatment-service-row {
  margin-top: 12px;
}

.tzd-portal-slab + .tzd-portal-actions {
  margin-top: -8px;
}

.tzd-portal-dashboard {
  width: 100%;
  background: transparent;
  border-radius: 24px;
  padding: 0;
  box-shadow: none;
  border: none;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.tzd-portal-page-title h1 {
  margin: 0;
  font-size: 26px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-page-sub,
.tzd-portal-section-head p {
  margin: 0;
  color: #64748b;
  font-size: 14px;
}

.tzd-portal-dashboard-head {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-end;
}

.tzd-portal-dashboard-status {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
  align-items: stretch;
}

.tzd-portal-task-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}

.tzd-portal-task-card {
  border: 1px solid var(--tzd-portal-border);
  border-radius: var(--tzd-portal-radius);
  padding: 18px;
  background: var(--tzd-portal-surface);
  box-shadow: var(--tzd-portal-shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
}

.tzd-portal-task-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
  color: #0f172a;
}

.tzd-portal-task-card p {
  margin: 0;
  color: var(--tzd-portal-muted);
  font-size: 14px;
}

.tzd-portal-task-meta {
  display: inline-block;
  margin-top: 6px;
  font-size: 12px;
  color: var(--tzd-portal-primary);
  font-weight: 600;
}

.tzd-portal-task-actions {
  display: flex;
  justify-content: flex-end;
}

.tzd-payroll-hero,
.tzd-portal-chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  width: 100%;
}

.tzd-payroll-highlight,
.tzd-portal-chart-card {
  border: 1px solid var(--tzd-portal-border);
  border-radius: var(--tzd-portal-radius);
  background: var(--tzd-portal-surface);
  padding: 16px;
  box-shadow: var(--tzd-portal-shadow);
  text-align: center;
  min-width: 0;
}

.tzd-portal-chart-card.full {
  grid-column: 0 / 0;
}

.tzd-portal-chart-card canvas {
  width: 100% !important;
  height: 260px;
  max-width: 100%;
}

@media (max-width: 900px) {
  body.tzd-portal {
    padding: 16px clamp(10px, 4vw, 24px);
  }
  .tzd-portal-nav {
    position: static;
  }
  .tzd-portal-dashboard-status,
  .tzd-payroll-hero,
  .tzd-portal-chart-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .tzd-portal-chart-card canvas {
    height: 220px;
  }
}

.tzd-portal-dashboard-clock {
  background: #ffffff;
  border-radius: 22px;
  padding: 32px;
  border: 1px solid var(--tzd-portal-border);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.tzd-portal-clock-label {
  font-size: 32px;
  font-weight: 700;
  color: #0f172a;
}

.tzd-portal-clock-meta {
  font-size: 16px;
  color: #1f2937;
}

.tzd-portal-clock-summary {
  margin: 0;
  font-size: 15px;
  color: var(--tzd-portal-primary);
}

.tzd-portal-dashboard-metrics {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tzd-portal-dashboard-metrics h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 18px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.tzd-portal-metric {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.03), rgba(15, 23, 42, 0.015));
  border-radius: 18px;
  padding: 20px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 15px 30px rgba(15, 23, 42, 0.08);
}

.tzd-portal-metric-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--tzd-portal-primary);
  font-weight: 600;
}

.tzd-portal-metric-value {
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
}

.tzd-portal-metric-meta {
  font-size: 13px;
  color: #475569;
}

.tzd-portal-dashboard-section,
.tzd-portal-slab,
.tzd-portal-approvals-panel {
  background: var(--tzd-portal-surface);
  border: 1px solid var(--tzd-portal-border);
  border-radius: var(--tzd-portal-radius);
  padding: 32px 36px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  box-shadow: var(--tzd-portal-shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  position: relative;
  overflow: hidden;
  min-width: 0;
}

.tzd-portal-slab::after,
.tzd-portal-card::after,
.tzd-portal-dashboard-section::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.35;
  background: radial-gradient(circle at 20% 20%, rgba(15, 23, 42, 0.08), transparent 60%);
  pointer-events: none;
}

.tzd-portal-shell-card,
.tzd-portal-page,
.tzd-portal-slab,
.tzd-portal-card,
.tzd-portal-dashboard,
.tzd-portal-dashboard-section,
.tzd-portal-approvals-panel {
  width: 100%;
  margin-inline: 0;
  min-width: 0;
}

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

.tzd-portal-link:hover,
.tzd-portal-link:focus {
  text-decoration: underline;
}

.tzd-portal-card,
.tzd-portal-slab,
.tzd-portal-dashboard,
.tzd-portal-dashboard-section {
  background: var(--tzd-portal-surface);
  /* box-shadow: var(--tzd-portal-shadow); */
}

.tzd-portal-card::after,
.tzd-portal-slab::after,
.tzd-portal-dashboard-section::after {
  display: none;
}

.tzd-portal-page-body > * {
  width: 100%;
}

.tzd-portal-slab {
  margin-block: 0;
}

.tzd-portal-approvals-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.tzd-portal-approvals-panel {
  gap: 18px;
}

.tzd-portal-approvals-panel h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-approvals-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tzd-portal-approvals-item {
  background: #f8fafc;
  border-radius: 16px;
  padding: 18px 20px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tzd-portal-approvals-item header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.tzd-portal-approvals-item strong {
  font-size: 15px;
  color: #0f172a;
}

.tzd-portal-approvals-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  font-size: 13px;
  color: #475569;
}

.tzd-portal-approvals-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tzd-portal-approvals-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tzd-portal-approvals-form textarea {
  width: 100%;
  border-radius: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  font-family: inherit;
  font-size: 14px;
}

.tzd-portal-approvals-form textarea:focus {
  border-color: var(--tzd-portal-primary);
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.12);
  outline: none;
}

.tzd-portal-holiday-panel {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.04), rgba(15, 23, 42, 0.02));
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.tzd-portal-actions {
  display: flex;
  justify-content: flex-end;
  padding: 0 4px 8px;
}

.tzd-portal-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tzd-admin-patient-form {
  gap: 28px;
}

.tzd-portal-card--intro {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.05), rgba(15, 23, 42, 0.02));
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
}

.tzd-portal-card-lead {
  margin: 12px 0 0;
  max-width: 720px;
  color: #0f172a;
  font-size: 15px;
  line-height: 1.5;
}

.tzd-portal-thirteenth-card{
  border:1px dashed rgba(15,23,42,0.2);
  background:transparent;
}

.tzd-portal-table--compact th,
.tzd-portal-table--compact td{
  font-size:13px;
}

.button-large {
  min-width: 180px;
  font-size: 16px;
  padding: 0.85em 2.2em;
}

.tzd-portal-form label {
  display: flex;
  flex-direction: column;
  font-size: 14px;
  font-weight: 500;
  gap: 6px;
}

.tzd-portal-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  padding: 16px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.tzd-portal-filter-inline {
  align-items: flex-end;
}

.tzd-portal-filter label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  margin: 0;
  min-width: 200px;
  color: rgba(15, 23, 42, 0.85);
}

.tzd-portal-filter select,
.tzd-portal-filter input {
  width: 100%;
}

.tzd-portal-filter select {
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 12px;
  padding: 10px 38px 10px 12px;
  background: #fff;
  font-size: 14px;
  font-family: inherit;
  color: #0f172a;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(15, 23, 42, 0.65) 50%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.65) 50%, transparent 50%),
    linear-gradient(to right, rgba(15, 23, 42, 0.12), rgba(15, 23, 42, 0.12));
  background-position:
    calc(100% - 18px) calc(50% - 2px),
    calc(100% - 12px) calc(50% - 2px),
    calc(100% - 2.5rem) 50%;
  background-size: 6px 6px, 6px 6px, 1px 60%;
  background-repeat: no-repeat;
  transition: border 0.2s ease, box-shadow 0.2s ease;
  min-height: 42px;
}

.tzd-portal-filter select:focus {
  outline: none;
  border-color: var(--tzd-portal-primary);
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.12);
}

.tzd-portal-filter select::-ms-expand {
  display: none;
}

.tzd-portal-filter input[type="search"],
.tzd-portal-filter input[type="date"] {
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  min-height: 42px;
  font-size: 14px;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.tzd-portal-filter input[type="search"]:focus,
.tzd-portal-filter input[type="date"]:focus {
  outline: none;
  border-color: var(--tzd-portal-primary);
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.12);
}

.tzd-portal-field input:not([type="radio"]):not([type="checkbox"]),
.tzd-portal-field select,
.tzd-portal-field textarea {
  border: 1px solid rgba(15, 23, 42, 0.18);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
  transition: border 0.2s ease, box-shadow 0.2s ease;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  min-width: 0;
}

.tzd-portal-field input:not([type="radio"]):not([type="checkbox"]):focus,
.tzd-portal-field select:focus,
.tzd-portal-field textarea:focus {
  outline: none;
  border-color: var(--tzd-portal-primary);
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.15);
}

.tzd-portal-field {
  margin-bottom: 12px;
}

.tzd-portal-form-grid input:not([type="radio"]):not([type="checkbox"]),
.tzd-portal-form-grid select,
.tzd-portal-form-grid textarea {
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  padding: 10px 14px;
  font-size: 14px;
  font-family: inherit;
  background: rgba(255, 255, 255, 0.9);
  transition: border 0.2s ease, box-shadow 0.2s ease;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  min-width: 0;
}

.tzd-portal-page select {
  background-image: linear-gradient(45deg, transparent 50%, rgba(15, 23, 42, 0.65) 50%), linear-gradient(135deg, rgba(15, 23, 42, 0.65) 50%, transparent 50%);
  background-position: calc(100% - 20px) calc(50% + 2px), calc(100% - 14px) calc(50% + 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

.tzd-portal-form-grid input:focus,
.tzd-portal-form-grid select:focus,
.tzd-portal-form-grid textarea:focus {
  border-color: var(--tzd-portal-primary);
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.12);
  outline: none;
}

.tzd-portal-form-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tzd-portal-form-grid--two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 24px;
}

.tzd-portal-form-grid--two-col .tzd-portal-field--full {
  grid-column: 1 / -1;
}

.tzd-portal-form-grid--two-col .tzd-portal-field--half {
  grid-column: span 1;
}

.tzd-portal-fieldset {
  border: none;
  padding: 0;
  margin: 0;
}

.tzd-portal-fieldset legend {
  font-weight: 600;
  margin-bottom: 8px;
}

/* reset portal radios/checkboxes to default layout */
.tzd-portal-fieldset-options { display: block; gap: 0; }
.tzd-portal-fieldset-options label,
.tzd-portal-field-inline { display: inline; padding: 0; margin: 0 8px 0 0; background: none; border: none; }
.tzd-portal-field-inline input,
.tzd-portal-field-inline select,
.tzd-portal-field-inline textarea { width: auto; min-width: 0; flex: none; }

/* keep radio/checkbox look plain */
.tzd-portal-fieldset-options input[type="radio"],
.tzd-portal-fieldset-options input[type="checkbox"],
.tzd-portal-form input[type="radio"],
.tzd-portal-form input[type="checkbox"] {
  accent-color: auto;
  box-shadow: none;
}

/* soften spacing inside treatment stack */
.tzd-portal-treatment-stack > .tzd-portal-card {
  margin-bottom: 16px;
}
.tzd-portal-treatment-stack > .tzd-portal-card:last-child {
  margin-bottom: 0;
}

@media (max-width: 720px) {
  .tzd-portal-field-inline {
    flex-direction: column;
    align-items: flex-start;
  }

  .tzd-portal-field-inline input,
  .tzd-portal-field-inline select,
  .tzd-portal-field-inline textarea {
    width: 100%;
    min-width: 0;
    flex: none;
  }
  .tzd-portal-form-grid--two-col {
    grid-template-columns: 1fr;
  }

  .tzd-portal-form-grid--two-col .tzd-portal-field--half,
  .tzd-portal-form-grid--two-col .tzd-portal-field--full {
    grid-column: 1 / -1;
  }

  .tzd-portal-slab,
  .tzd-portal-card,
  .tzd-portal-dashboard-section {
    padding: 24px 20px;
  }

  .tzd-portal-pill-grid,
  .tzd-portal-meta-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }
}

.tzd-portal-actions--block {
  width: 100%;
  padding: 0;
}

.tzd-button-block {
  display: inline-flex;
  width: 100%;
  justify-content: center;
}

.tzd-booking-portal {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 16px 24px;
}

.tzd-portal-card.tzd-booking-card {
  width: 100%;
}

.tzd-portal-form input,
.tzd-portal-form select,
.tzd-portal-form textarea {
  border: 1px solid var(--tzd-portal-border);
  border-radius: 16px;
  padding: 7px 14px;
  font-size: 15px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  background-color: #fff;
  color: var(--tzd-portal-text);
}

body.tzd-portal .tzd-portal-form input[type="date"],
body.tzd-portal .tzd-portal-form input[type="time"],
body.tzd-portal .tzd-portal-form input[type="datetime-local"] {
  background-color: #fff !important;
  color: #0f172a;
}

.tzd-portal-dentist-select{
  height: 100px;
}

.tzd-portal-form input:focus,
.tzd-portal-form select:focus,
.tzd-portal-form textarea:focus {
  border-color: var(--tzd-portal-primary);
  box-shadow: 0 0 0 4px rgba(15, 23, 42, 0.1);
  outline: none;
}

body.tzd-portal .button,
body.tzd-portal .button-primary,
body.tzd-portal .button-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  border-radius: 999px;
  padding: 0.7em 1.6em;
  border: none;
  text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  min-height: 44px;
}

.tzd-portal-auth-card h1 {
  margin-top: 0;
  margin-bottom: 16px;
  font-size: 26px;
  font-weight: 600;
  text-align: center;
}

.tzd-portal-auth-card .tzd-portal-form {
  gap: 16px;
}

.tzd-portal-auth-card .tzd-portal-muted {
  margin-top: 18px;
  text-align: center;
}

body.tzd-portal .button,
body.tzd-portal .button-secondary {
  background: rgba(255, 255, 255, 0.75);
  color: var(--tzd-portal-text);
  border: 1px solid var(--tzd-portal-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

body.tzd-portal .button:hover,
body.tzd-portal .button:focus,
body.tzd-portal .button-secondary:hover,
body.tzd-portal .button-secondary:focus {
  background: #f5f5f5;
  color: var(--tzd-portal-text);
  border-color: var(--tzd-portal-primary);
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
}

body.tzd-portal .button-primary {
  background: linear-gradient(135deg, var(--tzd-portal-primary), #393d45);
  color: #fff;
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.25);
}

body.tzd-portal .button-primary:hover,
body.tzd-portal .button-primary:focus {
  transform: translateY(-1px);
  background: linear-gradient(135deg, #2d3138, #4a4f57);
  box-shadow: 0 24px 42px rgba(15, 23, 42, 0.28);
}

body.tzd-portal .button:active,
body.tzd-portal .button-primary:active,
body.tzd-portal .button-secondary:active {
  transform: translateY(0);
  box-shadow: none;
}

.tzd-portal-error,
.tzd-portal-notice,
.tzd-portal-success {
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 14px;
  font-size: 14px;
  line-height: 1.4;
}

.tzd-portal-error {
  background: rgba(220, 53, 69, 0.12);
  border: 1px solid rgba(220, 53, 69, 0.4);
  color: #a61b29;
}

.tzd-portal-notice {
  background: rgba(15, 23, 42, 0.06);
  border: 1px solid rgba(15, 23, 42, 0.2);
  color: var(--tzd-portal-primary);
}

.tzd-portal-success {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.4);
  color: #15803d;
}

.tzd-portal-muted {
  margin-top: 18px;
  font-size: 13px;
  color: #64748b;
  text-align: center;
}

.tzd-portal-footer {
  margin-top: auto;
  padding: 18px;
  text-align: center;
  font-size: 13px;
  color: #64748b;
}

.tzd-portal-holiday-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tzd-portal-holiday-list li {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.9);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.tzd-portal-holiday-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-weight: 600;
  color: var(--tzd-portal-primary);
}

.tzd-portal-holiday-name {
  font-size: 14px;
  color: #0f172a;
  font-weight: 500;
}

.tzd-portal-holiday-summary {
  font-size: 14px;
  color: #1f2937;
}

.tzd-portal-holiday-muted {
  color: #4b5563;
}

.tzd-portal-holiday-date {
  font-size: 15px;
}

.tzd-portal-holiday-note {
  margin: 0;
  font-size: 12px;
  color: #475569;
}

.tzd-portal-tile h2 {
  margin: 0;
  font-size: 18px;
  color: #1f2937;
}

.tzd-portal-tile p {
  margin: 0;
  font-size: 14px;
  color: #475569;
}

.tzd-portal-clock {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 14px;
  padding: 20px 24px;
  background: #f1f5f9;
  margin: 24px 0 6px;
}

.tzd-portal-section-block {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
}

.tzd-portal-section-block:first-of-type {
  border-top: none;
  padding-top: 0;
}

.tzd-portal-section-block h2 {
  margin: 0;
  font-size: 18px;
  color: #0f172a;
}

.tzd-portal-clock-status {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tzd-portal-clock-status span {
  font-size: 18px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-clock-status small {
  font-size: 13px;
  color: #475569;
}

.tzd-portal-clock-form {
  display: flex;
  align-items: center;
}

.tzd-portal-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.tzd-portal-list li {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: #1f2937;
}

.tzd-portal-empty {
  margin: 0;
  padding: 18px;
  border-radius: 16px;
  background: rgba(148, 163, 184, 0.12);
  color: #475569;
  font-size: 14px;
  text-align: center;
}

.tzd-portal-list li small {
  color: #64748b;
}

.tzd-portal-list.tzd-portal-attendance {
  gap: 8px;
}

.tzd-portal-attendance-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  color: #1f2937;
}

.tzd-portal-att-date {
  font-weight: 600;
  font-size: 14px;
  color: #0f172a;
  min-width: 72px;
}

.tzd-portal-att-hours {
  font-size: 13px;
  color: #475569;
}

.tzd-portal-att-ot {
  font-size: 12px;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.08);
  color: var(--tzd-portal-primary);
  border: 1px solid rgba(15, 23, 42, 0.2);
}

.tzd-portal-att-ot.is-approved {
  background: rgba(16, 185, 129, 0.12);
  color: #047857;
  border-color: rgba(16, 185, 129, 0.35);
}

.tzd-portal-att-ot.is-declined {
  background: rgba(248, 113, 113, 0.15);
  color: #b91c1c;
  border-color: rgba(248, 113, 113, 0.35);
}

.tzd-portal-att-ot.is-pending {
  background: rgba(251, 191, 36, 0.18);
  color: #92400e;
  border-color: rgba(251, 191, 36, 0.4);
}

.tzd-portal-overtime {
  background: #ffffff;
}

.tzd-portal-ot {
  gap: 10px;
}

.tzd-portal-ot-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border-radius: 12px;
  background: rgba(248, 250, 252, 0.9);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
  padding: 12px 14px;
}

.tzd-portal-ot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tzd-portal-ot-date {
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-ot-chip {
  font-size: 12px;
  font-weight: 600;
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid rgba(107, 114, 128, 0.35);
  background: rgba(107, 114, 128, 0.12);
  color: #334155;
  text-transform: capitalize;
}

.tzd-portal-ot-chip.is-approved {
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.35);
  color: #047857;
}

.tzd-portal-ot-chip.is-declined {
  background: rgba(248, 113, 113, 0.15);
  border-color: rgba(248, 113, 113, 0.35);
  color: #b91c1c;
}

.tzd-portal-ot-chip.is-pending {
  background: rgba(251, 191, 36, 0.18);
  border-color: rgba(251, 191, 36, 0.4);
  color: #92400e;
}

.tzd-portal-ot-meta {
  font-size: 13px;
  color: #475569;
}

.tzd-portal-ot-notes {
  font-size: 12px;
  color: #64748b;
  border-left: 2px solid rgba(148, 163, 184, 0.4);
  padding-left: 10px;
}

.tzd-portal-compact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.tzd-portal-compact-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 15px;
  color: #1f2937;
}

.tzd-portal-table-wrap {
  overflow-x: auto;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.tzd-portal-table {
  width: 100%;
  border-collapse: collapse;
  background: rgba(255, 255, 255, 0.9);
  min-width: 640px;
}

.tzd-portal-table thead {
  background: linear-gradient(135deg, #0f1115, #2e323a);
  color: #fff;
}

.tzd-portal-table th,
.tzd-portal-table td {
  padding: 14px 16px;
  font-size: 14px;
  text-align: left;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.tzd-portal-table tbody tr:nth-child(odd) {
  background: rgba(248, 250, 252, 0.8);
}

.tzd-portal-table tbody tr:hover {
  background: rgba(226, 232, 240, 0.6);
}

.tzd-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2em 0.75em;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
}

.tzd-pill-success {
  background: rgba(34, 197, 94, 0.15);
  color: #15803d;
}

.tzd-pill-danger {
  background: rgba(220, 53, 69, 0.12);
  color: #a61b29;
}

.tzd-pill-warning {
  background: rgba(251, 191, 36, 0.2);
  color: #b45309;
}

.tzd-portal-muted p,
.tzd-portal-muted span {
  color: inherit;
}

.tzd-portal-card footer,
.tzd-portal-card .tzd-portal-muted {
  font-size: 13px;
  color: #64748b;
}

.tzd-portal-kanban {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  overflow-x: auto;
  padding-bottom: 8px;
}

.tzd-portal-kanban .tzd-col {
  min-width: 260px;
  flex: 0 0 260px;
  background: #ffffff;
  border: 1px solid rgba(203, 213, 225, 0.8);
  border-radius: 18px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: 0 16px 36px -24px rgba(15, 23, 42, 0.35);
  animation: tzdFadeSlideUp 360ms ease-out;
}

.tzd-portal-kanban .tzd-col-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-portal-kanban .tzd-col-title span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.tzd-portal-kanban .tzd-col-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 90px;
}

.tzd-portal-kanban .tzd-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.6);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 16px 30px -20px rgba(15, 23, 42, 0.18);
  transition: transform 160ms ease, box-shadow 160ms ease;
  cursor: grab;
}

.tzd-portal-kanban .tzd-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 34px -18px rgba(15, 23, 42, 0.25);
}
.tzd-portal-kanban .tzd-card.tzd-card-selected {
  border: 2px solid #007cba;
  box-shadow: 0 0 0 2px rgba(0, 124, 186, 0.18);
}

.tzd-portal-kanban .tzd-card:active {
  cursor: grabbing;
}

.tzd-portal-kanban .tzd-card.dragging {
  opacity: 0.65;
  transform: rotate(1deg);
}

.tzd-portal-kanban .tzd-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.tzd-portal-kanban .tzd-card-name {
  font-weight: 600;
  color: #0f172a;
  font-size: 15px;
}

.tzd-portal-kanban .tzd-card-meta {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: #475569;
}

.tzd-portal-kanban .tzd-card-meta li {
  background: rgba(148, 163, 184, 0.16);
  padding: 6px 10px;
  border-radius: 12px;
  line-height: 1.3;
}

.tzd-portal-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  z-index: 9999;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.tzd-portal-modal.tzd-modal-hidden {
  opacity: 0;
  visibility: hidden;
}

.tzd-portal-modal:not(.tzd-modal-hidden) {
  opacity: 1;
  visibility: visible;
}

.tzd-portal-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
}

.tzd-portal-modal-panel {
  position: relative;
  background: #ffffff;
  border-radius: 20px;
  width: min(760px, 92%);
  max-height: calc(100vh - 80px);
  overflow-y: auto;
  box-shadow: 0 30px 80px -30px rgba(15, 23, 42, 0.45);
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tzd-portal-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.tzd-portal-modal-headings {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tzd-modal-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(15, 23, 42, 0.08);
  color: var(--tzd-portal-primary);
  font-weight: 600;
}

.tzd-modal-title {
  margin: 0;
  font-size: 26px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-modal-subtitle {
  margin: 0;
  font-size: 14px;
  color: #475569;
}

.tzd-modal-close {
  border: none;
  background: transparent;
  font-size: 26px;
  line-height: 1;
  color: #475569;
  cursor: pointer;
}

.tzd-modal-close:hover {
  color: #0f172a;
}

.tzd-modal-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
}

.tzd-modal-details {
  display: grid;
  gap: 12px;
  margin: 0;
}

.tzd-modal-details dt {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
  margin-bottom: 2px;
}

.tzd-modal-details dd {
  margin: 0;
  font-size: 15px;
  color: #0f172a;
}

.tzd-modal-section {
  background: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 16px;
  padding: 18px;
  display: grid;
  gap: 6px;
}

.tzd-modal-section h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
}

.tzd-modal-section p {
  margin: 0;
  font-size: 14px;
  color: #475569;
  white-space: pre-wrap;
}

.tzd-modal-footer {
  display: flex;
  justify-content: flex-end;
}

.tzd-modal-profile-link[hidden] {
  display: none;
}

@media (max-width: 720px) {
  .tzd-portal-modal {
    padding: 24px;
  }

  .tzd-portal-modal-panel {
    padding: 22px;
  }

  .tzd-modal-columns {
    grid-template-columns: 1fr;
  }
}

.tzd-portal-kanban .tzd-card-actions {
  display: flex;
  justify-content: flex-end;
}

.tzd-portal-kanban .tzd-card-link {
  appearance: none;
  background: none;
  border: none;
  color: var(--tzd-portal-primary);
  font-weight: 600;
  font-size: 13px;
  padding: 0;
  cursor: pointer;
  transition: color 160ms ease;
}

.tzd-portal-kanban .tzd-card-link:hover,
.tzd-portal-kanban .tzd-card-link:focus {
  color: #3a3f47;
}

.tzd-portal-kanban .tzd-card-empty {
  padding: 18px;
  background: rgba(226, 232, 240, 0.6);
  border-radius: 12px;
  font-size: 14px;
  color: #475569;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  body.tzd-portal .button,
  body.tzd-portal .button-primary,
  body.tzd-portal .button-secondary {
    transition: none;
  }
}

@media (max-width: 768px) {
  .tzd-portal-clock {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .tzd-portal-nav {
    padding: 8px;
  }

  .tzd-portal-nav ul {
    gap: 6px;
  }

  .tzd-portal-nav-item a {
    flex: 1;
    text-align: center;
  }

  .tzd-portal-clock-form {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .tzd-portal-card {
    padding: 28px 22px;
    border-radius: 14px;
  }

  .tzd-portal-card.tzd-portal-wide,
  .tzd-portal-card.tzd-portal-dashboard {
    padding: 24px 20px;
  }

  .tzd-portal-nav-item a {
    padding: 10px 14px;
  }

  .tzd-portal-shell {
    padding-top: 30px;
  }
  .tzd-portal-logo img {
    height: 48px;
  }
}


.tzd-thirteenth-hero{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(200px,1fr));
  gap:16px;
  margin-bottom:16px;
}
.tzd-thirteenth-highlight{
  border:1px solid var(--tzd-portal-border);
  border-radius:var(--tzd-portal-radius);
  padding:16px;
  text-align:center;
  background:var(--tzd-portal-surface);
}
.tzd-thirteenth-progress{
  border:1px solid var(--tzd-portal-border);
  border-radius:var(--tzd-portal-radius);
  padding:16px;
  background:var(--tzd-portal-surface);
}
.tzd-progress-bar{
  width:100%;
  height:8px;
  border-radius:999px;
  background:rgba(37,99,235,.12);
  margin:8px 0;
  position:relative;
  overflow:hidden;
}
.tzd-progress-bar span{
  position:absolute;
  left:0;
  top:0;
  bottom:0;
  background:var(--tzd-portal-primary);
  border-radius:inherit;
}
.tzd-progress-meta{
  font-size:12px;
  color:var(--tzd-portal-muted);
}
.tzd-portal-figure{
  font-size:28px;
  display:block;
  margin:4px 0;
}


.tzd-payroll-hero{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(200px,1fr));
  gap:16px;
  margin-bottom:18px;
}
.tzd-payroll-highlight{
  border:1px solid var(--tzd-portal-border);
  border-radius:var(--tzd-portal-radius);
  padding:16px;
  background:var(--tzd-portal-surface);
  text-align:center;
}
