/* API Costs Page Specific Styles */

/* API Costs Header */
.api-costs-header {
    padding: 8rem 0 4rem;
    background: linear-gradient(135deg, #6366f1, #7c3aed, #00CFFF);
    color: white;
    text-align: center;
}

.api-costs-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    margin-bottom: 1rem;
}

.api-costs-subtitle {
    font-size: 1.3rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 3rem;
}

/* Pricing Philosophy */
.pricing-philosophy {
    max-width: 800px;
    margin: 0 auto;
}

.philosophy-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-lg);
    padding: 2rem;
}

.philosophy-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent-cyan);
}

.philosophy-card p {
    font-size: 1.1rem;
    line-height: 1.6;
    opacity: 0.9;
}

/* Pricing Tables Section */
.pricing-tables-section {
    padding: 4rem 0;
    background: var(--light-bg);
}

.pricing-section {
    margin-bottom: 4rem;
}

.pricing-section-title {
    text-align: center;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 3rem;
    position: relative;
}

.pricing-section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--primary-gradient);
    border-radius: 2px;
}

/* Pricing Grid */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.pricing-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-medium);
    overflow: hidden;
    transition: all 0.3s ease;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

.pricing-header {
    background: linear-gradient(135deg, #6366f1, #7c3aed);
    color: white;
    padding: 2rem;
    text-align: center;
    position: relative;
}

.pricing-header h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.pricing-icon {
    font-size: 2.5rem;
    margin-top: 0.5rem;
}

.pricing-content {
    padding: 2rem;
}

.price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.price-item:last-child {
    border-bottom: none;
}

.model-name {
    font-weight: 600;
    color: var(--text-primary);
}

.model-price {
    font-weight: 700;
    color: #6366f1;
    font-size: 1.1rem;
}

/* Examples Grid */
.examples-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
}

.example-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-medium);
    overflow: hidden;
    transition: all 0.3s ease;
}

.example-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-heavy);
}

.example-header {
    background: var(--light-bg);
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.example-header h3 {
    font-size: 1.3rem;
    color: var(--text-primary);
}

.example-total {
    font-size: 1.4rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.example-breakdown {
    padding: 2rem;
}

.breakdown-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 0;
    border-bottom: 1px solid #f1f5f9;
}

.breakdown-item:last-child {
    border-bottom: none;
    font-weight: 600;
    padding-top: 1rem;
    border-top: 2px solid var(--border-color);
}

.step {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.cost {
    font-weight: 700;
    color: var(--text-primary);
}

.example-note {
    padding: 0 2rem 1.5rem;
    color: var(--text-light);
    font-style: italic;
}

/* Chart Container */
.chart-container {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-medium);
    margin-bottom: 2rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.chart-container canvas {
    max-width: 100%;
    height: auto;
}

.chart-legend {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
}

.legend-color.aevaris {
    background: #6366f1;
}

.legend-color.competitor-a {
    background: #f59e0b;
}

.legend-color.competitor-b {
    background: #ef4444;
}

/* Calculator Section */
.calculator-section {
    padding: 4rem 0;
    background: white;
}

.calculator-card {
    background: var(--light-bg);
    border-radius: var(--radius-lg);
    padding: 3rem;
    max-width: 800px;
    margin: 2rem auto 0;
    box-shadow: var(--shadow-medium);
}

.calculator-inputs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

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

.input-group label {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.input-group input {
    padding: 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.calculator-results {
    background: white;
    border-radius: var(--radius-md);
    padding: 2rem;
    border: 2px solid #e5e7eb;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.result-item:last-child {
    border-bottom: none;
}

.result-item.savings {
    background: #f0fdf4;
    margin: 1rem -2rem -2rem;
    padding: 1.5rem 2rem;
    border-bottom: none;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.result-label {
    font-weight: 600;
    color: var(--text-primary);
}

.result-value {
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.result-value.competitor {
    background: linear-gradient(90deg, #f59e0b, #ef4444);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.result-item.savings .result-value {
    background: #059669;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Section Title */
.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--primary-gradient);
    border-radius: 2px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .examples-grid {
        grid-template-columns: 1fr;
    }
    
    .calculator-inputs {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .pricing-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .example-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .chart-legend {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
    
    .calculator-card {
        padding: 2rem;
    }
    
    .result-item {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .pricing-card {
        margin: 0 -10px;
    }
    
    .pricing-content {
        padding: 1.5rem;
    }
    
    .example-breakdown {
        padding: 1.5rem;
    }
    
    .breakdown-item {
        flex-direction: column;
        gap: 0.3rem;
        text-align: center;
    }
}