/* AlignerZone Portal — brand tokens sampled from alignerzone.com (live computed styles) */
.azp {
	--az-navy: #0c354a;      /* body text + headings */
	--az-navy-2: #13455e;    /* hover / deep surfaces */
	--az-teal: #006c7f;      /* primary buttons, links */
	--az-teal-2: #59abb3;    /* accents, borders, decorative (NOT for text on white: 2.6:1) */
	--az-mist: #dfeef0;      /* page tint, subtle fills */
	--az-white: #fff;
	--az-ink-2: #32525f;     /* muted text (AA on white) */
	--az-line: #c7dde1;
	/* functional colors not in the brand palette */
	--az-error: #b3261e;
	--az-success: #1b7f5b;

	--az-radius: 14px;
	--az-shadow: 0 1px 2px rgba(12, 53, 74, .06), 0 12px 32px -12px rgba(12, 53, 74, .18);
	--az-ease: cubic-bezier(.2, .7, .2, 1);

	font-family: "Fira Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
	color: var(--az-navy);
	line-height: 1.55;
	max-width: 1120px;
	margin: 0 auto;
	padding: clamp(16px, 4vw, 40px) 16px;
	box-sizing: border-box;
}
.azp *, .azp *::before, .azp *::after { box-sizing: inherit; }
.azp h1, .azp h2, .azp h3 { font-family: Oswald, "Helvetica Neue", Arial, sans-serif; color: var(--az-navy); letter-spacing: .01em; line-height: 1.2; margin: 0 0 .6em; }
.azp h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); }
.azp h2 { font-size: clamp(1.25rem, 3vw, 1.6rem); }
.azp h3 { font-size: 1.1rem; }
.azp-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.azp [hidden] { display: none !important; }

.azp-card { background: var(--az-white); border: 1px solid var(--az-line); border-radius: var(--az-radius); box-shadow: var(--az-shadow); padding: clamp(20px, 4vw, 36px); margin-bottom: 20px; }
.azp-center { text-align: center; max-width: 520px; margin: 40px auto; }
.azp-eyebrow { display: inline-block; font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--az-teal); margin-bottom: 8px; }
.azp-hint { font-size: .85rem; color: var(--az-ink-2); margin: 6px 0 0; }
.azp-empty { color: var(--az-ink-2); }
.azp-link { color: var(--az-teal); font-size: .9rem; }

/* Buttons */
.azp-btn { appearance: none; border: 2px solid var(--az-teal); background: var(--az-teal); color: #fff; font: 600 1rem/1 "Fira Sans", Arial, sans-serif; padding: 14px 26px; border-radius: 999px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; transition: background .2s var(--az-ease), transform .2s var(--az-ease), box-shadow .2s var(--az-ease), color .2s; }
.azp-btn:hover { background: var(--az-navy-2); border-color: var(--az-navy-2); transform: translateY(-1px); box-shadow: 0 8px 18px -8px rgba(0, 108, 127, .6); color: #fff; }
.azp-btn:active { transform: translateY(0); }
.azp-btn:focus-visible, .azp input:focus-visible, .azp select:focus-visible, .azp textarea:focus-visible, .azp-opt:focus-visible, .azp-day:focus-visible, .azp-slot:focus-visible { outline: 3px solid var(--az-teal-2); outline-offset: 2px; }
.azp-btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }
.azp-btn--ghost { background: transparent; color: var(--az-teal); }
.azp-btn--ghost:hover { background: var(--az-mist); color: var(--az-navy); border-color: var(--az-teal); box-shadow: none; }
.azp-btn--block { width: 100%; }
.azp-btn--sm { padding: 10px 16px; min-height: 40px; font-size: .9rem; }
.azp-spin { width: 18px; height: 18px; border: 3px solid rgba(255, 255, 255, .45); border-top-color: #fff; border-radius: 50%; animation: azp-spin .7s linear infinite; }
@keyframes azp-spin { to { transform: rotate(360deg); } }

/* Layout helpers */
.azp-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.azp-row--between { justify-content: space-between; }
.azp-row--center { justify-content: center; margin-top: 20px; }
.azp-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.azp-inline { display: flex; gap: 10px; }
.azp-inline input { flex: 1; }
.azp-nav { margin-top: 28px; }
.azp-nav [data-next], .azp-nav [data-submit] { margin-left: auto; }

/* Forms */
.azp-form { display: block; }
.azp-field { margin-bottom: 18px; }
.azp-field label, .azp-field > label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; }
.azp input[type=text], .azp input[type=email], .azp input[type=tel], .azp input[type=password], .azp input[type=number], .azp select, .azp textarea {
	width: 100%; font: 400 1rem "Fira Sans", Arial, sans-serif; color: var(--az-navy); background: #fff; border: 1.5px solid var(--az-line); border-radius: 10px; padding: 13px 14px; min-height: 48px; transition: border-color .2s, box-shadow .2s; }
.azp input:hover, .azp select:hover, .azp textarea:hover { border-color: var(--az-teal-2); }
.azp input:focus, .azp select:focus, .azp textarea:focus { border-color: var(--az-teal); box-shadow: 0 0 0 4px rgba(89, 171, 179, .25); outline: none; }
.azp input[disabled] { background: var(--az-mist); color: var(--az-ink-2); }
.azp .is-invalid { border-color: var(--az-error) !important; }
.azp-error { color: var(--az-error); font-size: .85rem; margin: 6px 0 0; min-height: 0; }
.azp-error:empty { display: none; }
.azp-ok { color: var(--az-success); font-size: .85rem; margin: 6px 0 0; font-weight: 600; }
.azp-check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; cursor: pointer; font-size: .92rem; }
.azp-check input { width: 20px; height: 20px; min-height: 0; margin-top: 2px; accent-color: var(--az-teal); flex: none; }
.azp-pass { position: relative; }
.azp-pass input { padding-right: 52px; }
.azp-eye { position: absolute; right: 4px; top: 4px; bottom: 4px; width: 44px; border: 0; background: transparent; cursor: pointer; font-size: 1.05rem; border-radius: 8px; opacity: .7; }
.azp-eye:hover { opacity: 1; background: var(--az-mist); }
.azp-meter { height: 6px; background: var(--az-mist); border-radius: 99px; margin-top: 10px; overflow: hidden; }
.azp-meter i { display: block; height: 100%; width: 0; background: var(--az-error); transition: width .3s var(--az-ease), background .3s; }
.azp-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
fieldset.azp-step { border: 0; padding: 0; margin: 0; min-width: 0; }

.azp-alert { border-radius: 10px; padding: 12px 16px; margin-bottom: 18px; font-size: .95rem; border: 1px solid; }
.azp-alert.is-error { background: #fdecea; border-color: #f2b8b5; color: var(--az-error); }
.azp-alert.is-success { background: #e6f4ee; border-color: #b4dcc9; color: var(--az-success); }

/* Step transitions */
.azp-step.is-active { animation: azp-in .35s var(--az-ease); }
@keyframes azp-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* Stepper */
.azp-steps { list-style: none; display: flex; gap: 8px; padding: 0; margin: 0 0 26px; counter-reset: s; }
.azp-steps li { flex: 1; display: flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 600; color: var(--az-ink-2); position: relative; }
.azp-steps li span { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--az-mist); color: var(--az-navy); flex: none; transition: background .25s, color .25s; }
.azp-steps li::after { content: ""; flex: 1; height: 2px; background: var(--az-line); margin-left: 4px; transition: background .3s; }
.azp-steps li:last-child::after { display: none; }
.azp-steps li.is-active { color: var(--az-navy); }
.azp-steps li.is-active span, .azp-steps li.is-done span { background: var(--az-teal); color: #fff; }
.azp-steps li.is-done::after { background: var(--az-teal); }
.azp-steps--wide { max-width: 760px; }

/* Auth */
.azp-auth { display: grid; grid-template-columns: 1fr 1.1fr; gap: 0; align-items: stretch; padding-left: 0; padding-right: 0; }
.azp-auth__aside { background: linear-gradient(160deg, var(--az-navy) 0%, var(--az-navy-2) 100%); color: #fff; border-radius: var(--az-radius) 0 0 var(--az-radius); padding: clamp(28px, 5vw, 56px); display: flex; flex-direction: column; justify-content: center; margin-bottom: 20px; }
.azp-auth__aside h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.azp-auth__aside .azp-eyebrow { color: var(--az-teal-2); }
.azp-auth__aside ul { list-style: none; padding: 0; margin: 12px 0 0; }
.azp-auth__aside li { padding: 8px 0 8px 28px; position: relative; color: var(--az-mist); }
.azp-auth__aside li::before { content: "✓"; position: absolute; left: 0; color: var(--az-teal-2); font-weight: 700; }
.azp-auth__panel { border-radius: 0 var(--az-radius) var(--az-radius) 0; margin-bottom: 20px; }
.azp-tabs { display: flex; background: var(--az-mist); border-radius: 999px; padding: 4px; margin-bottom: 26px; }
.azp-tabs button { flex: 1; border: 0; background: transparent; padding: 12px; border-radius: 999px; font: 600 .95rem "Fira Sans", Arial, sans-serif; color: var(--az-ink-2); cursor: pointer; transition: background .25s, color .25s, box-shadow .25s; min-height: 44px; }
.azp-tabs button[aria-selected=true] { background: #fff; color: var(--az-teal); box-shadow: 0 2px 8px rgba(12, 53, 74, .12); }

/* Booking */
.azp-book__grid { display: grid; grid-template-columns: 1fr 300px; gap: 20px; align-items: start; }
.azp-options { display: grid; gap: 12px; }
.azp-opt { text-align: left; width: 100%; background: #fff; border: 1.5px solid var(--az-line); border-radius: 12px; padding: 16px 18px; cursor: pointer; font: inherit; color: inherit; display: flex; justify-content: space-between; gap: 12px; align-items: center; transition: border-color .2s, background .2s, transform .2s var(--az-ease), box-shadow .2s; }
.azp-opt:hover { border-color: var(--az-teal-2); transform: translateY(-1px); box-shadow: 0 6px 16px -10px rgba(12, 53, 74, .3); }
.azp-opt[aria-checked=true] { border-color: var(--az-teal); background: var(--az-mist); box-shadow: 0 0 0 3px rgba(89, 171, 179, .3); }
.azp-opt strong { display: block; }
.azp-opt small { color: var(--az-ink-2); }
.azp-opt__tag { font-size: .8rem; font-weight: 600; color: var(--az-teal); white-space: nowrap; }
.azp-cal { border: 1.5px solid var(--az-line); border-radius: 12px; padding: 14px; max-width: 420px; }
.azp-cal__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.azp-icon { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--az-mist); color: var(--az-navy); font-size: 1.3rem; cursor: pointer; transition: background .2s; }
.azp-icon:hover:not([disabled]) { background: var(--az-teal-2); }
.azp-icon[disabled] { opacity: .35; cursor: not-allowed; }
.azp-cal__dow, .azp-cal__grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.azp-cal__dow span { font-size: .75rem; font-weight: 600; color: var(--az-ink-2); padding: 6px 0; }
.azp-day { aspect-ratio: 1; border: 0; background: transparent; border-radius: 50%; font: 500 .95rem "Fira Sans", Arial, sans-serif; color: var(--az-navy); cursor: pointer; transition: background .15s, color .15s; min-height: 40px; }
.azp-day:disabled { color: #9db4ba; cursor: not-allowed; background: transparent; text-decoration: line-through; text-decoration-color: transparent; }
.azp-day.has-slots { background: var(--az-mist); font-weight: 600; }
.azp-day.has-slots:hover { background: var(--az-teal-2); }
.azp-day[aria-pressed=true] { background: var(--az-teal); color: #fff; }
.azp-day.is-empty { visibility: hidden; }
.azp-sub { margin-top: 24px; }
.azp-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(108px, 1fr)); gap: 10px; }
.azp-slot { border: 1.5px solid var(--az-line); background: #fff; border-radius: 10px; padding: 12px 8px; font: 600 .95rem "Fira Sans", Arial, sans-serif; color: var(--az-navy); cursor: pointer; min-height: 46px; transition: border-color .2s, background .2s, color .2s; }
.azp-slot:hover { border-color: var(--az-teal); }
.azp-slot[aria-pressed=true] { background: var(--az-teal); border-color: var(--az-teal); color: #fff; }
.azp-skel { height: 46px; border-radius: 10px; background: linear-gradient(90deg, var(--az-mist), #fff, var(--az-mist)); background-size: 200% 100%; animation: azp-sk 1.2s linear infinite; }
@keyframes azp-sk { to { background-position: -200% 0; } }
.azp-summary { position: sticky; top: 24px; }
.azp-summary dl { margin: 0; }
.azp-summary dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--az-ink-2); margin-top: 14px; }
.azp-summary dd { margin: 2px 0 0; font-weight: 600; }
.azp-success { text-align: center; padding: 20px 0; }
.azp-check-anim { width: 72px; height: 72px; margin: 0 auto 12px; color: var(--az-success); }
.azp-check-anim circle { stroke-dasharray: 151; stroke-dashoffset: 151; animation: azp-draw .6s var(--az-ease) forwards; }
.azp-check-anim path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: azp-draw .4s .4s var(--az-ease) forwards; }
@keyframes azp-draw { to { stroke-dashoffset: 0; } }

/* Dashboard */
.azp-dash__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.azp-dash__head h1 { margin: 0; }
.azp-dash__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.azp-dash__cols .azp-card { margin-bottom: 0; }
.azp-dash > .azp-card, .azp-dash__cols { margin-bottom: 20px; }
.azp-timeline { list-style: none; display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; padding: 0; margin: 8px 0 22px; }
.azp-timeline li { text-align: center; position: relative; font-size: .8rem; color: var(--az-ink-2); }
.azp-timeline li::before { content: ""; position: absolute; top: 15px; left: -50%; width: 100%; height: 2px; background: var(--az-line); z-index: 0; }
.azp-timeline li:first-child::before { display: none; }
.azp-timeline__dot { position: relative; z-index: 1; width: 32px; height: 32px; margin: 0 auto 8px; border-radius: 50%; display: grid; place-items: center; background: var(--az-mist); color: var(--az-navy); font-weight: 600; }
.azp-timeline li.is-done::before, .azp-timeline li.is-current::before { background: var(--az-teal); }
.azp-timeline li.is-done .azp-timeline__dot { background: var(--az-teal); color: #fff; }
.azp-timeline li.is-current .azp-timeline__dot { background: #fff; border: 3px solid var(--az-teal); color: var(--az-teal); box-shadow: 0 0 0 5px rgba(89, 171, 179, .3); }
.azp-timeline li.is-current { color: var(--az-navy); font-weight: 600; }
.azp-progress { height: 10px; background: var(--az-mist); border-radius: 99px; overflow: hidden; }
.azp-progress__bar { height: 100%; background: linear-gradient(90deg, var(--az-teal), var(--az-teal-2)); border-radius: 99px; transition: width 1s var(--az-ease); }
.azp-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.azp-list li { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 14px 16px; border: 1px solid var(--az-line); border-radius: 12px; }
.azp-list li div { display: grid; gap: 2px; }
.azp-list small { color: var(--az-ink-2); }
.azp-details { margin-bottom: 18px; }
.azp-details summary { cursor: pointer; font-weight: 600; color: var(--az-teal); margin-bottom: 12px; }
.azp-table-wrap { overflow-x: auto; }
.azp-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.azp-table th { text-align: left; font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--az-ink-2); padding: 10px 12px; border-bottom: 2px solid var(--az-line); }
.azp-table td { padding: 12px; border-bottom: 1px solid var(--az-line); }
.azp-pill { display: inline-block; padding: 3px 10px; border-radius: 99px; font-size: .78rem; font-weight: 600; background: var(--az-mist); color: var(--az-navy); }
.azp-pill--confirmed, .azp-pill--completed { background: #e6f4ee; color: var(--az-success); }
.azp-pill--cancelled { background: #fdecea; color: var(--az-error); }

/* Mobile first adjustments (these are the narrow overrides) */
@media (max-width: 860px) {
	.azp-auth { grid-template-columns: 1fr; }
	.azp-auth__aside { display: none; }
	.azp-auth__panel { border-radius: var(--az-radius); }
	.azp-book__grid { grid-template-columns: 1fr; }
	.azp-summary { position: static; order: -1; }
	.azp-dash__cols { grid-template-columns: 1fr; }
	.azp-timeline { grid-template-columns: 1fr; gap: 0; text-align: left; }
	.azp-timeline li { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
	.azp-timeline li::before { display: none; }
	.azp-timeline__dot { margin: 0; }
}
@media (max-width: 560px) {
	.azp-grid2 { grid-template-columns: 1fr; }
	.azp-steps li { font-size: 0; }                 /* dots only on phones */
	.azp-steps li span { font-size: .8rem; }
	.azp-table thead { display: none; }
	.azp-table tr { display: block; border: 1px solid var(--az-line); border-radius: 12px; margin-bottom: 10px; padding: 6px 12px; }
	.azp-table td { display: flex; justify-content: space-between; gap: 12px; border: 0; padding: 6px 0; }
	.azp-table td::before { content: attr(data-label); font-weight: 600; color: var(--az-ink-2); }
	.azp-nav .azp-btn { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
	.azp *, .azp *::before, .azp *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---- Doctor registration, STL portal ---- */
.azp-h1-sm { font-size: clamp(1.3rem, 3vw, 1.7rem); margin-bottom: 18px; }
.azp-center-text { text-align: center; margin-top: 18px; }
.azp-drops { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 6px 0 10px; }
.azp-drop { position: relative; border: 2px dashed var(--az-teal-2); border-radius: 12px; background: var(--az-mist); padding: 22px 14px; text-align: center; transition: background .2s, border-color .2s, transform .2s var(--az-ease); min-height: 120px; display: flex; flex-direction: column; justify-content: center; gap: 6px; }
.azp-drop:hover, .azp-drop.is-over { background: #fff; border-color: var(--az-teal); transform: translateY(-1px); }
.azp-drop.has-file { border-style: solid; border-color: var(--az-success); background: #f1faf6; }
.azp-drop.is-bad { border-color: var(--az-error); background: #fdecea; }
.azp-drop input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; min-height: 0; padding: 0; border: 0; }
.azp-drop__t { font-weight: 600; }
.azp-drop__n { font-size: .85rem; color: var(--az-ink-2); word-break: break-all; }
.azp-uplist { display: grid; gap: 10px; margin: 14px 0; }
.azp-uprow { display: grid; grid-template-columns: minmax(0, 1.4fr) 2fr 56px; gap: 12px; align-items: center; font-size: .9rem; }
.azp-uprow__n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.azp-uprow__s { text-align: right; font-weight: 600; }
.azp-uprow.is-done .azp-uprow__s { color: var(--az-success); }
.azp-uprow.is-fail .azp-uprow__s { color: var(--az-error); grid-column: 1 / -1; text-align: left; }
.azp-cases { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.azp-case { border: 1px solid var(--az-line); border-radius: 12px; padding: 16px 18px; }
.azp-case__head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; }
.azp-case__head small { color: var(--az-ink-2); margin-left: 8px; }
.azp-case__label { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--az-ink-2); margin: 14px 0 6px; }
.azp-files { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.azp-files li { display: flex; justify-content: space-between; gap: 12px; align-items: center; flex-wrap: wrap; }
.azp-files small { color: var(--az-ink-2); margin-left: 6px; }
.azp-pill--submitted { background: var(--az-mist); }
.azp-pill--in_design { background: #fff4d6; color: #7a5a00; }
.azp-pill--plan_ready { background: #e3f1f3; color: var(--az-teal); }
.azp-staff-upload { max-width: 640px; padding: 0; }
@media (max-width: 700px) { .azp-drops { grid-template-columns: 1fr; } .azp-uprow { grid-template-columns: 1fr 56px; } .azp-uprow .azp-progress { grid-column: 1 / -1; order: 3; } }
.azp h2:focus, .azp h2[tabindex="-1"]:focus { outline: none; }
