/* Base Styles */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background-color: #ffffff;
    color: #000000;
    line-height: 1.5;
}

/* Header */
.header {
    background-color: #000000;
    color: #ffffff;
    padding: 4rem 1rem;
}

.header-content {
    max-width: 64rem;
    margin: 0 auto;
    text-align: center;
}

.header h1 {
    font-size: 3rem;
    font-weight: 700;
    margin: 0 0 1rem 0;
}

@media (min-width: 640px) {
    .header h1 {
        font-size: 3.75rem;
    }
}

.header p {
    color: #d1d5db;
    font-size: 1.25rem;
    margin: 0;
}

/* Referral Banner */
.referral-banner {
    width: 100%;
    padding: 1rem;
    background-color: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
}

.referral-banner-content {
    max-width: 64rem;
    margin: 0 auto;
    text-align: center;
}

.referral-banner a {
    text-decoration: underline;
    color: #000000;
}

/* Main Container */
.main-container {
    max-width: 64rem;
    margin: 0 auto;
    padding: 3rem 1rem;
}

/* Tab Navigation */
.tab-nav {
    display: flex;
    flex-wrap: wrap;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 3rem;
}

.tab-button {
    padding: 1rem 2rem;
    font-weight: 600;
    background: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    color: #6b7280;
    border-bottom: 2px solid transparent;
}

.tab-button:hover {
    color: #374151;
}

.tab-button.active {
    color: #000000;
    border-bottom: 2px solid #000000;
}

/* Section Titles */
.section-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: #000000;
    margin: 0 0 1rem 0;
}

/* Wealthsimple Rates Display */
.ws-rates-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.5rem;
    margin-bottom: 2rem;
    padding: 1rem;
    background-color: #f9fafb;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
}

@media (min-width: 768px) {
    .ws-rates-container {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }
}

.ws-rate-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background-color: #ffffff;
    border-radius: 0.375rem;
    border: 1px solid #e5e7eb;
}

.ws-rate-item.highlight {
    background-color: #000000;
    color: #ffffff;
    border-color: #000000;
}

.ws-rate-label {
    font-size: 0.875rem;
    color: #6b7280;
}

.ws-rate-item.highlight .ws-rate-label {
    color: #d1d5db;
}

.ws-rate-value {
    font-size: 1.5rem;
    font-weight: 700;
}

/* Info Box */
.info-box {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 2rem;
}

.info-box.blue {
    background-color: #eff6ff;
    border: 1px solid #bfdbfe;
}

.info-box.green {
    background-color: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.info-box.yellow {
    background-color: #fefce8;
    border: 1px solid #fef08a;
}

.info-box p {
    font-size: 0.875rem;
    color: #374151;
    margin: 0;
}

.info-box.green p {
    color: #166534;
    font-weight: 500;
}

/* Slider Controls */
.slider-container {
    margin-bottom: 2rem;
}

.slider-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.75rem;
}

.slider-value {
    font-size: 2.25rem;
    font-weight: 700;
    color: #000000;
    margin-bottom: 1rem;
}

.slider {
    width: 100%;
    height: 0.5rem;
    background-color: #e5e7eb;
    border-radius: 9999px;
    appearance: none;
    cursor: pointer;
    accent-color: #000000;
}

.slider::-webkit-slider-thumb {
    appearance: none;
    width: 1.25rem;
    height: 1.25rem;
    background-color: #000000;
    border-radius: 50%;
    cursor: pointer;
}

.slider::-moz-range-thumb {
    width: 1.25rem;
    height: 1.25rem;
    background-color: #000000;
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

/* Tier Selector */
.tier-selector {
    padding: 1.5rem;
    background-color: #f9fafb;
    border-radius: 0.5rem;
    margin-bottom: 2rem;
}

.tier-selector-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 1rem;
}

.tier-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tier-button {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    background-color: #ffffff;
    border: 1px solid #d1d5db;
    color: #374151;
}

.tier-button:hover {
    border-color: #9ca3af;
}

.tier-button.active {
    background-color: #000000;
    color: #ffffff;
    border-color: #000000;
}

/* Checkbox */
.checkbox-container {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.checkbox {
    margin-top: 0.125rem;
    width: 1rem;
    height: 1rem;
    accent-color: #000000;
}

.checkbox-label {
    font-size: 0.875rem;
    color: #374151;
}

/* Generation Note */
.generation-note {
    font-size: 0.875rem;
    color: #4b5563;
    margin-top: 1rem;
}

/* Results Cards */
.results-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.result-card {
    padding: 1.5rem;
    border-radius: 0.5rem;
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
}

.result-card.featured {
    background-color: #f9fafb;
    border-left: 4px solid #000000;
}

.result-card.unavailable {
    background-color: #f3f4f6;
    border-color: #d1d5db;
}

.result-card-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.result-card-content.align-start {
    align-items: flex-start;
}

.result-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #000000;
}

.result-name.unavailable {
    color: #9ca3af;
}

.result-details {
    font-size: 0.875rem;
    color: #4b5563;
    margin-top: 0.25rem;
}

.result-details.unavailable {
    color: #6b7280;
}

.result-link {
    font-size: 0.75rem;
    color: #4b5563;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    margin-top: 0.25rem;
}

.result-link:hover {
    color: #000000;
}

.result-amount {
    text-align: right;
}

.result-value {
    font-size: 2.25rem;
    font-weight: 700;
    color: #000000;
}

.result-value.small {
    font-size: 1.875rem;
}

.result-period {
    font-size: 0.875rem;
    color: #4b5563;
}

.result-annual {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 0.25rem;
}

/* Disclaimer */
.disclaimer {
    margin-top: 4rem;
    padding: 1.5rem;
    background-color: #fefce8;
    border-radius: 0.5rem;
    border: 2px solid #fde047;
}

.disclaimer h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #111827;
    margin: 0 0 0.5rem 0;
}

.disclaimer p {
    font-size: 0.875rem;
    color: #374151;
    margin: 0 0 0.5rem 0;
}

.disclaimer p:last-child {
    margin-bottom: 0;
}

/* Footer */
.footer {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
    text-align: center;
    font-size: 0.875rem;
    color: #6b7280;
}

.footer a {
    color: inherit;
    text-decoration: none;
}

.footer a:hover {
    color: #374151;
}

/* External Link Icon */
.external-link-icon {
    width: 0.75rem;
    height: 0.75rem;
    display: inline-block;
}

/* Two Column Layout */
.two-column-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

@media (min-width: 768px) {
    .two-column-layout {
        grid-template-columns: 1fr 1fr;
    }
}

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

.column-title {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
}
