/* Базовые стили */
:where([class^="ri-"])::before { content: "\f3c2"; }
body { 
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
    overflow-x: hidden;
    width: 100%;
    position: relative;
    color: #3C3C3C;
    line-height: 1.6;
}

/* Стили для типографики */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    line-height: 1.2;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

p, li, a, span, button, input, textarea, select {
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
}

.font-serif {
    font-family: 'Playfair Display', serif;
}

.font-sans {
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
}

.service-card:hover { transform: translateY(-4px); }

/* Стили для модальных окон */
.modal {
    display: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow-y: auto;
    overflow-x: hidden;
}

.modal.active {
    opacity: 1 !important;
    visibility: visible !important;
    display: flex !important;
}

.modal.hidden {
    display: none !important;
}

.modal-content {
    transform: scale(0.9);
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
    background-color: white;
    border-radius: 8px;
    padding: 2rem;
    position: relative;
    width: 100%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    opacity: 0;
    margin: auto;
}

.modal.active .modal-content {
    transform: scale(1);
    opacity: 1;
}

/* Анимации */
@keyframes slideIn {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes slideOut {
    from { transform: translateY(0); opacity: 1; }
    to { transform: translateY(-100%); opacity: 0; }
}

/* Мобильное меню */
#mobileMenu {
    z-index: 9980 !important;
}

/* Фиксированные элементы */
.fixed {
    z-index: 9970 !important;
}

/* Уведомления */
.notification {
    z-index: 9995 !important;
    position: fixed !important;
    top: 1rem !important;
    right: 1rem !important;
}

/* Дополнительные стили для анимаций */
.scale-100 {
    transform: scale(1) !important;
}

.fade-enter {
    opacity: 0;
}

.fade-enter-active {
    opacity: 1;
    transition: opacity 0.3s ease-in-out;
}

.fade-exit {
    opacity: 1;
}

.fade-exit-active {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

/* Стили для форм */
.error-message {
    color: #ef4444 !important;
    font-size: 0.875rem !important;
    margin-top: 0.25rem !important;
}

/* Анимация загрузки */
.animate-spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Стили для карточек проблем */
.prob-sec {
    -webkit-box-align: start;
    -ms-flex-align: start;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    align-items: flex-start;
    background: hsl(0deg 0% 100% / 96%);
    border: 1px solid #fff;
    border-radius: 30px;
    -webkit-box-shadow: 0 4px 24px rgba(123, 152, 198, .25);
    box-shadow: 0 4px 24px rgba(123, 152, 198, .25);
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    -ms-flex-direction: column;
    flex-direction: column;
    max-width: 420px;
    padding: 40px 30px;
}

.problems-section {
    background: #dbf6ff;
    background-image: url(/images/another2-min.png);
    background-position: center;
    background-repeat: no-repeat;
}

.probmob {
    background-color: rgb(0 110 101);
    border-radius: 50px;
    color: #fff;
    margin-bottom: 25px;
    padding: 20px 30px 20px;
    display: inline-block;
}

@media (max-width: 768px) {
    .problems-section {
        background: #dbf6ff;
        background-image: url(/images/another2-min.png);
    }
}

.rounded-button {
    border-radius: 8px;
    background-color: #01493b;
    color: white;
    transition: background-color 0.3s ease;
}

.rounded-button:hover {
    background-color: #013a2f;
}

/* Стили для секции услуг */
.services-section {
    background-color: #FAF9F6;
    padding: 80px 0;
}

.services-section h2 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: #3C3C3C;
    margin-bottom: 40px;
}

.services-section .probmob {
    background-color: rgb(0 110 101);
    border-radius: 50px;
    color: #FFFFFF;
    margin-bottom: 25px;
    padding: 20px 30px;
    display: inline-block;
    font-family: 'Playfair Display', serif;
    font-weight: 600;
}

.services-section .service-card {
    background-color: #FFFFFF;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    border-radius: 12px;
}

.services-section .service-card:hover { 
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.services-section .service-card h3 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: #3C3C3C;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.services-section .service-card p {
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
    color: #7A7A7A;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.services-section .service-card .text-primary {
    color: #B8A27A;
    font-family: 'DM Sans', 'Inter', Arial, sans-serif;
    font-weight: 700;
    font-size: 1.25rem;
}

.services-section .service-card button {
    background-color: #01493b;
    color: #FFFFFF;
    border-radius: 30px;
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.services-section .service-card button:hover {
    background-color: #013a2f;
}

.services-section .service-card .icon-container {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #EFE8DE;
    border-radius: 50%;
}

.services-section .service-card .icon-container img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.services-section .cards-alt .service-card {
    background-color: #F8F6F2;
}

@media (max-width: 768px) {
    .services-section {
        background: #FAF9F6;
        padding: 60px 0 40px;
    }

    .services-section .service-card {
        margin: 0 auto 20px;
        max-width: 90%;
        padding: 25px 20px;
    }
    
    .services-section .probmob {
        font-size: 1.25rem;
        padding: 15px 25px;
        margin-bottom: 20px;
    }
    
    /* Адаптация модальных окон */
    .modal-content {
        padding: 1.5rem;
        margin: 1rem;
        max-width: calc(100% - 2rem);
        width: 100%;
    }
    
    .modal-content h2 {
        font-size: 1.5rem;
    }
    
    .modal-content h3 {
        font-size: 1.25rem;
    }
    
    .modal-content p, 
    .modal-content li {
        font-size: 0.875rem;
    }
    
    .modal-content .list-disc {
        padding-left: 1.25rem;
    }

    /* Исправление горизонтального скролла */
    .container {
        width: 100%;
        max-width: 100%;
        padding-left: 1rem;
        padding-right: 1rem;
        margin-left: auto;
        margin-right: auto;
    }

    section {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    .grid {
        margin-left: 0;
        margin-right: 0;
    }

    .grid > * {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
}

/* Стили для модальных окон */
.modal-content h3 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    color: #3C3C3C;
}

.modal-content p, 
.modal-content li {
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
    color: #7A7A7A;
    line-height: 1.6;
}

.modal-content h4 {
    font-family: 'Playfair Display', serif;
    font-weight: 600;
    color: #3C3C3C;
}

.modal-content .text-primary {
    color: #B8A27A;
    font-weight: 700;
}

.modal-content a {
    background-color: #2A6E65;
    color: #FFFFFF;
}

.modal-content a:hover {
    background-color: rgba(42, 110, 101, 0.85);
}

.modal-content button[data-close-modal] {
    background-color: #01493b;
    color: white;
    border-radius: 8px;
}

.modal-content button[data-close-modal]:hover {
    background-color: #013a2f;
}

/* Стили для блога и статей блога */
.blog-content h2 { 
    font-size: 1.875rem;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.blog-content h3 { 
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

.blog-content p { 
    margin-bottom: 1rem;
    line-height: 1.7;
}

.blog-content ul, .blog-content ol { 
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.blog-content ul { list-style-type: disc; }
.blog-content ol { list-style-type: decimal; }
.blog-content li { margin-bottom: 0.5rem; }

.blog-content img { 
    max-width: 100%;
    height: auto;
    margin: 1.5rem 0;
    border-radius: 0.5rem;
}

.blog-content blockquote {
    border-left: 4px solid #01493b;
    padding-left: 1rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #4B5563;
}

.blog-content a {
    color: #01493b;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
    font-weight: 500;
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
    max-width: 100%;
    display: inline-block;
}

.blog-content a:hover {
    text-decoration-color: rgba(1, 73, 59, 1);
    color: #013a2f;
}

.blog-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.blog-content table th,
.blog-content table td {
    border: 1px solid #E5E7EB;
    padding: 0.75rem;
}

.blog-content table th {
    background-color: #F9FAFB;
    font-weight: 600;
}

.blog-content table tr:nth-child(even) {
    background-color: #F9FAFB;
}

/* Стили для карточек блога */
.blog-card:hover img {
    transform: scale(1.05);
}

.blog-card img {
    transition: all 0.3s ease-in-out;
}

/* Стили для секции последних статей на главной */
.recent-blog-section .blog-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.recent-blog-section .blog-card a {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.recent-blog-section .blog-card .p-4 {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.recent-blog-section .blog-card h3 {
    flex: 1;
}

/* Стили для элементов в блоге */
.category-filter.active {
    background-color: #01493b;
    color: white;
}

/* Адаптивные стили для блога */
@media (max-width: 768px) {
    .blog-content h2 {
        font-size: 1.5rem;
        line-height: 1.3;
    }
    
    .blog-content h3 {
        font-size: 1.25rem;
        line-height: 1.3;
    }
    
    .blog-content blockquote {
        margin-left: 0;
    }
    
    .blog-content a {
        word-wrap: break-word;
        overflow-wrap: break-word;
        word-break: break-word;
        hyphens: auto; 
        display: inline-block;
        max-width: 100%;
    }
    
    /* Исправление для длинных URL в ссылках */
    .blog-content a[href^="http"] {
        font-size: 15px;
    }
}

/* Стили для кнопок навигации и закрытия */
.swiper-button-prev:after,
.swiper-button-next:after {
  font-size: 1.5rem;
  color: #555;
}

[data-close-modal] {
  cursor: pointer;
  transition: color 0.2s;
}

[data-close-modal]:hover {
  color: #01493b;
}

/* Стили для кнопок модальных окон */
[data-service-button] {
    cursor: pointer;
    position: relative;
    overflow: hidden;
    background-color: #01493b;
    color: white;
    transition: all 0.3s ease;
}

[data-service-button]:hover {
    background-color: #013a2f;
}

/* Стили для оверлея модального окна */
.modal::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: -1;
}

/* Стили для новой цветовой схемы hero-секции */
.hero-section {
    background-color: #01493b;
}

.hero-section h1 {
    color: #FAF9F6;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.hero-section p, .hero-section .greeting {
    color: #faf9f6;
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
    line-height: 1.7;
}

.hero-section .greeting {
    font-family: 'Playfair Display', serif;
    font-weight: 500;
    font-style: italic;
}

.hero-section span.accent {
    color: #D8CAB8;
    font-weight: 700;
}

.hero-section .cta-button {
    background-color: #01493b;
    color: white;
    font-weight: 600;
    letter-spacing: 0.5px;
    padding: 0.75rem 1.5rem;
}

.hero-section .cta-button:hover {
    background-color: #013a2f;
}

.hero-section .reviews-button {
    border: 1px solid #01493b;
    color: #01493b;
}

.hero-section .reviews-button:hover {
    background-color: #01493b;
    color: white;
}

/* Стили для блока "Обо мне" */
.about-section {
    background-color: #FAF9F6;
}

.about-section h2 {
    color: #3C3C3C;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    position: relative;
    padding-bottom: 15px;
}

.about-section h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: #B8A27A;
}

.about-section p {
    color: #3C3C3C;
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
    line-height: 1.7;
    font-size: 1.05rem;
}

.about-section .secondary-text {
    color: #7A7A7A;
    font-style: italic;
}

.about-section .tag-container .tag {
    background-color: #EDE9DF;
    border: 1px solid #B8A27A;
    color: #3C3C3C;
    font-family: 'DM Sans', 'Inter', Arial, sans-serif;
    font-weight: 500;
}

.about-section .tag i {
    color: #B8A27A;
}

.about-section .image-card {
    background-color: #EFE8DE;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-section .image-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* Стили для сервисов */
.services-section {
    background-color: #FAF9F6;
}

.service-card {
    transition: all 0.3s ease;
    border-radius: 12px;
}

.service-card:hover { 
    transform: translateY(-4px); 
}

.icon-container {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background-color: #EFE8DE;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-container img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.service-card h3 {
    font-family: 'Playfair Display', serif;
    margin-bottom: 0.75rem;
}

.service-card p {
    color: #3C3C3C;
}

.rounded-button {
    border-radius: 8px;
    background-color: #01493b;
    color: white;
    transition: background-color 0.3s ease;
}

.rounded-button:hover {
    background-color: #013a2f;
}

/* Кнопки и элементы действия */
.cta-button {
    background-color: #01493b;
    color: white;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.cta-button:hover {
    background-color: #013a2f;
    transform: translateY(-2px);
}

.reviews-button {
    border: 1px solid #01493b;
    color: #01493b;
    border-radius: 8px;
    font-weight: 500;
}

.reviews-button:hover {
    background-color: #01493b;
    color: white;
}

/* Карточки и контейнеры */
.tag {
    background-color: #EFE8DE;
    border-radius: 8px;
}

.tag i {
    color: #CBA5A0;
}

.image-card {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.image-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* Цветовые акценты */
.accent {
    color: #CBA5A0;
}

.secondary-text {
    color: #666;
}

.greeting {
    color: #CBA5A0;
    font-family: 'Playfair Display', serif;
}

/* Медиа-запросы для адаптивности */
@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    .service-card {
        padding: 1.25rem;
    }
    
    .icon-container {
        width: 56px;
        height: 56px;
    }
    
    .icon-container img {
        width: 28px;
        height: 28px;
    }
    
    .rounded-button, .cta-button, .reviews-button {
        width: 100%;
        display: block;
        text-align: center;
    }
    
    .tag {
        padding: 0.5rem 0.75rem;
    }
    
    .tag-container {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 1rem;
        margin-bottom: 1.5rem;
    }
}

/* Фикс высоты для мобильных */
@media (max-width: 480px) {
    .hero-section {
        min-height: 80vh;
    }
    
    .image-card img {
        height: 160px;
    }
}

/* Стили для секции методических материалов */
.materials-section {
    background-color: #FAF9F6;
}

.materials-section h2 {
    color: #3C3C3C;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    position: relative;
    padding-bottom: 15px;
}

.materials-section h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: #B8A27A;
}

.materials-section h3 {
    font-family: 'Playfair Display', serif;
    color: #3C3C3C;
}

.materials-section p {
    color: #7A7A7A;
    font-family: 'Inter', 'DM Sans', Arial, sans-serif;
}

.materials-section .rounded-button {
    background-color: #01493b;
    color: #FFFFFF;
    transition: all 0.3s ease;
}
.rounded-button2 {
    background-color: #01493b;
    color: white;
    border-radius: 8px;
    transition: all 0.3s ease;
}
.rounded-button2:hover {
    background-color: #013a2f;
}
.materials-section .rounded-button:hover {
    background-color: #013a2f;
}

.materials-section a[href*="request.php"]:not(.rounded-button) {
    background-color: #2A6E65;
    color: #FFFFFF;
    transition: background-color 0.3s ease;
}

.materials-section a[href*="request.php"]:not(.rounded-button):hover {
    background-color: rgba(42, 110, 101, 0.85);
}

.materials-section .text-primary {
    color: #CBA5A0;
}

@media (max-width: 768px) {
    .materials-section .grid {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }
    
    .materials-section h2:after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .materials-section h2 {
        text-align: center;
    }
}

/* Стили для ссылок в FAQ */
#faq a {
    color: rgb(203 165 160);
    text-decoration: underline;
}

#faq a:hover {
    text-decoration: none;
}

/* Стили для cookie-баннера */
#cookieModal {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

#cookieModal:not([style*="display: none"]) {
    opacity: 1;
}

@media (max-width: 768px) {
    #cookieModal {
        max-width: calc(100% - 2rem);
    }
}