/* THEME: Soft Pastel Tech
   FONT: Nunito
*/

:root {
    /* Palette */
    --primary-color: #84A98C;
    /* Sage Green */
    --primary-dark: #52796F;
    --accent-color: #E5989B;
    /* Soft Coral */
    --bg-color: #FDFBF7;
    /* Off-white Cream */
    --card-bg: #FFFFFF;
    --text-main: #2F3E46;
    --text-muted: #6C757D;
    --border-color: #CAD2C5;

    /* Layout */
    --container-width: 1200px;
    --header-height: 70px;
    --radius-sm: 8px;
    --radius-xl: 24px;

    /* Effects */
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 15px 40px rgba(132, 169, 140, 0.2);
    --transition: all 0.3s ease;
}

/* Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Nunito', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 15px;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text-main);
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.1;
}

h2 {
    font-size: clamp(2rem, 4vw, 3rem);
}

.text-center {
    text-align: center;
}

.highlight {
    color: var(--primary-color);
}

.sub-heading {
    display: block;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-color);
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
    text-align: center;
}

.btn--primary {
    background-color: var(--primary-color);
    color: white;
}

.btn--primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn--outline {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn--outline:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn--accent {
    background-color: var(--accent-color);
    color: white;
}

.btn--small {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn--full {
    width: 100%;
}

.link-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    text-decoration: underline;
    cursor: pointer;
    font-family: inherit;
    font-size: inherit;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(253, 251, 247, 0.9);
    backdrop-filter: blur(10px);
    z-index: 100;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.header__container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--primary-dark);
}

.nav__list {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav__link {
    font-weight: 600;
    font-size: 1.05rem;
}

.nav__link:not(.btn):hover {
    color: var(--accent-color);
}

.nav__close,
.burger {
    display: none;
}

/* Mobile Menu */
@media (max-width: 1024px) {
    .burger {
        display: block;
        width: 30px;
        height: 20px;
        position: relative;
        cursor: pointer;
        border: none;
        background: none;
        z-index: 102;
    }

    .burger span {
        position: absolute;
        width: 100%;
        height: 2px;
        background: var(--text-main);
        transition: 0.3s;
        left: 0;
    }

    .burger span:nth-child(1) {
        top: 0;
    }

    .burger span:nth-child(2) {
        top: 9px;
    }

    .burger span:nth-child(3) {
        top: 18px;
    }

    .burger[aria-expanded="true"] span:nth-child(1) {
        transform: rotate(45deg);
        top: 9px;
    }

    .burger[aria-expanded="true"] span:nth-child(2) {
        opacity: 0;
    }

    .burger[aria-expanded="true"] span:nth-child(3) {
        transform: rotate(-45deg);
        top: 9px;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: white;
        padding: 80px 30px;
        transition: 0.4s ease;
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.1);
        z-index: 101;
    }

    .nav.active {
        right: 0;
    }

    .nav__list {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
}

/* Hero Section */
.hero {
    position: relative;
    padding-top: calc(var(--header-height) + 60px);
    padding-bottom: 60px;
    min-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 70% 20%, #E8F5E9 0%, transparent 40%),
        radial-gradient(circle at 20% 80%, #FFF3E0 0%, transparent 40%);
    z-index: -1;
}

.hero__card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
    padding: 40px;
    border-radius: var(--radius-xl);
    border: 1px solid white;
    box-shadow: var(--shadow-soft);
    max-width: 800px;
    margin: 0 auto;
}

.badge {
    display: inline-block;
    background: #E8F5E9;
    color: var(--primary-dark);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.hero__subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero__actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.hero__micro {
    font-size: 0.85rem;
    color: var(--text-muted);
    opacity: 0.8;
}

/* Section Common */
.section {
    padding: 80px 0;
}

.section-header {
    margin-bottom: 50px;
}

/* Features (Grid) */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-item {
    background: white;
    padding: 30px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    border: 1px solid transparent;
}

.feature-item:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

/* Generic Icon Box (for Features) */
.icon-box {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

/* Blog (Masonry-ish) */
.blog-masonry {
    display: grid;
    grid-template-columns: 1fr;
    /* Мобільні: 1 колонка */
    gap: 30px;
}

.blog-card {
    background: white;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.blog-card.large {
    grid-column: span 1;
}

@media (min-width: 768px) {
    .blog-masonry {
        grid-template-columns: repeat(2, 1fr);
    }
}

.blog-card {
    background: white;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
    /* Щоб картки були однакової висоти */
    min-height: 220px;
    /* Мінімальна висота для естетики */
}

/* Видаляємо старі стилі для large, бо фото немає */
/* .blog-card.large { grid-column: span 1; } */

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.blog-content {
    padding: 30px;
    /* Трохи більше відступів для тексту */
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    /* Вирівнювання зверху */
    gap: 15px;
}

.tag {
    color: var(--accent-color);
    font-weight: 700;
    font-size: 0.8rem;
    text-transform: uppercase;
    display: block;
    margin-bottom: 5px;
}

.blog-content h3 {
    margin-bottom: 10px;
    line-height: 1.3;
}

.read-more {
    margin-top: auto;
    /* Притискає кнопку до низу, якщо тексту мало */
    color: var(--primary-dark);
    font-weight: 700;
    display: inline-block;
}

/* Reviews (Horizontal Scroll) */
/* Reviews (Centered Grid) */
.reviews-slider {
    display: flex;
    gap: 30px;
    justify-content: center;
    /* Центрує картки по горизонталі */
    flex-wrap: wrap;
    /* Дозволяє перенос карток на новий рядок на малих екранах */
    padding-bottom: 20px;
}

.review-card {
    flex: 1 1 300px;
    /* Картка займає доступне місце, але не менше 300px */
    max-width: 380px;
    /* Обмеження ширини, щоб картки не були занадто широкими */
    background: white;
    padding: 30px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
    transition: var(--transition);
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.review-text {
    font-style: italic;
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: #555;
}

.reviewer {
    display: flex;
    align-items: center;
    gap: 15px;
}

.avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

/* Contact */
.contact-wrapper {
    background: white;
    border-radius: var(--radius-xl);
    overflow: hidden;
    display: flex;
    flex-wrap: wrap;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
}

.contact-text {
    flex: 1 1 400px;
    padding: 50px;
    background: #F2F7F4;
    position: relative;
}

/* === NEW CONTACT DETAILS STYLES START === */
/* Контейнер списка контактов */
.contact-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
    /* Отступ между строками */
    margin-top: 30px;
}

/* Одна строка контакта */
.detail-item {
    display: flex;
    align-items: flex-start;
    /* Выравнивание по верхнему краю для многострочного текста */
    gap: 15px;
    /* Отступ между иконкой и текстом */
    color: var(--text-main);
    /* Используем основной цвет текста */
}

/* Обертка иконки для фиксации размера (SPECIFIC to contact-details to avoid conflict) */
.contact-details .icon-box {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 3px;
    /* Небольшая поправка, чтобы иконка была ровно напротив первой строки текста */
    margin-bottom: 0;
    /* Reset global style */
    font-size: 1rem;
    /* Reset global style */
}

/* Сами SVG иконки */
.contact-icon {
    width: 100%;
    height: 100%;
    fill: var(--text-main);
    /* Цвет иконок */
}

.detail-item p {
    margin: 0;
    line-height: 1.5;
    font-size: 1rem;
}

.detail-item a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.3s;
}

.detail-item a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

/* === NEW CONTACT DETAILS STYLES END === */

.contact-img {
    margin-top: 30px;
    border-radius: var(--radius-sm);
    mix-blend-mode: multiply;
}

.contact-form {
    flex: 1 1 400px;
    padding: 50px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    transition: 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(132, 169, 140, 0.2);
}

.error-msg {
    color: #D32F2F;
    font-size: 0.8rem;
    margin-top: 5px;
    display: block;
}

.form-hint {
    font-size: 0.75rem;
    color: #999;
}

.captcha-group {
    background: #FFF3E0;
    padding: 15px;
    border-radius: var(--radius-sm);
}

.form-status {
    margin-top: 15px;
    font-weight: bold;
    text-align: center;
}

.status-success {
    color: var(--primary-dark);
}

.status-error {
    color: #D32F2F;
}

/* Footer */
.footer {
    background: #2F3E46;
    color: #E8F5E9;
    padding: 80px 0 30px;
}

.footer__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.footer h4 {
    color: white;
    margin-bottom: 20px;
}

.footer ul li {
    margin-bottom: 10px;
}

.footer a,
.footer-link {
    color: #CAD2C5;
    text-decoration: none;
    transition: 0.3s;
}

.footer a:hover,
.footer-link:hover {
    color: var(--accent-color);
}

.footer__bottom {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    color: #888;
}

.footer-link {
    background: none;
    border: none;
    font-size: inherit;
    font-family: inherit;
    cursor: pointer;
    text-align: left;
    padding: 0;
}

/* Cookie Popup */
.cookie-popup {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    max-width: 400px;
    background: white;
    padding: 20px;
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    z-index: 999;
    display: none;
    animation: slideUp 0.5s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cookie-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(47, 62, 70, 0.7);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: white;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    border-radius: var(--radius-xl);
    padding: 40px;
    position: relative;
    overflow-y: auto;
    display: none;
}

.modal.active {
    display: block;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-muted);
}

.modal h2 {
    color: var(--primary-dark);
    margin-bottom: 20px;
}

.modal h3 {
    font-size: 1.2rem;
    margin-top: 20px;
}

.modal p,
.modal li {
    font-size: 0.95rem;
    margin-bottom: 10px;
    color: #555;
}