/* ======================
   Calculator Hero Section
   ====================== */
.calculator-hero {
    padding: 3rem 0 2rem;
    background: linear-gradient(135deg, #f9fafb 0%, #eff6ff 50%, #faf5ff 100%);
    position: relative;
    overflow: hidden;
}

@media (min-width: 768px) {
    .calculator-hero {
        padding: 4rem 0 2.5rem;
    }
}

.calculator-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(14,165,233,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.calculator-hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.calculator-hero-content h1 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    background: linear-gradient(135deg, #0ea5e9 0%, #d946ef 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@media (min-width: 768px) {
    .calculator-hero-content h1 {
        font-size: 2.5rem;
    }
}

.calculator-hero-content p {
    font-size: 1rem;
    color: #6b7280;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .calculator-hero-content p {
        font-size: 1.125rem;
    }
}

.breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: #6b7280;
}

.breadcrumb a {
    color: #0ea5e9;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: #d946ef;
}

.breadcrumb svg {
    width: 1rem;
    height: 1rem;
    color: #9ca3af;
}

/* ======================
   Billing Toggle (Calculator)
   ====================== */
.calculator-hero .billing-toggle {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    background: white;
    padding: 0.75rem 1.5rem;
    border-radius: 9999px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    margin-top: 2rem;
}

.calculator-hero .toggle-label {
    font-weight: 600;
    color: #6b7280;
    transition: color 0.3s ease;
}

.calculator-hero .toggle-label.active {
    color: #0ea5e9;
}

.calculator-hero .toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.calculator-hero .toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.calculator-hero .toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #e5e7eb;
    transition: 0.3s;
    border-radius: 24px;
}

.calculator-hero .toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.calculator-hero input:checked + .toggle-slider {
    background: linear-gradient(135deg, #0ea5e9 0%, #d946ef 100%);
}

.calculator-hero input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.calculator-hero .discount-badge {
    display: inline-block;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

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

@media (min-width: 768px) {
    .calculator-section {
        padding: 2.5rem 0;
    }
}

.calculator-tabs {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 0;
}

@media (min-width: 768px) {
    .calculator-tabs {
        margin-bottom: 2rem;
    }
}

.tab-button {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: #6b7280;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    margin-bottom: -2px;
}

.tab-button:hover {
    color: #0ea5e9;
}

.tab-button.active {
    color: #0ea5e9;
    border-bottom-color: #0ea5e9;
}

.tab-button svg {
    width: 1.25rem;
    height: 1.25rem;
}

.calculator-content {
    display: none;
}

.calculator-content.active {
    display: block;
    animation: fadeIn 0.5s ease-out;
}

/* ======================
   Calculator Grid
   ====================== */
.calculator-grid {
    display: grid;
    gap: 1.5rem;
    max-width: 1400px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .calculator-grid {
        gap: 2rem;
    }
}

@media (min-width: 1024px) {
    .calculator-grid {
        gap: 2.5rem;
    }
}

@media (min-width: 1024px) {
    .calculator-grid {
        grid-template-columns: 1fr 1fr;
        align-items: start;
    }
}

/* ======================
   Calculator Inputs
   ====================== */
.calculator-inputs {
    background: #f9fafb;
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid #e5e7eb;
}

@media (min-width: 768px) {
    .calculator-inputs {
        padding: 2rem;
    }
}

.calculator-inputs h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #1f2937;
}

@media (min-width: 768px) {
    .calculator-inputs h2 {
        font-size: 1.75rem;
    }
}

.section-description {
    color: #6b7280;
    margin-bottom: 1.5rem;
    font-size: 0.938rem;
}

.input-section {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.input-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2937;
}

.section-title svg {
    width: 1.5rem;
    height: 1.5rem;
    color: #0ea5e9;
}

.input-group {
    margin-bottom: 1rem;
}

.input-group label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.75rem;
    font-size: 0.938rem;
}

.input-group label svg {
    width: 1.25rem;
    height: 1.25rem;
    color: #0ea5e9;
}

.input-group input[type="number"],
.input-group input[type="text"],
.input-group select {
    width: 100%;
    padding: 0.875rem 1.25rem;
    border: 2px solid #e5e7eb;
    border-radius: 0.75rem;
    font-size: 1rem;
    font-weight: 500;
    color: #1f2937;
    background: white;
    transition: all 0.3s ease;
}

.input-group input[type="number"]:focus,
.input-group input[type="text"]:focus,
.input-group select:focus {
    outline: none;
    border-color: #0ea5e9;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.1);
}

.input-group input[type="number"]:hover,
.input-group input[type="text"]:hover,
.input-group select:hover {
    border-color: #cbd5e1;
}

.input-group small {
    display: block;
    margin-top: 0.5rem;
    color: #6b7280;
    font-size: 0.813rem;
}

/* ======================
   Calculation Display
   ====================== */
.calculation-display {
    background: linear-gradient(135deg, #eff6ff 0%, #faf5ff 100%);
    border: 2px solid #e0e7ff;
    border-radius: 1rem;
    padding: 1.5rem;
    margin: 2rem 0;
    text-align: center;
}

.calc-label {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.calc-value {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #0ea5e9 0%, #d946ef 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.75rem;
}

.calc-formula {
    font-size: 0.875rem;
    color: #6b7280;
    font-style: italic;
}

.calc-formula span {
    font-weight: 600;
    color: #0ea5e9;
}

/* ======================
   Modules Section
   ====================== */
.modules-section {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
}

.modules-section h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #1f2937;
}

.module-option {
    margin-bottom: 1rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.checkbox-label:hover {
    border-color: #0ea5e9;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkbox-custom {
    width: 1.5rem;
    height: 1.5rem;
    border: 2px solid #d1d5db;
    border-radius: 0.375rem;
    position: relative;
    flex-shrink: 0;
    transition: all 0.3s ease;
    background: white;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom {
    background: linear-gradient(135deg, #0ea5e9 0%, #d946ef 100%);
    border-color: transparent;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: 700;
    font-size: 0.875rem;
}

.module-info {
    flex: 1;
}

.module-info strong {
    display: block;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

.module-info small {
    color: #6b7280;
    font-size: 0.813rem;
}

.calculate-btn {
    margin-top: 2rem;
}

/* ======================
   Calculator Results
   ====================== */
.calculator-results {
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 1.5rem;
    padding: 2.5rem;
    position: sticky;
    top: 6rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #e5e7eb;
}

.results-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
}

.tier-badge {
    background: linear-gradient(135deg, #0ea5e9 0%, #d946ef 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.813rem;
    font-weight: 600;
}

.price-breakdown {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid #e5e7eb;
}

.main-price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.25rem;
    margin-bottom: 0.75rem;
}

.main-price .currency {
    font-size: 1.5rem;
    font-weight: 600;
    color: #6b7280;
}

.main-price .amount {
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #0ea5e9 0%, #d946ef 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.main-price .period {
    font-size: 1.125rem;
    color: #6b7280;
    font-weight: 500;
}

.price-note {
    color: #6b7280;
    font-size: 0.938rem;
}

.price-note span {
    font-weight: 600;
    color: #0ea5e9;
}

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

.breakdown-section h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2937;
}

.breakdown-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

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

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

.breakdown-label {
    color: #6b7280;
    font-size: 0.938rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.breakdown-label small {
    font-size: 0.75rem;
    color: #9ca3af;
}

.breakdown-value {
    font-weight: 600;
    color: #1f2937;
    font-size: 1rem;
}

.growth-projection {
    background: #f9fafb;
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.growth-projection h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2937;
}

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

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

.projection-item span:first-child {
    color: #6b7280;
    font-size: 0.938rem;
}

.projection-item span:last-child {
    font-weight: 600;
    color: #0ea5e9;
    font-size: 1rem;
}

.features-included {
    margin-bottom: 2rem;
}

.features-included h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2937;
}

.features-included ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.features-included li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #374151;
    font-size: 0.938rem;
}

.features-included li svg {
    width: 1.25rem;
    height: 1.25rem;
    color: #10b981;
    flex-shrink: 0;
}

/* CTA Section - Override calculator-specific styles */
section.cta .cta-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    margin-bottom: 0;
}

@media (min-width: 640px) {
    section.cta .cta-buttons {
        flex-direction: row;
    }
}

section.cta .cta-buttons .btn {
    min-width: 200px;
    width: auto;
    max-width: none;
}

@media (max-width: 639px) {
    section.cta .cta-buttons .btn {
        width: 100%;
        max-width: 300px;
    }
}

.help-text {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: #eff6ff;
    border-radius: 0.75rem;
    border-left: 4px solid #0ea5e9;
}

.help-text svg {
    width: 1.25rem;
    height: 1.25rem;
    color: #0ea5e9;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.help-text p {
    color: #6b7280;
    font-size: 0.875rem;
    line-height: 1.6;
    margin: 0;
}

/* ======================
   Pricing Reference
   ====================== */
.pricing-reference {
    padding: 4rem 0;
    background: #f9fafb;
}

.pricing-reference h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: #1f2937;
}

.tiers-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.tier-card {
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 1.5rem;
    padding: 2rem;
    transition: all 0.3s ease;
}

.tier-card:hover {
    border-color: #0ea5e9;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transform: translateY(-5px);
}

.tier-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.tier-header h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #1f2937;
}

.tier-range {
    color: #6b7280;
    font-size: 0.938rem;
}

.tier-pricing {
    margin-bottom: 0.5rem;
    font-size: 1.125rem;
    color: #374151;
}

.tier-pricing strong {
    color: #0ea5e9;
    font-size: 1.5rem;
}

.tier-cpm {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.tier-cpm small {
    color: #6b7280;
    font-size: 0.875rem;
}

.tier-cpm strong {
    color: #0ea5e9;
    font-weight: 600;
}

.tier-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.tier-features li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #374151;
    font-size: 0.938rem;
}

.tier-features li svg {
    width: 1.25rem;
    height: 1.25rem;
    color: #10b981;
    flex-shrink: 0;
}

/* ======================
   FAQ Section
   ====================== */
.faq-section {
    padding: 4rem 0;
    background: white;
}

.faq-section h2 {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: #1f2937;
}

.faq-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.faq-item {
    background: #f9fafb;
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: #0ea5e9;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.faq-item h3 {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2937;
}

.faq-item h3 svg {
    width: 1.5rem;
    height: 1.5rem;
    color: #0ea5e9;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.faq-item p {
    color: #6b7280;
    line-height: 1.7;
    font-size: 0.938rem;
}

/* ======================
   Responsive Design
   ====================== */
@media (max-width: 1023px) {
    .calculator-results {
        position: static;
    }
    
    .calculator-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .calculator-hero {
        padding: 6rem 0 3rem;
    }
    
    .calculator-hero-content h1 {
        font-size: 2rem;
    }
    
    .calculator-hero-content p {
        font-size: 1rem;
    }
    
    .calculator-tabs {
        flex-direction: column;
        gap: 0;
    }
    
    .tab-button {
        width: 100%;
        justify-content: center;
        border-bottom: 1px solid #e5e7eb;
        border-left: 3px solid transparent;
        margin-bottom: 0;
    }
    
    .tab-button.active {
        border-bottom-color: #e5e7eb;
        border-left-color: #0ea5e9;
    }
    
    .calculator-inputs {
        padding: 1.5rem;
    }
    
    .calculator-results {
        padding: 1.5rem;
    }
    
    .main-price .amount {
        font-size: 2.5rem;
    }
    
    .pricing-reference h2,
    .faq-section h2 {
        font-size: 2rem;
    }
    
    .tiers-grid {
        grid-template-columns: 1fr;
    }
}

