/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background: #f5f7fa;
    min-height: 100vh;
    padding: 0;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: white;
    min-height: 100vh;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05);
}

/* Header Styles */
header {
    background: #1a1a1a;
    color: white;
    padding: 40px 40px 50px;
    text-align: center;
    border-bottom: 4px solid #17a7ce;
}

header h1 {
    font-size: 3rem;
    margin-bottom: 12px;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.1;
    text-align: center;
}

.brand-name {
    color: #17a7ce;
}

.subtitle {
    font-size: 1.25rem;
    color: #a3a3a3;
    font-weight: 400;
}

/* Form Section */
.input-section {
    padding: 50px 40px;
    background: white;
    max-width: 800px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 35px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 12px;
    color: #1a1a1a;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.875rem;
}

.value-display {
    float: right;
    color: #17a7ce;
    font-weight: 700;
    font-size: 1.25rem;
    font-variant-numeric: tabular-nums;
}

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

.currency {
    position: absolute;
    left: 14px;
    color: #6b7280;
    font-weight: 600;
    font-size: 1.125rem;
    z-index: 1;
    top: 50%;
    transform: translateY(-50%);
}

input[type="number"],
input[type="email"] {
    width: 100%;
    padding: 14px 16px;
    padding-left: 28px;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    font-size: 1.125rem;
    font-weight: 500;
    transition: all 0.2s ease;
    background: #fafafa;
    font-variant-numeric: tabular-nums;
}

input[type="number"]:focus,
input[type="email"]:focus {
    outline: none;
    border-color: #17a7ce;
    background: white;
    box-shadow: 0 0 0 3px rgba(23, 167, 206, 0.1);
}

input[type="number"]:focus + .currency,
input[type="email"]:focus + .currency {
    color: #17a7ce;
}

/* Slider Styles */
.slider-wrapper {
    margin-top: 10px;
}

input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e5e7eb;
    outline: none;
    -webkit-appearance: none;
    margin-bottom: 12px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #17a7ce;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(23, 167, 206, 0.3);
}

input[type="range"]::-webkit-slider-thumb:hover {
    background: #1390b8;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(23, 167, 206, 0.4);
}

input[type="range"]::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #17a7ce;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(23, 167, 206, 0.3);
}

input[type="range"]::-moz-range-thumb:hover {
    background: #1390b8;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(23, 167, 206, 0.4);
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 6px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Button Styles */
.btn-primary {
    width: 100%;
    padding: 18px 32px;
    background: #17a7ce;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1.125rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 30px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 2px solid #17a7ce;
}

.btn-primary:hover {
    background: #1390b8;
    border-color: #1390b8;
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(23, 167, 206, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    padding: 14px 28px;
    background: white;
    color: #1a1a1a;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-secondary:hover {
    background: #fafafa;
    border-color: #17a7ce;
    color: #17a7ce;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    padding: 48px;
    border-radius: 8px;
    max-width: 520px;
    width: 90%;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid #e5e7eb;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-content h2 {
    margin-bottom: 12px;
    color: #1a1a1a;
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.modal-content p {
    margin-bottom: 32px;
    color: #6b7280;
    font-size: 1rem;
    line-height: 1.6;
}

.error-message {
    color: #dc2626;
    font-size: 0.875rem;
    margin-top: 8px;
    font-weight: 500;
}

.error-message.hidden {
    display: none;
}

.btn-loading {
    display: none;
}

.btn-loading.hidden {
    display: none;
}

.btn-text.hidden {
    display: none;
}

.modal-buttons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.modal-buttons .btn-primary {
    flex: 1;
    margin: 0;
}

.modal-buttons .btn-secondary {
    flex: 1;
}

/* Results Section */
.results-section {
    padding: 0;
    background: #f5f7fa;
}

.results-section.hidden {
    display: none;
}

.results-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    margin-bottom: 0;
}

.result-box {
    padding: 60px 50px;
    position: relative;
    border-top: 6px solid;
}

.result-box-lost {
    background: #fef2f2;
    border-color: #dc2626;
    border-right: 3px solid #e5e7eb;
}

.result-box-profit {
    background: #f0fdf4;
    border-color: #16a34a;
}

.result-header {
    font-size: 1.5rem;
    margin-bottom: 40px;
    font-weight: 800;
    letter-spacing: -0.01em;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.875rem;
}

.result-box-lost .result-header {
    color: #dc2626;
}

.result-box-profit .result-header {
    color: #16a34a;
}

.result-item {
    margin-bottom: 35px;
}

.result-item:last-child {
    margin-bottom: 0;
}

.result-label {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.result-value {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
    animation: fadeInUp 0.6s ease-out;
}

.result-box-lost .result-value {
    color: #dc2626;
}

.result-box-profit .result-value {
    color: #16a34a;
}

/* Special styling for annual loss - make it HUGE */
#annual-loss {
    font-size: 4.5rem;
    line-height: 1;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

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

.result-box {
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* CTA Button */
.cta-container {
    text-align: center;
    padding: 60px 40px;
    background: #1a1a1a;
    border-top: 4px solid #17a7ce;
}

.cta-subtext {
    color: #a3a3a3;
    font-size: 1.125rem;
    margin-bottom: 20px;
    font-weight: 500;
}

.btn-cta {
    padding: 24px 48px;
    background: #17a7ce;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1.5rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 10px 25px rgba(23, 167, 206, 0.4);
    max-width: 800px;
    width: 100%;
    display: block;
    margin: 0 auto;
}

.btn-cta:hover {
    transform: translateY(-2px);
    background: #1390b8;
    box-shadow: 0 15px 35px rgba(23, 167, 206, 0.5);
}

.btn-cta:active {
    transform: translateY(0);
}

.cta-note {
    color: #6b7280;
    font-size: 0.875rem;
    margin-top: 16px;
    font-weight: 400;
}

/* Footer */
.footer {
    background: #1a1a1a;
    border-top: 1px solid #2a2a2a;
    padding: 40px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-brand {
    font-size: 1.5rem;
    font-weight: 800;
    color: #17a7ce;
    letter-spacing: -0.01em;
}

.footer-contact {
    display: flex;
    align-items: center;
    gap: 16px;
    color: #a3a3a3;
    font-size: 1rem;
}

.footer-link {
    color: #a3a3a3;
    text-decoration: none;
    transition: color 0.2s ease;
    font-weight: 500;
}

.footer-link:hover {
    color: #17a7ce;
}

.footer-separator {
    color: #4a4a4a;
}

/* Responsive Design */
@media (max-width: 768px) {
    header {
        padding: 50px 30px 40px;
    }

    header h1 {
        font-size: 2.25rem;
    }

    .subtitle {
        font-size: 1.125rem;
    }

    .input-section {
        padding: 40px 30px;
    }

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

    .result-box {
        padding: 50px 40px;
    }

    .result-box-lost {
        border-right: none;
        border-bottom: 3px solid #e5e7eb;
    }

    .result-value {
        font-size: 2.5rem;
    }

    #annual-loss {
        font-size: 3rem;
    }

    .btn-cta {
        font-size: 1.25rem;
        padding: 20px 32px;
    }

    .cta-container {
        padding: 50px 30px;
    }

    .footer {
        padding: 30px;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }

    .modal-content {
        padding: 40px 30px;
    }

    .modal-buttons {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    header {
        padding: 40px 24px 32px;
    }

    header h1 {
        font-size: 1.875rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    .input-section {
        padding: 32px 24px;
    }

    .result-box {
        padding: 40px 30px;
    }

    .result-value {
        font-size: 2rem;
    }

    #annual-loss {
        font-size: 2.5rem;
    }

    .btn-cta {
        font-size: 1.125rem;
        padding: 18px 24px;
    }

    .cta-container {
        padding: 40px 24px;
    }

    .footer {
        padding: 30px 24px;
    }

    header h1 {
        font-size: 1.875rem;
    }
}

