/* Acuity Doctor Booking — doctor detail + booking.
   Colors reference the ciputra theme's :root tokens with safe fallbacks so the
   plugin still renders acceptably on a theme without them. */
.adb-page {
	--adb-navy: var(--navy, #423f59);
	--adb-green: var(--green, #159d68);
	--adb-green-d: var(--green-d, #0e7d51);
	--adb-ink: var(--ink, #2d2d3a);
	--adb-muted: var(--muted, #6d6d7d);
	--adb-line: var(--line, #e6e7ec);
	--adb-soft: var(--soft, #f7f7fa);
	color: var(--adb-ink);
	background: linear-gradient(180deg, #eef3f7 0%, #e7edf3 100%);
	min-height: 100vh;
}

/* Logo header — 3-track grid (spacer / logo / CTA) keeps the logo truly
   centered while "Cari Dokter" stays pinned to the right, at any width. */
.adb-topbar { background: #fff; border-bottom: 1px solid var(--adb-line); }
.adb-topbar-inner {
	max-width: 1440px; margin: 0 auto; padding: 14px 24px;
	display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	align-items: center; column-gap: 12px;
}
.adb-topbar-spacer { visibility: hidden; }
.adb-logo { display: inline-block; justify-self: center; }
.adb-logo img { height: 46px; width: auto; display: block; }
.adb-logo-text { font-weight: 800; color: var(--adb-green-d); font-size: 20px; }

.adb-topbar-cta,
.adb-topbar-cta:link,
.adb-topbar-cta:visited {
	justify-self: end; white-space: nowrap; -webkit-tap-highlight-color: transparent;
	background: var(--adb-green); color: #fff; font-weight: 700; font-size: 14px;
	padding: 9px 16px; border-radius: 8px; text-decoration: none;
}
.adb-topbar-cta:hover,
.adb-topbar-cta:focus,
.adb-topbar-cta:active { background: var(--adb-green-d); color: #fff; }
.adb-topbar-cta:focus-visible { outline: 2px solid var(--adb-green-d); outline-offset: 2px; }

.adb-doctor-single { max-width: 1440px; margin: 0 auto; padding: 32px 24px 56px; }
.adb-doctor-grid { display: grid; grid-template-columns: 300px 1fr; gap: 40px; align-items: start; }

/* ---- Breadcrumb: single row, current segment truncates with ellipsis ---- */
.adb-breadcrumb-wrap { max-width: 1440px; margin: 0 auto; padding: 16px 24px 0; }
.adb-breadcrumb {
	display: flex;
	align-items: center;
	overflow: hidden;
	white-space: nowrap;
	font-size: 14px;
	color: var(--adb-muted, #6d6d7d);
}
.adb-breadcrumb a {
	flex: 0 0 auto;
	color: var(--adb-muted, #6d6d7d);
	text-decoration: none;
}
.adb-breadcrumb a:hover,
.adb-breadcrumb a:focus { color: var(--adb-green, #159d68); text-decoration: underline; }
.adb-breadcrumb-sep { flex: 0 0 auto; margin: 0 8px; color: var(--adb-line, #e6e7ec); }
.adb-breadcrumb-current {
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: var(--adb-ink, #2d2d3a);
	font-weight: 600;
}
@media (max-width: 600px) {
	.adb-breadcrumb-wrap { padding: 12px 16px 0; }
}

/* ---- LEFT: ID card ---- */
.adb-card-col { position: sticky; top: 24px; }
.adb-idcard {
	background: #fff;
	border: 1px solid var(--adb-line);
	border-top: 4px solid var(--adb-green);
	border-radius: 18px;
	box-shadow: 0 14px 34px rgba(0, 0, 0, .10);
	padding: 26px 22px 24px;
	text-align: center;
}
.adb-idcard-photo { width: 100%; aspect-ratio: 4 / 5; border-radius: 10px; overflow: hidden; background: var(--adb-soft); margin-bottom: 16px; }
.adb-idcard-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.adb-photo-placeholder { display: block; width: 100%; height: 100%; background: repeating-linear-gradient(45deg, #eceef2, #eceef2 10px, #f5f6f8 10px, #f5f6f8 20px); }

/* Doctor photos synced from Acuity arrive already cropped to a circle
   against a square canvas — object-fit:cover on a 4:5 rectangle would
   stretch/crop that circle unevenly. .adb-photo-circle makes the container
   itself a true circle and switches to object-fit:contain so the source's
   own circular crop is shown intact, not re-cropped. Kept as an opt-in
   modifier (not the default) since it assumes a pre-cropped source image —
   only doctor templates apply it. */
.adb-idcard-photo.adb-photo-circle,
.adb-doc-card-photo.adb-photo-circle {
	aspect-ratio: 1 / 1;
	border-radius: 50%;
}
.adb-idcard-photo.adb-photo-circle img,
.adb-doc-card-photo.adb-photo-circle img {
	object-fit: contain;
}
.adb-idcard-name { font-size: 18px; font-weight: 800; line-height: 1.3; margin: 0 0 6px; color: var(--adb-ink); }
.adb-idcard-specialty { font-size: 13.5px; color: var(--adb-muted); margin: 0; }

/* Explicit color on every pseudo-class: the browser's default a:visited rule
   has higher specificity than a plain class selector, so without this the
   text silently reverts to the default (often near-invisible against the
   green background) the moment the link is visited/focused/pressed. */
.adb-buatjanji,
.adb-buatjanji:link,
.adb-buatjanji:visited,
.adb-buatjanji:hover,
.adb-buatjanji:focus,
.adb-buatjanji:active {
	display: block; margin-top: 18px; text-align: center; text-decoration: none;
	background: var(--adb-green); color: #fff; font-weight: 700; font-size: 16px;
	padding: 15px 20px; border-radius: 12px; transition: filter .15s, transform .12s;
	-webkit-tap-highlight-color: transparent;
}
.adb-buatjanji:hover { filter: brightness(1.12); transform: translateY(-1px); }
.adb-buatjanji:focus-visible { outline: 2px solid var(--adb-green-d); outline-offset: 2px; }

/* ---- RIGHT: schedule + info ---- */
.adb-schedule { width: 100%; border-collapse: collapse; background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 8px 24px rgba(0, 0, 0, .05); margin-bottom: 28px; }
.adb-schedule thead th { background: var(--adb-green); color: #fff; text-align: left; font-size: 15px; font-weight: 700; padding: 16px 22px; }
.adb-schedule tbody th, .adb-schedule tbody td { padding: 15px 22px; border-top: 1px solid var(--adb-line); font-size: 15px; }
.adb-schedule tbody th { text-align: left; font-weight: 600; color: var(--adb-muted); width: 45%; }
.adb-schedule tbody td { color: var(--adb-ink); }
.adb-schedule tbody tr:first-child th, .adb-schedule tbody tr:first-child td { border-top: 0; }

.adb-section { background: #fff; border: 1px solid var(--adb-line); border-radius: 14px; padding: 24px 26px; margin-bottom: 18px; box-shadow: 0 6px 18px rgba(0, 0, 0, .04); }
.adb-section-title { font-size: 18px; font-weight: 700; color: var(--adb-green-d); margin: 0 0 14px; padding-bottom: 10px; border-bottom: 2px solid var(--adb-line); }
.adb-list { margin: 0; padding-left: 20px; }
.adb-list li { margin: 6px 0; line-height: 1.55; }
.adb-readmore { margin-top: 12px; }
.adb-readmore summary { cursor: pointer; color: var(--adb-green-d); font-weight: 600; list-style: none; }
.adb-readmore summary::-webkit-details-marker { display: none; }
.adb-readmore .adb-bio { margin-top: 12px; color: var(--adb-ink); line-height: 1.6; }

/* ---- Booking section ---- */
.adb-booking-section { margin-top: 40px; }
.adb-booking { max-width: 640px; margin: 0 auto; }
.adb-booking-heading { font-size: 16px; font-weight: 700; color: var(--adb-green-d); margin: 0 0 14px; }
.adb-booking-card { background: #fff; border: 1px solid var(--adb-line); border-radius: 16px; padding: 28px; box-shadow: 0 10px 28px rgba(0, 0, 0, .07); }
.adb-block-title { font-size: 17px; font-weight: 700; color: var(--adb-green-d); margin: 0 0 16px; }
.adb-block-date { margin-top: 26px; }

.adb-field { margin: 0 0 16px; }
.adb-field label { display: block; font-size: 14px; font-weight: 600; color: var(--adb-green-d); margin-bottom: 6px; }
.adb-field input, .adb-field select { width: 100%; padding: 12px 14px; border: 1px solid var(--adb-line); border-radius: 9px; font-size: 15px; font-family: inherit; background: var(--adb-soft); color: var(--adb-ink); box-sizing: border-box; }
.adb-field input:focus, .adb-field select:focus { outline: none; border-color: var(--adb-green); box-shadow: 0 0 0 3px rgba(21, 157, 104, .12); }
.adb-hint { display: block; font-size: 12px; color: var(--adb-muted); margin-top: 4px; }
.adb-req { color: #d64545; }

/* Calendar grid */
.adb-cal { border: 1px solid var(--adb-line); border-radius: 12px; padding: 16px; background: var(--adb-soft); margin-bottom: 8px; }
.adb-cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.adb-cal-label { font-size: 13px; color: var(--adb-muted); }
.adb-cal-nav { display: flex; align-items: center; gap: 12px; }
.adb-cal-month { font-weight: 700; font-size: 14px; min-width: 110px; text-align: center; }
.adb-cal-prev, .adb-cal-next {
	-webkit-appearance: none; -moz-appearance: none; appearance: none;
	display: flex; align-items: center; justify-content: center; flex: 0 0 auto;
	width: 32px; height: 32px; padding: 0; margin: 0;
	border-radius: 50%; border: 1px solid var(--adb-line); background: #fff;
	color: var(--adb-green-d); cursor: pointer;
}
.adb-cal-prev svg, .adb-cal-next svg { display: block; pointer-events: none; }
.adb-cal-prev:hover:not([disabled]), .adb-cal-next:hover:not([disabled]) { border-color: var(--adb-green); color: var(--adb-green-d); }
.adb-cal-prev[disabled] { opacity: .35; cursor: not-allowed; }
.adb-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.adb-cal-empty { text-align: center; color: var(--adb-muted); font-size: 14px; line-height: 1.6; padding: 22px 12px; margin: 0; }
.adb-cal-dow { text-align: center; font-size: 12px; font-weight: 600; color: var(--adb-muted); padding: 4px 0; }
.adb-cal-cell { aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; font-size: 14px; border: 1px solid transparent; border-radius: 8px; background: transparent; color: var(--adb-ink); cursor: pointer; }
.adb-cal-cell.is-empty { visibility: hidden; }
.adb-cal-cell.is-disabled { color: #c2c6d0; cursor: not-allowed; }
.adb-cal-cell.is-available { background: #e6f6ee; color: var(--adb-green-d); font-weight: 600; }
.adb-cal-cell.is-available:hover { background: #d3efe0; }
.adb-cal-cell.is-selected { background: var(--adb-green); color: #fff; border-color: var(--adb-green); }

/* Times */
.adb-times-hint { font-size: 14px; color: var(--adb-muted); margin: 0 0 10px; }
.adb-times { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.adb-time { padding: 9px 14px; border: 1px solid var(--adb-line); border-radius: 8px; background: #fff; cursor: pointer; font-size: 14px; }
.adb-time:hover { border-color: var(--adb-green); }
.adb-time.is-selected { background: var(--adb-green); color: #fff; border-color: var(--adb-green); }

/* Submit */
.adb-submit { margin-top: 20px; width: auto; min-width: 220px; background: var(--adb-green); color: #fff; font-size: 16px; font-weight: 700; padding: 15px 28px; border: 0; border-radius: 10px; cursor: pointer; box-shadow: 0 4px 12px rgba(21, 157, 104, .28); transition: background .15s, transform .12s; }
.adb-submit:hover:not([disabled]) { background: var(--adb-green-d); transform: translateY(-1px); }
.adb-submit[disabled] { opacity: .5; cursor: not-allowed; }

.adb-msg { min-height: 0; font-size: 14px; margin-bottom: 0; }
.adb-msg.is-error { min-height: 1.4em; margin-bottom: 14px; color: #b13636; background: #fdeaea; border: 1px solid #f2c6c6; padding: 10px 12px; border-radius: 8px; }
.adb-success { text-align: center; background: #fff; border: 1px solid var(--adb-line); border-radius: 16px; padding: 40px 28px; box-shadow: 0 10px 28px rgba(0, 0, 0, .07); }
.adb-success h3 { color: var(--adb-green-d); margin: 0 0 8px; }
.adb-notice { color: #b45309; font-size: 14px; }

/* Responsive */
@media (max-width: 860px) {
	.adb-doctor-grid { grid-template-columns: 1fr; gap: 24px; }
	.adb-card-col { position: static; max-width: 340px; margin: 0 auto; }
	.adb-booking-card { padding: 20px; }
}

@media (max-width: 600px) {
	.adb-topbar-inner { padding: 12px 16px; column-gap: 8px; }
	.adb-topbar-cta { font-size: 12.5px; padding: 8px 11px; }

	.adb-doctor-single { padding: 20px 16px 44px; }
	.adb-schedule thead th, .adb-schedule tbody th, .adb-schedule tbody td { padding: 12px 14px; font-size: 14px; }
	.adb-section { padding: 20px 18px; }

	/* Calendar: tighter so all 7 columns fit comfortably on small screens */
	.adb-booking-card { padding: 16px; }
	.adb-cal { padding: 10px; }
	.adb-cal-head { flex-wrap: wrap; gap: 8px; }
	.adb-cal-label { flex: 1 1 100%; }
	.adb-cal-nav { width: 100%; justify-content: space-between; }
	.adb-cal-month { min-width: 0; flex: 1; }
	.adb-cal-grid { gap: 3px; }
	.adb-cal-dow { font-size: 10px; padding: 2px 0; }
	.adb-cal-cell { font-size: 13px; border-radius: 6px; }
	.adb-time { padding: 10px 14px; }           /* larger tap target */
	.adb-submit { width: 100%; min-width: 0; }  /* full-width CTA */
}

/* Very small phones: keep day cells legible without overflow */
@media (max-width: 360px) {
	.adb-cal-grid { gap: 2px; }
	.adb-cal-cell { font-size: 12px; }
}
