/* ========================================
   B2B One-Page Prequalification
   ======================================== */

.b2b-page {
    max-width: 720px;
    margin: 0 auto;
    padding: 20px 20px 60px;
}

/* ========================================
   Form section
   ======================================== */
.b2b-form-section {
    animation: b2bFadeIn 0.4s ease;
}

@keyframes b2bFadeIn {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========================================
   Header
   ======================================== */
.b2b-form-header {
    text-align: center;
    margin-bottom: 48px;
}

.b2b-form-header h1 {
    font-family: var(--font-title);
    font-size: clamp(1.8rem, 4.5vw, 2.6rem);
    font-weight: 800;
    line-height: 1.2;
    color: var(--text);
    margin-bottom: 16px;
    letter-spacing: 0.5px;
}

.b2b-form-header h1 .highlight {
    color: var(--primary);
}

.b2b-form-header p {
    font-family: var(--font-body);
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ========================================
   Question blocks
   ======================================== */
.b2b-question-block {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 20px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.b2b-question-block.has-error {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12);
}

.b2b-question-block h2 {
    font-family: var(--font-title);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 20px;
    display: flex;
    align-items: baseline;
    gap: 12px;
    line-height: 1.4;
}

.q-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--text);
    color: white;
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}

/* ========================================
   Radio options (pill style)
   ======================================== */
.b2b-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.b2b-option {
    cursor: pointer;
    display: block;
}

.b2b-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.option-pill {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-radius: 12px;
    background: white;
    border: 2px solid var(--border);
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text);
    transition: all 0.2s ease;
    line-height: 1.4;
}

.option-letter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #f0f0f0;
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 1.25rem;
    font-weight: 700;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.b2b-option:hover .option-pill {
    border-color: var(--border-strong);
    background: #fafafa;
}

.b2b-option:hover .option-letter {
    background: #e4e4e4;
}

.b2b-option input[type="radio"]:checked + .option-pill {
    border-color: var(--text);
    background: var(--text);
    color: white;
}

.b2b-option input[type="radio"]:checked + .option-pill .option-letter {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

/* Multi-select (checkbox) */
.b2b-option input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.b2b-options-multi .option-pill {
    position: relative;
    padding-right: 52px;
}

.b2b-options-multi .option-pill::after {
    content: '';
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    height: 22px;
    border: 2px solid var(--border-strong);
    border-radius: 6px;
    background: white;
    transition: all 0.2s ease;
}

.b2b-option input[type="checkbox"]:checked + .option-pill {
    border-color: var(--text);
    background: var(--text);
    color: white;
}

.b2b-option input[type="checkbox"]:checked + .option-pill .option-letter {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.b2b-option input[type="checkbox"]:checked + .option-pill::after {
    border-color: white;
    background: transparent;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
    background-size: 14px;
    background-repeat: no-repeat;
    background-position: center;
}

/* Hint text */
.b2b-hint {
    font-family: var(--font-body);
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-top: -12px;
    margin-bottom: 18px;
    font-style: italic;
}

/* ========================================
   Contact block
   ======================================== */
.b2b-contact-block {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 28px;
}

.b2b-contact-block h2 {
    font-family: var(--font-title);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 6px;
}

.b2b-contact-block p {
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.b2b-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.b2b-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.b2b-fields input,
.b2b-fields select {
    width: 100%;
    padding: 14px 20px;
    font-family: var(--font-body);
    font-size: 1rem;
    border: 2px solid var(--border);
    border-radius: 50px;
    background: white;
    color: var(--text);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.b2b-fields input:focus,
.b2b-fields select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.b2b-fields input::placeholder {
    color: var(--text-light);
}

.b2b-fields select {
    appearance: none;
    -webkit-appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, var(--text-light) 50%), linear-gradient(135deg, var(--text-light) 50%, transparent 50%);
    background-position: calc(100% - 22px) calc(50% + 1px), calc(100% - 16px) calc(50% + 1px);
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
}

/* ========================================
   Submit button
   ======================================== */
.b2b-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 18px 40px;
    background: var(--text);
    color: white;
    border: none;
    border-radius: 14px;
    font-family: var(--font-body);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.b2b-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

.b2b-submit:active {
    transform: translateY(0);
}

.b2b-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.b2b-submit .btn-arrow {
    transition: transform 0.2s ease;
}

.b2b-submit:hover .btn-arrow {
    transform: translateX(4px);
}

/* ========================================
   Privacy
   ======================================== */
.b2b-privacy {
    text-align: center;
    margin-top: 16px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ========================================
   Confirmation
   ======================================== */
.b2b-confirmation {
    text-align: center;
    padding: 60px 20px;
}

.b2b-confirmation .confirmation-check {
    margin-bottom: 24px;
}

.b2b-confirmation h2 {
    font-family: var(--font-title);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 12px;
}

.b2b-confirmation > p {
    font-family: var(--font-body);
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 480px;
    margin: 0 auto 40px;
}

.b2b-summary-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    text-align: left;
    max-width: 460px;
    margin: 0 auto;
}

.b2b-summary-title {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    background: #f0f0f0;
    padding: 4px 12px;
    border-radius: 6px;
    margin-bottom: 16px;
}

.b2b-summary-items {
    display: flex;
    flex-direction: column;
}

.b2b-summary-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.b2b-summary-row:last-child {
    border-bottom: none;
}

.b2b-summary-row strong {
    color: var(--text);
}

/* ========================================
   Calendly CTA Card
   ======================================== */
.b2b-calendly-card {
    display: flex;
    align-items: center;
    gap: 20px;
    background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
    border: 2px solid #ddd6fe;
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    margin: 0 auto 40px;
    max-width: 600px;
    text-align: left;
}

.calendly-icon {
    font-size: 2rem;
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    background: white;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.12);
}

.calendly-content {
    flex: 1;
}

.calendly-content h3 {
    font-family: var(--font-title);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 4px;
}

.calendly-content p {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.calendly-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--text);
    color: white;
    padding: 14px 24px;
    border-radius: 12px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.calendly-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18);
}

.calendly-btn span {
    transition: transform 0.2s ease;
}

.calendly-btn:hover span {
    transform: translateX(3px);
}

/* ========================================
   Programme Section (confirmation page)
   ======================================== */
.b2b-programme-section {
    text-align: left;
    margin-bottom: 40px;
}

.b2b-programme-title {
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-muted);
    margin-bottom: 20px;
    text-align: center;
}

.b2b-programme-stats {
    display: flex;
    background: #faf5ff;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 28px;
    text-align: center;
}

.b2b-programme-stats .stat-item {
    flex: 1;
}

.b2b-programme-stats .stat-item + .stat-item {
    border-left: 1px solid #e5e7eb;
}

.b2b-programme-stats .stat-item strong {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: #6366f1;
    font-family: var(--font-title);
}

.b2b-programme-stats .stat-item span {
    font-size: 0.75rem;
    color: #888;
    margin-top: 2px;
    display: block;
}

/* Module cards */
.b2b-module {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
}

.b2b-module-header {
    background: #ffffff;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.module-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.module-name {
    font-family: var(--font-title);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
}

.module-meta {
    font-size: 0.8rem;
    color: #888;
    margin-top: 2px;
}

.b2b-module-body {
    padding: 16px 20px;
}

.b2b-module-body .lesson {
    font-family: var(--font-body);
    font-size: 0.88rem;
    color: #555;
    line-height: 2;
}

/* Badges */
.badge {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    color: white;
    vertical-align: middle;
    margin-left: 4px;
}

.badge-purple { background: #6366f1; }
.badge-green { background: #10b981; }
.badge-amber { background: #f59e0b; }
.badge-violet { background: #8b5cf6; }
.badge-dark { background: #1a1a1a; }

/* Calendly bottom CTA */
.b2b-calendly-bottom {
    margin-top: 40px;
    text-align: center;
}

.calendly-btn-large {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--text);
    color: white;
    padding: 18px 40px;
    border-radius: 14px;
    font-family: var(--font-body);
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.calendly-btn-large:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

.calendly-btn-large span {
    transition: transform 0.2s ease;
}

.calendly-btn-large:hover span {
    transform: translateX(4px);
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 600px) {
    .b2b-page {
        padding: 12px 14px 40px;
    }

    .b2b-form-header {
        margin-bottom: 32px;
    }

    .b2b-form-header h1 {
        font-size: 1.9rem;
    }

    .b2b-form-header p {
        font-size: 1rem;
    }

    .b2b-question-block {
        padding: 24px 18px;
        margin-bottom: 14px;
    }

    .b2b-question-block h2 {
        font-size: 1.2rem;
    }

    .option-pill {
        padding: 12px 14px;
        gap: 10px;
        font-size: 0.9rem;
    }

    .option-letter {
        width: 32px;
        height: 32px;
        font-size: 1.1rem;
        border-radius: 6px;
    }

    .b2b-contact-block {
        padding: 24px 18px;
    }

    .b2b-field-row {
        grid-template-columns: 1fr;
    }

    .b2b-fields input,
    .b2b-fields select {
        padding: 14px 18px;
        font-size: 16px;
    }

    .b2b-submit {
        padding: 16px 32px;
        font-size: 1rem;
    }

    .b2b-confirmation {
        padding: 40px 16px;
    }

    .b2b-summary-card {
        padding: 20px;
    }

    .b2b-calendly-card {
        flex-direction: column;
        text-align: center;
        padding: 24px 20px;
    }

    .calendly-content h3 {
        text-align: center;
    }

    .calendly-content p {
        text-align: center;
    }

    .b2b-programme-stats {
        flex-wrap: wrap;
        gap: 12px;
    }

    .b2b-programme-stats .stat-item {
        min-width: 40%;
        border: none !important;
    }

    .b2b-programme-stats .stat-item + .stat-item {
        border-left: none;
    }

    .b2b-module-header {
        padding: 14px 16px;
    }

    .module-name {
        font-size: 1.1rem;
    }

    .b2b-module-body {
        padding: 14px 16px;
    }

    .calendly-btn-large {
        padding: 16px 28px;
        font-size: 1rem;
    }
}
