/* Páginas públicas de AVA: citas, firma de contratos y portal del cliente */
body { background: var(--soft); }
body::before { display: none; }
[hidden] { display: none !important; }
.p-top { position: sticky; top: 0; z-index: 20; background: rgba(243, 242, 238, 0.86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.p-top .container { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 66px; }
.p-main { padding: clamp(28px, 5vw, 56px) 0 80px; }
.p-wrap { max-width: 760px; margin: 0 auto; }
.p-head { text-align: center; }
.p-head h1 { margin-top: 12px; font-size: clamp(34px, 5vw, 52px); font-weight: 500; line-height: 1.05; }
.p-head h1 .serif { color: var(--accent); }
.p-head p { margin: 10px auto 0; max-width: 520px; color: var(--muted); }
.p-card { margin-top: 26px; padding: clamp(20px, 4vw, 32px); border-radius: 26px; background: #fff; border: 1px solid var(--line); box-shadow: 0 40px 80px -60px rgba(42, 42, 42, 0.5); animation: pIn 0.6s var(--ease); }
@keyframes pIn { from { opacity: 0; transform: translateY(14px); } }
.p-step { font-size: 11px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); margin: 22px 0 10px; }
.p-step:first-child { margin-top: 0; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: #fff; font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; transition: all 0.2s; }
.opt:hover { border-color: var(--accent); }
.opt.on { background: var(--charcoal); border-color: var(--charcoal); color: #fff; }
.opt:disabled { opacity: 0.35; cursor: not-allowed; }
.days { display: grid; grid-auto-flow: column; grid-auto-columns: 74px; gap: 8px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.day { display: grid; gap: 2px; justify-items: center; padding: 10px 6px; border-radius: 16px; border: 1px solid var(--line-strong); background: #fff; font: inherit; cursor: pointer; }
.day span { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.day b { font-family: var(--font-serif); font-size: 26px; font-weight: 500; line-height: 1; }
.day.on { background: var(--charcoal); border-color: var(--charcoal); color: #fff; }
.day.on span { color: rgba(255, 255, 255, 0.7); }
.day:disabled { opacity: 0.3; cursor: not-allowed; }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.p-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.p-grid .full { grid-column: 1 / -1; }
.p-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.msg { padding: 12px 14px; border-radius: 12px; font-size: 13.5px; font-weight: 500; margin-top: 14px; }
.msg.error { background: #fbeee9; color: #b4472f; }
.msg.ok { background: var(--accent-50); color: var(--accent); }
.done { text-align: center; }
.done .ok-ico { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto; border-radius: 50%; background: var(--accent); color: #fff; animation: pop 0.6s var(--ease); }
@keyframes pop { from { transform: scale(0.6); opacity: 0; } }
.done h2 { margin-top: 16px; font-size: 32px; font-weight: 500; }
.done p { margin-top: 8px; color: var(--muted); }
.summary { margin-top: 18px; padding: 16px; border-radius: 16px; background: var(--stone-50); text-align: left; font-size: 14px; }
.contrato { max-height: 52vh; overflow-y: auto; padding: 18px 20px; border-radius: 16px; background: var(--stone-50); border: 1px solid var(--line); white-space: pre-wrap; font-size: 14px; line-height: 1.6; }
.firma-box { position: relative; margin-top: 8px; border-radius: 16px; border: 1.5px dashed var(--line-strong); background: #fff; touch-action: none; }
.firma-box canvas { display: block; width: 100%; height: 180px; border-radius: 16px; cursor: crosshair; }
.firma-box .hint { position: absolute; inset: auto 0 12px; text-align: center; font-size: 12px; color: var(--muted); pointer-events: none; }
.firma-img { max-width: 280px; margin-top: 8px; border-bottom: 1px solid var(--ink); }
.check-row { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; font-size: 14px; }
.check-row input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--accent); flex: none; }
.p-foot { padding: 26px 0; text-align: center; font-size: 13px; color: var(--muted); }
@media (max-width: 640px) { .p-grid { grid-template-columns: 1fr; } }
@media print { .p-top, .p-actions, .p-foot { display: none; } .p-card { box-shadow: none; border: 0; } .contrato { max-height: none; overflow: visible; } }

.link-btn { border: 0; background: none; padding: 0; color: var(--accent); font: inherit; font-weight: 600; font-size: 13.5px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.contrato.fx-doc { white-space: normal; line-height: 1.65; }
.p-grid .field > div > label { display: block; margin-bottom: 7px; font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-2); }
