/* ============================================================
   Visit Prep Pack — Frontend Styles
   DCC brand palette: Navy #1B3A5C · Teal #0D8F8F · Gold #C9A84C
   ============================================================ */

/* ── Reset & base ─────────────────────────────────────────── */
#vpp-app *,
#vpp-app *::before,
#vpp-app *::after {
    box-sizing: border-box;
}

#vpp-app {
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #1a2332;
    -webkit-font-smoothing: antialiased;
}

/* ── Section visibility ───────────────────────────────────── */
.vpp-section {
    display: none;
}
.vpp-section.vpp-active {
    display: block;
}

/* ── Hero / Landing ───────────────────────────────────────── */
.vpp-hero {
    max-width: 780px;
    margin: 0 auto;
    padding: 48px 24px 64px;
    text-align: center;
}

.vpp-hero-badge {
    display: inline-block;
    background: #0D8F8F;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 4px 14px;
    border-radius: 20px;
    margin-bottom: 20px;
}

.vpp-hero-title {
    font-size: clamp(28px, 5vw, 46px);
    font-weight: 800;
    line-height: 1.15;
    color: #1B3A5C;
    margin: 0 0 16px;
    letter-spacing: -0.02em;
}

.vpp-accent {
    color: #0D8F8F;
}

.vpp-hero-subtitle {
    font-size: 18px;
    color: #4a5568;
    max-width: 580px;
    margin: 0 auto 36px;
    line-height: 1.7;
}

/* ── Generate card (no-form variant) ─────────────────────── */
.vpp-generate-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    max-width: 480px;
    margin: 0 auto 44px;
}

.vpp-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #1B3A5C;
    margin-bottom: 10px;
    text-align: left;
}

.vpp-input-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.vpp-input {
    flex: 1;
    min-width: 200px;
    height: 52px;
    padding: 0 16px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 15px;
    color: #1a2332;
    background: #f8fafc;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.vpp-input:focus {
    border-color: #0D8F8F;
    box-shadow: 0 0 0 3px rgba(13, 143, 143, 0.12);
    background: #fff;
}

.vpp-input-error {
    color: #c0392b;
    font-size: 13px;
    margin-top: 8px;
    min-height: 18px;
    text-align: left;
}

/* ── Buttons ──────────────────────────────────────────────── */
.vpp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 52px;
    padding: 0 24px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
    white-space: nowrap;
}
.vpp-btn:active {
    transform: translateY(1px);
}

.vpp-btn-primary {
    background: #C9A84C;
    color: #1B3A5C;
}
.vpp-btn-primary:hover {
    background: #b8953f;
    box-shadow: 0 4px 16px rgba(201, 168, 76, 0.35);
    color: #1B3A5C;
}
.vpp-btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.vpp-btn-secondary {
    background: transparent;
    border: 2px solid #1B3A5C;
    color: #1B3A5C;
}
.vpp-btn-secondary:hover {
    background: #1B3A5C;
    color: #fff;
}

.vpp-btn-teal {
    background: #0D8F8F;
    color: #fff;
}
.vpp-btn-teal:hover {
    background: #0a7a7a;
    color: #fff;
    box-shadow: 0 4px 16px rgba(13, 143, 143, 0.3);
}

.vpp-btn-large {
    height: 60px;
    padding: 0 36px;
    font-size: 17px;
    border-radius: 12px;
}

/* ── Trust row ────────────────────────────────────────────── */
.vpp-trust-row {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    margin-top: 16px;
}

.vpp-trust-item {
    font-size: 13px;
    color: #0D8F8F;
    font-weight: 600;
}

/* ── What you get grid ────────────────────────────────────── */
.vpp-what-you-get {
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
}

.vpp-section-label {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #94a3b8;
    margin-bottom: 20px;
    text-align: center;
}

.vpp-feature-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 480px) {
    .vpp-feature-grid {
        grid-template-columns: 1fr;
    }
}

.vpp-feature {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #e9ecf0;
}

.vpp-feature-icon {
    font-size: 22px;
    flex-shrink: 0;
    line-height: 1;
    margin-top: 2px;
}

.vpp-feature-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.vpp-feature-text strong {
    font-size: 14px;
    color: #1B3A5C;
    font-weight: 700;
}
.vpp-feature-text span {
    font-size: 13px;
    color: #64748b;
    line-height: 1.4;
}

/* ── Loading / Progress ───────────────────────────────────── */
#vpp-loading.vpp-active {
    display: flex;
    min-height: 400px;
    align-items: center;
    justify-content: center;
}

.vpp-loading-card {
    text-align: center;
    max-width: 480px;
    margin: 0 auto;
    padding: 48px 24px;
}

.vpp-spinner {
    width: 56px;
    height: 56px;
    margin: 0 auto 24px;
    position: relative;
}

.vpp-spinner-ring {
    width: 56px;
    height: 56px;
    border: 4px solid #e2e8f0;
    border-top-color: #0D8F8F;
    border-radius: 50%;
    animation: vpp-spin 0.9s linear infinite;
}

@keyframes vpp-spin {
    to { transform: rotate(360deg); }
}

.vpp-loading-title {
    font-size: 22px;
    font-weight: 700;
    color: #1B3A5C;
    margin: 0 0 8px;
}

.vpp-loading-step {
    font-size: 15px;
    color: #0D8F8F;
    font-weight: 500;
    margin: 0 0 24px;
    min-height: 22px;
    transition: opacity 0.3s;
}

.vpp-progress-bar-track {
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 28px;
}

.vpp-progress-bar-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #0D8F8F, #C9A84C);
    border-radius: 3px;
    transition: width 0.6s ease;
}

.vpp-progress-steps {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: left;
}

.vpp-step {
    font-size: 13px;
    color: #94a3b8;
    padding-left: 22px;
    position: relative;
    transition: color 0.3s;
}
.vpp-step::before {
    content: '○';
    position: absolute;
    left: 0;
    color: #cbd5e1;
    transition: color 0.3s;
}
.vpp-step.vpp-step-active {
    color: #1B3A5C;
    font-weight: 600;
}
.vpp-step.vpp-step-active::before {
    content: '◉';
    color: #0D8F8F;
}
.vpp-step.vpp-step-done {
    color: #0D8F8F;
}
.vpp-step.vpp-step-done::before {
    content: '✓';
    color: #0D8F8F;
}

/* ── Report / Results ─────────────────────────────────────── */
#vpp-results {
    max-width: 860px;
    margin: 0 auto;
    padding: 24px;
}

.vpp-report {
    background: #fff;
}

/* Report header */
.vpp-report-header {
    background: linear-gradient(135deg, #1B3A5C 0%, #0f2740 100%);
    color: #fff;
    padding: 40px 40px 32px;
    border-radius: 16px 16px 0 0;
    position: relative;
    overflow: hidden;
}

/* Explicitly override any theme h1/h2/p/span color rules inside the dark header */
.vpp-report-header h1,
.vpp-report-header h2,
.vpp-report-header h3,
.vpp-report-header p,
.vpp-report-header span,
.vpp-report-header div {
    color: #fff;
}

.vpp-report-home-name {
    color: #fff !important;
}

.vpp-report-eyebrow {
    color: #C9A84C !important;
}

.vpp-report-header::after {
    content: '';
    position: absolute;
    bottom: -30px;
    right: -30px;
    width: 180px;
    height: 180px;
    background: rgba(201, 168, 76, 0.08);
    border-radius: 50%;
}

.vpp-report-eyebrow {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #C9A84C;
    margin-bottom: 8px;
}

.vpp-report-home-name {
    font-size: clamp(22px, 4vw, 34px);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 6px;
    letter-spacing: -0.02em;
}

.vpp-report-meta {
    font-size: 13px;
    color: rgba(255,255,255,0.65);
    margin-bottom: 20px;
}

.vpp-report-meta a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
}
.vpp-report-meta a:hover {
    color: #C9A84C;
}

.vpp-report-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.vpp-tag {
    background: rgba(255,255,255,0.12);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.2);
}

.vpp-tag-gold {
    background: rgba(201, 168, 76, 0.2);
    border-color: #C9A84C;
    color: #C9A84C;
}

/* Report body */
.vpp-report-body {
    border: 1px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 16px 16px;
    overflow: hidden;
}

/* Report sections */
.vpp-report-section {
    padding: 32px 40px;
    border-bottom: 1px solid #f1f5f9;
}

.vpp-report-section:last-child {
    border-bottom: none;
}

.vpp-section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

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

.vpp-icon-blue   { background: #e8f0f8; }
.vpp-icon-teal   { background: #e0f5f5; }
.vpp-icon-gold   { background: #fdf6e3; }
.vpp-icon-purple { background: #f0e8fa; }
.vpp-icon-green  { background: #e8f8ec; }
.vpp-icon-navy   { background: #e8edf5; }

.vpp-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #1B3A5C;
    margin: 0;
    line-height: 1.2;
}

.vpp-section-subtitle {
    font-size: 13px;
    color: #94a3b8;
    margin: 2px 0 0;
}

/* Summary */
.vpp-summary-text {
    font-size: 16px;
    line-height: 1.75;
    color: #334155;
}

.vpp-visit-tip {
    margin-top: 20px;
    padding: 16px 20px;
    background: linear-gradient(135deg, #e0f5f5, #f0fafa);
    border-left: 3px solid #0D8F8F;
    border-radius: 0 8px 8px 0;
    font-size: 14px;
    color: #0a5a5a;
    font-style: italic;
}

.vpp-visit-tip strong {
    font-style: normal;
    color: #0D8F8F;
}

/* Facilities pills */
.vpp-facilities {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.vpp-pill {
    background: #f1f5f9;
    color: #475569;
    font-size: 13px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
}

/* Questions */
.vpp-questions-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vpp-question-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 16px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #edf2f7;
    transition: border-color 0.2s, background 0.2s;
}

.vpp-question-item:hover {
    background: #f0f7ff;
    border-color: #c3dafe;
}

.vpp-question-number {
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    background: #1B3A5C;
    color: #fff;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 1px;
}

.vpp-question-text {
    font-size: 15px;
    color: #334155;
    line-height: 1.5;
}

/* Checklist */
.vpp-checklist {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.vpp-checklist-category {
    border: 1px solid #e9ecf0;
    border-radius: 10px;
    overflow: hidden;
}

.vpp-checklist-category-header {
    background: #f8fafc;
    padding: 10px 16px;
    font-size: 13px;
    font-weight: 700;
    color: #1B3A5C;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border-bottom: 1px solid #e9ecf0;
}

.vpp-checklist-items {
    padding: 4px 0;
}

.vpp-checklist-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 16px;
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.15s;
    cursor: pointer;
}

.vpp-checklist-item:last-child {
    border-bottom: none;
}

.vpp-checklist-item:hover {
    background: #f8fafc;
}

.vpp-checkbox {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border: 2px solid #cbd5e1;
    border-radius: 4px;
    margin-top: 2px;
    transition: border-color 0.15s, background 0.15s;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: transparent;
}

.vpp-checklist-item.vpp-checked .vpp-checkbox {
    background: #0D8F8F;
    border-color: #0D8F8F;
    color: #fff;
}

.vpp-checklist-item-text {
    font-size: 14px;
    color: #334155;
    line-height: 1.5;
}

.vpp-checklist-item.vpp-checked .vpp-checklist-item-text {
    text-decoration: line-through;
    color: #94a3b8;
}

/* Notes section */
.vpp-notes-area {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.vpp-note-line {
    height: 40px;
    border-bottom: 1px solid #e2e8f0;
    position: relative;
}

.vpp-notes-prompt {
    font-size: 13px;
    color: #94a3b8;
    font-style: italic;
    margin-bottom: 12px;
}

/* Scoring section */
.vpp-scoring-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.vpp-scoring-table th {
    text-align: left;
    padding: 10px 12px;
    background: #1B3A5C;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
}

.vpp-scoring-table th:first-child { border-radius: 8px 0 0 0; }
.vpp-scoring-table th:last-child  { border-radius: 0 8px 0 0; }

.vpp-scoring-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #f1f5f9;
    color: #475569;
    vertical-align: top;
}

.vpp-scoring-table tr:nth-child(even) td {
    background: #f8fafc;
}

.vpp-scoring-table tr:last-child td {
    border-bottom: none;
}

.vpp-scoring-table .vpp-score-cell {
    text-align: center;
    width: 80px;
}

.vpp-score-box {
    display: inline-block;
    width: 36px;
    height: 36px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
}

/* CTA section */
.vpp-cta-section {
    background: linear-gradient(135deg, #0D8F8F 0%, #0a7070 100%);
    padding: 36px 40px;
    border-radius: 0 0 16px 16px;
    text-align: center;
    color: #fff;
}

.vpp-cta-title {
    font-size: 22px;
    font-weight: 800;
    margin: 0 0 8px;
    color: #fff;
}

.vpp-cta-subtitle {
    font-size: 15px;
    color: rgba(255,255,255,0.85);
    margin: 0 0 24px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.vpp-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #C9A84C;
    color: #1B3A5C;
    font-weight: 800;
    font-size: 16px;
    padding: 16px 32px;
    border-radius: 12px;
    text-decoration: none;
    transition: background 0.2s, transform 0.1s, box-shadow 0.2s;
    border: none;
    cursor: pointer;
}
.vpp-cta-btn:hover {
    background: #e0ba5e;
    color: #1B3A5C;
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(201, 168, 76, 0.4);
    text-decoration: none;
}

.vpp-cta-secondary {
    margin-top: 14px;
    font-size: 13px;
    color: rgba(255,255,255,0.7);
}

/* Report action bar */
.vpp-action-bar {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
    padding: 20px 40px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
}

.vpp-action-bar-label {
    font-size: 14px;
    color: #64748b;
    margin-right: 4px;
}

/* DCC footer in report */
.vpp-report-footer {
    padding: 16px 40px;
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
    border-top: 1px solid #f1f5f9;
}

.vpp-report-footer a {
    color: #0D8F8F;
    text-decoration: none;
}

/* Error state */
.vpp-error-card {
    max-width: 560px;
    margin: 48px auto;
    padding: 32px;
    background: #fff;
    border: 1px solid #fecaca;
    border-radius: 16px;
    border-left: 4px solid #ef4444;
    text-align: center;
}

.vpp-error-icon {
    font-size: 40px;
    margin-bottom: 12px;
}

.vpp-error-title {
    font-size: 20px;
    font-weight: 700;
    color: #1B3A5C;
    margin-bottom: 8px;
}

.vpp-error-msg {
    font-size: 15px;
    color: #64748b;
    margin-bottom: 24px;
    line-height: 1.6;
}

/* ── Print styles ─────────────────────────────────────────── */
@media print {
    #vpp-landing,
    #vpp-loading,
    .vpp-action-bar,
    .vpp-cta-section {
        display: none !important;
    }

    #vpp-results,
    #vpp-app {
        max-width: 100%;
        padding: 0;
    }

    .vpp-report-header {
        border-radius: 0;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .vpp-report-body {
        border-radius: 0;
    }

    .vpp-report-section {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .vpp-checklist-category {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .vpp-note-line {
        height: 36px;
    }

    .vpp-scoring-table {
        break-inside: avoid;
    }

    .vpp-report-footer {
        display: block !important;
    }

    a[href]::after {
        content: none !important;
    }
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 640px) {
    .vpp-hero {
        padding: 32px 16px 48px;
    }

    .vpp-input-card {
        padding: 24px 20px;
    }

    .vpp-input-row {
        flex-direction: column;
    }

    .vpp-btn {
        width: 100%;
    }

    .vpp-report-header,
    .vpp-report-section,
    .vpp-action-bar,
    .vpp-cta-section,
    .vpp-report-footer {
        padding-left: 20px;
        padding-right: 20px;
    }

    .vpp-question-item {
        padding: 12px;
    }
}
