/* THEME: Dark Neon Cyberpunk (Randomized)
   FONT: Space Grotesk
*/

:root {
    /* Color Palette */
    --color-bg: #0b1120;
    /* Dark Blue/Black Background */
    --color-bg-alt: #151e32;
    /* Slightly lighter background for cards */
    --color-primary: #00ff9d;
    /* Neon Green/Cyan Accent */
    --color-secondary: #7f5af0;
    /* Purple Accent */
    --color-text: #94a1b2;
    /* Muted Text */
    --color-heading: #fffffe;
    /* White Headings */
    --color-border: #2cb67d;

    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 80px;
    --border-radius: 1rem;
    /* 2xl radius concept */

    /* Transitions */
    --transition: all 0.3s ease;

    /* Fonts */
    --font-main: 'Space Grotesk', sans-serif;
    /* CHANGE_FONT_HERE if needed */
}

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

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

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

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--color-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

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

ul {
    list-style: none;
}

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

/* Container */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Utilities */
.text-center {
    text-align: center;
}

.hidden {
    display: none !important;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    font-size: 1rem;
    text-align: center;
    white-space: nowrap;
    min-width: fit-content;
}

.btn--primary {
    background-color: var(--color-primary);
    color: var(--color-bg);
    box-shadow: 0 4px 14px 0 rgba(0, 255, 157, 0.39);
}

.btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 255, 157, 0.23);
}

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

.btn--outline:hover {
    background: rgba(0, 255, 157, 0.1);
}

.btn--small {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

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

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

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-heading);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition);
}

.logo:hover {
    opacity: 0.9;
}

.logo__img {
    flex-shrink: 0;
    display: block;
}

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

/* Navigation & Burger */
.nav__list {
    display: flex;
    gap: 2rem;
}

.nav__link {
    font-weight: 500;
}

.nav__link:hover {
    color: var(--color-primary);
}

.nav__close {
    display: none;
}

.burger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
}

@media screen and (max-width: 1024px) {
    .burger {
        display: block;
        width: 30px;
        height: 20px;
        position: relative;
        z-index: 200;
    }

    .burger span {
        display: block;
        width: 100%;
        height: 2px;
        background: var(--color-heading);
        position: absolute;
        left: 0;
        transition: all 0.3s ease-in-out;
    }

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

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

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

    /* Анімація перетворення в хрестик */
    .burger.active span:nth-child(1) {
        top: 9px;
        transform: rotate(45deg);
    }

    .burger.active span:nth-child(2) {
        opacity: 0;
    }

    .burger.active span:nth-child(3) {
        top: 9px;
        transform: rotate(-45deg);
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: var(--color-bg-alt);
        padding: 4rem 2rem;
        transition: var(--transition);
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.5);
    }

    .nav.show {
        right: 0;
    }

    .nav__list {
        flex-direction: column;
        gap: 1.5rem;
    }

    /* Burger Animation when open can be handled via JS adding class to burger, usually simpler to just use close btn in drawer */
}

/* Hero Section */
.hero {
    padding-top: calc(var(--header-height) + 4rem);
    padding-bottom: 4rem;
    min-height: 90vh;
    display: flex;
    align-items: center;
    background: radial-gradient(circle at top right, rgba(127, 90, 240, 0.15), transparent 40%);
}

.hero__container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 3rem;
    align-items: center;
}

.badge {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: rgba(0, 255, 157, 0.1);
    color: var(--color-primary);
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.hero__title {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
}

.hero__subtitle {
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
    max-width: 500px;
}

.hero__note {
    display: block;
    margin-top: 0.5rem;
    opacity: 0.7;
    font-size: 0.85rem;
}

.hero__actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero__visual {
    position: relative;
}

.hero__card-abstract img {
    width: 100%;
    border-radius: var(--border-radius);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.hero__floating-card {
    position: absolute;
    bottom: -20px;
    left: -20px;
    background: var(--color-bg-alt);
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@media (max-width: 768px) {
    .hero__container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero__actions {
        justify-content: center;
        flex-direction: column;
        width: 100%;
        gap: 0.75rem;
    }

    .hero__actions .btn {
        width: 100%;
        max-width: 100%;
        padding: 0.9rem 1.5rem;
        font-size: 0.95rem;
    }

    .hero__subtitle {
        margin: 0 auto 2rem;
    }

    .hero__title {
        font-size: 2.5rem;
    }

    .hero__floating-card {
        display: none;
    }
}

@media (max-width: 480px) {
    .btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.9rem;
    }

    .hero__actions .btn {
        padding: 0.85rem 1.25rem;
        font-size: 0.9rem;
    }

    .hero__title {
        font-size: 2rem;
    }
}

/* Sections Common */
.section {
    padding: 5rem 0;
}

.section__header {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.section__title {
    font-size: 2.5rem;
    color: var(--color-heading);
}

.section__desc {
    color: var(--color-text);
}

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

.feature-card {
    background: var(--color-bg-alt);
    padding: 2rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    border: 1px solid transparent;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.feature-card__icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Services (Grid Masonry Look) */
.services__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: auto auto;
    gap: 1.5rem;
}

.service-card {
    background: var(--color-bg-alt);
    border-radius: var(--border-radius);
    padding: 2rem;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-card__content {
    position: relative;
    z-index: 1;
}

.service-card--large {
    grid-column: span 2;
    background: linear-gradient(135deg, var(--color-bg-alt) 0%, rgba(127, 90, 240, 0.2) 100%);
}

.link-arrow {
    color: var(--color-primary);
    font-weight: 700;
    margin-top: 1rem;
    display: inline-block;
}

@media (max-width: 768px) {
    .services__grid {
        grid-template-columns: 1fr;
    }

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

/* Reviews */
.reviews {
    background: rgba(255, 255, 255, 0.02);
}

.reviews__wrapper {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.review-card {
    flex: 1 1 300px;
    background: var(--color-bg);
    padding: 2rem;
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.review-card__text {
    font-style: italic;
    margin-bottom: 1.5rem;
}

.review-card__author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.review-card__avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-primary);
}

.review-card__author strong {
    display: block;
    color: var(--color-heading);
}

.review-card__author span {
    font-size: 0.85rem;
    color: var(--color-primary);
}

/* Contact Form */
.contact__wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
}

.contact__info h2 {
    font-size: 2rem;
}

.contact__list {
    margin-top: 2rem;
}

.contact__list li {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.contact__icon {
    color: var(--color-primary);
    flex-shrink: 0;
}

.footer__col p {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.8rem;
}

.contact__lang {
    display: block;
    margin-top: 0.3rem;
    font-size: 0.95rem;
    opacity: 0.8;
    font-style: italic;
}

.contact__form {
    background: var(--color-bg-alt);
    padding: 2.5rem;
    border-radius: var(--border-radius);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--color-heading);
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    background: var(--color-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--color-heading);
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.checkbox-group input {
    width: auto;
}

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

.error-msg {
    color: #ff6b6b;
    font-size: 0.8rem;
    display: block;
    margin-top: 0.3rem;
    height: 1rem;
}

/* Loader */
.loader {
    width: 16px;
    height: 16px;
    border: 2px solid #fff;
    border-bottom-color: transparent;
    border-radius: 50%;
    display: inline-block;
    animation: rotate 1s linear infinite;
    margin-left: 10px;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@media (max-width: 768px) {
    .contact__wrapper {
        grid-template-columns: 1fr;
    }
}

/* Footer */
.footer {
    background: #050a14;
    padding: 4rem 0 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

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

.footer h4 {
    color: var(--color-heading);
    margin-bottom: 1.2rem;
}

.footer ul li {
    margin-bottom: 0.8rem;
}

.footer ul li a:hover,
.footer ul li button:hover {
    color: var(--color-primary);
}

.footer button {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    font-family: inherit;
    font-size: 1rem;
    text-align: left;
}

.footer__bottom {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 1.5rem;
    font-size: 0.9rem;
}

/* Modals & Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

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

.modal {
    background: var(--color-bg-alt);
    padding: 2rem;
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    border-radius: var(--border-radius);
    position: relative;
    transform: translateY(20px);
    transition: var(--transition);
    display: none;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    /* Controlled by JS to show specific one */
}

.modal.active {
    display: block;
    transform: translateY(0);
}

.modal__close {
    position: sticky;
    top: 0;
    float: right;
    background: rgba(11, 17, 32, 0.8);
    border: none;
    font-size: 1.5rem;
    color: var(--color-heading);
    cursor: pointer;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10;
    margin-bottom: 1rem;
}

.modal__close:hover {
    background: rgba(0, 255, 157, 0.2);
    color: var(--color-primary);
}

.modal__content {
    clear: both;
    padding-top: 0.5rem;
}

.modal__content h2 {
    margin-bottom: 1.5rem;
    color: var(--color-heading);
    font-size: 2rem;
}

.modal__content h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
    font-size: 1.3rem;
    font-weight: 600;
}

.modal__content h4 {
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--color-heading);
    font-size: 1.1rem;
    font-weight: 600;
}

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

.modal__content ul {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
    list-style-type: disc;
}

.modal__content li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.modal__content strong {
    color: var(--color-heading);
    font-weight: 600;
}

/* Scrollbar styling for modal */
.modal::-webkit-scrollbar {
    width: 8px;
}

.modal::-webkit-scrollbar-track {
    background: var(--color-bg);
    border-radius: 4px;
}

.modal::-webkit-scrollbar-thumb {
    background: var(--color-primary);
    border-radius: 4px;
}

.modal::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 255, 157, 0.8);
}

/* Cookie Popup */
.cookie-popup {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--color-bg-alt);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--color-primary);
    max-width: 350px;
    z-index: 900;
    animation: slideUp 0.5s ease-out;
}

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

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

.cookie-actions {
    margin-top: 1rem;
    display: flex;
    gap: 1rem;
}