/* Компоненты UI */
.back-btn { position: absolute; top: 20px; left: 20px; background: none; border: none; color: #667eea; font-size: .9rem; cursor: pointer; display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 8px; transition: background-color .3s; }
.back-btn:hover { background-color: #f7fafc; }

.search-container { margin-bottom: 30px; }
.search-box { position: relative; margin-bottom: 20px; }
.search-box i { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: #a0aec0; font-size: 1.1rem; }
.search-box input { width: 100%; padding: 16px 44px 16px 48px; border: 2px solid #e2e8f0; border-radius: 12px; font-size: 1rem; transition: all .3s; background: #f7fafc; }
.search-box input:focus { outline: none; border-color: #667eea; background: #fff; box-shadow: 0 0 0 3px rgba(102,126,234,.1); }
.clear-btn { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; color: #a0aec0; cursor: pointer; padding: 6px; border-radius: 50%; transition: all .2s ease; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; font-size: 12px; }
.clear-btn:hover { background: #f1f5f9; color: #64748b; transform: translateY(-50%) scale(1.02); }

.suggestions-dropdown { background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; box-shadow: 0 10px 25px rgba(0,0,0,.1); max-height: 300px; overflow-y: auto; margin-top: 8px; }
.suggestion-item { padding: 12px 16px; cursor: pointer; transition: background-color .3s; border-bottom: 1px solid #f7fafc; }
.suggestion-item:last-child { border-bottom: none; }
.suggestion-item:hover { background-color: #f7fafc; }
.suggestion-item.selected { background-color: #667eea; color: #fff; }

.popular-cities { margin-top: 30px; }
.popular-cities h3 { font-size: 1.1rem; color: #4a5568; margin-bottom: 15px; text-align: center; }
.cities-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.city-btn { background: #f7fafc; border: 2px solid #e2e8f0; border-radius: 10px; padding: 12px 16px; font-size: .9rem; cursor: pointer; transition: all .3s; color: #4a5568; }
.city-btn:hover { border-color: #667eea; background: #edf2f7; transform: translateY(-2px); }

.calculation-explanation { background: #f7fafc; border-radius: 16px; padding: 30px; margin-bottom: 30px; }
.calculation-explanation h2 { font-size: 1.5rem; color: #2d3748; margin-bottom: 20px; text-align: center; }
.explanation-content { display: grid; gap: 20px; }
.explanation-section { background: #fff; padding: 20px; border-radius: 12px; border-left: 4px solid #667eea; }
.explanation-section h3 { font-size: 1.1rem; color: #2d3748; margin-bottom: 10px; display: flex; align-items: center; gap: 10px; }
.explanation-section h3 i { color: #667eea; }
.explanation-section p { color: #4a5568; margin-bottom: 10px; }
.explanation-section ul { list-style: none; padding-left: 0; }
.explanation-section li { padding: 4px 0 4px 20px; color: #718096; position: relative; }
.explanation-section li::before { content: '•'; color: #667eea; position: absolute; left: 0; font-weight: bold; }

.calculator-form { background: #f7fafc; padding: 30px; border-radius: 16px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-weight: 500; color: #2d3748; margin-bottom: 8px; }
.form-group input, .form-group select { width: 100%; padding: 12px 16px; border: 2px solid #e2e8f0; border-radius: 10px; font-size: 1rem; transition: all .3s; background: #fff; }
.form-group input:focus, .form-group select:focus { outline: none; border-color: #667eea; box-shadow: 0 0 0 3px rgba(102,126,234,.1); }

.calculate-btn { width: 100%; background: linear-gradient(135deg,#667eea,#764ba2); color: #fff; border: none; padding: 16px 24px; border-radius: 12px; font-size: 1.1rem; font-weight: 600; cursor: pointer; transition: all .3s; display: flex; align-items: center; justify-content: center; gap: 10px; }
.calculate-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 25px rgba(102,126,234,.3); }

/* Отступ под кнопкой расчёта за месяц */
.monthly-section .calculate-btn { margin-bottom: 30px; }

.result-item { display: flex; justify-content: space-between; align-items: center; padding: 12px 0; border-bottom: 1px solid #f7fafc; }
.result-item:last-child { border-bottom: none; }
.result-item.total { font-weight: 700; font-size: 1.2rem; color: #2d3748; border-top: 2px solid #e2e8f0; padding-top: 20px; margin-top: 10px; }
.result-item .label { color: #4a5568; }
.result-item .value { font-weight: 600; color: #667eea; }
.result-item.total .value { color: #2d3748; font-size: 1.3rem; }

.disclaimer-content i { color: #f59e0b; font-size: 1.2rem; margin-top: 2px; flex-shrink: 0; }
.disclaimer-content p { color: #92400e; font-size: .95rem; line-height: 1.5; margin: 0; font-weight: 500; }

.support-content { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; text-align: center; }
.support-content p { color: #2d3748; margin: 0; }
.support-btn { display: inline-flex; align-items: center; gap: 8px; background: #249bd7; color: #fff; text-decoration: none; padding: 10px 14px; border-radius: 10px; font-weight: 600; transition: transform .2s, box-shadow .2s, opacity .2s; }
.support-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(36,155,215,.3); opacity: .95; }

.suggestions-dropdown::-webkit-scrollbar { width: 6px; }
.suggestions-dropdown::-webkit-scrollbar-track { background: #f1f1f1; border-radius: 3px; }
.suggestions-dropdown::-webkit-scrollbar-thumb { background: #c1c1c1; border-radius: 3px; }
.suggestions-dropdown::-webkit-scrollbar-thumb:hover { background: #a8a8a8; }

.step.active { animation: fadeIn .5s ease-out; }
@keyframes fadeIn { from{opacity:0; transform: translateY(20px);} to{opacity:1; transform: translateY(0);} }

/* Инфоблок ставок */
.rates-info { background: #f7fafc; border: 2px solid #e2e8f0; border-radius: 16px; padding: 20px; margin-bottom: 20px; }
.rates-groups { display: grid; grid-template-columns: 1fr; gap: 16px; }
.rates-group h3 { margin: 0 0 8px; font-size: 1.1rem; color: #2d3748; }
.rates-group { background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: 14px; }
.rates-note { color: #718096; font-size: .9rem; margin-top: 8px; }
.section-title { font-size: 1.5rem; color: #2d3748; margin: 0 0 16px; font-weight: 700; text-align: center; }
.section-header { margin-bottom: 16px; text-align: center; }
.section-header .section-title { margin: 0 0 6px; }
.section-subtitle { color: #718096; margin: 0; text-align: center; }
.rates-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.rates-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; color: #2d3748; }
.rates-list .label { color: #4a5568; font-weight: 500; }
.rates-list .value { color: #667eea; font-weight: 600; }
.rates-list .note { color: #718096; font-size: .9rem; }

/* Кнопка и подсказка "как это считается?" */
.result-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: relative; }
.how-it-works-btn { background: none; border: none; color: #667eea; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-weight: 600; padding: 6px 10px; border-radius: 8px; transition: background-color .2s, color .2s; }
.how-it-works-btn .btn-text { font-size: .9rem; }
.how-it-works-btn:hover { background: #f7fafc; color: #5a67d8; }
.how-tooltip { position: absolute; z-index: 50; background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; box-shadow: 0 12px 28px rgba(0,0,0,.12); padding: 16px; max-width: 420px; width: max-content; right: 0; top: calc(100% + 8px); }
.how-content { font-size: .95rem; color: #2d3748; }
.how-title { font-weight: 700; margin-bottom: 8px; color: #2d3748; }
.how-block { background: #f7fafc; border: 1px solid #e2e8f0; border-radius: 10px; padding: 10px 12px; margin-top: 8px; }
.how-line { font-weight: 600; margin-bottom: 6px; color: #2d3748; }
.how-text { color: #4a5568; margin: 4px 0; }
.how-total { margin-top: 10px; font-weight: 700; color: #2d3748; }

/* Модальное окно для мобильных */
.modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.35); display: none; align-items: center; justify-content: center; padding: 20px; z-index: 100; backdrop-filter: blur(1px); }
.modal-overlay.open { display: flex; }
.modal-card { background: #fff; border-radius: 16px; box-shadow: 0 20px 40px rgba(0,0,0,.2); width: 100%; max-width: 540px; overflow: hidden; }
.modal-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid #e2e8f0; }
.modal-header span { font-weight: 700; color: #2d3748; }
.modal-close { background: none; border: none; color: #a0aec0; font-size: 1.1rem; cursor: pointer; }
.modal-close:hover { color: #718096; }
.modal-body { padding: 16px; max-height: 70vh; overflow-y: auto; }

