.appointment-import { width: min(1480px, calc(100vw - 2rem)); max-width: none; }
.appointment-import .dialog-card { padding: 0; overflow: hidden; }
.appointment-import .dialog-header { margin: 0; padding: 1.5rem 1.75rem; border-bottom: 1px solid var(--border, #dce2e8); }
.appointment-import__body { padding: 1.5rem 1.75rem; display: grid; gap: 1.25rem; }
.appointment-import__steps { display: flex; gap: 1.5rem; list-style: none; padding: 0; margin: 0; color: #647180; font-size: .88rem; }
.appointment-import__steps li { display: flex; align-items: center; gap: .5rem; }
.appointment-import__steps span { display: grid; place-items: center; width: 1.8rem; height: 1.8rem; border-radius: 50%; background: #edf0f3; font-weight: 700; }
.appointment-import__steps [aria-current] { color: #8b3545; font-weight: 700; }
.appointment-import__steps [aria-current] span { background: #8b3545; color: #fff; }
.appointment-import__steps .is-complete span { background: #e3eee7; color: #335f45; }
.appointment-import__intro { display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.appointment-import h3 { margin: 0 0 .35rem; font-size: 1.1rem; }
.appointment-import__intro p { max-width: 52rem; margin: 0; color: #647180; font-size: .9rem; line-height: 1.5; }
.appointment-import__intro .button { flex-shrink: 0; }
.appointment-import__help { border: 1px solid #dce2e8; padding: .85rem 1rem; border-radius: .75rem; font-size: .875rem; color: #465565; }
.appointment-import__help summary { cursor: pointer; font-weight: 600; }
.appointment-import__options { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.appointment-import__options ul { margin: .5rem 0 0; padding-left: 1.2rem; max-height: 12rem; overflow: auto; }
.appointment-import__dropzone { position: relative; display: flex; justify-content: center; align-items: center; gap: 1rem; border: 2px dashed #c6ced7; background: #f8fafb; border-radius: 1rem; padding: 1.75rem; cursor: pointer; color: #465565; transition: border-color .15s, background .15s; }
.appointment-import__dropzone:hover, .appointment-import__dropzone.is-dragging, .appointment-import__dropzone:focus-within { border-color: #8b3545; background: #fbf5f6; }
.appointment-import__dropzone:focus-within { outline: 2px solid #8b3545; outline-offset: 3px; }
.appointment-import__dropzone input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.appointment-import__dropzone strong { display: block; overflow-wrap: anywhere; }
.appointment-import__dropzone small { display: block; margin-top: .4rem; color: #647180; font-weight: 400; }
.appointment-import__upload-actions, .appointment-import__toolbar, .appointment-import__pagination { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.appointment-import__upload-actions { margin-top: .9rem; }
.appointment-import__upload-actions > span, .appointment-import__pagination { color: #647180; font-size: .85rem; }
.appointment-import__message { padding: 1rem 1.1rem; border-radius: .75rem; font-size: .9rem; line-height: 1.5; background: #edf2f7; color: #354b63; display: flex; align-items: center; gap: .7rem; }
.appointment-import__message.is-error { background: #fbebeb; color: #8c3039; }
.appointment-import__message.is-success { background: #eaf2ed; color: #365d48; }
.appointment-import__message.is-loading::before { content: ''; flex: 0 0 auto; width: 1.1rem; height: 1.1rem; border: 2px solid #bac7d3; border-top-color: #354b63; border-radius: 50%; animation: appointment-import-spin .8s linear infinite; }
@keyframes appointment-import-spin { to { transform: rotate(360deg); } }
.appointment-import__results { display: grid; gap: 1rem; }
.appointment-import__summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; }
.appointment-import__summary > div { display: flex; align-items: baseline; gap: .65rem; border: 1px solid #dce2e8; border-radius: .75rem; padding: .85rem 1rem; }
.appointment-import__summary strong { font-size: 1.65rem; font-variant-numeric: tabular-nums; }
.appointment-import__summary span { color: #647180; font-size: .85rem; }
.appointment-import__toolbar h3 { margin: 0; }
.appointment-import__toolbar label, .appointment-import__confirmation label { display: flex; align-items: center; gap: .65rem; font-size: .875rem; font-weight: 400; }
.appointment-import input[type=checkbox] { width: 1rem; height: 1rem; flex: 0 0 auto; accent-color: #8b3545; }
.appointment-import__table { overflow: auto; max-height: 46vh; border: 1px solid #dce2e8; border-radius: .75rem; }
.appointment-import__table table { width: 100%; min-width: 1080px; border-collapse: collapse; font-size: .85rem; }
.appointment-import__table th { position: sticky; top: 0; background: #f1f4f6; z-index: 1; text-align: left; color: #566575; font-size: .75rem; }
.appointment-import__table td, .appointment-import__table th { padding: .8rem; border-bottom: 1px solid #e8edf1; vertical-align: top; }
.appointment-import__table td { max-width: 20rem; overflow-wrap: anywhere; }
.appointment-import__table small { display: block; color: #647180; margin-top: .3rem; line-height: 1.45; }
.appointment-import__table .has-error { background: #fff7f6; }
.appointment-import__table .has-error td:last-child small { color: #8c3039; }
.appointment-import__time { white-space: nowrap; font-variant-numeric: tabular-nums; }
.appointment-import__note { white-space: pre-wrap; min-width: 8rem; }
.appointment-import__pagination > div { display: flex; gap: .5rem; }
.appointment-import__confirmation { padding-top: 1rem; border-top: 1px solid #dce2e8; display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; }
.appointment-import__confirmation label { align-items: flex-start; max-width: 52rem; line-height: 1.5; }
.appointment-import__confirmation input { margin-top: .2rem; }
.appointment-import__confirmation .button { flex-shrink: 0; }
.appointment-import [hidden] { display: none !important; }
.appointment-import.has-preview .appointment-import__intro { display: none; }
.appointment-import.has-preview #appointment-import-form { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 1rem; }
.appointment-import.has-preview .appointment-import__dropzone { padding: .75rem 1rem; justify-content: flex-start; }
.appointment-import.has-preview .appointment-import__dropzone svg { width: 22px; height: 22px; }
.appointment-import.has-preview .appointment-import__upload-actions { margin: 0; }
.appointment-import.has-preview .appointment-import__upload-actions > span { display: none; }
.appointment-import.has-preview .appointment-import__table { max-height: 32vh; }
@media(max-width: 740px) {
    .appointment-import { width: calc(100vw - 1rem); }
    .appointment-import .dialog-header, .appointment-import__body { padding: 1rem; }
    .appointment-import__steps { gap: .6rem; font-size: .75rem; }
    .appointment-import__steps li { align-items: flex-start; flex: 1; }
    .appointment-import__steps span { flex: 0 0 1.5rem; height: 1.5rem; }
    .appointment-import__intro, .appointment-import__confirmation { align-items: stretch; flex-direction: column; gap: .85rem; }
    .appointment-import__summary > div { flex-direction: column; gap: .15rem; padding: .7rem; }
    .appointment-import__summary strong { font-size: 1.4rem; }
    .appointment-import__dropzone { padding: 1.3rem .9rem; justify-content: flex-start; }
    .appointment-import__dropzone svg { flex-shrink: 0; }
    .appointment-import__upload-actions { align-items: flex-start; }
    .appointment-import__upload-actions .button { flex-shrink: 0; }
    .appointment-import__toolbar { align-items: flex-start; flex-direction: column; gap: .6rem; }
    .appointment-import__options { grid-template-columns: 1fr; }
}
@media(prefers-reduced-motion: reduce) { .appointment-import__message.is-loading::before { animation: none; } }
