.ic-wrap {
    max-width: 760px;
    margin: 0 auto;
    padding: 1rem;
}

.ic-title {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    text-align: center;
}

.ic-sub {
    margin: 0 0 1.25rem;
    color: #4b5563;
    line-height: 1.55;
    text-align: center;
}

.ic-form {
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 1.25rem;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
}

.ic-field { margin-bottom: 1rem; }

.ic-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.ic-row-3 { grid-template-columns: 1fr 1fr 1fr; }

.ic-field label {
    display: block;
    font-weight: 700;
    font-size: 0.92rem;
    margin-bottom: 0.35rem;
}

.ic-input {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 8px;
    font: inherit;
    box-sizing: border-box;
    background: #fff;
}

.ic-input:focus {
    outline: 2px solid #b45309;
    outline-offset: 1px;
    border-color: #b45309;
}

.ic-btn {
    padding: 0.6rem 1.25rem;
    border: 1px solid #888;
    border-radius: 8px;
    background: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.ic-btn:hover { background: #f0f0f0; }

.ic-btn-primary {
    background: #b45309;
    border-color: #b45309;
    color: #fff;
    width: 100%;
    font-size: 1.02rem;
    padding: 0.7rem 1.5rem;
}

.ic-btn-primary:hover { background: #92400e; }

.ic-error {
    margin: 0.9rem 0 0;
    padding: 0.7rem 0.9rem;
    border-radius: 8px;
    background: #fdecea;
    color: #b3261e;
    border: 1px solid #f5c6c2;
}

.ic-error[hidden] { display: none; }

/* ------- results ------- */

.ic-results { margin-top: 1.5rem; }

.ic-sumcard {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.1rem 1.25rem;
    background: #fffbeb;
    margin-bottom: 1.5rem;
}

.ic-sum-over {
    font-weight: 700;
    font-size: 1.02rem;
    margin-bottom: 0.75rem;
}

.ic-sumgrid { display: grid; gap: 0.35rem; }

.ic-sumrow {
    display: flex;
    justify-content: space-between;
    font-size: 0.95rem;
    color: #44403c;
}

.ic-sumbig {
    font-size: 1.15rem;
    font-weight: 700;
    color: #111;
    border-top: 1px solid #e7e5e4;
    padding-top: 0.5rem;
    margin-top: 0.25rem;
}

.ic-h { font-size: 1.1rem; margin: 0 0 0.25rem; }

.ic-h-sub {
    font-weight: 400;
    font-size: 0.85rem;
    color: #6b7280;
}

.ic-letter {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.1rem 1.25rem;
    margin: 1rem 0;
    background: #fff;
}

.ic-letter.ic-best {
    border-color: #b45309;
    border-width: 2px;
    box-shadow: 0 2px 14px rgba(180, 83, 9, 0.12);
}

.ic-letter-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.6rem;
    margin-bottom: 0.8rem;
}

.ic-letter-name { font-weight: 700; font-size: 1.02rem; }

.ic-letter-when { font-size: 0.83rem; color: #6b7280; }

.ic-letter-badge {
    background: #b45309;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    white-space: nowrap;
}

.ic-subject-label {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
}

.ic-subject {
    font-weight: 600;
    margin: 0.15rem 0 0.7rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px dashed #e2e8f0;
}

.ic-body {
    white-space: pre-wrap;
    line-height: 1.65;
    font-size: 0.95rem;
    background: #fafaf9;
    border: 1px solid #f0ede8;
    border-radius: 8px;
    padding: 0.9rem 1rem;
    margin-bottom: 0.9rem;
}

.ic-note {
    font-size: 0.87rem;
    color: #57534e;
    line-height: 1.55;
    margin: 0.6rem 0 0;
}

.ic-disclaimer {
    font-size: 0.8rem;
    color: #78716c;
    border-top: 1px solid #e7e5e4;
    padding-top: 0.8rem;
    margin-top: 1.2rem;
    line-height: 1.5;
}

.ic-flash {
    margin-top: 1rem;
    padding: 0.6rem 0.9rem;
    background: #e9f7ee;
    border: 1px solid #bfe6c9;
    color: #166534;
    border-radius: 8px;
    font-size: 0.9rem;
}

.ic-flash[hidden] { display: none; }

@media (max-width: 560px) {
    .ic-field-row, .ic-row-3 { grid-template-columns: 1fr; }
}
