/* ===================================
   Calculator Page Styles
   =================================== */

/* Main Content - Modern Design */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 4rem 1.5rem 5rem;
    min-height: calc(100vh - 200px);
}

.calculator-content {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 32px;
    padding: 4rem 3.5rem;
    box-shadow:
        0 32px 80px rgba(15, 23, 42, 0.1),
        0 16px 40px rgba(15, 23, 42, 0.05);
    border: 2px solid rgba(226, 232, 240, 0.3);
    position: relative;
    overflow: hidden;
}

.calculator-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, #0ea5e9, #38bdf8, #7dd3fc, #38bdf8, #0ea5e9);
    background-size: 200% 100%;
    animation: shimmer 3s linear infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.back-link {
    display: inline-block;
    color: #0ea5e9;
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 2rem;
    transition: color 0.2s ease;
}

.back-link:hover {
    color: #0284c7;
}

.intro-text {
    font-size: 1.125rem;
    color: #64748b;
    margin-bottom: 2.5rem;
    font-weight: 400;
}

.caveat-text {
    font-size: 0.9375rem;
    color: #64748b;
    font-style: italic;
    margin-top: -1.5rem;
    margin-bottom: 2.5rem;
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, rgba(254, 243, 199, 0.3) 0%, rgba(253, 230, 138, 0.2) 100%);
    border-left: 3px solid #f59e0b;
    border-radius: 0.375rem;
    line-height: 1.6;
}

.caveat-text strong {
    color: #ea580c;
    font-style: normal;
}

/* Form Styles - Modern Bold Design */
.calculator-form {
    margin-bottom: 3rem;
}

.form-section {
    margin-bottom: 3.5rem;
    padding: 3rem 2.5rem;
    background: linear-gradient(135deg, rgba(240, 249, 255, 0.5) 0%, rgba(255, 255, 255, 0.8) 100%);
    border-radius: 24px;
    border: 2px solid rgba(14, 165, 233, 0.1);
    position: relative;
    overflow: visible;
    box-shadow: 0 8px 32px rgba(14, 165, 233, 0.08);
    transition: all 0.3s ease;
}

.form-section:hover {
    border-color: rgba(14, 165, 233, 0.2);
    box-shadow: 0 12px 40px rgba(14, 165, 233, 0.12);
}

.form-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #0ea5e9 0%, #38bdf8 50%, #7dd3fc 100%);
    border-radius: 24px 24px 0 0;
}

.form-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #0c4a6e;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.form-section-title::before {
    content: '';
    width: 6px;
    height: 32px;
    background: linear-gradient(180deg, #0ea5e9 0%, #38bdf8 100%);
    border-radius: 3px;
}

/* Tooltip Styles */
.label-with-tooltip {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tooltip-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.tooltip-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    background: #94a3b8;
    color: white;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: help;
    transition: all 0.2s ease;
    border: 2px solid rgba(148, 163, 184, 0.3);
}

.tooltip-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(148, 163, 184, 0.4);
}

.tooltip-content {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background: rgba(30, 41, 59, 0.97);
    backdrop-filter: blur(10px);
    color: white;
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    line-height: 1.5;
    width: 280px;
    max-width: 90vw;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    z-index: 9999;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.tooltip-content::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: rgba(30, 41, 59, 0.95);
}

.tooltip-wrapper:hover .tooltip-content {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-12px);
}

.form-group {
    margin-bottom: 2rem;
    text-align: left;
    position: relative;
}

.form-group label {
    display: block;
    font-weight: 500;
    color: #334155;
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 10;
    font-size: 1rem;
}

.form-group select {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.5rem;
    font-size: 1rem;
    color: #334155;
    background-color: #ffffff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    font-family: inherit;
}

.form-group select:focus {
    outline: none;
    border-color: #0ea5e9;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

/* Radio Button Styles */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.radio-option {
    position: relative;
    display: flex;
    align-items: flex-start;
    padding: 1.125rem 1rem;
    border: 1px solid rgba(226, 232, 240, 0.6);
    border-radius: 0.25rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(4px);
}

.radio-option:hover {
    border-color: #cbd5e1;
    background-color: #f8fafc;
}

.radio-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.radio-option input[type="radio"]:checked ~ .radio-label {
    font-weight: 600;
}

.radio-option input[type="radio"]:checked ~ .radio-custom {
    border-color: #0ea5e9;
    background-color: #0ea5e9;
}

.radio-option input[type="radio"]:checked ~ .radio-custom::after {
    opacity: 1;
}

.radio-option.selected {
    border-color: #0ea5e9;
    background: linear-gradient(135deg, rgba(240, 249, 255, 0.9) 0%, rgba(224, 242, 254, 0.7) 100%);
    box-shadow: 0 2px 8px rgba(14, 165, 233, 0.15);
}

.radio-custom {
    position: relative;
    width: 20px;
    height: 20px;
    min-width: 20px;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    background-color: #ffffff;
    transition: all 0.2s ease;
    margin-right: 0.75rem;
    margin-top: 0.125rem;
}

.radio-custom::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #ffffff;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.radio-content {
    flex: 1;
}

.radio-label {
    display: block;
    font-size: 1rem;
    color: #334155;
    line-height: 1.5;
    transition: font-weight 0.2s ease;
}

.radio-helper {
    display: block;
    font-size: 0.875rem;
    color: #64748b;
    margin-top: 0.25rem;
    line-height: 1.4;
}

/* Slider Styles - Modern Bold Design */
.slider-container {
    padding: 1.5rem 0.5rem;
}

.slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 12px;
    border-radius: 12px;
    background: linear-gradient(to right, #e0f2fe 0%, #0ea5e9 25%, #38bdf8 50%, #0ea5e9 75%, #e0f2fe 100%);
    outline: none;
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.slider:hover {
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.15);
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0ea5e9 0%, #38bdf8 100%);
    cursor: grab;
    border: 4px solid #ffffff;
    box-shadow:
        0 4px 12px rgba(14, 165, 233, 0.4),
        0 2px 4px rgba(14, 165, 233, 0.2);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    box-shadow:
        0 8px 20px rgba(14, 165, 233, 0.5),
        0 4px 8px rgba(14, 165, 233, 0.3);
}

.slider::-webkit-slider-thumb:active {
    cursor: grabbing;
    transform: scale(1.05);
}

.slider::-moz-range-thumb {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0ea5e9 0%, #38bdf8 100%);
    cursor: grab;
    border: 4px solid #ffffff;
    box-shadow:
        0 4px 12px rgba(14, 165, 233, 0.4),
        0 2px 4px rgba(14, 165, 233, 0.2);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.slider::-moz-range-thumb:hover {
    transform: scale(1.15);
    box-shadow:
        0 8px 20px rgba(14, 165, 233, 0.5),
        0 4px 8px rgba(14, 165, 233, 0.3);
}

.slider::-moz-range-thumb:active {
    cursor: grabbing;
    transform: scale(1.05);
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.75rem;
    padding: 0 0.25rem;
}

.slider-labels span {
    font-size: 0.8125rem;
    color: #64748b;
    font-weight: 500;
    text-align: center;
    flex: 1;
}

.slider-labels-4 span {
    font-size: 0.75rem;
}

.slider-value {
    text-align: center;
    font-size: 1.125rem;
    font-weight: 600;
    color: #0ea5e9;
    margin-top: 1rem;
    padding: 0.5rem;
    background-color: #f0f9ff;
    border-radius: 0.5rem;
}

.slider-helper {
    text-align: center;
    margin-top: 0.5rem;
    font-size: 0.8125rem;
    color: #64748b;
    font-style: italic;
    line-height: 1.4;
    padding: 0 1rem;
}

/* Error Message Styles */
.error-message {
    display: none;
    color: #dc2626;
    font-size: 0.875rem;
    margin-top: 0.5rem;
    font-weight: 500;
}

.form-group.error .error-message {
    display: block;
}

.form-group.error select {
    border-color: #dc2626;
}

.form-group.error .radio-option {
    border-color: #fecaca;
}

/* Loading State */
.loading-state {
    text-align: center;
    padding: 3rem 1rem;
    animation: fadeIn 0.3s ease-in;
}

.loading-spinner {
    display: inline-block;
    width: 50px;
    height: 50px;
    border: 4px solid #e2e8f0;
    border-top: 4px solid #0ea5e9;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    margin-top: 1.5rem;
    font-size: 1.125rem;
    color: #64748b;
    font-weight: 500;
}

.submit-button {
    width: 100%;
    background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
    color: white;
    font-size: 1.125rem;
    font-weight: 600;
    padding: 1rem 2rem;
    border: none;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(14, 165, 233, 0.25), 0 2px 4px rgba(14, 165, 233, 0.15);
    position: relative;
    overflow: hidden;
}

.submit-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.submit-button:hover::before {
    left: 100%;
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(14, 165, 233, 0.35), 0 4px 8px rgba(14, 165, 233, 0.2);
}

.submit-button:active {
    transform: translateY(0);
}

/* Results Section */
.results-section {
    border-top: none;
    padding-top: 2.5rem;
    margin-top: 2.5rem;
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.results-section h2 {
    font-size: 2.5rem;
    font-weight: 800;
    color: #0c4a6e;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
    line-height: 1.2;
    text-align: center;
}

.results-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.result-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 2px solid transparent;
    border-radius: 24px;
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow:
        0 20px 60px rgba(15, 23, 42, 0.08),
        0 8px 24px rgba(15, 23, 42, 0.04);
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
}

.result-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.05) 0%, rgba(56, 189, 248, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.5s;
    border-radius: 24px;
    z-index: 0;
}

.result-card::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #38bdf8, #7dd3fc, #bae6fd, #7dd3fc, #38bdf8);
    background-size: 300% 300%;
    border-radius: 24px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.5s;
    animation: gradientRotate 3s ease infinite;
}

@keyframes gradientRotate {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.result-card:hover::before {
    opacity: 1;
}

.result-card:hover::after {
    opacity: 1;
}

.result-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow:
        0 32px 80px rgba(14, 165, 233, 0.2),
        0 16px 40px rgba(15, 23, 42, 0.12);
    border-color: transparent;
}

.result-card > * {
    position: relative;
    z-index: 1;
}

.result-card-label {
    font-size: 0.875rem;
    font-weight: 700;
    color: #0284c7;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
}

.result-card-percentage {
    font-size: 3.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, #0c4a6e 0%, #0284c7 50%, #0ea5e9 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.result-card-description {
    font-size: 1rem;
    color: #64748b;
    line-height: 1.6;
    font-weight: 500;
}

.results-explanation {
    background: linear-gradient(135deg, rgba(240, 249, 255, 0.5) 0%, rgba(255, 255, 255, 0.8) 100%);
    border-radius: 24px;
    padding: 2rem 2.5rem;
    margin-bottom: 2.5rem;
    border: 2px solid rgba(14, 165, 233, 0.1);
    box-shadow: 0 8px 32px rgba(14, 165, 233, 0.08);
}

.results-explanation p {
    font-size: 1.125rem;
    color: #475569;
    line-height: 1.8;
    margin: 0;
    text-align: center;
}

.reset-button {
    display: inline-block;
    background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
    color: white;
    font-size: 1.125rem;
    font-weight: 700;
    padding: 1.125rem 2.75rem;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 8px 24px rgba(14, 165, 233, 0.3),
        0 2px 8px rgba(14, 165, 233, 0.2),
        inset 0 -2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.02em;
}

.reset-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.6s;
}

.reset-button:hover::before {
    left: 100%;
}

.reset-button:hover {
    color: white !important;
    transform: translateY(-4px) scale(1.02);
    box-shadow:
        0 16px 40px rgba(14, 165, 233, 0.4),
        0 8px 16px rgba(14, 165, 233, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.1);
}

.reset-button:active {
    transform: translateY(-2px) scale(0.98);
}

/* Next Steps Section */
.next-steps {
    margin-top: 3rem;
    text-align: center;
}

.next-steps h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #0c4a6e;
    margin-bottom: 0.75rem;
    letter-spacing: -0.02em;
}

.next-steps > p {
    font-size: 1.125rem;
    color: #64748b;
    margin-bottom: 2rem;
}

.next-steps-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    align-items: center;
}

.next-steps-buttons .btn {
    flex: 1;
    min-width: 200px;
    max-width: 280px;
}

.next-steps-buttons .btn-primary {
    background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
    color: white;
    font-size: 1.125rem;
    font-weight: 700;
    padding: 1.125rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow:
        0 8px 24px rgba(14, 165, 233, 0.3),
        0 2px 8px rgba(14, 165, 233, 0.2),
        inset 0 -2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.02em;
    display: inline-block;
    text-align: center;
}

.next-steps-buttons .btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.6s;
}

.next-steps-buttons .btn-primary:hover::before {
    left: 100%;
}

.next-steps-buttons .btn-primary:hover {
    color: white !important;
    transform: translateY(-4px) scale(1.02);
    box-shadow:
        0 16px 40px rgba(14, 165, 233, 0.4),
        0 8px 16px rgba(14, 165, 233, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.1);
}

.next-steps-buttons .btn-primary:active {
    transform: translateY(-2px) scale(0.98);
}

.next-steps-buttons .reset-button {
    flex: 0 0 auto;
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    color: #334155;
    border: 2px solid #cbd5e1;
    font-weight: 600;
    min-width: 150px;
}

.next-steps-buttons .reset-button:hover {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    color: #1e293b !important;
    border-color: #94a3b8;
}

/* Research Section */
.research-section {
    margin-top: 3rem;
    padding: 2rem;
    background-color: #f8fafc;
    border-radius: 0.75rem;
    border: 1px solid #e2e8f0;
}

.research-section h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.research-section p {
    font-size: 0.9375rem;
    color: #475569;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.research-section a {
    color: #0ea5e9;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.research-section a:hover {
    color: #0284c7;
    text-decoration: underline;
}

/* Future Features List */
.future-features {
    background-color: #f0f9ff;
    border-left: 4px solid #0ea5e9;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin: 2rem 0;
}

.future-features h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #0284c7;
    margin-bottom: 1rem;
}

.future-features ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.future-features li {
    position: relative;
    padding-left: 1.75rem;
    margin-bottom: 0.75rem;
    color: #334155;
    line-height: 1.6;
}

.future-features li:last-child {
    margin-bottom: 0;
}

.future-features li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: #0ea5e9;
    font-weight: 700;
}

/* Disclaimer */
.disclaimer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

.disclaimer p {
    font-size: 0.875rem;
    color: #64748b;
    font-style: italic;
    line-height: 1.6;
    text-align: center;
    margin: 0;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .tooltip-content {
        width: 240px;
        font-size: 0.8125rem;
        padding: 0.625rem 0.875rem;
    }

    .intro-text {
        font-size: 1rem;
    }

    .calculator-content {
        padding: 2.5rem 1.5rem;
    }

    .container {
        padding: 2rem 1rem 3rem;
    }

    .form-section {
        padding: 2rem 1.5rem;
        margin-bottom: 2.5rem;
    }

    .submit-button {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .intro-text {
        font-size: 0.9375rem;
    }

    .calculator-content {
        padding: 2rem 1.25rem;
    }

    .container {
        padding: 1.5rem 0.75rem 2.5rem;
    }

    .form-section {
        padding: 1.5rem 1rem;
        margin-bottom: 2rem;
    }

    .form-section-title {
        font-size: 1.125rem;
    }

    .form-group label {
        font-size: 0.9375rem;
    }

    .form-group select {
        font-size: 0.9375rem;
        padding: 0.75rem 0.875rem;
    }

    .radio-option {
        padding: 1rem 0.875rem;
    }

    .radio-label {
        font-size: 0.9375rem;
        line-height: 1.5;
    }

    .radio-helper {
        font-size: 0.8125rem;
        margin-top: 0.375rem;
    }

    .radio-group {
        gap: 0.875rem;
    }

    .results-section h2 {
        font-size: 1.5rem;
    }

    .result-card {
        padding: 1.25rem;
    }

    .result-card-percentage {
        font-size: 2rem;
    }

    .calculator-form {
        margin-bottom: 2rem;
    }

    .results-section {
        margin-bottom: 2rem;
    }

    .result-cards {
        margin: 1.5rem 0;
    }

    .result-card-description {
        font-size: 0.875rem;
    }

    .results-explanation {
        padding: 1.25rem;
    }

    .results-explanation p {
        font-size: 0.9375rem;
    }

    .next-steps h3 {
        font-size: 1.5rem;
    }

    .next-steps > p {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }

    .next-steps-buttons {
        flex-direction: column;
    }

    .next-steps-buttons .btn,
    .next-steps-buttons .reset-button {
        width: 100%;
        max-width: none;
    }

    .future-features {
        padding: 1.25rem;
    }

    .research-section {
        padding: 1.5rem;
    }

    .slider-labels span {
        font-size: 0.75rem;
    }

    .slider-labels-4 span {
        font-size: 0.625rem;
    }

    .slider-value {
        font-size: 1rem;
    }

    .slider::-webkit-slider-thumb {
        width: 28px;
        height: 28px;
    }

    .slider::-moz-range-thumb {
        width: 28px;
        height: 28px;
    }
}

/* === Learn More Link === */
.learn-more-link {
    color: #0ea5e9;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
    cursor: pointer;
}

.learn-more-link:hover {
    color: #0284c7;
    text-decoration: underline;
}

/* === Modal Styles === */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 24px;
    padding: 3rem;
    max-width: 800px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow:
        0 32px 80px rgba(15, 23, 42, 0.2),
        0 16px 40px rgba(15, 23, 42, 0.1);
    margin: 1.5rem;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: none;
    border: none;
    font-size: 2rem;
    color: #64748b;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    line-height: 1;
}

.modal-close:hover {
    background-color: #f1f5f9;
    color: #334155;
    transform: rotate(90deg);
}

.modal-content h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #0c4a6e;
    margin-bottom: 1rem;
    padding-right: 3rem;
}

.modal-content > p {
    font-size: 1.125rem;
    color: #475569;
    margin-bottom: 2rem;
    line-height: 1.7;
}

.research-sources {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.research-item {
    background: white;
    border-radius: 16px;
    padding: 1.5rem;
    border: 2px solid #e2e8f0;
    transition: all 0.3s ease;
}

.research-item:hover {
    border-color: #0ea5e9;
    box-shadow: 0 8px 24px rgba(14, 165, 233, 0.1);
    transform: translateY(-2px);
}

.research-item h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.research-item p {
    font-size: 1rem;
    color: #64748b;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.research-item a {
    display: inline-flex;
    align-items: center;
    color: #0ea5e9;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.research-item a:hover {
    color: #0284c7;
    text-decoration: underline;
}

/* Modal Mobile Responsive */
@media (max-width: 768px) {
    .modal-content {
        padding: 2rem;
        margin: 1rem;
        max-height: 90vh;
    }

    .modal-content h2 {
        font-size: 1.5rem;
        padding-right: 2.5rem;
    }

    .modal-content > p {
        font-size: 1rem;
    }

    .research-item {
        padding: 1.25rem;
    }

    .research-item h3 {
        font-size: 1.125rem;
    }

    .research-item p {
        font-size: 0.9375rem;
    }
}

@media (max-width: 480px) {
    .modal-content {
        padding: 1.5rem;
        margin: 0.75rem;
    }

    .modal-close {
        top: 1rem;
        right: 1rem;
        width: 36px;
        height: 36px;
        font-size: 1.75rem;
    }

    .modal-content h2 {
        font-size: 1.375rem;
        padding-right: 2rem;
        margin-bottom: 0.75rem;
    }

    .modal-content > p {
        font-size: 0.9375rem;
        margin-bottom: 1.5rem;
    }

    .research-sources {
        gap: 1rem;
    }

    .research-item {
        padding: 1rem;
    }

    .research-item h3 {
        font-size: 1rem;
    }

    .research-item p {
        font-size: 0.875rem;
        margin-bottom: 0.75rem;
    }
}
