/* Groww Style SIP Calculator */
.groww-sip-calculator {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: #fff;
}

.sip-container {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sip-header {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #00d09c 0%, #00b8a9 100%);
    color: white;
    border-radius: 12px 12px 0 0;
}

.sip-header h1 {
    margin: 0 0 10px 0;
    font-size: 2.5rem;
    font-weight: 700;
}

.sip-header p {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
}

.sip-header i {
    margin-right: 10px;
}

.sip-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 40px;
}

/* Input Section */
.sip-inputs {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 12px;
    border: 1px solid #e9ecef;
}

.input-section {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.input-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    color: #2d3748;
    font-size: 1rem;
}

.label-text {
    font-size: 1.1rem;
}

.currency {
    color: #718096;
    font-size: 0.9rem;
}

.input-with-slider {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.amount-input {
    position: relative;
    display: flex;
    align-items: center;
}

.amount-input input {
    width: 100%;
    padding: 15px 50px 15px 40px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    background: white;
    transition: border-color 0.3s ease;
}

.amount-input input:focus {
    outline: none;
    border-color: #00d09c;
}

.currency-symbol {
    position: absolute;
    left: 15px;
    font-weight: 600;
    color: #2d3748;
}

.percent-symbol, .years-text {
    position: absolute;
    right: 15px;
    font-weight: 600;
    color: #718096;
}

/* Custom Slider */
.custom-slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: #e2e8f0;
    outline: none;
    -webkit-appearance: none;
}

.custom-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #00d09c;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.custom-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #00d09c;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: #718096;
    font-weight: 500;
}

/* Results Section */
.sip-results {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.summary-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.summary-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.summary-card.invested {
    border-left: 4px solid #00d09c;
}

.summary-card.returns {
    border-left: 4px solid #ff6b6b;
}

.summary-card.total {
    border-left: 4px solid #667eea;
}

.card-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.invested .card-icon {
    background: rgba(0, 208, 156, 0.1);
    color: #00d09c;
}

.returns .card-icon {
    background: rgba(255, 107, 107, 0.1);
    color: #ff6b6b;
}

.total .card-icon {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
}

.card-content {
    flex: 1;
}

.card-label {
    font-size: 0.9rem;
    color: #718096;
    margin-bottom: 5px;
}

.card-value {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2d3748;
}

/* Chart Section */
.chart-section {
    background: white;
    padding: 25px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.chart-header h3 {
    margin: 0;
    color: #2d3748;
    font-size: 1.2rem;
}

.chart-legend {
    display: flex;
    gap: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #718096;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 2px;
}

.invested-color {
    background: #00d09c;
}

.returns-color {
    background: #ff6b6b;
}

.chart-container {
    height: 300px;
    position: relative;
}

#sipChart {
    width: 100% !important;
    height: 100% !important;
}

/* Insights Section */
.insights-section {
    background: white;
    padding: 25px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
}

.insights-section h3 {
    margin: 0 0 20px 0;
    color: #2d3748;
    font-size: 1.2rem;
}

.insights-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.insight-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.insight-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: #00d09c;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.insight-card:nth-child(2) .insight-icon {
    background: #667eea;
}

.insight-card:nth-child(3) .insight-icon {
    background: #ff6b6b;
}

.insight-card:nth-child(4) .insight-icon {
    background: #fbc531;
}

.insight-content {
    flex: 1;
}

.insight-value {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 2px;
}

.insight-label {
    font-size: 0.8rem;
    color: #718096;
}

/* Yearly Breakdown */
.yearly-breakdown {
    padding: 40px;
    border-top: 1px solid #e2e8f0;
}

.yearly-breakdown h3 {
    margin: 0 0 20px 0;
    color: #2d3748;
    font-size: 1.3rem;
}

.table-container {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.breakdown-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.breakdown-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    color: #2d3748;
    border-bottom: 1px solid #e2e8f0;
}

.breakdown-table td {
    padding: 12px;
    border-bottom: 1px solid #e2e8f0;
}

.breakdown-table tbody tr:hover {
    background: #f8f9fa;
}

.breakdown-table tbody tr:nth-child(even) {
    background: #fafafa;
}

/* Responsive Design */
@media (max-width: 968px) {
    .sip-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .summary-cards {
        grid-template-columns: 1fr;
    }
    
    .insights-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .groww-sip-calculator {
        padding: 10px;
    }
    
    .sip-header {
        padding: 30px 15px;
    }
    
    .sip-header h1 {
        font-size: 2rem;
    }
    
    .sip-content {
        padding: 20px;
    }
    
    .sip-inputs {
        padding: 20px;
    }
    
    .yearly-breakdown {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .sip-header h1 {
        font-size: 1.5rem;
    }
    
    .amount-input input {
        padding: 12px 45px 12px 35px;
        font-size: 1rem;
    }
    
    .chart-container {
        height: 250px;
    }
}