/* ============================================
   Schedule Discovery Call - Modal Styles
   ============================================
   Self-contained. Inherits CSS variables from styles.css.
   Used by both the modal (schedule-modal.js) and the dedicated
   schedule.html page (which renders the same form inline).
   ============================================ */

/* ===========================================
   BACKDROP + DIALOG
   =========================================== */
.sched-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    z-index: 9000;
    display: none;
    align-items: flex-start;
    justify-content: center;
    overflow-y: auto;
    padding: 60px 16px 40px;
}

.sched-backdrop.is-open {
    display: flex;
}

.sched-dialog {
    background: var(--bg-card, #1e293b);
    color: var(--text-primary, #f1f5f9);
    border: 1px solid var(--border-color, #334155);
    border-radius: var(--radius-lg, 12px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 540px;
    padding: 28px 28px 24px;
    position: relative;
    font-family: var(--font-primary, 'Inter', sans-serif);
}

.sched-dialog__close {
    position: absolute;
    top: 14px;
    right: 14px;
    background: transparent;
    border: 1px solid var(--border-light, #475569);
    color: var(--text-secondary, #cbd5e1);
    width: 32px;
    height: 32px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.sched-dialog__close:hover {
    background: var(--bg-tertiary, #334155);
    border-color: var(--color-primary, #2563eb);
}

.sched-dialog__title {
    font-family: var(--font-display, 'Plus Jakarta Sans', sans-serif);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary, #f1f5f9);
    margin: 0 0 6px;
    padding-right: 40px;
}

.sched-dialog__lede {
    color: var(--text-secondary, #cbd5e1);
    font-size: 0.95rem;
    line-height: 1.55;
    margin: 0 0 18px;
}

/* ===========================================
   FORM
   =========================================== */
.sched-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.sched-form__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sched-form__label {
    color: var(--text-primary, #f1f5f9);
    font-size: 0.9rem;
    font-weight: 500;
}

.sched-form__label .req {
    color: var(--color-error, #ef4444);
    margin-left: 2px;
}

.sched-form__input,
.sched-form__textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-input, #475569);
    border-radius: var(--radius-sm, 6px);
    font-size: 1rem;
    font-family: inherit;
    background: var(--bg-input, #1e293b);
    color: var(--text-primary, #f1f5f9);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    box-sizing: border-box;
}

.sched-form__textarea {
    min-height: 80px;
    resize: vertical;
}

.sched-form__input:focus,
.sched-form__textarea:focus {
    outline: none;
    border-color: var(--color-primary, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.sched-form__input::placeholder,
.sched-form__textarea::placeholder {
    color: var(--text-tertiary, #94a3b8);
    opacity: 0.7;
}

.sched-form__check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    color: var(--text-secondary, #cbd5e1);
    font-size: 0.92rem;
    line-height: 1.5;
}

.sched-form__check input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
    accent-color: var(--color-primary, #2563eb);
    cursor: pointer;
}

/* Honeypot — invisible to humans, visible to dumb bots. */
.sched-form__honeypot {
    position: absolute !important;
    left: -10000px !important;
    top: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
    display: none !important;
}

.sched-form__submit {
    margin-top: 4px;
    padding: 12px 18px;
    background: var(--color-primary, #2563eb);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm, 6px);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background 0.15s ease;
}

.sched-form__submit:hover:not(:disabled) {
    background: var(--color-primary-dark, #1d4ed8);
}

.sched-form__submit:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.sched-form__error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.35);
    color: #fecaca;
    padding: 10px 12px;
    border-radius: var(--radius-sm, 6px);
    font-size: 0.92rem;
    display: none;
}

.sched-form__error.is-visible {
    display: block;
}

/* ===========================================
   SUCCESS STATE
   =========================================== */
.sched-success {
    display: none;
    padding: 8px 0;
}

.sched-success.is-visible {
    display: block;
}

.sched-success__headline {
    font-family: var(--font-display, 'Plus Jakarta Sans', sans-serif);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary, #f1f5f9);
    margin: 0 0 10px;
}

.sched-success__body {
    color: var(--text-secondary, #cbd5e1);
    line-height: 1.6;
    margin: 0 0 16px;
}

.sched-success__phone {
    color: var(--color-primary-light, #3b82f6);
    font-weight: 600;
    text-decoration: none;
}

.sched-success__phone:hover {
    text-decoration: underline;
}

/* ===========================================
   INLINE PAGE VARIANT (schedule.html)
   ============================================
   Reuses the same form. Wraps it in a page-level card instead of a modal. */
.sched-page {
    max-width: 600px;
    margin: 0 auto;
    padding: 130px 20px 80px;
}

.sched-page .sched-dialog {
    box-shadow: none;
    border: 1px solid var(--border-color, #334155);
    padding: 32px 28px 28px;
    max-width: none;
}

.sched-page .sched-dialog__close {
    display: none;
}

/* ===========================================
   RESPONSIVE
   =========================================== */
@media (max-width: 600px) {
    .sched-backdrop {
        padding: 24px 12px 24px;
    }

    .sched-dialog {
        padding: 22px 18px 18px;
    }

    .sched-dialog__title {
        font-size: 1.2rem;
    }

    .sched-page {
        padding: 110px 16px 60px;
    }
}
