.coach-advice-result {
    display: grid;
    gap: 14px;
}

.coach-advice-result h4,
.coach-advice-result h5,
.coach-history-page h1,
.coach-history-page h2,
.coach-history-page h3 {
    margin: 0;
}

.coach-verdict {
    font-size: 1.05rem;
    line-height: 1.55;
    margin: 0;
}

.coach-action-card,
.coach-food-decision,
.coach-plan-review,
.coach-check-next,
.coach-current-plan,
.coach-trend-card {
    border: 1px solid rgba(125, 145, 190, .26);
    border-radius: 14px;
    padding: 14px 16px;
    background: rgba(14, 22, 42, .72);
}

.coach-action-card {
    border-color: rgba(96, 214, 155, .52);
    box-shadow: inset 3px 0 0 rgba(96, 214, 155, .85);
}

.coach-kicker {
    display: block;
    color: #69dba4;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .09em;
    margin-bottom: 5px;
}

.coach-action-card h5 {
    font-size: 1.12rem;
}

.coach-action-minimum {
    opacity: .88;
}

.coach-plan-review-completed { border-color: rgba(96, 214, 155, .48); }
.coach-plan-review-partial { border-color: rgba(255, 190, 80, .48); }
.coach-plan-review-skipped { border-color: rgba(255, 105, 105, .48); }

.coach-history-page {
    display: grid;
    gap: 18px;
}

.coach-history-title-row,
.coach-history-entry-actions {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.coach-history-entry-actions {
    align-items: center;
}

.coach-history-intro {
    max-width: 920px;
    margin: 0;
}

.coach-current-plan {
    display: grid;
    gap: 10px;
    border-color: rgba(96, 214, 155, .48);
}

.coach-current-plan-head,
.coach-history-entry > header,
.coach-plan-history-item > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.coach-status-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 4px 9px;
    background: rgba(96, 214, 155, .14);
    border: 1px solid rgba(96, 214, 155, .32);
    font-size: .75rem;
    white-space: nowrap;
}

.coach-trend-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.coach-trend-card span,
.coach-trend-card small {
    display: block;
}

.coach-trend-card b {
    display: block;
    font-size: 1.2rem;
    margin: 5px 0;
}

.coach-calculation-days {
    border: 1px solid rgba(125, 145, 190, .24);
    border-radius: 14px;
    padding: 14px;
    background: rgba(10, 17, 33, .48);
}

.coach-calculation-days > summary {
    cursor: pointer;
}

.coach-days-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    font-size: .86rem;
}

.coach-days-table th,
.coach-days-table td {
    padding: 8px 10px;
    border-bottom: 1px solid rgba(125, 145, 190, .16);
    text-align: left;
    white-space: nowrap;
}

.coach-days-table th {
    color: var(--muted);
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.coach-history-list,
.coach-plan-history-list {
    display: grid;
    gap: 14px;
}

.coach-history-entry,
.coach-plan-history-item {
    border: 1px solid rgba(125, 145, 190, .22);
    border-radius: 16px;
    padding: 16px;
    background: rgba(10, 17, 33, .62);
}

.coach-history-answer {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}

.coach-history-answer p,
.coach-current-plan p,
.coach-plan-history-item p {
    margin: 0;
    line-height: 1.5;
}

.coach-history-json-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.coach-history-json-grid pre {
    max-height: 520px;
    overflow: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

@media (max-width: 900px) {
    .coach-trend-grid,
    .coach-history-json-grid {
        grid-template-columns: 1fr;
    }

    .coach-history-title-row,
    .coach-history-entry-actions,
    .coach-current-plan-head,
    .coach-history-entry > header,
    .coach-plan-history-item > header {
        display: grid;
    }
}
