/* Global Variables & Theming */
:root {
    --primary-color: #3b82f6; /* Tech Blue */
    --primary-dark: #2563eb;
    --secondary-color: #ffffff; /* Pure White */
    --dark-bg: #0b1021; /* Tech Dark Background */
    --darker-bg: #050812;
    --text-color: #f8fafc;
    --text-muted: #94a3b8;
    --border-color: rgba(255, 255, 255, 0.1);
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-color);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

html,
body {
    max-width: 100%;
}

img,
svg {
    max-width: 100%;
    height: auto;
}

.bg-darker {
    background-color: var(--darker-bg) !important;
}

.text-purple {
    color: var(--secondary-color) !important;
}

.bg-purple {
    background-color: var(--secondary-color) !important;
}

/* Typography & Utilities */
h1,
h2,
h3,
h4,
h5,
h6 {
    letter-spacing: 0;
    overflow-wrap: break-word;
}

.tracking-wide {
    letter-spacing: 0.1em;
}

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

/* Navbar Customization */
.custom-navbar {
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.custom-navbar.fixed-top {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1030;
}

.custom-navbar .nav-link {
    font-weight: 500;
    color: var(--text-color);
    transition: color 0.2s;
}

.custom-navbar .nav-link:hover,
.custom-navbar .nav-link.active {
    color: var(--primary-color);
}

.custom-navbar .navbar-brand img {
    height: 58px !important;
    max-width: 210px;
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: none !important;
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
    /* Space Background */
    background-color: #050812 !important; /* Force dark for space */
    background-image: 
        radial-gradient(1px 1px at 20px 30px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 40px 70px, #ffffff, rgba(0,0,0,0)),
        radial-gradient(1.5px 1.5px at 90px 40px, #ffffff, rgba(0,0,0,0)),
        url('../img/infinity-neon.png');
    background-size: 200px 200px, 200px 200px, 200px 200px, cover; /* Full width image */
    background-position: 0 0, 0 0, 0 0, center center; /* Centered image */
    background-repeat: repeat, repeat, repeat, no-repeat;
    /* Animation for stars drift */
    animation: spacePan 60s linear infinite;
}

@keyframes spacePan {
    from { background-position: 0 0, 0 0, 0 0, center center; }
    to { background-position: -200px 200px, -200px 200px, -200px 200px, center center; }
}

/* Add an overlay to ensure text is readable */
.hero-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(5, 8, 18, 0.85); /* Even dark overlay over the whole background */
    z-index: 1;
}

/* Interior Hero Styling */
.interior-hero {
    min-height: 400px;
    background: var(--darker-bg);
    border-bottom: 1px solid var(--border-color);
}

.breadcrumb-item + .breadcrumb-item::before {
    color: var(--text-muted) !important;
}

.hero-content {
    position: relative;
    z-index: 2; /* Bring text above overlay */
    text-align: center !important; /* Force center alignment */
}

/* Force light text in hero regardless of theme */
.hero-section h1, .hero-section p, .hero-section .text-muted, .hero-section .fw-bold {
    color: #ffffff !important;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}
.hero-section .text-muted {
    color: #d1d5db !important;
}

.glow-btn {
    box-shadow: 0 0 15px var(--primary-color);
    border: 1px solid var(--primary-color);
    transition: all 0.3s ease;
}
.glow-btn:hover {
    box-shadow: 0 0 25px var(--primary-color), inset 0 0 10px rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.hero-image-wrapper {
    position: relative;
    z-index: 1;
}

.terminal-window {
    background-color: #0b0f19;
}

.mac-buttons span {
    display: inline-block;
}

/* Service Cards */
.service-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-color) !important;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2) !important;
    border-color: rgba(59, 130, 246, 0.5) !important;
}

[data-bs-theme="light"] .service-card {
    background-color: #ffffff !important;
}

.hover-lift {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
    border: 1px solid var(--border-color);
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3) !important;
    border-color: var(--primary-color);
}

/* Accordion */
.custom-accordion .accordion-button {
    box-shadow: none !important;
}

.custom-accordion .accordion-button:not(.collapsed) {
    color: var(--primary-color) !important;
}

[data-bs-theme="light"] .custom-accordion .accordion-item {
    background-color: #ffffff !important;
}

[data-bs-theme="light"] .custom-accordion .accordion-button {
    color: #0f172a !important;
}

/* Footer */
.site-footer {
    background-color: var(--darker-bg);
    border-top: 1px solid var(--border-color);
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--text-color);
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--primary-color);
    color: #fff;
    transform: translateY(-2px);
}

/* WhatsApp Float Widget */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    color: #fff;
}

/* Py-6 Utility */
.py-6 {
    padding-top: 5rem;
    padding-bottom: 5rem;
}

.glass-card {
-webkit-backdrop-filter: blur(12px);
transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
transform-style: preserve-3d;
overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: skewX(-20deg);
    transition: 0.5s;
}

.glass-card:hover {
    transform: translateY(-10px) translateZ(20px);
    border-color: rgba(108, 44, 251, 0.5);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), 0 0 20px rgba(108, 44, 251, 0.2);
}

.glass-card:hover::before {
    left: 200%;
}

.icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
}

.icon-orange {
    color: var(--neon-orange);
    box-shadow: inset 0 0 15px rgba(255, 106, 0, 0.1);
}

.icon-purple {
    color: var(--cosmic-purple);
    box-shadow: inset 0 0 15px rgba(108, 44, 251, 0.1);
}

.icon-blue {
    color: var(--electric-blue);
    box-shadow: inset 0 0 15px rgba(0, 212, 255, 0.1);
}

/* Utilities */
.py-6 {
    padding-top: 6rem;
    padding-bottom: 6rem;
}

.bg-gradient-radial {
    background: radial-gradient(circle at center, var(--bg-secondary) 0%, var(--bg-dark) 100%);
}

/* Stylish Dropdown */
.custom-navbar .dropdown-menu {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 1rem;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.8);
    margin-top: 15px;
    opacity: 0;
    visibility: hidden;
    display: block;
    transform: translateY(15px);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.custom-navbar .nav-item.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-navbar .dropdown-item {
    color: var(--text-muted);
    border-radius: 10px;
    padding: 0.75rem 1.25rem;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    margin-bottom: 2px;
}

.custom-navbar .dropdown-item:hover {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.15), transparent);
    color: var(--primary-color);
    transform: translateX(8px);
}

.custom-navbar .dropdown-divider {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin: 0.5rem 0;
}

/* Dropdown link indicator */
.custom-navbar .nav-link.dropdown-toggle::after {
    transition: transform 0.3s ease;
    border-top: 0.3em solid;
    border-right: 0.3em solid transparent;
    border-bottom: 0;
    border-left: 0.3em solid transparent;
    vertical-align: middle;
    margin-left: 0.4em;
}

.custom-navbar .nav-item.dropdown:hover .nav-link.dropdown-toggle::after {
    transform: rotate(180deg);
}

/* Contact Page */
.contact-hero {
    min-height: 640px;
    padding: 140px 0 80px;
    background:
        linear-gradient(135deg, rgba(5, 8, 18, 0.92), rgba(11, 16, 33, 0.82)),
        radial-gradient(circle at 18% 24%, rgba(0, 212, 255, 0.22), transparent 34%),
        radial-gradient(circle at 82% 20%, rgba(59, 130, 246, 0.24), transparent 30%),
        var(--darker-bg);
    border-bottom: 1px solid var(--border-color);
}

.contact-visual-wrap {
    position: relative;
    max-width: 560px;
    margin-left: auto;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
}

.contact-visual-wrap::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 55%, rgba(5, 8, 18, 0.18));
    pointer-events: none;
}

.contact-visual-img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.contact-panel-section {
    padding: 90px 0;
    background:
        linear-gradient(180deg, rgba(5, 8, 18, 0.28), rgba(5, 8, 18, 0.86)),
        var(--dark-bg);
}

.contact-info-stack {
    display: grid;
    gap: 1rem;
    position: sticky;
    top: 110px;
}

.contact-info-card,
.contact-form-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: rgba(5, 8, 18, 0.72);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.24);
}

.contact-info-card {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    padding: 1.25rem;
}

.contact-info-icon,
.contact-form-badge {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 8px;
    color: var(--primary-color);
    background: rgba(59, 130, 246, 0.13);
    border: 1px solid rgba(59, 130, 246, 0.2);
    font-size: 1.35rem;
}

.contact-info-link {
    display: inline-block;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.contact-info-link:hover {
    color: var(--primary-color);
}

.contact-form-card {
    padding: clamp(1.35rem, 4vw, 2.5rem);
}

.contact-form-card code {
    color: #bfdbfe;
}

.contact-form-card .form-label {
    color: var(--text-color);
    font-size: 0.85rem;
    font-weight: 700;
}

.contact-control {
    min-height: 52px;
    color: var(--text-color) !important;
    background-color: rgba(15, 23, 42, 0.74) !important;
    border: 1px solid rgba(148, 163, 184, 0.26) !important;
    border-radius: 8px !important;
    box-shadow: none !important;
}

.contact-control:focus {
    border-color: rgba(59, 130, 246, 0.78) !important;
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.14) !important;
}

.contact-control::placeholder {
    color: rgba(148, 163, 184, 0.72);
}

.contact-control option {
    color: #0f172a;
}

@media (max-width: 991.98px) {
    .contact-hero {
        min-height: auto;
        padding: 120px 0 60px;
    }

    .contact-visual-wrap {
        width: 100%;
        margin: 0 auto;
    }

    .contact-info-stack {
        position: static;
    }
}

/* Responsive System */
@media (max-width: 1199.98px) {
    .custom-navbar .navbar-brand img {
        height: 52px !important;
        max-width: 190px;
    }

    .custom-navbar .nav-link {
        font-size: 0.94rem;
    }

    .btn-get-started {
        padding-right: 1.1rem !important;
        padding-left: 1.1rem !important;
    }
}

@media (max-width: 991.98px) {
    .custom-navbar {
        background: rgba(15, 23, 42, 0.96);
    }

    .custom-navbar .container {
        max-width: 100%;
    }

    .custom-navbar .navbar-brand img {
        height: 46px !important;
        max-width: 180px;
    }

    .navbar-collapse {
        max-height: calc(100vh - 76px);
        overflow-y: auto;
        padding: 1rem 0 0.35rem;
    }

    .custom-navbar .navbar-nav {
        align-items: stretch !important;
        gap: 0.25rem;
    }

    .custom-navbar .nav-link,
    .custom-navbar .dropdown-item {
        border-radius: 8px;
        padding: 0.75rem 1rem;
    }

    .custom-navbar .dropdown-menu {
        position: static !important;
        display: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        margin: 0.25rem 0 0.5rem;
        padding: 0.45rem;
        box-shadow: none;
        border-radius: 8px;
        background: rgba(5, 8, 18, 0.72);
    }

    .custom-navbar .dropdown-menu.show {
        display: block;
    }

    .custom-navbar .dropdown-item {
        white-space: normal;
    }

    .custom-navbar .nav-item.dropdown:hover .dropdown-menu {
        transform: none;
    }

    .custom-navbar .nav-item.dropdown:hover .nav-link.dropdown-toggle::after {
        transform: none;
    }

    .custom-navbar .btn-get-started {
        width: 100%;
        margin-top: 0.5rem;
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    .hero-section {
        min-height: auto;
        padding: 125px 0 70px;
    }

    .hero-section .display-4,
    .interior-hero .display-4,
    .contact-hero .display-4 {
        font-size: 3rem;
        line-height: 1.15;
    }

    .display-5 {
        font-size: 2.45rem;
        line-height: 1.16;
    }

    .display-6 {
        font-size: 2.1rem;
        line-height: 1.18;
    }

    .lead {
        font-size: 1.08rem;
    }

    .py-6 {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }

    .container.py-5 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    .interior-hero {
        min-height: 320px;
        padding-top: 5.5rem !important;
        padding-bottom: 3rem !important;
    }

    .sticky-top {
        position: static !important;
    }

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

    .site-footer .social-links {
        display: flex;
        justify-content: center;
    }

    .site-footer .d-flex {
        justify-content: center !important;
    }

    .site-footer img {
        height: 46px !important;
    }

    .contact-panel-section {
        padding: 70px 0;
    }
}

@media (max-width: 767.98px) {
    body {
        min-width: 320px;
    }

    .custom-navbar .navbar-brand img {
        height: 42px !important;
        max-width: 168px;
    }

    .hero-section {
        padding: 115px 0 60px;
        background-position: center top, center top, center top, center center;
    }

    .hero-section .display-4,
    .interior-hero .display-4,
    .contact-hero .display-4 {
        font-size: 2.35rem;
        line-height: 1.14;
    }

    .display-5 {
        font-size: 2rem;
        line-height: 1.16;
    }

    .display-6 {
        font-size: 1.75rem;
        line-height: 1.2;
    }

    .hero-section .lead,
    .interior-hero .lead,
    .contact-hero .lead,
    .lead {
        font-size: 1rem;
    }

    .hero-section .trust-badges > div {
        flex: 0 1 calc(50% - 1rem);
    }

    .tech-logos {
        gap: 1.35rem !important;
    }

    .tech-logos i {
        font-size: 1.85rem !important;
    }

    .py-6 {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }

    main .row.g-5 {
        --bs-gutter-y: 2rem;
    }

    main .p-5 {
        padding: 1.5rem !important;
    }

    main .p-4 {
        padding: 1.25rem !important;
    }

    main .rounded-5,
    main .rounded-4 {
        border-radius: 8px !important;
    }

    .card,
    .blog-card,
    .tools-box,
    .contact-info-card,
    .contact-form-card {
        border-radius: 8px !important;
    }

    .blog-card .d-flex.align-items-center.justify-content-between {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 1rem;
    }

    .pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .pagination .page-link {
        border-radius: 8px !important;
        padding: 0.55rem 0.85rem !important;
    }

    .contact-hero {
        padding: 110px 0 50px;
    }

    .contact-visual-wrap {
        max-width: 100%;
    }

    .contact-visual-img {
        aspect-ratio: 16 / 11;
        max-height: 280px;
    }

    .contact-panel-section {
        padding: 55px 0;
    }

    .contact-info-card {
        gap: 0.85rem;
    }

    .contact-info-icon,
    .contact-form-badge {
        width: 42px;
        height: 42px;
        font-size: 1.1rem;
    }

    .service-article,
    .content-text {
        word-break: normal;
        overflow-wrap: anywhere;
    }

    .tool-tag {
        width: 100%;
    }

    .custom-accordion .accordion-button,
    .accordion-button {
        align-items: flex-start;
        white-space: normal;
        line-height: 1.35;
    }

    .CTA-section .btn,
    main .btn-lg {
        width: 100%;
        justify-content: center;
    }

    .whatsapp-float {
        width: 54px;
        height: 54px;
        right: 18px;
        bottom: 18px;
        font-size: 27px;
    }
}

@media (max-width: 575.98px) {
    .custom-navbar .container {
        padding-right: 1rem;
        padding-left: 1rem;
    }

    .custom-navbar .navbar-brand img {
        height: 38px !important;
        max-width: 152px;
    }

    .navbar-toggler {
        width: 46px;
        height: 42px;
        padding: 0.25rem 0.55rem;
    }

    .hero-section .display-4,
    .interior-hero .display-4,
    .contact-hero .display-4 {
        font-size: 2rem;
    }

    .display-5 {
        font-size: 1.8rem;
    }

    .display-6 {
        font-size: 1.55rem;
    }

    .hero-section .btn,
    .contact-hero .btn,
    .CTA-section .btn {
        width: 100%;
    }

    .hero-section .trust-badges {
        gap: 1.5rem 0.75rem !important;
    }

    .hero-section .trust-badges h3 {
        font-size: 1.45rem;
    }

    .interior-hero {
        min-height: 280px;
    }

    .breadcrumb {
        flex-wrap: wrap;
        row-gap: 0.35rem;
    }

    .contact-info-card {
        flex-direction: column;
    }

    .contact-control {
        min-height: 50px;
    }

    .site-footer .list-inline-item {
        margin-bottom: 0.4rem;
    }
}
