/* ==========================================================================
   Coaching Snapshot Assessment — Public Styles
   Plugin slug: coaching-snapshot-pre-program-assessment-s
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&display=swap');

/* ── Reset / Base ─────────────────────────────────────────────────────────── */
.csppas-wrap,
.csppas-result-wrap {
    font-family: 'Montserrat', 'Segoe UI', system-ui, sans-serif;
    color: #1a1a2e;
    -webkit-font-smoothing: antialiased;
}

/* ── Hero Banner ──────────────────────────────────────────────────────────── */
.csppas-hero {
    background: linear-gradient(135deg, #0f3460 0%, #16213e 100%);
    padding: 56px 0 48px;
    text-align: center;
    color: #fff;
}
.csppas-hero-inner {
    max-width: 1140px;
    width: 100%;
    margin: 0 auto;
    padding: 0 32px;
}
.csppas-title {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin: 0 0 12px;
    color: #fff;
}
.csppas-subtitle {
    font-size: 1rem;
    opacity: .85;
    margin: 0 0 36px;
}

/* ── Scale bar ─────────────────────────────────────────────────────────────── */
.csppas-scale-bar {
    display: flex;
    justify-content: center;
    gap: 4px;
    flex-wrap: wrap;
}
.csppas-scale-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    min-width: 60px;
    max-width: 90px;
    background: rgba(255,255,255,.08);
    border-radius: 8px;
    padding: 10px 6px;
    transition: background .2s;
}
.csppas-scale-item:hover { background: rgba(255,255,255,.15); }
.csppas-scale-num {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1;
}
.csppas-scale-label {
    font-size: .65rem;
    opacity: .75;
    text-align: center;
    margin-top: 4px;
    text-transform: uppercase;
    letter-spacing: .3px;
}

/* ── Sticky progress bar ──────────────────────────────────────────────────── */
.csppas-progress-sticky {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    border-bottom: 1px solid #e8eaf0;
    padding: 10px 0;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
}
.csppas-progress-inner {
    max-width: 1140px;
    width: 100%;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.csppas-progress-label {
    font-size: .75rem;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .5px;
    white-space: nowrap;
}
.csppas-progress-track {
    flex: 1;
    height: 6px;
    background: #e8eaf0;
    border-radius: 99px;
    overflow: hidden;
}
.csppas-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #6366f1);
    border-radius: 99px;
    transition: width .4s ease;
}
.csppas-progress-pct {
    font-size: .8rem;
    font-weight: 600;
    color: #3b82f6;
    white-space: nowrap;
    min-width: 60px;
    text-align: right;
}

/* ── Form ─────────────────────────────────────────────────────────────────── */
.csppas-form {
    max-width: 1140px;
    width: 100%;
    margin: 0 auto;
    padding: 0 32px 60px;
}

/* Name row */
.csppas-name-row {
    padding: 36px 0 24px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.csppas-name-label {
    font-weight: 600;
    font-size: .9rem;
    color: #374151;
}
.csppas-name-label .required { color: #ef4444; }
.csppas-name-input {
    max-width: 400px;
    padding: 12px 16px;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    font-size: 1rem;
    font-family: 'Montserrat', sans-serif;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}
.csppas-name-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}

/* Section header */
.csppas-section { margin-top: 28px; padding-top: 4px; }
.csppas-section-header {
    background: linear-gradient(135deg, #0f3460, #1a4a7a);
    color: #fff;
    padding: 14px 24px;
    border-radius: 10px;
    margin-bottom: 16px;
}
.csppas-section-header h2 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #fff;
}

/* Question card */
.csppas-question {
    background: #fff;
    border-bottom: 1px solid #e8eaf0;
    border-radius: 0;
    padding: 18px 0;
    margin-bottom: 0;
    transition: background .15s;
}
.csppas-question:last-child {
    border-bottom: none;
}
.csppas-question.answered {
    background: #f8fffe;
}
.csppas-question-text {
    font-size: .92rem;
    font-weight: 700;
    color: #0f3460;
    margin: 0 0 12px;
    line-height: 1.5;
}

/* Options — flat inline radio style */
.csppas-options {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 20px;
}
.csppas-option {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    padding: 4px 0;
    border: none;
    border-radius: 0;
    background: none;
    position: relative;
    white-space: nowrap;
    transition: color .15s;
}
.csppas-option input[type="radio"] {
    position: static;
    opacity: 1;
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
    accent-color: #0f3460;
    flex-shrink: 0;
}
.csppas-option-num {
    display: none;
}
.csppas-option-label {
    font-size: .82rem;
    font-weight: 500;
    color: #374151;
    margin-top: 0;
    text-transform: none;
    letter-spacing: 0;
}
.csppas-option:hover .csppas-option-label { color: #0f3460; }
.csppas-option.selected .csppas-option-label {
    color: #0f3460;
    font-weight: 700;
}

/* Submit row */
.csppas-submit-row {
    text-align: center;
    padding-top: 32px;
}
.csppas-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 16px;
    font-size: .9rem;
}
.csppas-btn-submit {
    background: linear-gradient(135deg, #0f3460, #3b82f6);
    color: #fff;
    border: none;
    padding: 16px 48px;
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Montserrat', sans-serif;
    border-radius: 10px;
    cursor: pointer;
    letter-spacing: .5px;
    transition: opacity .2s, transform .1s;
}
.csppas-btn-submit:hover { opacity: .9; transform: translateY(-1px); }
.csppas-btn-submit:active { transform: translateY(0); }
.csppas-btn-submit:disabled { opacity: .6; cursor: not-allowed; }

/* Overlay */
.csppas-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15,52,96,.75);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    gap: 20px;
}
.csppas-overlay p { font-size: 1.1rem; font-weight: 600; }
.csppas-spinner {
    width: 52px;
    height: 52px;
    border: 5px solid rgba(255,255,255,.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: csppas-spin .8s linear infinite;
}
@keyframes csppas-spin { to { transform: rotate(360deg); } }

/* ── Result Page ──────────────────────────────────────────────────────────── */
.csppas-result-wrap {
    max-width: 1140px;
    width: 100%;
    margin: 0 auto;
    padding: 0 32px 80px;
}
.csppas-result-header {
    background: linear-gradient(135deg, #0f3460 0%, #16213e 100%);
    color: #fff;
    padding: 52px 36px;
    border-radius: 14px;
    margin-bottom: 28px;
    margin-top: 36px;
}
.csppas-result-header h1 { font-size: 2rem; margin: 0 0 12px; color: #fff; }
.csppas-result-intro { font-size: .95rem; opacity: .85; margin: 0; max-width: 620px; line-height: 1.65; }

/* Overall score card */
.csppas-overall-card {
    background: #fff;
    border: 1.5px solid #e8eaf0;
    border-radius: 14px;
    padding: 32px;
    margin-bottom: 28px;
    display: flex;
    align-items: flex-start;
    gap: 32px;
    flex-wrap: wrap;
}
.csppas-overall-score {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
}
.csppas-score-circle {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
}
.csppas-score-circle.bar-green  { background: linear-gradient(135deg, #22c55e, #16a34a); }
.csppas-score-circle.bar-yellow { background: linear-gradient(135deg, #f59e0b, #d97706); }
.csppas-score-circle.bar-red    { background: linear-gradient(135deg, #ef4444, #dc2626); }
.csppas-score-num { font-size: 1.8rem; font-weight: 800; line-height: 1; }
.csppas-score-denom { font-size: .7rem; opacity: .8; }
.csppas-score-meta h2 { margin: 0 0 4px; font-size: 1.1rem; color: #1e293b; }
.csppas-pct { font-size: 2rem; font-weight: 800; color: #3b82f6; margin: 0; }

.csppas-section-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    flex: 1;
}
.csppas-pill {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 12px 16px;
    border-radius: 10px;
    min-width: 140px;
    flex: 1;
}
.csppas-pill.bar-green  { background: #f0fdf4; border: 1.5px solid #86efac; }
.csppas-pill.bar-yellow { background: #fffbeb; border: 1.5px solid #fde68a; }
.csppas-pill.bar-red    { background: #fef2f2; border: 1.5px solid #fecaca; }
.pill-label { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: #6b7280; }
.pill-score { font-size: 1.4rem; font-weight: 800; }
.bar-green  .pill-score { color: #16a34a; }
.bar-yellow .pill-score { color: #d97706; }
.bar-red    .pill-score { color: #dc2626; }

/* Detailed table */
.csppas-section-heading {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #0f3460;
    margin: 32px 0 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e8eaf0;
}
.csppas-table-scroll { overflow-x: auto; }
.csppas-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
}
.csppas-table th {
    background: #0f3460;
    color: #fff;
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.csppas-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}
.csppas-table tr:hover td { background: #f8fafc; }
.csppas-competency-cell {
    font-weight: 700;
    color: #0f3460;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .5px;
    vertical-align: top !important;
    padding-top: 16px !important;
    white-space: nowrap;
}
.csppas-score-cell { font-weight: 700; text-align: center; width: 60px; }
.csppas-bar-cell { width: 200px; min-width: 140px; }
.csppas-bar-track {
    height: 10px;
    background: #e8eaf0;
    border-radius: 99px;
    overflow: hidden;
}
.csppas-bar-fill {
    height: 100%;
    border-radius: 99px;
    transition: width .6s ease;
}
.csppas-bar-fill.bar-green  { background: linear-gradient(90deg, #22c55e, #16a34a); }
.csppas-bar-fill.bar-yellow { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.csppas-bar-fill.bar-red    { background: linear-gradient(90deg, #ef4444, #f87171); }

/* Legend table */
.csppas-legend-wrap { margin-top: 32px; }
.csppas-legend-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.csppas-legend-table th {
    background: #f8fafc;
    color: #374151;
    padding: 10px 14px;
    text-align: left;
    font-weight: 700;
    border-bottom: 2px solid #e2e8f0;
}
.csppas-legend-table td {
    padding: 12px 14px;
    border-bottom: 1px solid #f1f5f9;
    line-height: 1.5;
}
.csppas-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 6px;
    vertical-align: middle;
}
.csppas-dot.bar-green  { background: #22c55e; }
.csppas-dot.bar-yellow { background: #f59e0b; }
.csppas-dot.bar-red    { background: #ef4444; }

/* Notice */
.csppas-notice {
    background: #fef9c3;
    border: 1px solid #fde047;
    padding: 14px 18px;
    border-radius: 8px;
    font-size: .95rem;
    color: #713f12;
    margin: 24px 0;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
    .csppas-title { font-size: 1.5rem; }
    .csppas-scale-bar { gap: 3px; }
    .csppas-scale-item { min-width: 40px; padding: 7px 4px; }
    .csppas-scale-num { font-size: 1.1rem; }
    .csppas-options { gap: 4px 14px; flex-wrap: wrap; }
    .csppas-option { white-space: normal; }
    .csppas-option-label { font-size: .78rem; }
    .csppas-btn-submit { width: 100%; }
    .csppas-overall-card { flex-direction: column; }
    .csppas-score-circle { width: 76px; height: 76px; }
    .csppas-score-num { font-size: 1.4rem; }
    .csppas-form { padding: 0 16px 60px; }
    .csppas-hero-inner { padding: 0 16px; }
    .csppas-progress-inner { padding: 0 16px; }
    .csppas-result-wrap { padding: 0 16px 80px; }
}

/* ── Result Header: flex row for title + PDF button ──────────────────────── */
.csppas-result-header-inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}
.csppas-result-header-text {
    flex: 1;
    min-width: 0;
}

/* ── Download Your Report Button ─────────────────────────────────────────── */
.csppas-pdf-btn-wrap {
    flex-shrink: 0;
    display: flex;
    align-items: flex-start;
    padding-top: 6px;
}

.csppas-btn-pdf {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 13px 24px 13px 20px;
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
    color: #ffffff !important;
    border: none;
    border-radius: 12px;
    font-family: inherit;
    font-size: .88rem;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none !important;
    white-space: nowrap;
    letter-spacing: .2px;
    box-shadow: 0 4px 16px rgba(211, 84, 0, .40), 0 1px 4px rgba(0,0,0,.15);
    transition: transform .15s ease, box-shadow .15s ease, background .2s ease;
    -webkit-font-smoothing: antialiased;
    overflow: hidden;
}

/* Subtle inner shine */
.csppas-btn-pdf::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 50%;
    background: rgba(255, 255, 255, .10);
    border-radius: 12px 12px 0 0;
    pointer-events: none;
}

/* Icon container */
.csppas-btn-pdf-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: rgba(255, 255, 255, .18);
    border-radius: 8px;
    flex-shrink: 0;
    transition: background .15s ease;
}

.csppas-btn-pdf-icon svg {
    display: block;
    transition: transform .2s ease;
}

/* Text stack */
.csppas-btn-pdf-text {
    display: flex;
    flex-direction: column;
    line-height: 1;
    gap: 2px;
}
.csppas-btn-pdf-label {
    font-size: .72rem;
    font-weight: 500;
    opacity: .82;
    text-transform: uppercase;
    letter-spacing: .6px;
}
.csppas-btn-pdf-title {
    font-size: .95rem;
    font-weight: 800;
    letter-spacing: .1px;
}

/* Hover */
.csppas-btn-pdf:hover {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(211, 84, 0, .45), 0 2px 6px rgba(0,0,0,.18);
    text-decoration: none;
    color: #ffffff;
}
.csppas-btn-pdf:hover .csppas-btn-pdf-icon {
    background: rgba(255, 255, 255, .28);
}
.csppas-btn-pdf:hover .csppas-btn-pdf-icon svg {
    transform: translateY(2px);
}

/* Active */
.csppas-btn-pdf:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(211, 84, 0, .35);
}

/* ── Mobile ───────────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
    .csppas-result-header-inner {
        flex-direction: column;
        gap: 18px;
    }
    .csppas-pdf-btn-wrap {
        width: 100%;
    }
    .csppas-btn-pdf {
        width: 100%;
        justify-content: center;
        padding: 14px 24px;
    }
}