/* VX Clínica panel. Minimal on purpose: a theme restyles it by overriding these
   variables or by copying the templates to <theme>/vxc/panel/. */
:root {
	--vxc-brand: #00589c;
	--vxc-brand-deep: #003f73;
	--vxc-ink: #0a2540;
	--vxc-muted: #52637a;
	--vxc-mist: #eef3f7;
	--vxc-hairline: #d3dce5;
	--vxc-surface: #fff;
	--vxc-danger: #b42318;
	--vxc-radius: 14px;
	--vxc-font: "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}

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

body.vxc-panel {
	margin: 0;
	min-height: 100vh;
	min-height: 100dvh;
	background: var(--vxc-mist);
	color: var(--vxc-ink);
	font: 16px/1.5 var(--vxc-font);
	-webkit-font-smoothing: antialiased;
	-webkit-tap-highlight-color: transparent;
}

.vxc-panel a { color: var(--vxc-brand); }
.vxc-panel :focus-visible { outline: 3px solid var(--vxc-brand); outline-offset: 2px; }

.vxc-skip { position: absolute; left: -9999px; }
/* WordPress's own recipe: the -1px margin keeps it from widening the page at a right edge. */
.vxc-panel .screen-reader-text { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.vxc-nowrap { white-space: nowrap; }
.vxc-skip:focus { left: 16px; top: 16px; z-index: 10; background: var(--vxc-surface); padding: 8px 12px; border-radius: 8px; }

/* One row that stays put while the page scrolls: a translucent layer, so content reads as passing under it. */
.vxc-bar {
	position: sticky;
	top: 0;
	z-index: 20;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 16px;
	padding-top: max(10px, env(safe-area-inset-top));
	background: rgba(255, 255, 255, 0.82);
	-webkit-backdrop-filter: saturate(180%) blur(16px);
	backdrop-filter: saturate(180%) blur(16px);
	border-bottom: 1px solid var(--vxc-hairline);
}
.vxc-brand { flex: none; color: var(--vxc-ink) !important; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; }
.vxc-brand img, .vxc-brand svg { height: 32px; width: auto; }
.vxc-user { display: flex; align-items: center; gap: 12px; min-width: 0; font-size: 14px; }
.vxc-user__name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vxc-user__role { color: var(--vxc-muted); white-space: nowrap; }
.vxc-user .vxc-button { flex: none; }
.vxc-user__me { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 44px; color: var(--vxc-ink) !important; text-decoration: none; }
.vxc-user__me[aria-current="page"] .vxc-user__name { color: var(--vxc-brand); }

/* "Ver como": a strip that can't be missed while the administrator previews a profile. */
.vxc-viewas { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; max-width: 1200px; margin: 12px auto 0; padding: 10px 16px; border-radius: 12px; background: #fffaeb; border: 1px solid #fedf89; color: #93370d; font-size: 14px; }
.vxc-viewas p { margin: 0; }
@media (max-width: 1231px) { .vxc-viewas { margin-inline: 16px; } }

/* A person's photo, or their initials on a soft disc. */
.vxc-avatar { flex: none; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; object-fit: cover; background: var(--vxc-mist); color: var(--vxc-brand-deep); font-weight: 600; letter-spacing: 0.02em; }
.vxc-profile-photo { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.vxc-profile-photo > div { display: grid; gap: 10px; flex: 1 1 260px; min-width: 0; }
.vxc-profile-photo__name { margin: 0; overflow-wrap: anywhere; }
.vxc-profile-photo .vxc-actions { margin-top: 0; }
.vxc-profile-photo .vxc-field { flex: 1 1 220px; }

.vxc-shell { display: grid; gap: 16px; padding: 16px; max-width: 1200px; margin: 0 auto; }
/* On a phone the sections are one row that slides sideways, so the page starts right below it. */
/* min-width: 0 lets the grid column shrink so the row scrolls inside itself instead of widening the page. */
.vxc-nav { min-width: 0; }
.vxc-nav ul { list-style: none; margin: 0 -16px; padding: 2px 16px; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; scroll-padding-inline: 16px; }
.vxc-nav ul::-webkit-scrollbar { display: none; }
.vxc-nav li { flex: none; }
.vxc-nav a,
.vxc-nav__toggle {
	display: flex;
	align-items: center;
	padding: 8px 14px;
	border-radius: 999px;
	color: var(--vxc-ink);
	text-decoration: none;
	white-space: nowrap;
	background: var(--vxc-surface);
	/* White on the mist page needs a firmer edge and a lift to read as a button on a phone. */
	border: 1px solid #b7c4d1;
	box-shadow: 0 1px 2px rgba(10, 37, 64, 0.08);
	font-weight: 500;
	min-height: 44px;
}
.vxc-nav a[aria-current="page"] { background: var(--vxc-brand); border-color: var(--vxc-brand); color: #fff; }
.vxc-nav__toggle { gap: 8px; font: inherit; cursor: pointer; }
/* A small chevron that turns when the group opens. */
.vxc-nav__toggle::after { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform 150ms ease; }
.vxc-nav__toggle[aria-expanded="true"]::after { transform: translateY(2px) rotate(-135deg); }
@media (max-width: 599px) {
	.vxc-user__role { display: none; }
}
@media (prefers-reduced-transparency: reduce) {
	.vxc-bar { background: var(--vxc-surface); -webkit-backdrop-filter: none; backdrop-filter: none; }
}

.vxc-main { background: var(--vxc-surface); border: 1px solid var(--vxc-hairline); border-radius: var(--vxc-radius); padding: 20px; min-width: 0; }
.vxc-main:focus { outline: none; }
.vxc-title { margin: 0 0 8px; font-size: 26px; line-height: 1.2; letter-spacing: -0.01em; }
.vxc-muted { color: var(--vxc-muted); }

.vxc-empty { padding: 24px 0; color: var(--vxc-muted); }
.vxc-cards { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.vxc-card { display: block; padding: 20px; border-radius: var(--vxc-radius); background: var(--vxc-mist); color: var(--vxc-ink) !important; font-weight: 600; text-decoration: none; }

.vxc-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 10px 18px;
	border: 0;
	border-radius: 999px;
	background: var(--vxc-brand);
	color: #fff !important;
	font: 600 15px/1 var(--vxc-font);
	text-decoration: none;
	cursor: pointer;
	touch-action: manipulation;
}
.vxc-button--quiet { background: var(--vxc-mist); color: var(--vxc-ink) !important; min-height: 36px; padding: 8px 14px; }

/* Feedback the instant something is pressed, on touch too: hover alone never shows on a phone. */
.vxc-button,
.vxc-card,
.vxc-nav a,
.vxc-chips a,
.vxc-slot span,
.vxc-pager a { transition: transform 100ms ease-out, background-color 150ms ease; }
a.vxc-card:active,
.vxc-button:active,
.vxc-nav a:active,
.vxc-chips a:active,
.vxc-slot span:active,
.vxc-pager a:active { transform: scale(0.97); }
.vxc-button:active { background: var(--vxc-brand-deep); }
.vxc-button--quiet:active,
a.vxc-card:active { background: var(--vxc-hairline); }
@media (hover: hover) {
	.vxc-button:hover { background: var(--vxc-brand-deep); }
	.vxc-button--quiet:hover,
	a.vxc-card:hover { background: var(--vxc-hairline); }
}
@media (prefers-reduced-motion: reduce) {
	.vxc-button, .vxc-card, .vxc-nav a, .vxc-chips a, .vxc-slot span, .vxc-pager a { transition: background-color 150ms ease; }
	a.vxc-card:active, .vxc-button:active, .vxc-nav a:active, .vxc-chips a:active, .vxc-slot span:active, .vxc-pager a:active { transform: none; }
}

.vxc-login {
	max-width: 400px;
	margin: 0 auto;
	padding: 48px 16px;
	padding-top: max(48px, env(safe-area-inset-top));
}
.vxc-login .vxc-brand { margin-bottom: 32px; }
.vxc-form { display: grid; gap: 16px; margin: 24px 0; padding: 24px; background: var(--vxc-surface); border: 1px solid var(--vxc-hairline); border-radius: var(--vxc-radius); }
.vxc-field { display: grid; gap: 6px; font-weight: 600; font-size: 14px; }
.vxc-field input {
	width: 100%;
	min-height: 48px;
	padding: 10px 14px;
	border: 1px solid var(--vxc-hairline);
	border-radius: 10px;
	font: 16px/1.4 var(--vxc-font); /* 16px stops iOS zooming into the field */
	color: var(--vxc-ink);
	background: var(--vxc-surface);
}
.vxc-field input:focus { border-color: var(--vxc-brand); outline: 3px solid rgba(0, 88, 156, 0.2); outline-offset: 0; }
.vxc-check { display: flex; gap: 8px; align-items: center; font-size: 14px; color: var(--vxc-muted); }
.vxc-check input { width: 18px; height: 18px; accent-color: var(--vxc-brand); }
.vxc-alert { margin: 16px 0 0; padding: 12px 14px; border-radius: 10px; background: #fef3f2; color: var(--vxc-danger); border: 1px solid #fecdca; }

.vxc-alert--ok { background: #ecfdf3; color: #067647; border-color: #abefc6; }
/* Something to know, not something that failed: red stays for errors. */
.vxc-alert--warn { background: #fffaeb; color: #93370d; border-color: #fedf89; }
.vxc-alert__label { font-weight: 600; }

/* The figures of a period (Inicio, Finanzas): label, big number, a quiet note. */
.vxc-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin: 0; }
.vxc-stat { padding: 14px 16px; border: 1px solid var(--vxc-hairline); border-radius: 12px; background: var(--vxc-surface); }
.vxc-stat dt { font-size: 13px; color: var(--vxc-muted); }
.vxc-stat dd { margin: 4px 0 0; font-size: 24px; font-weight: 600; line-height: 1.2; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; color: var(--vxc-ink); }
.vxc-stat small { display: block; margin-top: 2px; font-size: 12px; font-weight: 400; letter-spacing: 0; color: var(--vxc-muted); }

/* Panel forms (field rows, selects, textareas) */
.vxc-panel select,
.vxc-panel textarea,
.vxc-panel input[type="text"],
.vxc-panel input[type="email"],
.vxc-panel input[type="tel"],
.vxc-panel input[type="date"],
.vxc-panel input[type="time"],
.vxc-panel input[type="month"],
.vxc-panel input[type="number"],
.vxc-panel input[type="search"],
.vxc-panel input[type="file"] {
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid var(--vxc-hairline);
	border-radius: 10px;
	font: 16px/1.4 var(--vxc-font);
	color: var(--vxc-ink);
	background: var(--vxc-surface);
}
.vxc-panel textarea { min-height: 96px; resize: vertical; }
/* align-content: start keeps a short form beside a tall one from spreading its rows apart. */
.vxc-grid { display: grid; gap: 16px; margin: 20px 0; align-content: start; }
.vxc-grid h3 { margin: 0; font-size: 17px; }
.vxc-grid > .vxc-grid { margin: 0; }
.vxc-grid > .vxc-button { justify-self: start; }
.vxc-fieldset { border: 0; margin: 0; padding: 0; display: grid; gap: 16px; }
.vxc-fieldset legend { font-weight: 600; font-size: 18px; margin-bottom: 4px; }
.vxc-help { font-weight: 400; color: var(--vxc-muted); font-size: 13px; }
.vxc-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 8px; }
/* Fields share the row and grow; buttons keep their size beside them instead of stretching or dropping below. */
.vxc-filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin: 16px 0; }
.vxc-filters > * { flex: 1 1 180px; min-width: 0; }
.vxc-filters > .vxc-button { flex: none; min-height: 44px; }
/* A search box and its button stay on one line (Pacientes, Inventario). */
.vxc-panel form[role="search"] { flex: 1 1 280px; flex-wrap: nowrap; max-width: 520px; margin-top: 0; }
.vxc-panel form[role="search"] input { flex: 1 1 auto; width: auto; min-width: 0; }
.vxc-panel form[role="search"] .vxc-button { flex: none; min-height: 44px; }

/* Tables and lists */
/* relative: absolutely positioned children (screen-reader text) stay inside the scroller instead of widening the page */
.vxc-table-wrap { position: relative; overflow-x: auto; margin: 16px 0; }
.vxc-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.vxc-table th, .vxc-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--vxc-hairline); vertical-align: top; }
.vxc-table th { font-size: 13px; color: var(--vxc-muted); font-weight: 600; }
/* Money and counts line up digit under digit. */
.vxc-table td { font-variant-numeric: tabular-nums; }
/* Names in lists read as links by color and weight; the underline is for links inside running text. */
.vxc-table a,
.vxc-cita__body a:not(.vxc-button) { font-weight: 600; text-decoration: none; }
@media (hover: hover) {
	.vxc-table a:hover,
	.vxc-cita__body a:not(.vxc-button):hover { text-decoration: underline; }
}
.vxc-table + .vxc-table { margin-top: 20px; }
.vxc-pager { display: flex; flex-wrap: wrap; gap: 6px; }
.vxc-pager a { padding: 6px 12px; border-radius: 8px; text-decoration: none; }
.vxc-pager a[aria-current="page"] { background: var(--vxc-brand); color: #fff; }

/* Record sheet */
.vxc-section { margin: 28px 0 0; padding-top: 20px; border-top: 1px solid var(--vxc-hairline); }
.vxc-section__head { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.vxc-section h2 { margin: 0; font-size: 20px; }
.vxc-dl { display: grid; grid-template-columns: minmax(120px, max-content) 1fr; gap: 6px 16px; margin: 0; }
.vxc-dl dt { color: var(--vxc-muted); }
.vxc-dl dd { margin: 0; white-space: pre-line; }
.vxc-flag { display: inline-block; padding: 4px 10px; border-radius: 999px; background: #fef3f2; color: var(--vxc-danger); font-weight: 600; font-size: 14px; margin: 0 6px 6px 0; }
.vxc-tag { display: inline-block; padding: 2px 8px; border-radius: 999px; background: var(--vxc-mist); font-size: 13px; color: var(--vxc-muted); }
.vxc-timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.vxc-note { padding: 14px 16px; border: 1px solid var(--vxc-hairline); border-radius: 12px; }
.vxc-note--addendum { margin: 10px 0 0 16px; border-left: 3px solid var(--vxc-brand); }
.vxc-note__meta { font-size: 13px; color: var(--vxc-muted); margin-bottom: 8px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* Settings pages: section cards, switches, numbers with units, a save bar that stays in reach */
.vxc-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 20px; }
.vxc-chips a { display: inline-flex; align-items: center; min-height: 36px; padding: 6px 14px; border-radius: 999px; background: var(--vxc-mist); color: var(--vxc-ink); font-size: 14px; text-decoration: none; }
.vxc-chips a:hover { background: var(--vxc-hairline); }
.vxc-settings { display: grid; gap: 20px; }
.vxc-panel-card { padding: 20px; border: 1px solid var(--vxc-hairline); border-radius: var(--vxc-radius); scroll-margin-top: 16px; }
.vxc-panel-card__head { margin-bottom: 16px; }
.vxc-panel-card__head h2 { margin: 0 0 4px; font-size: 19px; }
.vxc-panel-card__head p { margin: 0; font-size: 15px; }
.vxc-rule { display: grid; gap: 14px; align-content: start; }
.vxc-rule h3 { margin: 0; font-size: 15px; color: var(--vxc-muted); font-weight: 600; }

.vxc-switch { display: inline-flex; align-items: center; gap: 12px; min-height: 44px; cursor: pointer; }
.vxc-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.vxc-switch__track { position: relative; flex: none; width: 44px; height: 26px; border-radius: 999px; background: var(--vxc-hairline); transition: background-color 0.18s ease; }
.vxc-switch__track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(10, 37, 64, 0.25); transition: transform 0.18s ease; }
.vxc-switch input:checked + .vxc-switch__track { background: var(--vxc-brand); }
.vxc-switch input:checked + .vxc-switch__track::after { transform: translateX(18px); }
.vxc-switch input:focus-visible + .vxc-switch__track { outline: 3px solid var(--vxc-brand); outline-offset: 2px; }
.vxc-switch input:disabled + .vxc-switch__track { opacity: 0.4; }
.vxc-switch__label { font-weight: 600; }
.vxc-switch--block { display: flex; align-items: flex-start; padding: 8px 0; }
.vxc-switch--block .vxc-switch__track { margin-top: 2px; }
.vxc-switch--block .vxc-switch__label { font-weight: 400; }
.vxc-fieldset--cols { display: grid; gap: 0 24px; }
@media (min-width: 600px) { .vxc-fieldset--cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 900px) { .vxc-fieldset--cols { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.vxc-fieldset--cols .vxc-muted { grid-column: 1 / -1; }

.vxc-unit { display: flex; align-items: stretch; max-width: 220px; }
.vxc-panel .vxc-unit input { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.vxc-unit > span { display: flex; align-items: center; padding: 0 12px; border: 1px solid var(--vxc-hairline); border-left: 0; border-radius: 0 10px 10px 0; background: var(--vxc-mist); color: var(--vxc-muted); font-weight: 400; font-size: 14px; white-space: nowrap; }

.vxc-week { display: grid; border-top: 1px solid var(--vxc-hairline); margin-bottom: 12px; }
.vxc-day { padding: 8px 0; border-bottom: 1px solid var(--vxc-hairline); }
.vxc-shift { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px 16px; align-items: center; }
.vxc-shift__times { display: flex; align-items: center; gap: 8px; }
.vxc-panel .vxc-shift__times input { width: auto; flex: 1 1 0; min-width: 0; max-width: 140px; font-variant-numeric: tabular-nums; }
.vxc-day__closed { display: none; color: var(--vxc-muted); }
.vxc-day.is-closed .vxc-shift__times,
.vxc-day.is-closed .vxc-day__more { display: none; }
.vxc-day.is-closed .vxc-day__closed { display: block; }
.vxc-day__more summary { display: inline-flex; align-items: center; min-height: 36px; color: var(--vxc-brand); cursor: pointer; font-size: 14px; }
.vxc-day__more[open] summary { color: var(--vxc-muted); }
.vxc-day .vxc-shift + .vxc-shift .vxc-switch__label { font-weight: 400; color: var(--vxc-muted); }

.vxc-closed-list { display: grid; gap: 8px; margin-bottom: 12px; }
.vxc-closed { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; align-items: center; }
.vxc-closed.is-past { opacity: 0.6; }

.vxc-preview { padding: 14px 16px; border-radius: 12px; background: var(--vxc-mist); align-self: start; }
.vxc-preview ul { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 4px; }
.vxc-preview .vxc-help { margin: 0; }

/* Stays at the bottom of the screen while the form scrolls; the page leaves room for it. */
.vxc-savebar { position: sticky; bottom: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px; margin: 0 -20px -20px; padding: 12px 20px; padding-bottom: max(12px, env(safe-area-inset-bottom)); border-top: 1px solid var(--vxc-hairline); background: rgba(255, 255, 255, 0.96); border-radius: 0 0 var(--vxc-radius) var(--vxc-radius); }
.vxc-savebar__state { color: var(--vxc-muted); font-size: 14px; }
.is-dirty .vxc-savebar__state { color: #b54708; }
.vxc-button:disabled { opacity: 0.6; cursor: progress; }

@media (min-width: 720px) {
	.vxc-shift { grid-template-columns: 220px minmax(0, 1fr); }
	.vxc-shift .vxc-day__closed { grid-column: 2; }
	.vxc-day__more { padding-left: 236px; }
	.vxc-closed { grid-template-columns: 180px minmax(0, 1fr) auto auto; }
}
@media (min-width: 900px) {
	.vxc-savebar { margin: 0 -32px -32px; padding-left: 32px; padding-right: 32px; }
}
@media (prefers-reduced-motion: reduce) {
	.vxc-switch__track,
	.vxc-switch__track::after { transition: none; }
}

/* Agenda (its own name: .vxc-day is a day of the opening-hours settings) */
.vxc-agenda-day { margin-top: 24px; }
.vxc-agenda-day__title { font-size: 17px; margin: 0 0 10px; }
/* Agenda header: Día · Semana · Mes as one segmented control, then ‹ Hoy › beside the period's name. */
.vxc-viewtabs { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--vxc-mist); }
.vxc-viewtabs a { display: inline-flex; align-items: center; min-height: 38px; padding: 0 16px; border-radius: 999px; color: var(--vxc-ink); font-weight: 600; font-size: 14px; text-decoration: none; transition: background-color 150ms ease; }
.vxc-viewtabs a[aria-current="page"] { background: var(--vxc-surface); box-shadow: 0 1px 3px rgba(10, 37, 64, 0.12); }
.vxc-agenda-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin: 4px 0 12px; }
.vxc-agenda-bar__title { margin: 0; font-size: 19px; letter-spacing: -0.01em; }
.vxc-datenav { flex-wrap: nowrap; gap: 6px; margin-top: 0; }
.vxc-datenav .vxc-button { min-height: 44px; }
.vxc-datenav a:first-child, .vxc-datenav a:nth-child(3) { min-width: 44px; padding-inline: 0; font-size: 22px; line-height: 1; }
.vxc-agenda-stats { margin: 0 0 16px; }
@media (min-width: 900px) { .vxc-agenda-stats { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.vxc-agenda-stats .vxc-stat dd { font-size: 22px; }

/* A state's color, always beside its name or count (never color alone). */
.vxc-dot { display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; background: var(--vxc-hairline); vertical-align: 1px; }
.vxc-dot--pendiente { background: #f79009; }
.vxc-dot--confirmada { background: var(--vxc-brand); }
.vxc-dot--completada { background: #17b26a; }
.vxc-dot--cancelada, .vxc-dot--no_asistio { background: #98a2b3; }

/* Month: seven columns of days; a day is a link to that day's full list. */
.vxc-month { border: 1px solid var(--vxc-hairline); border-radius: var(--vxc-radius); overflow: hidden; }
.vxc-month__head, .vxc-month__week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.vxc-month__head { background: var(--vxc-mist); }
.vxc-month__head span { padding: 8px; font-size: 12px; font-weight: 600; color: var(--vxc-muted); text-align: center; }
.vxc-month__day { display: flex; flex-direction: column; gap: 4px; min-height: 92px; padding: 8px; border-top: 1px solid var(--vxc-hairline); border-left: 1px solid var(--vxc-hairline); color: var(--vxc-ink) !important; text-decoration: none; transition: background-color 150ms ease; }
.vxc-month__week .vxc-month__day:first-child { border-left: 0; }
.vxc-month__day.is-outside { background: #fafbfc; }
.vxc-month__day.is-outside .vxc-month__num { color: var(--vxc-muted); }
.vxc-month__num { font-weight: 600; font-variant-numeric: tabular-nums; }
.vxc-month__day.is-today .vxc-month__num { display: inline-grid; place-items: center; width: 28px; height: 28px; margin: -4px 0 0 -4px; border-radius: 50%; background: var(--vxc-brand); color: #fff; }
.vxc-month__count { font-size: 13px; font-weight: 600; color: var(--vxc-brand-deep); }
.vxc-month__short { display: none; }
.vxc-month__dots { display: flex; flex-wrap: wrap; gap: 2px 8px; font-size: 12px; color: var(--vxc-muted); font-variant-numeric: tabular-nums; }
.vxc-month__dots .vxc-dot { margin-right: 3px; }
.vxc-month__day:active { background: var(--vxc-mist); }
@media (hover: hover) { .vxc-month__day:hover { background: var(--vxc-mist); } }

/* Week: seven columns of compact rows; each opens its day at that appointment. */
.vxc-week-grid { display: grid; gap: 12px; }
.vxc-week-grid__day { min-width: 0; padding: 10px; border: 1px solid var(--vxc-hairline); border-radius: 12px; }
.vxc-week-grid__day.is-today { border-color: var(--vxc-brand); box-shadow: inset 0 3px 0 var(--vxc-brand); }
.vxc-week-grid__day h3 { margin: 0 0 8px; font-size: 15px; }
.vxc-week-grid__day h3 a { color: var(--vxc-ink); text-decoration: none; }
.vxc-week-grid__day h3 span { color: var(--vxc-muted); font-weight: 500; }
.vxc-week-grid__day .vxc-muted { margin: 0; font-size: 13px; }
.vxc-week-grid ul { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.vxc-week-grid__item a { display: grid; gap: 1px; padding: 6px 8px; border-left: 3px solid var(--vxc-hairline); border-radius: 6px; background: var(--vxc-mist); color: var(--vxc-ink); text-decoration: none; font-size: 13px; }
.vxc-week-grid__item a strong { font-variant-numeric: tabular-nums; }
.vxc-week-grid__item a span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vxc-week-grid__item a small { color: var(--vxc-muted); }
.vxc-week-grid__item--pendiente a { border-left-color: #f79009; }
.vxc-week-grid__item--confirmada a { border-left-color: var(--vxc-brand); }
.vxc-week-grid__item--completada a { border-left-color: #17b26a; }
.vxc-week-grid__item--cancelada a, .vxc-week-grid__item--no_asistio a { opacity: 0.6; }
@media (min-width: 1000px) {
	.vxc-week-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
	.vxc-week-grid__day { min-height: 160px; padding: 8px; }
}
@media (max-width: 599px) {
	/* On a phone the month keeps its grid, but each day shows its number and a count only. */
	.vxc-month__day { min-height: 56px; padding: 6px 4px; align-items: center; }
	.vxc-month__dots { display: none; }
	.vxc-month__long { display: none; }
	.vxc-month__short { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: #eff8ff; font-size: 12px; }
	.vxc-agenda-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
	.vxc-agenda-stats .vxc-stat { padding: 10px; }
	.vxc-agenda-stats .vxc-stat dd { font-size: 18px; }
}
.vxc-citas { display: grid; gap: 10px; }
.vxc-cita { display: grid; grid-template-columns: 64px 1fr; gap: 12px; padding: 12px 14px; border: 1px solid var(--vxc-hairline); border-left: 4px solid var(--vxc-hairline); border-radius: 12px; }
.vxc-cita__time { display: grid; font-variant-numeric: tabular-nums; color: var(--vxc-muted); font-size: 14px; }
.vxc-cita__time strong { color: var(--vxc-ink); font-size: 17px; }
.vxc-cita__body { display: grid; gap: 4px; min-width: 0; }
.vxc-cita .vxc-actions { margin-top: 6px; }
.vxc-cita--pendiente { border-left-color: #f79009; }
.vxc-cita--confirmada { border-left-color: var(--vxc-brand); }
.vxc-cita--completada { border-left-color: #17b26a; }
.vxc-cita--cancelada,
.vxc-cita--no_asistio { border-left-color: var(--vxc-hairline); opacity: 0.7; }
.vxc-state--pendiente { background: #fffaeb; color: #b54708; }
.vxc-state--confirmada { background: #eff8ff; color: var(--vxc-brand-deep); }
.vxc-state--completada { background: #ecfdf3; color: #067647; }
.vxc-button--small { min-height: 36px; padding: 6px 12px; font-size: 14px; }
.vxc-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.vxc-slots--long { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.vxc-slot { position: relative; }
.vxc-slot input { position: absolute; opacity: 0; }
.vxc-slot span { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 6px 8px; border: 1px solid var(--vxc-hairline); border-radius: 10px; font-variant-numeric: tabular-nums; text-align: center; cursor: pointer; }
.vxc-slot input:checked + span { background: var(--vxc-brand); border-color: var(--vxc-brand); color: #fff; }
.vxc-slot input:focus-visible + span { outline: 3px solid var(--vxc-brand); outline-offset: 2px; }

@media (min-width: 900px) {
	.vxc-grid--2 { grid-template-columns: 1fr 1fr; align-items: start; }
	.vxc-shell { grid-template-columns: 240px minmax(0, 1fr); align-items: start; padding: 24px; }
	/* Line the bar up with the 1200px shell below it. */
	.vxc-bar { padding-inline: max(24px, calc((100% - 1200px) / 2 + 24px)); }
	/* The side menu stays in view under the bar on long pages. */
	.vxc-nav { position: sticky; top: 80px; }
	.vxc-nav ul { flex-direction: column; margin: 0; padding: 0; overflow: visible; }
	.vxc-nav a, .vxc-nav__toggle { border-radius: 10px; background: transparent; border-color: transparent; box-shadow: none; font-weight: 400; }
	.vxc-nav__toggle { width: 100%; justify-content: space-between; margin-top: 8px; color: var(--vxc-muted, inherit); font-size: 14px; }
	.vxc-nav__sub a { padding-left: 26px; }
	.vxc-nav a:not([aria-current="page"]):hover, .vxc-nav__toggle:hover { background: var(--vxc-surface); }
	.vxc-main { padding: 32px; }
}
