/* Reserva pública de citas — temas claro / oscuro (html data-theme + repairbill_theme) */

.appointment-public-page {
    min-height: 100vh;
    padding-bottom: 2.5rem;
    transition: background 0.2s ease, color 0.2s ease;
}

.appointment-public-page .appointment-brand-head {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.8rem;
}

.appointment-public-page .appointment-brand-head-main {
    flex: 1 1 auto;
    min-width: 0;
}

.appointment-public-page .appointment-brand-title {
    font-weight: 700;
    letter-spacing: 0.02em;
    margin-bottom: 0.75rem;
}

.appointment-public-page .appointment-brand-logo {
    width: 54px;
    height: 54px;
    border-radius: 10px;
    object-fit: contain;
    padding: 5px;
    flex-shrink: 0;
}

.appointment-public-page .appointment-steps {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.appointment-public-page .appointment-step-pill {
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.appointment-public-page .appointment-step-pane {
    display: none;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.appointment-public-page .appointment-step-pane.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.appointment-public-page .appointment-step-pane h5 .fas {
    margin-right: 0.35rem;
}

.appointment-public-page .form-group label {
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.appointment-public-page .form-control,
.appointment-public-page select.form-control {
    border-radius: 8px;
}

.appointment-public-page .appointment-next,
.appointment-public-page .appointment-prev {
    min-width: 130px;
}

.appointment-public-page textarea.form-control {
    min-height: 80px;
}

.appointment-public-page ul {
    list-style: none;
    padding-left: 0;
}

.appointment-public-page ul li label {
    font-weight: 500;
    cursor: pointer;
}

.appointment-public-page .appointment-portal-auth {
    border-radius: 10px;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
}

.appointment-public-theme-toggle {
    flex-shrink: 0;
}

@keyframes appointment-matricula-pulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.65;
    }
}

.appointment-public-page .appointment-matricula-loading-box {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.65rem 1rem;
    border-radius: 10px;
}

.appointment-public-page .appointment-matricula-loading-box .pos-loading-bar {
    width: 100%;
}

/* —— Tema oscuro —— */
html[data-theme='dark'] .appointment-public-page {
    background: linear-gradient(165deg, #0a0f1a 0%, #0f172a 40%, #111827 100%);
}

html[data-theme='dark'] .appointment-public-page .appointment-brand-shell {
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 14px;
    padding: 1.25rem 1.25rem 1rem;
    background: linear-gradient(180deg, #1e293b 0%, #172033 55%, #151c2c 100%);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

html[data-theme='dark'] .appointment-public-page .appointment-brand-title {
    color: #f1f5f9;
}

html[data-theme='dark'] .appointment-public-page .appointment-brand-title .fa-tools {
    color: #5eead4;
}

html[data-theme='dark'] .appointment-public-page .appointment-brand-logo {
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(15, 23, 42, 0.6);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

html[data-theme='dark'] .appointment-public-page .appointment-step-pill {
    border: 1px solid rgba(148, 163, 184, 0.35);
    color: #cbd5e1;
    background: rgba(15, 23, 42, 0.55);
}

html[data-theme='dark'] .appointment-public-page .appointment-step-pill.active {
    border-color: #22c55e;
    color: #fff;
    background: linear-gradient(90deg, #0d4a2c 0%, #15803d 50%, #166534 100%);
    font-weight: 600;
    box-shadow: 0 6px 20px rgba(34, 197, 94, 0.25);
}

html[data-theme='dark'] .appointment-public-page .appointment-step-pane h5.text-secondary {
    color: #e2e8f0 !important;
    border-bottom-color: rgba(148, 163, 184, 0.35) !important;
}

html[data-theme='dark'] .appointment-public-page .appointment-step-pane h5 .fas {
    color: #94a3b8;
}

html[data-theme='dark'] .appointment-public-page .form-group label {
    color: #e2e8f0;
}

html[data-theme='dark'] .appointment-public-page .form-control,
html[data-theme='dark'] .appointment-public-page select.form-control {
    background-color: #0f172a !important;
    color: #f8fafc !important;
    border: 1px solid rgba(148, 163, 184, 0.4) !important;
}

html[data-theme='dark'] .appointment-public-page .form-control:focus,
html[data-theme='dark'] .appointment-public-page select.form-control:focus {
    border-color: #38bdf8 !important;
    box-shadow: 0 0 0 0.15rem rgba(56, 189, 248, 0.25) !important;
}

html[data-theme='dark'] .appointment-public-page .form-control::placeholder {
    color: #64748b !important;
}

html[data-theme='dark'] .appointment-public-page .text-muted {
    color: #94a3b8 !important;
}

html[data-theme='dark'] .appointment-public-page ul li,
html[data-theme='dark'] .appointment-public-page .form-check-label,
html[data-theme='dark'] .appointment-public-page label[for^='id_document_type'] {
    color: #cbd5e1;
}

html[data-theme='dark'] .appointment-public-page input[type='radio'] {
    accent-color: #22c55e;
}

html[data-theme='dark'] .appointment-public-page .btn-primary.appointment-next,
html[data-theme='dark'] .appointment-public-page button[type='submit'].btn-primary {
    border-color: #0ea5e9 !important;
    background: linear-gradient(180deg, #0284c7 0%, #0369a1 100%) !important;
    color: #fff !important;
    font-weight: 600;
    border-radius: 10px;
}

html[data-theme='dark'] .appointment-public-page .btn-primary.appointment-next:hover,
html[data-theme='dark'] .appointment-public-page button[type='submit'].btn-primary:hover {
    filter: brightness(1.08);
    border-color: #38bdf8 !important;
}

html[data-theme='dark'] .appointment-public-page .btn-outline-secondary {
    color: #e2e8f0 !important;
    border-color: rgba(148, 163, 184, 0.5) !important;
    background: rgba(15, 23, 42, 0.4) !important;
    border-radius: 10px;
}

html[data-theme='dark'] .appointment-public-page .btn-outline-secondary:hover {
    background: rgba(51, 65, 85, 0.85) !important;
    color: #fff !important;
    border-color: #94a3b8 !important;
}

html[data-theme='dark'] .appointment-public-page .appointment-matricula-loading-box {
    border: 1px solid rgba(56, 189, 248, 0.35);
    background: linear-gradient(90deg, rgba(30, 58, 95, 0.55) 0%, rgba(30, 64, 90, 0.45) 100%);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

html[data-theme='dark'] .appointment-public-page .appointment-matricula-loading-box .text-primary {
    color: #7dd3fc !important;
}

html[data-theme='dark'] .appointment-public-page .alert-danger {
    background: rgba(127, 29, 29, 0.45);
    border: 1px solid rgba(248, 113, 113, 0.45);
    color: #fecaca;
}

html[data-theme='dark'] .appointment-public-page .border-top {
    border-top-color: rgba(148, 163, 184, 0.28) !important;
}

html[data-theme='dark'] .appointment-public-page select.form-control option {
    background: #1e293b;
    color: #f1f5f9;
}

html[data-theme='dark'] .appointment-public-page .text-danger {
    color: #fca5a5 !important;
}

html[data-theme='dark'] .appointment-public-page .appointment-portal-auth {
    border: 1px solid rgba(56, 189, 248, 0.35);
    background: rgba(15, 23, 42, 0.65);
}

html[data-theme='dark'] .appointment-public-page .appointment-portal-auth .btn-outline-light {
    border-color: rgba(148, 163, 184, 0.5);
    color: #e2e8f0;
}

html[data-theme='dark'] .appointment-public-page .modal-content {
    background: #1e293b;
    color: #f1f5f9;
    border: 1px solid rgba(148, 163, 184, 0.35);
}

html[data-theme='dark'] .appointment-public-page .modal-header,
html[data-theme='dark'] .appointment-public-page .modal-footer {
    border-color: rgba(148, 163, 184, 0.25);
}

html[data-theme='dark'] .appointment-public-page .close {
    color: #f1f5f9;
    text-shadow: none;
}

/* —— Tema claro —— */
html[data-theme='light'] .appointment-public-page {
    background: linear-gradient(165deg, #f0f4f8 0%, #e8eef5 45%, #dfe7f0 100%);
    color: #1e293b;
}

html[data-theme='light'] .appointment-public-page .appointment-brand-shell {
    border: 1px solid rgba(15, 23, 42, 0.1);
    border-radius: 14px;
    padding: 1.25rem 1.25rem 1rem;
    background: #fff;
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

html[data-theme='light'] .appointment-public-page .appointment-brand-title {
    color: #0f172a;
}

html[data-theme='light'] .appointment-public-page .appointment-brand-title .fa-tools {
    color: #0d9488;
}

html[data-theme='light'] .appointment-public-page .appointment-brand-logo {
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: #fff;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.08);
}

html[data-theme='light'] .appointment-public-page .appointment-step-pill {
    border: 1px solid rgba(15, 23, 42, 0.12);
    color: #475569;
    background: #f8fafc;
}

html[data-theme='light'] .appointment-public-page .appointment-step-pill.active {
    border-color: #16a34a;
    color: #fff;
    background: linear-gradient(90deg, #15803d 0%, #16a34a 50%, #22c55e 100%);
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(22, 163, 74, 0.25);
}

html[data-theme='light'] .appointment-public-page .appointment-step-pane h5.text-secondary {
    color: #334155 !important;
    border-bottom-color: rgba(15, 23, 42, 0.12) !important;
}

html[data-theme='light'] .appointment-public-page .appointment-step-pane h5 .fas {
    color: #64748b;
}

html[data-theme='light'] .appointment-public-page .form-group label {
    color: #1e293b;
}

html[data-theme='light'] .appointment-public-page .form-control,
html[data-theme='light'] .appointment-public-page select.form-control {
    background-color: #fff !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
}

html[data-theme='light'] .appointment-public-page .form-control:focus,
html[data-theme='light'] .appointment-public-page select.form-control:focus {
    border-color: #0284c7 !important;
    box-shadow: 0 0 0 0.15rem rgba(2, 132, 199, 0.2) !important;
}

html[data-theme='light'] .appointment-public-page .form-control::placeholder {
    color: #94a3b8 !important;
}

html[data-theme='light'] .appointment-public-page .text-muted {
    color: #64748b !important;
}

html[data-theme='light'] .appointment-public-page ul li,
html[data-theme='light'] .appointment-public-page .form-check-label,
html[data-theme='light'] .appointment-public-page label[for^='id_document_type'] {
    color: #334155;
}

html[data-theme='light'] .appointment-public-page input[type='radio'] {
    accent-color: #16a34a;
}

html[data-theme='light'] .appointment-public-page .btn-primary.appointment-next,
html[data-theme='light'] .appointment-public-page button[type='submit'].btn-primary {
    border-color: #0284c7 !important;
    background: linear-gradient(180deg, #0ea5e9 0%, #0284c7 100%) !important;
    color: #fff !important;
    font-weight: 600;
    border-radius: 10px;
}

html[data-theme='light'] .appointment-public-page .btn-outline-secondary {
    color: #475569 !important;
    border-color: #94a3b8 !important;
    background: #fff !important;
    border-radius: 10px;
}

html[data-theme='light'] .appointment-public-page .btn-outline-secondary:hover {
    background: #f1f5f9 !important;
    color: #0f172a !important;
}

html[data-theme='light'] .appointment-public-page .appointment-matricula-loading-box {
    border: 1px solid rgba(2, 132, 199, 0.25);
    background: #eff6ff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

html[data-theme='light'] .appointment-public-page .appointment-portal-auth {
    border: 1px solid rgba(2, 132, 199, 0.2);
    background: #f8fafc;
}

html[data-theme='light'] .appointment-public-page .appointment-portal-auth .btn-outline-light {
    border-color: #94a3b8;
    color: #334155;
    background: #fff;
}

html[data-theme='light'] .appointment-public-page .modal-content {
    background: #fff;
    color: #0f172a;
    border: 1px solid rgba(15, 23, 42, 0.12);
}

html[data-theme='light'] .appointment-public-page .modal-header,
html[data-theme='light'] .appointment-public-page .modal-footer {
    border-color: rgba(15, 23, 42, 0.1);
}

html[data-theme='light'] .appointment-public-page .close {
    color: #334155;
}

html[data-theme='light'] .appointment-public-page .rb-theme-toggle {
    border-color: rgba(15, 23, 42, 0.15);
    background: #f8fafc;
    color: #334155;
}

html[data-theme='light'] .appointment-public-page .rb-theme-toggle:hover {
    background: #e2e8f0;
    color: #0f172a;
}

/* Página «listo» tras reservar */
.appointment-public-done-page {
    min-height: 100vh;
    padding-bottom: 2rem;
}

.appointment-public-done-page .card-done-inner {
    border-radius: 14px;
    padding: 1.75rem;
}

.appointment-public-done-page .done-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

html[data-theme='dark'] .appointment-public-done-page {
    background: linear-gradient(165deg, #0a0f1a 0%, #0f172a 40%, #111827 100%);
}

html[data-theme='dark'] .appointment-public-done-page .card-done-inner {
    border: 1px solid rgba(148, 163, 184, 0.22);
    background: linear-gradient(180deg, #1e293b 0%, #172033 100%);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
}

html[data-theme='dark'] .appointment-public-done-page h3 {
    color: #f1f5f9;
}

html[data-theme='dark'] .appointment-public-done-page .text-muted {
    color: #94a3b8 !important;
}

html[data-theme='dark'] .appointment-public-done-page .alert-success {
    background: rgba(22, 101, 52, 0.45);
    border: 1px solid rgba(74, 222, 128, 0.45);
    color: #bbf7d0;
}

html[data-theme='dark'] .appointment-public-done-page .alert-danger {
    background: rgba(127, 29, 29, 0.45);
    border: 1px solid rgba(248, 113, 113, 0.45);
    color: #fecaca;
}

html[data-theme='dark'] .appointment-public-done-page .alert-info {
    background: rgba(30, 58, 138, 0.45);
    border: 1px solid rgba(147, 197, 253, 0.45);
    color: #dbeafe;
}

html[data-theme='dark'] .appointment-public-done-page .btn-outline-primary {
    color: #7dd3fc !important;
    border-color: rgba(56, 189, 248, 0.55) !important;
    background: rgba(15, 23, 42, 0.5) !important;
    border-radius: 10px;
}

html[data-theme='light'] .appointment-public-done-page {
    background: linear-gradient(165deg, #f0f4f8 0%, #e8eef5 45%, #dfe7f0 100%);
}

html[data-theme='light'] .appointment-public-done-page .card-done-inner {
    border: 1px solid rgba(15, 23, 42, 0.1);
    background: #fff;
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

html[data-theme='light'] .appointment-public-done-page h3 {
    color: #0f172a;
}
