* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background: #f8fafc;
    color: #0f172a;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 38px 28px 72px;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;
    margin-bottom: 28px;
}

.eyebrow {
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #6d28d9;
}

.header h1 {
    margin: 0 0 10px;
    font-size: 44px;
    font-weight: 850;
    color: #0f172a;
    letter-spacing: -0.04em;
}

.header p {
    margin: 0;
    max-width: 820px;
    font-size: 17px;
    line-height: 1.6;
    color: #64748b;
}

.header-link {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 16px;
    border-radius: 12px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 800;
    color: #334155;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.header-link:hover {
    color: #6d28d9;
}

.form-section,
.results-section {
    background: #ffffff;
    padding: 30px;
    border-radius: 24px;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.08);
    margin-bottom: 32px;
    border: 1px solid #e2e8f0;
}

.section-intro {
    margin-bottom: 24px;
}

.section-intro h2 {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 850;
    color: #0f172a;
    letter-spacing: -0.03em;
}

.section-intro p {
    margin: 0;
    max-width: 760px;
    font-size: 15px;
    line-height: 1.6;
    color: #64748b;
}

.input-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 24px;
}

.card-header {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 13px;
    margin-bottom: 22px;
}

.card-header h3 {
    margin: 0;
    font-size: 21px;
    font-weight: 850;
    color: #0f172a;
}

.card-header p,
.section-heading,
.section-heading p {
    display: none;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
    align-items: start;
}

.form-group {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.form-group label {
    margin-bottom: 7px;
    font-size: 13px;
    font-weight: 800;
    color: #334155;
}

.form-group input,
.form-group select {
    width: 100%;
    height: 46px;
    padding: 10px 12px;
    font-size: 15px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    background: #ffffff;
    color: #0f172a;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #7c3aed;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}

.form-group input[readonly] {
    background: #f8fafc;
    color: #475569;
}

.help-text {
    margin-top: 7px;
    font-size: 12px;
    line-height: 1.45;
    color: #64748b;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

button[type="submit"],
#premiumReportButton {
    padding: 14px 26px;
    font-size: 15px;
    font-weight: 850;
    color: #ffffff;
    background: #0f172a;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.18);
}

button[type="submit"]:hover,
#premiumReportButton:hover:not(:disabled) {
    background: #020617;
}

#premiumReportButton:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.result-card {
    background: #f8fafc;
    padding: 18px;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    min-height: 96px;
}

.result-card h3 {
    margin: 0 0 10px;
    font-size: 12.5px;
    font-weight: 800;
    color: #64748b;
}

.result-card p {
    margin: 0;
    font-size: 21px;
    font-weight: 850;
    color: #0f172a;
    word-break: break-word;
}

#results p {
    margin: 0;
}

.premium-report-card {
    margin-top: 28px;
    padding: 24px;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.10), rgba(255, 255, 255, 0.95));
    border: 1px solid #e9d5ff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
}

.premium-report-card h3 {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 850;
    color: #0f172a;
}

.premium-report-card p {
    margin: 0;
    max-width: 760px;
    font-size: 14px;
    line-height: 1.6;
    color: #64748b;
}

pre {
    white-space: pre-wrap;
    word-wrap: break-word;
    background: #0f172a;
    color: #f8fafc;
    padding: 16px;
    border-radius: 12px;
    overflow-x: auto;
}

@media (max-width: 1100px) {
    .form-grid,
    .results-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 850px) {
    .header {
        flex-direction: column;
    }

    .header h1 {
        font-size: 38px;
    }

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

    .premium-report-card {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 560px) {
    .container {
        padding: 28px 16px 48px;
    }

    .header h1 {
        font-size: 34px;
    }

    .form-section,
    .results-section {
        padding: 20px;
    }

    .input-card {
        padding: 18px;
    }

    .form-grid,
    .results-grid {
        grid-template-columns: 1fr;
    }

    .form-actions {
        justify-content: stretch;
    }

    button[type="submit"],
    #premiumReportButton {
        width: 100%;
    }
}