.crg-wrap {
    --crg-bg: #fffaf0;
    --crg-panel: #ffffff;
    --crg-ink: #1f2933;
    --crg-muted: #52616b;
    --crg-border: #e4ded0;
    --crg-accent: #8a4b2a;
    --crg-soft: #f5ead7;
    color: var(--crg-ink);
    font-family: inherit;
    max-width: 1120px;
    margin: 0 auto;
    padding: 24px 12px;
}

.crg-wrap * { box-sizing: border-box; }

.crg-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px;
    align-items: stretch;
    background: linear-gradient(135deg, #fff4db, #f8efe4);
    border: 1px solid var(--crg-border);
    border-radius: 24px;
    padding: 32px;
    margin-bottom: 22px;
}

.crg-eyebrow {
    margin: 0 0 8px;
    color: var(--crg-accent);
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    font-size: 13px;
}

.crg-hero h1,
.crg-section-heading h2,
.crg-panel h2,
.crg-panel h3 {
    line-height: 1.15;
    margin-top: 0;
}

.crg-hero h1 { font-size: clamp(32px, 5vw, 52px); margin-bottom: 12px; }
.crg-lede { font-size: 18px; max-width: 760px; color: var(--crg-muted); margin: 0; }

.crg-hero-card {
    border-radius: 20px;
    background: rgba(255, 255, 255, .72);
    border: 1px solid rgba(138, 75, 42, .18);
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    min-height: 160px;
}

.crg-hero-card strong { font-size: 24px; }
.crg-hero-card span { color: var(--crg-muted); }

.crg-panel {
    background: var(--crg-panel);
    border: 1px solid var(--crg-border);
    border-radius: 22px;
    padding: 26px;
    margin-bottom: 22px;
    box-shadow: 0 10px 24px rgba(31, 41, 51, .06);
}

.crg-section-heading { max-width: 820px; margin-bottom: 18px; }
.crg-section-heading p:last-child { color: var(--crg-muted); }

.crg-form {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: end;
}

.crg-field { display: flex; flex-direction: column; gap: 7px; }
.crg-field-wide { grid-column: 1 / -1; }

.crg-field label,
.crg-checks legend {
    font-weight: 800;
}

.crg-field input,
.crg-field select,
.crg-field textarea {
    width: 100%;
    border: 1px solid #cfc7b8;
    border-radius: 14px;
    padding: 12px 14px;
    font: inherit;
    background: #fff;
}

.crg-field input:focus,
.crg-field select:focus,
.crg-field textarea:focus {
    outline: 3px solid rgba(138, 75, 42, .18);
    border-color: var(--crg-accent);
}

.crg-checks {
    border: 1px solid var(--crg-border);
    border-radius: 16px;
    padding: 14px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px 14px;
}

.crg-checks legend { padding: 0 6px; }
.crg-checks label { font-weight: 500; color: var(--crg-muted); }
.crg-checks input { margin-right: 6px; }

.crg-button {
    border: 0;
    border-radius: 999px;
    padding: 14px 22px;
    font-weight: 900;
    background: var(--crg-accent);
    color: #fff;
    cursor: pointer;
    justify-self: start;
}

.crg-button:hover,
.crg-button:focus { filter: brightness(.96); }

.crg-results:empty { display: none; }
.crg-results { margin-top: 22px; }

.crg-result-card {
    background: #fffaf0;
    border: 1px solid var(--crg-border);
    border-radius: 18px;
    padding: 20px;
    margin-top: 14px;
}

.crg-result-card h3 { margin-bottom: 8px; }
.crg-result-card ul { margin-bottom: 0; }
.crg-pill-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.crg-pill { border-radius: 999px; background: var(--crg-soft); padding: 6px 10px; font-size: 14px; font-weight: 700; }

.crg-grid-two {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.crg-steps { padding-left: 22px; }
.crg-steps li { margin-bottom: 12px; }

.crg-help-list p { margin: 0 0 14px; }
.crg-resource-box {
    background: #fffaf0;
    border: 1px solid var(--crg-border);
    border-radius: 16px;
    padding: 18px;
    margin-top: 16px;
}
.crg-resource-box ul { margin-bottom: 0; }

.crg-age-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.crg-age-cards div {
    background: #fffaf0;
    border: 1px solid var(--crg-border);
    border-radius: 16px;
    padding: 16px;
}
.crg-age-cards h3 { color: var(--crg-accent); margin-bottom: 8px; }
.crg-age-cards p { margin-bottom: 0; color: var(--crg-muted); }

@media (max-width: 850px) {
    .crg-hero,
    .crg-grid-two,
    .crg-form,
    .crg-age-cards {
        grid-template-columns: 1fr;
    }

    .crg-checks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 520px) {
    .crg-hero,
    .crg-panel { padding: 20px; border-radius: 18px; }
    .crg-checks { grid-template-columns: 1fr; }
}

.crg-result-card-ai {
    border-left: 4px solid currentColor;
}

.crg-ai-list {
    display: grid;
    gap: 1rem;
    margin: 1rem 0;
}

.crg-ai-item {
    padding: 1rem;
    border: 1px solid rgba(0,0,0,.12);
    border-radius: 12px;
    background: rgba(255,255,255,.72);
}

.crg-ai-item h4 {
    margin-top: 0;
}

.crg-ai-note {
    font-size: .92rem;
    opacity: .82;
}
