/* 
 * Theme: Dark Neon Tech
 * Font: 'Exo 2', sans-serif
 * Primary Color: Indigo (#4f46e5)
 * Secondary Color: Pink (#ec4899)
 */

:root {
    /* Color Palette */
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --secondary: #ec4899;
    --accent: #10b981;
    --bg-body: #0f172a;
    --bg-surface: #1e293b;
    --bg-surface-2: #334155;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --border: #334155;

    /* Effects */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-neon: 0 0 15px rgba(79, 70, 229, 0.5);

    /* Layout */
    --container-width: 1280px;
    --header-height: 80px;
    --radius-xl: 1.5rem;
    /* 24px - 2xl equivalent */
    --radius-lg: 1rem;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-medium: 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: 'Exo 2', sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

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

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

ul {
    list-style: none;
}

button,
input,
textarea {
    font-family: inherit;
    border: none;
    outline: none;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-body);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-surface-2);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Typography */
h1,
h2,
h3,
h4 {
    line-height: 1.2;
    font-weight: 700;
    margin-bottom: 1rem;
}

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

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

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-muted);
}

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

/* Components */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    letter-spacing: 0.5px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: white;
    box-shadow: var(--shadow-neon);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 25px rgba(79, 70, 229, 0.7);
}

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

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

.badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(16, 185, 129, 0.1);
    /* Emerald tint */
    color: var(--accent);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1rem;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(to right, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav__link {
    font-weight: 500;
    color: var(--text-main);
}

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

.nav__toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    background: none;
    padding: 5px;
    z-index: 1001;
}

.nav__toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background-color: var(--text-main);
    transition: 0.3s;
}

/* Mobile Menu */
@media (max-width: 1024px) {
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: var(--bg-body);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.4s ease-in-out;
    }

    .nav.active {
        right: 0;
    }

    .nav__toggle {
        display: flex;
    }

    /* Burger Animation */
    .nav__toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 6px);
    }

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

    .nav__toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -6px);
    }
}

/* Hero Section - Split Layout */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    background: radial-gradient(circle at top right, rgba(79, 70, 229, 0.15), transparent 40%);
    overflow: hidden;
}

.hero__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero__content {
    order: 1;
}

.hero__visual {
    order: 2;
    position: relative;
}

.hero__img-wrapper {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    background: var(--bg-surface);
}

.hero__img {
    width: 100%;
    height: auto;
    object-fit: cover;
    transform: scale(1);
    transition: transform 0.7s ease;
}

.hero__img-wrapper:hover .hero__img {
    transform: scale(1.05);
}

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

    .hero__content {
        order: 1;
    }

    .hero__visual {
        order: 2;
        margin-top: 2rem;
    }
}

/* About / Features */
.features {
    padding: 6rem 0;
}

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

.feature-card {
    background: var(--bg-surface);
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: 0.3s;
}

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

.feature-icon {
    width: 50px;
    height: 50px;
    background: rgba(79, 70, 229, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

/* Services - Bento Grid Redesign */
/* Services - Bento Grid Redesign (Dark Neon Theme) */
.services {
    padding: 6rem 0;
    /* Keeps bg-surface-2 or can be bg-body if preferred */
    background: var(--bg-body);
    text-align: center;
    /* Centers content including h2 */
}

.services h2 {
    margin-bottom: 3rem;
    /* Adds spacing below heading */
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, auto);
    gap: 1.5rem;
}

@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bento-item:nth-child(2) {
        grid-column: span 1 !important;
        grid-row: span 1 !important;
    }
}

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

    .bento-item.col-span-2 {
        grid-column: span 1 !important;
    }

    .bento-item.row-span-2 {
        grid-row: span 1 !important;
    }
}

.bento-item {
    background: var(--bg-surface);
    color: var(--text-main);
    padding: 2.5rem;
    border-radius: var(--radius-xl);
    position: relative;
    overflow: hidden;
    transition: 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--border);
    text-align: left;
    /* Reset text align for cards */
}

.bento-item:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--shadow-neon);
}

/* Dark variant (Accent Card) */
.bento-item.dark {
    background: linear-gradient(135deg, var(--bg-surface-2), var(--bg-surface));
    border: 1px solid var(--primary);
    box-shadow: 0 0 20px rgba(79, 70, 229, 0.2);
}

.bento-item.col-span-2 {
    grid-column: span 2;
}

.bento-item.row-span-2 {
    grid-row: span 2;
}

.bento-title {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: white;
}

.bento-desc {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

.bento-tags {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: auto;
}

.bento-tag {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid var(--border);
    transition: 0.2s;
}

.bento-tag:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.dark .bento-tag {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.bento-badge-float {
    display: inline-block;
    background: rgba(79, 70, 229, 0.2);
    /* Primary tint */
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    width: fit-content;
    border: 1px solid rgba(79, 70, 229, 0.3);
}

.bento-item.dark .bento-badge-float {
    background: rgba(236, 72, 153, 0.2);
    /* Pink tint for contrast on dark */
    color: var(--secondary);
    border-color: rgba(236, 72, 153, 0.3);
}

/* Green badge style */
.badge-green {
    background: rgba(16, 185, 129, 0.2);
    /* Emerald tint */
    color: var(--accent);
    border-color: rgba(16, 185, 129, 0.3);
}

/* Reviews */
.reviews {
    padding: 6rem 0;
    text-align: center;
    /* Centers content including h2 */
}

.reviews h2 {
    margin-bottom: 3rem;
    /* Adds spacing below heading */
}

.reviews__scroller {
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    padding-bottom: 2rem;
    scroll-snap-type: x mandatory;
}

.review-card {
    min-width: 350px;
    background: var(--bg-surface);
    padding: 2rem;
    border-radius: var(--radius-lg);
    scroll-snap-align: start;
    border: 1px solid var(--border);
    text-align: left;
    /* Reset text align for cards */
}

.review-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.review-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--bg-surface-2);
    overflow: hidden;
    flex-shrink: 0;
    border: 2px solid var(--primary);
    box-shadow: 0 0 10px rgba(79, 70, 229, 0.3);
}

.review-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Contact Section */
.contact {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--bg-surface), var(--bg-body));
}

.contact__wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    background: var(--bg-surface);
    padding: 3rem;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border);
}

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

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

.form-input,
.form-textarea {
    width: 100%;
    padding: 1rem;
    background: var(--bg-body);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-main);
    transition: 0.3s;
}

.form-input:focus,
.form-textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}

.error-message {
    color: #ef4444;
    font-size: 0.75rem;
    margin-top: 0.25rem;
    display: none;
}

.form-group.error .error-message {
    display: block;
}

.form-group.error .form-input {
    border-color: #ef4444;
}

/* Cookie Modal */
.cookie-popup {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 350px;
    background: var(--bg-surface);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--primary);
    z-index: 2000;
    transform: translateY(150%);
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: none;
    /* Controlled by JS */
}

.cookie-popup.active {
    transform: translateY(0);
    display: block;
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s;
}

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

.modal__content {
    background: var(--bg-surface);
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    position: relative;
    overflow-y: auto;
    transform: scale(0.9);
    transition: 0.3s;
    border: 1px solid var(--border);
}

.modal.active .modal__content {
    transform: scale(1);
}

.modal__close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    background: none;
    color: var(--text-muted);
    cursor: pointer;
}

/* Footer */
.footer {
    padding: 4rem 0 2rem;
    background: var(--bg-body);
    border-top: 1px solid var(--border);
}

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

.footer__bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Utilities */
.hidden {
    display: none !important;
}

.text-gradient {
    background: linear-gradient(to right, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    color: transparent;
}

/* Status Toast */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 2rem;
    border-radius: 8px;
    color: white;
    z-index: 4000;
    transform: translateX(200%);
    transition: 0.3s;
}

.toast.success {
    background: var(--accent);
    transform: translateX(0);
}

.toast.error {
    background: #ef4444;
    transform: translateX(0);
}

/* CHANGE_FONT_HERE: Edit import in index.html and update :root --font-main */

/* Mobile Adaptation (Rubber Layout) */
@media (max-width: 768px) {
    .container {
        padding: 0 1.25rem;
    }

    h1 {
        font-size: 2.25rem;
        text-align: center;
    }

    .hero {
        padding-top: 100px;
        padding-bottom: 4rem;
        min-height: auto;
    }

    .hero__content {
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero__subtitle {
        font-size: 1rem;
        max-width: 100%;
        text-align: center;
    }

    /* Target the inline styled hero actions */
    .hero__actions {
        flex-direction: column;
        width: 100%;
        gap: 1rem !important;
    }

    .hero__actions .btn {
        width: 100%;
        max-width: 100%;
        /* Ensure full width */
    }

    .section-header h2 {
        font-size: 2rem;
    }

    /* Adjust padding for sections */
    .features,
    .services,
    .reviews,
    .contact {
        padding: 4rem 0;
    }

    /* Fix modal sizing on mobile */
    .modal__content {
        width: 95%;
        padding: 1.5rem;
        margin: 1rem;
    }
}