/* ============================================================
   Self-hosted booking widget — Calendly-style calendar.
   Lives inside .booking-embed (white panel, min-height 560px),
   so it always renders on a light surface regardless of theme.
   ============================================================ */
.cal{height:100%;min-height:560px;display:flex;flex-direction:column;background:#fff;color:#1a1a1a;font-family:'Manrope',system-ui,sans-serif;-webkit-font-smoothing:antialiased}
.cal *{box-sizing:border-box}
.cal-view{flex:1;display:flex;flex-direction:column;padding:20px 22px 16px;min-height:0}
.cal-heading{font-size:1.05rem;font-weight:700;color:#0a2540;margin:0 0 4px;text-align:center}
.cal-sub{font-size:.8rem;color:#476282;text-align:center;margin:0 0 14px}
.cal-loading{flex:1;display:flex;align-items:center;justify-content:center;font-size:.85rem;color:#476282}

/* ---- month nav ---- */
.cal-nav{display:flex;align-items:center;justify-content:space-between;margin:2px 4px 10px}
.cal-month{font-size:.95rem;font-weight:600;color:#0a2540}
.cal-nav button{width:34px;height:34px;border:0;border-radius:50%;background:transparent;color:#0069ff;font-size:1.1rem;line-height:1;cursor:pointer;display:grid;place-items:center;transition:background .15s}
.cal-nav button:hover:not(:disabled){background:rgba(0,105,255,.08)}
.cal-nav button:disabled{color:#c3cdd9;cursor:default}

/* ---- day grid ---- */
.cal-dow{display:grid;grid-template-columns:repeat(7,1fr);margin-bottom:6px}
.cal-dow span{text-align:center;font-size:.62rem;font-weight:600;letter-spacing:.08em;color:#476282;text-transform:uppercase;padding:4px 0}
.cal-grid{display:grid;grid-template-columns:repeat(7,1fr);row-gap:4px}
.cal-day{width:40px;height:40px;margin:0 auto;border:0;border-radius:50%;background:transparent;font:inherit;font-size:.85rem;color:#b7c1cc;display:grid;place-items:center;position:relative}
.cal-day.open{background:rgba(0,105,255,.065);color:#0069ff;font-weight:700;cursor:pointer;transition:background .15s}
.cal-day.open:hover{background:rgba(0,105,255,.15)}
.cal-day.today::after{content:"";position:absolute;bottom:5px;left:50%;transform:translateX(-50%);width:4px;height:4px;border-radius:50%;background:currentColor}
.cal-day.sel{background:#0069ff;color:#fff;font-weight:700}

/* ---- timezone footer ---- */
.cal-tz{margin-top:auto;padding-top:12px;display:flex;align-items:center;gap:7px;font-size:.74rem;color:#476282}
.cal-tz svg{width:15px;height:15px;flex:none}

/* ---- slots view ---- */
.cal-top{display:flex;align-items:center;gap:10px;margin-bottom:12px}
.cal-back{width:36px;height:36px;flex:none;border:1px solid #dce3ea;border-radius:50%;background:#fff;color:#0069ff;cursor:pointer;display:grid;place-items:center;transition:background .15s}
.cal-back:hover{background:rgba(0,105,255,.06)}
.cal-back svg{width:16px;height:16px}
.cal-top-title{font-size:.92rem;font-weight:700;color:#0a2540}
.cal-top-sub{font-size:.74rem;color:#476282}
.cal-slots{flex:1;overflow-y:auto;display:flex;flex-direction:column;gap:9px;padding:2px 2px 6px;min-height:0}
.cal-slot-row{display:flex;gap:8px;flex:none}
.cal-slot{flex:1;padding:11px 0;border:1px solid rgba(0,105,255,.55);border-radius:6px;background:#fff;color:#0069ff;font:inherit;font-size:.86rem;font-weight:700;cursor:pointer;text-align:center;transition:border-color .15s,box-shadow .15s}
.cal-slot:hover{border-color:#0069ff;box-shadow:inset 0 0 0 1px #0069ff}
.cal-slot-row.armed .cal-slot{flex:1;background:#5c6a79;border-color:#5c6a79;color:#fff;cursor:default}
.cal-next{flex:1;padding:11px 0;border:0;border-radius:6px;background:#0069ff;color:#fff;font:inherit;font-size:.86rem;font-weight:700;cursor:pointer;transition:background .15s}
.cal-next:hover{background:#0053cc}

/* ---- details form ---- */
.cal-form{display:flex;flex-direction:column;gap:12px;overflow-y:auto;min-height:0;padding:2px}
.cal-field label{display:block;font-size:.8rem;font-weight:700;color:#0a2540;margin-bottom:5px}
.cal-field input,.cal-field textarea{width:100%;padding:10px 12px;border:1px solid #c3cdd9;border-radius:8px;background:#fff;color:#1a1a1a;font:inherit;font-size:.86rem}
.cal-field input:focus,.cal-field textarea:focus{outline:none;border-color:#0069ff;box-shadow:0 0 0 1px #0069ff}
.cal-field textarea{min-height:70px;resize:vertical}
.cal-summary{border:1px solid #e4e9ef;border-radius:8px;padding:10px 12px;font-size:.78rem;color:#476282;display:flex;flex-direction:column;gap:3px}
.cal-summary strong{color:#0a2540;font-size:.84rem}
.cal-err{font-size:.78rem;color:#c4320a;background:#fff2ee;border:1px solid #ffd6c9;border-radius:8px;padding:9px 12px;display:none}
.cal-err.show{display:block}
.cal-submit{margin-top:2px;padding:12px 0;border:0;border-radius:24px;background:#0069ff;color:#fff;font:inherit;font-size:.9rem;font-weight:700;cursor:pointer;transition:background .15s}
.cal-submit:hover:not(:disabled){background:#0053cc}
.cal-submit:disabled{opacity:.6;cursor:wait}

/* ---- confirmation ---- */
.cal-done{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;gap:12px;padding:28px}
.cal-done-icon{width:52px;height:52px;border-radius:50%;background:#e6f4ea;color:#1a7f37;display:grid;place-items:center}
.cal-done-icon svg{width:26px;height:26px}
.cal-done h3{margin:0;font-size:1.15rem;color:#0a2540}
.cal-done p{margin:0;font-size:.82rem;color:#476282;max-width:340px}
.cal-done-card{border:1px solid #e4e9ef;border-radius:10px;padding:14px 18px;font-size:.84rem;color:#0a2540;display:flex;flex-direction:column;gap:5px;min-width:240px}
.cal-done-card .dim{color:#476282;font-size:.76rem}

@media (max-width:480px){
  .cal-view{padding:16px 14px 12px}
  .cal-day{width:36px;height:36px}
}
