body {
    margin: 0;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(180deg, #f4fbfb 0%, #edf7f7 100%);
    color: #183b3b;
}

.page-shell {
    padding: 26px;
    max-width: 1500px;
    margin: 0 auto;
}

.app-header {
    background: linear-gradient(135deg, #ffffff 0%, #f6ffff 100%);
    border-radius: 22px;
    padding: 28px 32px;
    box-shadow: 0 8px 28px rgba(21, 101, 112, 0.10);
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.header-text {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.app-title {
    margin: 0;
    color: #0f5257;
    font-size: 46px;
    font-weight: 800;
    letter-spacing: -0.8px;
}

.app-subtitle {
    margin: 0;
    color: #4b7275;
    font-size: 17px;
}

.app-logo {
    width: 108px;
    height: 108px;
    object-fit: cover;
    object-position: center;
    border-radius: 20px;
    background: white;
    padding: 2px;
    box-shadow: 0 8px 22px rgba(22, 138, 173, 0.16);
}

.main-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 22px;
    align-items: start;
}

.left-column,
.right-column {
    min-width: 0;
}

.pretty-container {
    background: white;
    border-radius: 20px;
    padding: 26px;
    box-shadow: 0 6px 24px rgba(21, 101, 112, 0.08);
}

.sticky-results {
    position: sticky;
    top: 20px;
}

.panel-title {
    color: #146c72;
    margin-top: 0;
    margin-bottom: 6px;
    font-size: 34px;
    font-weight: 800;
}

.panel-subtitle {
    color: #5c8083;
    margin-top: 0;
    margin-bottom: 24px;
    line-height: 1.6;
}

.section-heading {
    color: #1b7f85;
    border-left: 5px solid #49b6bb;
    padding-left: 10px;
    margin-top: 28px;
    margin-bottom: 14px;
    font-size: 22px;
}

.form-grid {
    display: grid;
    gap: 16px;
}

.form-grid.two-col {
    grid-template-columns: 1fr 1fr;
}

.form-grid.three-col {
    grid-template-columns: 1fr 1fr 1fr;
}

.field-group {
    display: flex;
    flex-direction: column;
}

.field-label {
    font-weight: 700;
    color: #225b5f;
    margin-bottom: 8px;
    display: block;
    font-size: 15px;
}

.form-input {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #cfe7e7;
    border-radius: 12px;
    padding: 12px 14px;
    min-height: 46px;
    font-size: 15px;
    background: #fbffff;
    transition: 0.2s ease;
}

.form-input:focus {
    outline: none;
    border-color: #35b8bb;
    box-shadow: 0 0 0 3px rgba(53, 184, 187, 0.12);
}

button,
.predict-button {
    background: linear-gradient(90deg, #168aad, #1db9c3);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(22, 138, 173, 0.25);
    transition: 0.2s ease-in-out;
    padding: 14px 22px;
    font-size: 16px;
    width: 100%;
    margin-top: 24px;
}

button:hover,
.predict-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(22, 138, 173, 0.35);
}

.results-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 24px;
}

.results-card {
    background: #ffffff;
    border-left: 6px solid #20b2aa;
    border-radius: 16px;
    padding: 18px 18px;
    box-shadow: 0 4px 14px rgba(32, 178, 170, 0.08);
}

.summary-card {
    min-height: 96px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.card-title {
    font-size: 13px;
    font-weight: 800;
    color: #2a6f73;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.7px;
}

.card-value {
    font-size: 20px;
    font-weight: 800;
    color: #173f43;
    line-height: 1.45;
}

.explanation-box {
    background: #f8ffff;
    border: 1px solid #c9ecec;
    border-radius: 16px;
    padding: 20px;
    color: #204b4f;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.03);
    margin-bottom: 24px;
    font-size: 15px;
}

.explanation-section {
    margin-bottom: 18px;
}

.explanation-section:last-child {
    margin-bottom: 0;
}

.explanation-heading {
    color: #176d73;
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 800;
}

.explanation-paragraph {
    color: #204b4f;
    line-height: 1.75;
    margin: 0;
}

.explanation-paragraph p {
    margin: 0;
}

.explanation-paragraph strong {
    color: #173f43;
    font-weight: 800;
}

.references-box {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.reference-card {
    background: #fafdfe;
    border: 1px solid #d6efef;
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 3px 10px rgba(18, 94, 99, 0.04);
}

.reference-badge {
    display: inline-block;
    background: #e8f8f8;
    color: #15656a;
    font-size: 12px;
    font-weight: 800;
    padding: 6px 10px;
    border-radius: 999px;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.reference-title {
    font-size: 16px;
    font-weight: 700;
    color: #163f43;
    margin-bottom: 6px;
    line-height: 1.5;
}

.reference-meta {
    color: #5d7b7e;
    font-size: 13px;
    margin-bottom: 8px;
}

.reference-link {
    color: #0b7285;
    font-weight: 700;
    text-decoration: none;
}

.reference-link:hover {
    text-decoration: underline;
}

@media (max-width: 1200px) {
    .main-grid {
        grid-template-columns: 1fr;
    }

    .sticky-results {
        position: static;
    }
}

@media (max-width: 768px) {
    .page-shell {
        padding: 16px;
    }

    .app-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .app-logo {
        width: 82px;
        height: 82px;
    }

    .app-title {
        font-size: 38px;
    }

    .form-grid.two-col,
    .form-grid.three-col {
        grid-template-columns: 1fr;
    }

    .card-value {
        font-size: 18px;
    }

    .explanation-heading {
        font-size: 17px;
    }
}