/* CAR LEASE CALCULATOR - PRODUCTION CSS v3.0 */

:root {
    --primary: #24ACB9;
    --primary-dark: #19343B;
    --accent: #FFC107;
    --accent-dark: #E69500;
    --text: #1F2121;
    --text-light: #64748B;
    --bg: #FFFFFD;
    --bg-secondary: #F5F7FA;
    --card: #FFFFFF;
    --border: #E2E8F0;
    --error: #EF4444;
    --success: #10B981;
}

[data-color-scheme="dark"] {
    --text: #E1E8ED;
    --text-light: #B8C5D0;
    --bg: #1F2121;
    --bg-secondary: #242B36;
    --card: #181919;
    --border: #38444D;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    transition: all 0.3s;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 9999;
}

.skip-link:focus {
    top: 16px;
}

/* HEADER */
.header {
    background: var(--card);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-top {
    padding: 24px 0;
}

.header-top .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--primary);
    font-size: 1.25rem;
    font-weight: bold;
}

.site-title {
    font-size: 1.125rem;
    font-weight: 600;
}

.site-subtitle {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-top: 4px;
}

.header-controls {
    display: flex;
    gap: 8px;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text);
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.btn-icon:hover {
    background: var(--bg-secondary);
    border-color: var(--primary);
}

/* SPONSOR BANNER */
.sponsor-banner {
    background: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%);
    color: white;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.sponsor-label {
    font-weight: bold;
}

.sponsor-text {
    flex: 1;
    min-width: 200px;
}

.sponsor-btn {
    padding: 8px 20px;
    background: rgba(255,255,255,0.2);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    border: 1px solid rgba(255,255,255,0.3);
    transition: all 0.2s;
}

.sponsor-btn:hover {
    background: rgba(255,255,255,0.3);
    transform: translateY(-2px);
}

/* BREADCRUMB */
.breadcrumb {
    background: var(--bg-secondary);
    padding: 16px 0;
    font-size: 0.875rem;
    border-bottom: 1px solid var(--border);
}

.breadcrumb a {
    color: var(--primary);
    text-decoration: none;
}

/* MAIN */
.main {
    padding: 48px 0;
}

.calculator-wrapper {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 24px;
}

/* PANELS */
.inputs-panel,
.results-panel {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.panel-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.125rem;
    margin-bottom: 24px;
    color: var(--primary);
}

/* INPUTS */
.input-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border);
}

.input-section:last-child {
    border-bottom: none;
}

.section-heading {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    font-size: 0.875rem;
}

.form-group input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text);
    border-radius: 4px;
    font-family: inherit;
    transition: all 0.2s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(36, 172, 185, 0.1);
}

.form-group small {
    display: block;
    color: var(--text-light);
    font-size: 0.75rem;
    margin-top: 4px;
}

.fred-note {
    color: var(--accent);
    font-weight: 600;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* AD SLOTS */
.ad-slot {
    background: var(--bg-secondary);
    border: 2px dashed var(--border);
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    margin-bottom: 24px;
}

.ad-label {
    font-size: 0.75rem;
    font-weight: bold;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

/* SUMMARY CARD */
.summary-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 24px;
    border-radius: 8px;
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(36, 172, 185, 0.2);
}

.summary-label {
    font-size: 0.875rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.payment-amount {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 8px;
    margin: 16px 0;
}

.amount {
    font-size: 2.5rem;
    font-weight: bold;
}

.unit {
    font-size: 1.125rem;
    opacity: 0.9;
}

/* TABS */
.tabs {
    margin-bottom: 24px;
}

.tab-buttons {
    display: flex;
    gap: 4px;
    border-bottom: 2px solid var(--border);
    margin-bottom: 24px;
}

.tab-btn {
    padding: 16px 24px;
    border: none;
    background: transparent;
    color: var(--text-light);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: -2px;
}

.tab-btn:hover {
    color: var(--text);
}

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* RESULTS */
.result-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.125rem;
    margin: 24px 0 16px 0;
}

.lease-title {
    color: var(--accent-dark);
}

.buy-title {
    color: var(--primary);
}

.result-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.result-box {
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: 6px;
    border-left: 4px solid var(--border);
    transition: all 0.2s;
}

.result-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.result-box.highlight {
    border-left-color: var(--primary);
    background: rgba(36, 172, 185, 0.1);
}

.result-label {
    display: block;
    font-size: 0.875rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.result-value {
    display: block;
    font-size: 1.25rem;
    font-weight: bold;
}

.verdict-box {
    background: var(--bg-secondary);
    padding: 24px;
    border-radius: 8px;
    border-left: 4px solid var(--border);
    text-align: center;
    margin: 24px 0;
}

/* AFFILIATE BOX */
.affiliate-box {
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.1) 0%, rgba(255, 193, 7, 0.05) 100%);
    border: 1px solid rgba(255, 193, 7, 0.2);
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 24px;
    text-align: center;
}

.affiliate-box h3 {
    margin-bottom: 8px;
}

.affiliate-box p {
    color: var(--text-light);
    margin-bottom: 16px;
}

/* BUTTONS */
.btn-primary {
    display: inline-block;
    padding: 10px 24px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    font-size: 1rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(36, 172, 185, 0.3);
}

/* INSIGHTS */
.insights-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.insight-item {
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: 6px;
    border-left: 3px solid var(--primary);
}

/* FOOTER */
.footer {
    background: var(--card);
    border-top: 1px solid var(--border);
    margin-top: 48px;
}

.footer-sponsor {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(147, 51, 234, 0.1) 100%);
    padding: 48px 0;
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.sponsor-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
}

.sponsor-item {
    text-align: center;
}

.sponsor-item h4 {
    margin-bottom: 8px;
}

.sponsor-item p {
    color: var(--text-light);
    margin-bottom: 16px;
    font-size: 0.875rem;
}

.sponsor-item a {
    display: inline-block;
    padding: 8px 16px;
    background: var(--accent);
    color: var(--text);
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    transition: all 0.2s;
}

.sponsor-item a:hover {
    background: var(--accent-dark);
    color: white;
}

.footer-nav {
    padding: 48px 0;
    border-bottom: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 24px;
}

.footer-col h5 {
    margin-bottom: 12px;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 8px;
}

.footer-col a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-col a:hover {
    color: var(--primary);
}

.footer-bottom {
    padding: 24px 0;
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-light);
    border-top: 1px solid var(--border);
}

/* TOAST */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    background: var(--card);
    padding: 16px 24px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .calculator-wrapper {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .result-grid {
        grid-template-columns: 1fr;
    }
    
    .sponsor-grid {
        grid-template-columns: 1fr;
    }
    
    .tab-btn {
        font-size: 0.875rem;
        padding: 12px 16px;
    }
    
    .sponsor-banner {
        flex-direction: column;
    }
    
    .header-top .container {
        flex-direction: column;
        gap: 16px;
    }
}



/* Cookie Consent Banner Styles (GDPR/CCPA Compliance) */
.cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    z-index: 10000;
    display: none;
    animation: slideUp 0.5s ease-out;
}

.cookie-consent-banner.show {
    display: block;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
}

.cookie-consent-content p {
    margin: 8px 0;
    font-size: 14px;
    line-height: 1.6;
}

.cookie-links {
    margin: 12px 0;
}

.cookie-links a {
    color: #fff;
    text-decoration: underline;
    margin: 0 8px;
}

.cookie-links a:hover {
    color: #ffd700;
}

.cookie-consent-buttons {
    display: flex;
    gap: 12px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.btn-accept, .btn-reject, .btn-manage {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
}

.btn-accept {
    background-color: #10b981;
    color: white;
}

.btn-accept:hover {
    background-color: #059669;
    transform: translateY(-2px);
}

.btn-reject {
    background-color: #ef4444;
    color: white;
}

.btn-reject:hover {
    background-color: #dc2626;
    transform: translateY(-2px);
}

.btn-manage {
    background-color: #6b7280;
    color: white;
}

.btn-manage:hover {
    background-color: #4b5563;
    transform: translateY(-2px);
}

/* Cookie Settings Modal */
.cookie-modal {
    position: fixed;
    z-index: 10001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    overflow: auto;
}

.cookie-modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: modalFadeIn 0.3s ease;
}

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

.cookie-modal-close {
    color: #aaa;
    float: right;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
}

.cookie-modal-close:hover,
.cookie-modal-close:focus {
    color: #000;
}

.cookie-modal-content h3 {
    margin-top: 0;
    color: #333;
    font-size: 24px;
}

.cookie-category {
    margin: 20px 0;
    padding: 15px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background-color: #f9fafb;
}

.cookie-category label {
    display: block;
    cursor: pointer;
}

.cookie-category input[type="checkbox"] {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.cookie-category strong {
    display: block;
    margin-bottom: 5px;
    color: #1f2937;
    font-size: 16px;
}

.cookie-category p {
    margin: 5px 0 0 28px;
    font-size: 13px;
    color: #6b7280;
}

.cookie-modal-buttons {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    justify-content: flex-end;
}

/* Affiliate Disclosure Styles (FTC Compliance) */
.affiliate-disclosure {
    background-color: #fef3c7;
    border-left: 4px solid #f59e0b;
    padding: 16px 20px;
    margin: 20px 0;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.affiliate-disclosure p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: #78350f;
}

.affiliate-disclosure strong {
    color: #92400e;
}

.affiliate-disclosure a {
    color: #92400e;
    text-decoration: underline;
    font-weight: 600;
}

.affiliate-disclosure a:hover {
    color: #78350f;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cookie-consent-content {
        padding: 0 10px;
    }

    .cookie-consent-buttons {
        flex-direction: column;
    }

    .btn-accept, .btn-reject, .btn-manage {
        width: 100%;
    }

    .cookie-modal-content {
        width: 95%;
        margin: 10% auto;
        padding: 20px;
    }
}
