/* ================================================================ */
/* --- 1. Глобальные переменные и сброс стилей --- */
/* ================================================================ */
:root {
    --primary-color: #0056b3;
    --secondary-color: #007bff;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --white-color: #ffffff;
    --gray-color: #6c757d;
    --border-color: #dee2e6;
    --font-main: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-main); color: var(--dark-color); line-height: 1.6; background-color: var(--white-color); }
.container { width: 95%; max-width: 1200px; margin: 0 auto; padding: 0 15px; }
a { color: var(--primary-color); text-decoration: none; transition: color 0.3s ease; }
a:hover { color: var(--secondary-color); }
img { max-width: 100%; height: auto; }
ul { list-style: none; }

/* ================================================================ */
/* --- 2. Шапка (Header) и Навигация --- */
/* ================================================================ */
.site-header { background-color: var(--white-color); padding: 15px 0; border-bottom: 1px solid var(--border-color); position: sticky; top: 0; z-index: 1000; }
.header-content { display: flex; justify-content: space-between; align-items: center; }
.logo img { height: 50px; }
.main-nav { margin-right: auto; margin-left: 40px; }
.main-nav ul { display: flex; gap: 25px; list-style: none; padding: 0; margin: 0; }
.main-nav a { font-weight: 500; font-size: 16px; color: var(--dark-color); text-decoration: none; padding: 5px 0; position: relative; }
.main-nav a::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px; background-color: var(--primary-color); transition: width 0.3s ease; }
.main-nav a:hover::after { width: 100%; }
.header-right-group { display: flex; align-items: center; gap: 20px; }
.header-contacts { display: flex; gap: 10px; }
.header-cart-icon { position: relative; font-size: 1.8rem; color: var(--dark-color); }
.cart-counter { position: absolute; top: -5px; right: -10px; background-color: var(--primary-color); color: white; font-size: 0.75rem; font-weight: bold; border-radius: 50%; width: 20px; height: 20px; display: flex; justify-content: center; align-items: center; }
.burger-menu { display: none; background: none; border: none; cursor: pointer; font-size: 2.2rem; color: var(--dark-color); padding: 0; line-height: 1; }
.mobile-nav-wrapper { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: var(--white-color); z-index: 2000; transform: translateX(100%); transition: transform 0.4s cubic-bezier(0.77, 0, 0.175, 1); display: flex; flex-direction: column; }
.mobile-nav-wrapper.is-open { transform: translateX(0); }
.mobile-nav-header { display: flex; justify-content: space-between; align-items: center; padding: 15px; border-bottom: 1px solid var(--border-color); flex-shrink: 0; }
.close-menu-btn { background: none; border: none; cursor: pointer; font-size: 2rem; color: var(--dark-color); padding: 0; line-height: 1; }
.mobile-nav { padding: 30px; flex-grow: 1; overflow-y: auto; }
.mobile-nav ul li { margin-bottom: 20px; }
.mobile-nav ul li a { font-size: 1.5rem; font-weight: 600; color: var(--dark-color); }
.mobile-nav-footer { padding: 30px; border-top: 1px solid var(--border-color); text-align: center; flex-shrink: 0; }

/* ================================================================ */
/* --- 3. Подвал (Footer) --- */
/* ================================================================ */
.site-footer { background-color: var(--dark-color); color: var(--light-color); padding: 40px 0; margin-top: 50px; }
.footer-content { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 30px; }
.footer-block { flex: 1; min-width: 250px; }
.footer-block h4 { margin-bottom: 15px; color: var(--white-color); }
.footer-block a { color: var(--light-color); }
.footer-block a:hover { color: var(--secondary-color); }
.footer-block ul li { margin-bottom: 8px; }

/* ================================================================ */
/* --- 4. Общие компоненты и классы --- */
/* ================================================================ */
.site-main { padding: 40px 0; }
.section-title { text-align: center; font-size: 2.5rem; margin-bottom: 40px; font-weight: 600; }
.page-main-title { font-size: 3rem; text-align: center; margin-bottom: 10px; }
.page-subtitle { font-size: 1.2rem; text-align: center; color: var(--gray-color); margin-bottom: 50px; }
.text-center { text-align: center; }
.btn { display: inline-block; padding: 12px 25px; border-radius: 5px; font-weight: 600; text-align: center; transition: all 0.3s ease; cursor: pointer; border: 1px solid transparent; }
.btn-primary { background-color: var(--primary-color); color: var(--white-color); border-color: var(--primary-color); }
.btn-primary:hover { background-color: var(--secondary-color); border-color: var(--secondary-color); color: var(--white-color); }
.btn-secondary { background-color: var(--white-color); color: var(--primary-color); border-color: var(--primary-color); }
.btn-secondary:hover { background-color: var(--primary-color); color: var(--white-color); }
.btn-lg { font-size: 1.1rem; padding: 15px 35px; }
.btn.btn-sm { padding: 5px 15px; font-size: 0.9rem; }
.btn-success { background-color: #28a745 !important; border-color: #28a745 !important; color: white !important; cursor: default !important; }
.form-message { padding: 15px; margin-bottom: 20px; border-radius: 5px; border: 1px solid transparent; }
.form-message.success { background-color: #d4edda; border-color: #c3e6cb; color: #155724; }
.form-message.error { background-color: #f8d7da; border-color: #f5c6cb; color: #721c24; }
.form-group.honeypot { display: none !important; visibility: hidden; position: absolute; left: -9999px; }
.contact-form .form-group { margin-bottom: 20px; }
.contact-form label { display: block; margin-bottom: 8px; font-weight: 600; }
.contact-form input[type="text"], .contact-form input[type="email"], .contact-form input[type="tel"], .contact-form input[type="password"], .contact-form textarea, .contact-form select { width: 100%; padding: 12px; border: 1px solid var(--border-color); border-radius: 5px; font-size: 1rem; transition: border-color 0.3s ease, box-shadow 0.3s ease; }
.contact-form input:focus, .contact-form textarea:focus, .contact-form select:focus { outline: none; border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25); }
.contact-form textarea { resize: vertical; }
.cookie-banner { position: fixed; bottom: 20px; left: 20px; right: 20px; max-width: 1000px; margin: 0 auto; background-color: rgba(33, 37, 41, 0.95); color: var(--white-color); padding: 20px; border-radius: 8px; display: none; z-index: 1001; align-items: center; gap: 20px; box-shadow: 0 5px 20px rgba(0,0,0,0.2); opacity: 1; transition: opacity 0.3s ease, transform 0.3s ease; transform: translateY(0); }
.cookie-banner p { margin: 0; line-height: 1.5; }
.cookie-banner a { color: var(--secondary-color); text-decoration: underline; }
.banner-buttons { display: flex; gap: 10px; flex-shrink: 0; }

/* ================================================================ */
/* --- 5. Стили для конкретных страниц и блоков --- */
/* ================================================================ */

/* --- Главная страница --- */
.hero-section { background-color: var(--light-color); padding: 80px 0; text-align: center; }
.hero-content h1 { font-size: 3.5rem; font-weight: 700; margin-bottom: 20px; }
.hero-subtitle { font-size: 1.25rem; color: var(--gray-color); max-width: 700px; margin: 0 auto 30px; }
.features-section { padding: 60px 0; }
.features-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; }
.feature-item { text-align: center; }
.feature-icon { font-size: 3rem; color: var(--primary-color); margin-bottom: 15px; }
.feature-item h3 { font-size: 1.25rem; margin-bottom: 10px; }
.features-grid.six-items { grid-template-columns: repeat(3, 1fr); }
.services-preview-section { padding: 60px 0; background-color: var(--light-color); }
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; margin-bottom: 40px; }
.service-card { background-color: var(--white-color); border: 1px solid var(--border-color); border-radius: 8px; padding: 30px; text-align: center; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.service-card:hover { transform: translateY(-10px); box-shadow: 0 10px 20px rgba(0,0,0,0.08); }
.service-card h3 { font-size: 1.5rem; margin-bottom: 15px; }
.service-price { font-size: 1.75rem; font-weight: 700; color: var(--primary-color); margin-bottom: 15px; }
.service-description { color: var(--gray-color); margin-bottom: 25px; min-height: 70px; }
.how-it-works-section { padding: 60px 0; }
.timeline { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; position: relative; }
.timeline::before { content: ''; position: absolute; top: 25px; left: 15%; right: 15%; height: 2px; background-color: var(--border-color); z-index: -1; }
.timeline-item { text-align: center; }
.timeline-step { width: 50px; height: 50px; border-radius: 50%; background-color: var(--primary-color); color: var(--white-color); display: flex; justify-content: center; align-items: center; font-size: 1.5rem; font-weight: 700; margin: 0 auto 20px; border: 3px solid var(--light-color); }
.timeline-item h4 { font-size: 1.2rem; margin-bottom: 10px; }
.cloud-promo-section { padding: 80px 0; background-color: var(--dark-color); color: var(--white-color); }
.cloud-promo-content { display: flex; align-items: center; gap: 50px; }
.cloud-promo-icon { flex-shrink: 0; }
.cloud-promo-icon i { font-size: 8rem; color: var(--primary-color); opacity: 0.8; }
.cloud-promo-text h2 { font-size: 2.5rem; margin-bottom: 15px; }
.cloud-promo-text .promo-subtitle { font-size: 1.2rem; color: var(--light-color); margin-bottom: 25px; }
.promo-features-list { list-style: none; padding: 0; margin-bottom: 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.promo-features-list li { display: flex; align-items: center; gap: 10px; font-size: 1.1rem; }
.promo-features-list i { color: var(--primary-color); font-size: 1.2rem; }
.promo-gift { background-color: rgba(255, 255, 255, 0.1); border-left: 4px solid var(--primary-color); padding: 15px; border-radius: 4px; margin: 30px 0; display: flex; align-items: center; gap: 15px; }
.promo-gift i { font-size: 1.5rem; color: var(--primary-color); }
.cloud-promo-section .btn-primary { background-color: var(--primary-color); border-color: var(--primary-color); }

/* --- Страницы Услуг, Обо мне, Контакты и др. --- */
.services-category-section { margin-bottom: 50px; }
.category-title { font-size: 2.2rem; font-weight: 600; margin-bottom: 25px; padding-bottom: 10px; border-bottom: 2px solid var(--primary-color); }
.service-list { display: flex; flex-direction: column; gap: 20px; }
.service-item { display: flex; justify-content: space-between; align-items: center; padding: 20px; background-color: var(--light-color); border: 1px solid var(--border-color); border-radius: 8px; transition: box-shadow 0.3s ease; flex-wrap: wrap; }
.service-item:hover { box-shadow: 0 5px 15px rgba(0,0,0,0.07); }
.service-info { flex: 3; padding-right: 20px; }
.service-name { font-size: 1.4rem; margin-bottom: 8px; font-weight: 600; display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.service-description-full { color: var(--gray-color); line-height: 1.5; }
.service-price-action { flex: 1; text-align: right; min-width: 220px; }
.service-price-action .service-price { font-size: 1.5rem; font-weight: 700; color: var(--primary-color); margin-bottom: 5px; }
.service-badge { background-color: var(--primary-color); color: var(--white-color); padding: 3px 10px; border-radius: 15px; font-size: 0.8rem; font-weight: 500; white-space: nowrap; }
.on-site-fee-note { display: block; color: var(--gray-color); font-size: 0.9rem; margin-bottom: 10px; text-align: right; }
.service-detail-layout { display: flex; gap: 40px; }
.service-detail-content { flex: 2; }
.service-detail-sidebar { flex: 1; min-width: 300px; }
.about-intro-section { display: flex; gap: 40px; align-items: flex-start; margin-bottom: 60px; }
.about-photo { flex-basis: 250px; flex-shrink: 0; }
.about-photo img { border-radius: 50%; border: 5px solid var(--light-color); box-shadow: 0 4px 15px rgba(0,0,0,0.1); }
.about-text { flex-grow: 1; }
.about-text .lead-text { font-size: 1.2rem; font-weight: 500; margin-bottom: 20px; }
.about-text p { margin-bottom: 15px; }
.certificates-section { padding: 60px 0; background-color: var(--light-color); }
.certificates-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.certificate-card { background-color: var(--white-color); border: 1px solid var(--border-color); border-radius: 8px; padding: 30px; text-align: center; display: flex; flex-direction: column; justify-content: space-between; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.certificate-card:hover { transform: translateY(-10px); box-shadow: 0 10px 20px rgba(0,0,0,0.08); }
.certificate-card-icon { font-size: 3.5rem; color: var(--primary-color); margin-bottom: 15px; }
.certificate-card-title { font-size: 1.25rem; margin-bottom: 15px; flex-grow: 1; }
.certificate-card-description { color: var(--gray-color); font-size: 0.9rem; margin-bottom: 25px; }
.certificate-card .btn i { margin-right: 8px; }
.contacts-wrapper { display: flex; gap: 50px; margin-top: 40px; }
.contact-details { flex: 1; }
.contact-form-container { flex: 1.5; }
.contact-details h2, .contact-form-container h2 { font-size: 1.8rem; margin-bottom: 20px; }
.contact-item { display: flex; align-items: center; margin-bottom: 20px; font-size: 1.1rem; }
.contact-item i { font-size: 1.5rem; color: var(--primary-color); margin-right: 15px; width: 25px; text-align: center; }
.contact-item strong { display: block; color: var(--dark-color); }
.contact-item span, .contact-item a { color: var(--gray-color); }
.contact-item a:hover { color: var(--primary-color); }
.text-content { max-width: 800px; margin: 0 auto; }
.text-content h1 { font-size: 2.5rem; margin-bottom: 10px; }
.text-content h3 { font-size: 1.5rem; margin-top: 40px; margin-bottom: 15px; padding-bottom: 10px; border-bottom: 1px solid var(--border-color); }
.text-content p, .text-content li { margin-bottom: 15px; line-height: 1.7; }
.text-content ul { padding-left: 20px; list-style-type: disc; }
.text-content strong { color: var(--dark-color); }
.text-content .highlight { background-color: #fff3cd; border-left: 4px solid #ffeeba; padding: 15px; border-radius: 4px; margin: 20px 0; }
.text-content .details-box { background-color: var(--light-color); border: 1px solid var(--border-color); padding: 20px; border-radius: 8px; }
.text-content .details-box p { margin-bottom: 5px; }
.auth-container { max-width: 500px; margin-top: 20px; margin-bottom: 20px; }
.auth-form-wrapper { background-color: #fff; padding: 30px 40px; border-radius: 8px; border: 1px solid var(--border-color); box-shadow: 0 5px 20px rgba(0,0,0,0.05); }
.auth-form-wrapper .page-main-title { font-size: 2rem; margin-bottom: 5px; }
.auth-form-wrapper .page-subtitle { font-size: 1rem; margin-bottom: 25px; }
.auth-links { margin-top: 25px; padding-top: 20px; border-top: 1px solid var(--border-color); text-align: center; }
.auth-links p { margin-bottom: 10px; }
.order-layout { display: flex; gap: 40px; }
.customer-data { flex: 1.5; }
.payment-data { flex: 1; }
.customer-data h3, .payment-data h3 { font-size: 1.5rem; margin-top: 0; margin-bottom: 20px; border-bottom: 1px solid var(--border-color); padding-bottom: 10px; }
.order-summary { background-color: var(--light-color); padding: 20px; border-radius: 8px; margin-bottom: 30px; }
.summary-row { display: flex; justify-content: space-between; margin-bottom: 10px; }
.summary-total { display: flex; justify-content: space-between; font-weight: 700; font-size: 1.2rem; margin-top: 15px; border-top: 2px solid var(--border-color); padding-top: 15px; }
.payment-methods { display: flex; flex-direction: column; gap: 15px; margin-top: 15px; }
.payment-method { display: block; border: 2px solid var(--border-color); padding: 15px; border-radius: 8px; cursor: pointer; transition: all 0.2s ease; position: relative; }
.payment-method input[type="radio"] { position: absolute; opacity: 0; }
.payment-method:has(input:checked) { border-color: var(--primary-color); background-color: #f0f7ff; }
.payment-method span { font-size: 1.1rem; font-weight: 600; display: flex; align-items: center; gap: 10px; }
.payment-method small { display: block; margin-top: 5px; color: var(--gray-color); padding-left: 34px; line-height: 1.3; }
.form-group-agree { margin: 20px 0; display: flex; align-items: flex-start; gap: 10px; }
.form-group-agree input[type="checkbox"] { width: auto; margin-top: 5px; flex-shrink: 0; }
.form-group-agree label { margin: 0; font-weight: 400; font-size: 0.9rem; }
.summary-row.on-site-row { color: var(--primary-color); font-weight: 500; }
.summary-row.on-site-row i { margin-right: 5px; }
#on-site-details .details-card { box-shadow: none; border: 1px solid var(--border-color); }
#on-site-details h4 { margin-top: 0; margin-bottom: 15px; }
#on-site-details select { width: 100%; padding: 12px; border: 1px solid var(--border-color); border-radius: 5px; font-size: 1rem; background-color: #fff; }
#on-site-details select:disabled { background-color: #e9ecef; cursor: not-allowed; }

/* --- Личный Кабинет --- */
.account-layout { padding: 40px 0; }
.account-wrapper { display: flex; gap: 30px; margin-top: 30px; align-items: flex-start; }
.account-sidebar { flex: 1; min-width: 250px; background: #fff; border: 1px solid var(--border-color); border-radius: 8px; padding: 15px; }
.account-sidebar ul { list-style: none; padding: 0; margin: 0; }
.account-sidebar li a { display: flex; align-items: center; padding: 12px 15px; text-decoration: none; color: var(--dark-color); border-radius: 5px; font-weight: 500; transition: all 0.2s ease; }
.account-sidebar li a i { margin-right: 12px; font-size: 1.2rem; }
.account-sidebar li a:hover { background-color: var(--light-color); color: var(--primary-color); }
.account-sidebar li.active a { background-color: var(--primary-color); color: var(--white-color); }
.account-content { flex: 3; }
.account-card { background: #fff; border: 1px solid var(--border-color); border-radius: 8px; margin-bottom: 20px; }
.account-card-header { padding: 15px 20px; border-bottom: 1px solid var(--border-color); display: flex; justify-content: space-between; align-items: center; }
.account-card-header h3 { margin: 0; font-size: 1.2rem; }
.account-card-body { padding: 20px; }
.detail-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px dashed var(--border-color); }
.digital-key-item { margin-bottom: 15px; }
.digital-key-item strong { display: block; margin-bottom: 5px; }
.digital-key-item pre { background-color: var(--light-color); padding: 10px; border-radius: 5px; border: 1px solid var(--border-color); white-space: pre-wrap; word-break: break-all; }
.proposal-item { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; }
.proposal-item:not(:last-child) { border-bottom: 1px dashed var(--border-color); }
.proposal-info strong { display: block; }
.proposal-info span { font-size: 0.9rem; color: var(--gray-color); }
.proposal-status { display: flex; gap: 10px; }
.chat-container { margin-top: 20px; }
.chat-messages { max-height: 400px; overflow-y: auto; border: 1px solid var(--border-color); border-radius: 8px; padding: 15px; margin-bottom: 20px; }
.chat-message { display: flex; margin-bottom: 15px; }
.chat-message.user { justify-content: flex-end; }
.chat-message .message-bubble { max-width: 70%; padding: 10px 15px; border-radius: 15px; }
.chat-message.admin .message-bubble { background-color: var(--light-color); border-top-left-radius: 0; }
.chat-message.user .message-bubble { background-color: #eafaf1; color: #1e6641; border-top-right-radius: 0; }
.message-bubble .message-text { margin: 0 0 5px; }
.message-bubble .message-time { font-size: 0.8rem; color: var(--gray-color); text-align: right; }
.debt-notification { background-color: #fff3cd; color: #856404; border: 1px solid #ffeeba; border-radius: 8px; padding: 20px; margin-bottom: 30px; display: flex; align-items: center; gap: 20px; }
.debt-notification i { font-size: 2.5rem; }
.debt-notification p { margin: 5px 0 0; }

/* ================================================================ */
/* --- 6. Адаптивность --- */
/* ================================================================ */

@media (max-width: 992px) {
    .section-title { font-size: 2rem; }
    .hero-content h1 { font-size: 2.5rem; }
    .features-grid, .features-grid.six-items { grid-template-columns: repeat(2, 1fr); }
    .services-grid { grid-template-columns: 1fr; }
    .timeline { grid-template-columns: 1fr; }
    .timeline::before { display: none; }
    .certificates-grid { grid-template-columns: repeat(2, 1fr); }
    .contacts-wrapper { flex-direction: column; }
    .main-nav, .header-contacts { display: none; }
    .burger-menu { display: block; }
    .header-cart-icon { margin-right: 0; }
    .order-layout { flex-direction: column; }
    .service-detail-layout { flex-direction: column; }
    .cloud-promo-content { flex-direction: column; text-align: center; }
    .promo-features-list { grid-template-columns: 1fr; text-align: left; }
}

@media (max-width: 768px) {
    .features-grid, .features-grid.six-items { grid-template-columns: 1fr; }
    .about-intro-section { flex-direction: column; align-items: center; text-align: center; }
    .about-text .page-main-title { text-align: center !important; }
    .certificates-grid { grid-template-columns: 1fr; }
    .track-form { flex-direction: column; }
    .order-details-grid { grid-template-columns: 1fr; }
    .account-wrapper { flex-direction: column; }
    .on-site-fee-note { text-align: left; }
    .cookie-banner { flex-direction: column; text-align: center; bottom: 10px; left: 10px; right: 10px; }
    .banner-buttons { width: 100%; justify-content: center; }
    .banner-buttons .btn { width: 50%; }
    .service-item { flex-direction: column; align-items: flex-start; text-align: left; }
    .service-price-action { text-align: left; margin-top: 20px; width: 100%; }
}

@media (max-width: 480px) {
    .payment-method { padding: 12px; }
    .payment-method span { font-size: 1rem; flex-wrap: wrap; }
    .payment-method small { font-size: 0.85rem; padding-left: 0; text-align: left; margin-top: 8px; }
    .payment-method span i { align-self: flex-start; }
}
/* --- Стили для Блога --- */
.blog-list { max-width: 800px; margin: 0 auto; }
.blog-post-preview { border-bottom: 1px solid var(--border-color); padding: 30px 0; }
.blog-post-preview:last-child { border-bottom: none; }
.post-date { font-size: 0.9rem; color: var(--gray-color); margin-bottom: 5px; }
.blog-post-preview h2 { font-size: 1.8rem; margin-bottom: 10px; }
.blog-post-preview h2 a { color: var(--dark-color); text-decoration: none; }
.blog-post-preview h2 a:hover { color: var(--primary-color); }
.blog-post-preview p { color: var(--gray-color); margin-bottom: 20px; }
.post-meta { color: var(--gray-color); text-align: center; margin-top: -20px; margin-bottom: 30px; }
.post-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 20px 0; }
/* --- Улучшенные стили для Блога и блоков кода --- */
.post-content pre[class*="language-"] {
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.post-content code[class*="language-"] {
    font-size: 0.9em;
}
/* Стили для однострочных команд */
.post-content p > code, .post-content li > code {
    background-color: #e9ecef;
    padding: 3px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    color: #c7254e; /* Розовый цвет для акцента */
}
/* --- Стили для пагинации --- */
.pagination {
    margin-top: 40px;
    text-align: center;
}
.pagination ul {
    display: inline-flex;
    list-style: none;
    padding: 0;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.pagination li {
    margin: 0;
}
.pagination li a,
.pagination li span {
    display: block;
    padding: 10px 15px;
    background: var(--white-color);
    border-right: 1px solid var(--border-color);
    text-decoration: none;
    color: var(--primary-color);
    transition: background-color 0.2s ease;
}
.pagination li:last-child a,
.pagination li:last-child span {
    border-right: none;
}
.pagination li a:hover {
    background-color: var(--light-color);
}
.pagination li.active span {
    background-color: var(--primary-color);
    color: var(--white-color);
    cursor: default;
}
.pagination li.disabled span {
    background-color: var(--light-color);
    color: var(--gray-color);
    cursor: not-allowed;
}
/* --- Стили для формы отслеживания заказа --- */
.track-form.contact-form .form-group {
    margin-bottom: 15px; /* Уменьшаем отступ под полем ввода */
}
/* --- Стили для блока "Социальная скидка" --- */
.social-promo-section {
    padding: 60px 0;
    background-color: #eafaf1; /* Приятный светло-зеленый фон */
    border-top: 1px solid #d4edda;
    border-bottom: 1px solid #d4edda;
}
.social-promo-content {
    display: flex;
    align-items: center;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
}
.social-promo-icon i {
    font-size: 6rem;
    color: #28a745; /* Зеленый цвет сердца */
}
.social-promo-text h3 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--dark-color);
}
.social-promo-text p {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 20px;
}
.discount-value {
    font-size: 4rem;
    font-weight: 700;
    color: #28a745;
    text-align: center;
    line-height: 1;
}
.discount-description {
    text-align: center;
    font-weight: 500;
    margin-bottom: 20px !important;
}
.social-promo-text small {
    display: block;
    color: var(--gray-color);
    font-size: 0.9rem;
    margin-top: 20px;
    border-top: 1px dashed var(--border-color);
    padding-top: 15px;
}

@media (max-width: 768px) {
    .social-promo-content {
        flex-direction: column;
        text-align: center;
    }
}
.promocode-block { border-top: 1px dashed var(--border-color); margin-top: 20px; padding-top: 20px; }
.promocode-input-group { display: flex; gap: 10px; }
.promocode-input-group input { flex-grow: 1; }
#promocode-message { margin-top: 10px; font-weight: 500; }
.promo-success { color: green; }
.promo-error { color: red; }
.discount-row { color: green; font-weight: 500; }
/* --- Стили для блока "Акция дня" --- */
.daily-deal-section {
    padding: 60px 0;
    background-color: var(--white-color); /* Или можно var(--light-color) для контраста */
}

.daily-deal-section .section-title i {
    color: #ff9800; /* Оранжевый цвет для иконки огня */
}

.deal-card {
    max-width: 800px;
    margin: 0 auto;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white-color);
    padding: 40px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 86, 179, 0.3);
}

.deal-card h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 15px;
}

.deal-card h3 a {
    color: var(--white-color);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.deal-card h3 a:hover {
    opacity: 0.9;
}

.deal-card .deal-text {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 30px;
    opacity: 0.9;
}

.promocode-container {
    background-color: rgba(255, 255, 255, 0.1);
    border: 2px dashed var(--white-color);
    padding: 20px;
    border-radius: 8px;
    display: inline-block;
}

.promocode-container span {
    display: block;
    font-size: 1rem;
    opacity: 0.8;
}

.promocode-container .promocode-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin-top: 5px;
    color: #ffd700; /* Золотой цвет для промокода */
}

.deal-card small {
    display: block;
    margin-top: 15px;
    opacity: 0.7;
}
/* Стили для "Акции дня" v2 */
.deal-footer { display: flex; justify-content: space-between; align-items: center; width: 100%; margin: 15px 0; }
.remaining-codes { font-weight: bold; background: rgba(255,255,255,0.2); padding: 5px 10px; border-radius: 20px; font-size: 0.9rem; }
.deal-expiry { font-style: italic; opacity: 0.9; font-size: 0.9rem; }

/* Стили для кнопки очистки кэша */
#clear-cache-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background-color: var(--dark-color);
    color: var(--white-color);
    border: none;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 1002;
    transition: transform 0.2s ease;
}
#clear-cache-btn:hover {
    transform: scale(1.1) rotate(90deg);
}
/* --- Стили для "Акции дня" v3 --- */
.deal-card-v2 {
    max-width: 850px;
    margin: 0 auto;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.07);
    overflow: hidden;
}
.deal-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white-color);
    padding: 25px 30px;
}
.deal-header .deal-tag {
    display: inline-block;
    background: rgba(255,255,255,0.2);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 15px;
}
.deal-header h3 {
    font-size: 2rem;
    margin: 0;
}
.deal-body {
    padding: 30px;
}
.deal-audience {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    text-align: left;
    margin-bottom: 30px;
}
.audience-block h4 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.2rem;
    color: var(--dark-color);
    margin-bottom: 10px;
}
.audience-block h4 i {
    color: var(--primary-color);
}
.audience-block p {
    color: var(--gray-color);
    line-height: 1.6;
}
.deal-benefit {
    background: var(--light-color);
    border-radius: 8px;
    padding: 15px;
    font-size: 1.1rem;
    border-left: 4px solid var(--primary-color);
}
.deal-promo-footer {
    background: var(--light-color);
    padding: 20px 30px;
    border-top: 1px solid var(--border-color);
}
.deal-promo-footer .promocode-container {
    border-color: var(--primary-color);
    background: #fff;
}
.deal-promo-footer .promocode-container span { color: var(--dark-color); }
@media(max-width: 768px) {
    .deal-audience { grid-template-columns: 1fr; }
}
.read-more-link {
    display: inline-block;
    margin-top: 10px;
    font-size: 0.9rem;
    font-weight: 500;
}
/* --- Стили для страницы Контакты (дополнения) --- */
#yandex-map {
    border: 1px solid var(--border-color);
}
.international-info-block {
    margin-top: 30px;
    padding: 20px;
    background-color: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}
.international-info-block h4 {
    margin-top: 0;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.international-info-block p {
    margin: 0;
}
/* --- Стили для страницы Корзины --- */
.cart-layout {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}
.cart-items-list {
    flex: 2;
}
.cart-summary {
    flex: 1;
    min-width: 300px;
    position: sticky;
    top: 100px;
}
.cart-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
}
.cart-item:not(:last-child) {
    margin-bottom: 15px;
}
.cart-item-name {
    font-weight: 600;
    color: var(--dark-color);
    text-decoration: none;
}
.cart-item-name:hover {
    color: var(--primary-color);
}
.cart-item-price {
    display: block;
    color: var(--gray-color);
    font-size: 0.9rem;
}
.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--gray-color);
    transition: color 0.2s ease;
}
.btn-icon:hover {
    color: var(--dark-color);
}
.remove-from-cart-btn:hover {
    color: #dc3545; /* Красный при наведении */
}
#clear-cart-btn {
    background-color: var(--gray-color);
    border-color: var(--gray-color);
}
#clear-cart-btn:hover {
    background-color: var(--dark-color);
    border-color: var(--dark-color);
}

@media (max-width: 992px) {
    .cart-layout {
        flex-direction: column;
    }
    .cart-summary {
        position: static;
        width: 100%;
    }
}
/* --- Стили для поиска и фильтров --- */
.services-filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}
.search-form {
    position: relative;
    flex-grow: 1;
    min-width: 250px;
}
#service-search-input {
    width: 100%;
    padding: 12px 15px 12px 40px;
    border-radius: 25px;
    border: 1px solid var(--border-color);
    font-size: 1rem;
}
.search-form i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-color);
}
.filter-buttons {
    display: flex;
    gap: 10px;
    background-color: var(--light-color);
    padding: 5px;
    border-radius: 25px;
}
.filter-btn {
    background: none;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}
.filter-btn.active {
    background-color: var(--primary-color);
    color: var(--white-color);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
#services-list-container {
    transition: opacity 0.3s ease;
}
/* ================================================================ */
/* --- Стили для блока анонса уроков "IT-ликбез" --- */
/* ================================================================ */

.it-lessons-promo-section {
    padding: 60px 0;
    background-color: var(--light-color); /* Используем цвет фона как у других секций */
}

.it-lessons-promo-card {
    display: flex;
    align-items: center;
    gap: 30px;
    background: var(--white-color);
    padding: 40px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.07);
    transition: all 0.3s ease;
}

.it-lessons-promo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
}

.it-lessons-promo-card .promo-icon {
    flex-shrink: 0;
}

.it-lessons-promo-card .promo-icon i {
    font-size: 4rem;
    color: var(--primary-color);
    background-color: #f0f7ff;
    padding: 20px;
    border-radius: 50%;
    line-height: 1;
}

.it-lessons-promo-card .promo-content {
    flex-grow: 1;
}

.it-lessons-promo-card .promo-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 20px;
}

.it-lessons-promo-card .lessons-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.it-lessons-promo-card .lessons-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.it-lessons-promo-card .lessons-list i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.it-lessons-promo-card .promo-cta {
    margin: 0;
    color: var(--gray-color);
}

.it-lessons-promo-card .promo-action {
    flex-shrink: 0;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 992px) {
    .it-lessons-promo-card {
        flex-direction: column;
        text-align: center;
        padding: 30px;
    }
    .it-lessons-promo-card .lessons-list li {
       justify-content: center;
    }
}
/* ================================================================ */
/* --- Стили для блока превью уроков на главной --- */
/* ================================================================ */

.lessons-preview-section {
    padding: 60px 0;
    background-color: var(--white-color); /* Или var(--light-color), если хотите фон */
}

.lessons-preview-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.lesson-preview-card {
    background-color: var(--white-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.lesson-preview-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.lesson-preview-icon {
    margin-bottom: 20px;
    font-size: 2.5rem;
    color: var(--primary-color);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--light-color);
    border-radius: 50%;
}

.lesson-preview-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
}

.lesson-preview-body {
    flex-grow: 1; /* Этот трюк заставляет футер прижаться к низу */
}

.lesson-preview-body h3 {
    font-size: 1.4rem;
    margin-top: 0;
    margin-bottom: 15px;
    line-height: 1.4;
    min-height: 58px; /* Примерная высота для 2 строк текста */
}

.lesson-preview-snippet {
    color: var(--gray-color);
    line-height: 1.6;
    margin-bottom: 20px;
}

.lesson-preview-footer .read-more-link {
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
}
.lesson-preview-footer .read-more-link:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* Адаптивность */
@media (max-width: 992px) {
    .lessons-preview-grid {
        grid-template-columns: 1fr;
    }
    .lesson-preview-body h3 {
        min-height: auto; /* На мобильных убираем фиксацию высоты */
    }
}
/* ================================================================ */
/* --- Стили для плейсхолдеров в блоке превью уроков --- */
/* ================================================================ */

.lesson-preview-card.placeholder {
    background: 
        linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(240, 247, 255, 0.1) 100%),
        url('data:image/svg+xml,<svg width="100" height="100" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"><path d="M11 18.28L18.28 11 82 74.72 74.72 82 11 18.28zM18.28 89L89 18.28 82 11 11 82l7.28 7z" fill="%23e9ecef" fill-opacity="0.4" fill-rule="evenodd"/></svg>');
    border-style: dashed;
    text-align: center;
    justify-content: center;
    align-items: center;
}

.lesson-preview-card.placeholder:hover {
    transform: none;
    box-shadow: 0 10px 30px rgba(0,0,0,0.07);
}

.placeholder-content {
    max-width: 400px;
}

.placeholder-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    opacity: 0.7;
}

.placeholder-title {
    font-size: 1.4rem;
    color: var(--dark-color);
    margin-bottom: 10px;
}

.placeholder-time {
    font-size: 1.1rem;
    color: var(--gray-color);
    margin-bottom: 15px;
}

.placeholder-time strong {
    color: var(--primary-color);
    font-weight: 700;
}

.placeholder-text {
    color: var(--gray-color);
    line-height: 1.6;
}