@import url('variable.css');

/* ====================================== cursor =============================================== */
.header-cursor {
    pointer-events: none;
    z-index: 9999999;
}

.header-cursor__dot {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--cursor-dot-size, 6px);
    height: var(--cursor-dot-size, 6px);
    border-radius: 50%;
    background-color: var(--accent);
    pointer-events: none;
    z-index: 10000000;
    opacity: 0;
    visibility: hidden;
    transform: translate3d(-100px, -100px, 0) translate(-50%, -50%);
    transition: opacity 0.2s ease, visibility 0.2s ease, width 0.2s ease, height 0.2s ease, background-color 0.2s ease;
    will-change: transform;
}

.header-cursor__circle {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--cursor-circle-size, 36px);
    height: var(--cursor-circle-size, 36px);
    border-radius: 50%;
    border: 1.5px solid var(--accent);
    background-color: transparent;
    pointer-events: none;
    z-index: 9999999;
    opacity: 0;
    visibility: hidden;
    transform: translate3d(-100px, -100px, 0) translate(-50%, -50%);
    transition: opacity 0.25s ease, visibility 0.25s ease, width 0.25s cubic-bezier(0.16, 1, 0.3, 1), height 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, background-color 0.2s ease;
    will-change: transform;
}

.header-cursor.is-visible .header-cursor__dot,
.header-cursor.is-visible .header-cursor__circle {
    opacity: 1;
    visibility: visible;
}

/* Hover link styles: follower circle expands, center dot stays solid and visible */
.header-cursor.cursor-link .header-cursor__circle {
    background-color: color-mix(in srgb, var(--accent) 15%, transparent);
    border-color: var(--accent);
}

.header-cursor.cursor-link .header-cursor__dot {
    opacity: 1 !important;
    visibility: visible !important;
    background-color: var(--accent);
}

/* Background invert difference blend mode */
.header-cursor.cursor-invert-enabled.cursor-link .header-cursor__circle {
    mix-blend-mode: difference;
    background-color: #ffffff !important;
    border-color: transparent !important;
}

/* Smooth button & link scale-up on hover */
.index-sec1_container-actions_btn,
.header-navbar__quote,
.admin-btn,
.portal-card,
button.interactive,
a.interactive {
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.25s ease;
}

.index-sec1_container-actions_btn:hover,
.header-navbar__quote:hover {
    transform: translateY(-2px) scale(1.045);
}

@media (pointer: fine) {
    /* Only hide native cursor when hovering interactive / clickable elements */
    a,
    a *,
    button,
    button *,
    [role="button"],
    [role="button"] *,
    input[type="submit"],
    input[type="button"],
    .interactive,
    .interactive *,
    .portal-card,
    .portal-card *,
    .project-card,
    .project-card *,
    .pricing-card,
    .pricing-card *,
    .team-card,
    .team-card *,
    .se-tilt-card,
    .se-tilt-card *,
    .se-hud-btn,
    .se-hud-btn *,
    .hero-carousel-arrow,
    .hero-carousel-arrow *,
    .hero-carousel-indicator-btn,
    .hero-carousel-indicator-btn *,
    .floating-whatsapp,
    .floating-whatsapp *,
    .header-navbar__container-menu,
    .header-navbar__container-menu *,
    .projects-filter__btn,
    .projects-filter__btn *,
    .index-sec1_container-actions_btn,
    .index-sec1_container-actions_btn *,
    .index-sec6_container-form_pill,
    .index-sec6_container-form_pill *,
    .index-sec6_container-form_submit,
    .index-sec6_container-form_submit *,
    .welcome-modal_close,
    .welcome-modal_close *,
    .footer-benchmark-tag,
    .footer-benchmark-tag * {
        cursor: none !important;
        user-select: none;
        -webkit-user-select: none;
    }

    /* Keep native text caret inside form text fields */
    input:not([type="submit"]):not([type="button"]):not([type="radio"]):not([type="checkbox"]),
    textarea {
        cursor: text !important;
        user-select: text !important;
        -webkit-user-select: text !important;
    }
}

/* ====================================== /cursor =============================================== */

/* ====================================== navbar =============================================== */

.header-navbar {
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    width: 100vw;
    z-index: 1000;
    transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.4s ease;
}

.header-navbar.navbar-hidden {
    transform: translateY(-115%);
}

.header-navbar__container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 1.15rem 2rem;
    color: var(--text-main);
    background-color: color-mix(in srgb, var(--bg-color) 50%, transparent);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    transition: all 0.5s ease-in-out;
}

.navbar-scroll .header-navbar__container {
    background-color: color-mix(in srgb, var(--bg-color) 0%, transparent);
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
    transition-delay: 0.5s;
}

.header-navbar__container-logo {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    height: calc(var(--font-size-base) + 6px);
    overflow-y: hidden;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;

}

.navbar-scroll .header-navbar__container-logo {
    pointer-events: none;
}

.header-navbar__container-logo a {
    transition: all 0.5s ease-in-out;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: inherit;
}

.brand-logo-text {
    font-family: var(--font-main);
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    color: var(--text-main);
}

.brand-logo-tag {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    color: var(--accent);
    padding: 0.15rem 0.4rem;
    border: 1px solid rgba(217, 119, 6, 0.3);
    border-radius: 3px;
    background: rgba(217, 119, 6, 0.08);
}

.header-navbar__container-logo a img {
    height: 22px;
    width: auto;
    display: block;
}

.header-navbar__container-links a.active-link p {
    color: var(--accent);
}

.navbar-admin-pill {
    padding: 0.2rem 0.65rem !important;
    border: 1px solid rgba(217, 119, 6, 0.4);
    border-radius: 9999px;
    background: rgba(217, 119, 6, 0.08);
}

.navbar-admin-pill p {
    color: var(--accent) !important;
}

.navbar-admin-pill:hover {
    background: var(--accent) !important;
}

.navbar-admin-pill:hover p {
    color: #ffffff !important;
}

.navbar-scroll .header-navbar__container-logo a {
    transform: translateY(-40px);
}

.header-navbar__container-logo {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
    height: calc(var(--font-size-base) + 8px);
    overflow: hidden;
}

.header-navbar__container-logo a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: inherit;
}

.header-navbar__container-logo .nav-word {
    display: inline-flex;
    align-items: center;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    transition-delay: calc(0.35s + (9 - var(--w-idx, 0)) * 0.035s);
}

.navbar-scroll .header-navbar__container-logo .nav-word {
    transform: translateY(-110%);
    opacity: 0;
    transition-delay: calc(var(--w-idx, 0) * 0.035s);
}

.header-navbar__container-links {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 2.25rem;
    height: calc(var(--font-size-base) + 8px);
    overflow: hidden;
}

.header-navbar__container-links a {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: calc(var(--font-size-base) + 8px);
    font-family: var(--font-main);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--text-main);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
    transition-delay: calc(0.35s + (9 - var(--w-idx, 0)) * 0.035s);
}

/* Slower, ultra-smooth navbar link hover typography (clean, no underlines) */
.header-navbar__container-links a p {
    position: relative;
    margin: 0;
    padding: 0 0.15rem;
    color: inherit;
    transition: color 0.55s cubic-bezier(0.16, 1, 0.3, 1), transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

.header-navbar__container-links a:hover {
    transition-delay: 0s !important;
}

.header-navbar__container-links a:hover p {
    color: var(--accent);
    transform: translateY(-1.5px);
    transition: color 0.55s cubic-bezier(0.16, 1, 0.3, 1), transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

.header-navbar__container-links a.active-link p {
    color: var(--accent);
}

.navbar-scroll .header-navbar__container-links {
    pointer-events: none;
}

.navbar-scroll .header-navbar__container-links a {
    transform: translateY(-110%);
    opacity: 0;
    pointer-events: none;
    transition-delay: calc(var(--w-idx, 0) * 0.035s);
}

/* User's Custom Animated Circular Hamburger Menu */
.header-navbar__container-menu {
    z-index: 1005;
    right: 2rem;
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 42px;
    width: 42px;
    transform: translateX(0);
    border-radius: 50%;
    overflow: hidden;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease 0.45s, background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid transparent;
    background-color: transparent;
    padding: 0;
}

.navbar-scroll .header-navbar__container-menu {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
    transition: opacity 0.25s ease 0s, background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-strong);
    background-color: var(--bg-surface);
    box-shadow: 0 4px 16px -4px rgba(20, 20, 19, 0.12);
}

.header-navbar__container-menu:hover {
    border-color: var(--accent);
}

/* SVG Line Architecture & Smooth Animations */
.header-navbar__menu-svg {
    display: block;
    width: 22px;
    height: 22px;
    color: var(--text-main);
    overflow: visible;
    transition: color 0.4s ease;
}

.header-navbar__container-menu:hover .header-navbar__menu-svg {
    color: var(--accent);
}

.menu-svg-line {
    stroke: currentColor;
    transform-box: view-box;
    transform-origin: 12px 12px;
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease, stroke 0.35s ease;
}

/* Desktop & Tablet: Staggered Horizontal Line-by-Line Pop-up & Hide */
@media (min-width: 721px) {
    /* When hiding (scrolled to top): lines exit line by line to the right in the opposite order (bottom -> mid -> top) */
    :not(.navbar-scroll) .header-navbar__container-menu .menu-svg-line-bot {
        transform: translateX(40px);
        transition-delay: 0.05s;
    }
    :not(.navbar-scroll) .header-navbar__container-menu .menu-svg-line-mid {
        transform: translateX(40px);
        transition-delay: 0.15s;
    }
    :not(.navbar-scroll) .header-navbar__container-menu .menu-svg-line-top {
        transform: translateX(40px);
        transition-delay: 0.25s;
    }

    /* When popping up (scrolling down): lines slide into place with staggered delays (top -> mid -> bot) */
    .navbar-scroll .header-navbar__container-menu .menu-svg-line-top {
        transform: translateX(0);
        transition-delay: 0.3s;
    }
    .navbar-scroll .header-navbar__container-menu .menu-svg-line-mid {
        transform: translateX(0);
        transition-delay: 0.4s;
    }
    .navbar-scroll .header-navbar__container-menu .menu-svg-line-bot {
        transform: translateX(0);
        transition-delay: 0.5s;
    }
}

/* Previous Hover Animation: Staggered horizontal offset (top shifts left, bottom shifts right) */
.header-navbar__container-menu:not(.is-active):hover .menu-svg-line-top {
    transform: translateX(-2.5px);
    transition-delay: 0s !important;
}
.header-navbar__container-menu:not(.is-active):hover .menu-svg-line-mid {
    transform: translateX(0);
    transition-delay: 0.05s !important;
}
.header-navbar__container-menu:not(.is-active):hover .menu-svg-line-bot {
    transform: translateX(2.5px);
    transition-delay: 0.1s !important;
}

/* Active State: 100% PERFECTLY SIGHT-ALIGNED, SYMMETRIC, MATHEMATICALLY ACCURATE "X" CLOSE CROSS */
.header-navbar__container-menu.is-active .header-navbar__menu-svg {
    color: var(--accent);
}

.header-navbar__container-menu.is-active .menu-svg-line-top {
    transform: rotate(45deg) translateY(6px) !important;
    transition-delay: 0s !important;
}

.header-navbar__container-menu.is-active .menu-svg-line-mid {
    opacity: 0 !important;
    transform: scaleX(0) !important;
    transition-delay: 0s !important;
}

.header-navbar__container-menu.is-active .menu-svg-line-bot {
    transform: rotate(-45deg) translateY(-6px) !important;
    transition-delay: 0s !important;
}

/* ====================================== mobile drawer =============================================== */

.header-mobile-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background-color: color-mix(in srgb, var(--bg-surface) 96%, transparent);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border-bottom: 1px solid var(--border-subtle);
    padding: 5.75rem 2rem 2.5rem 2rem;
    box-sizing: border-box;
    z-index: 990;
    transform: translateY(-105%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.65s;
    box-shadow: 0 24px 48px -12px rgba(20, 20, 19, 0.2);
}

.header-mobile-drawer.is-open {
    transform: translateY(0%);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.header-mobile-drawer__links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.header-mobile-drawer__links a {
    display: flex;
    align-items: baseline;
    gap: 0.85rem;
    font-family: var(--font-main);
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--text-main);
    padding: 0.55rem 0;
    border-bottom: 1px solid var(--border-subtle);
    opacity: 0;
    transform: translateY(-10px);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease, color 0.25s ease, padding-left 0.25s var(--ease-out-expo);
}

.header-mobile-drawer.is-open .header-mobile-drawer__links a {
    opacity: 1;
    transform: translateY(0);
}

/* Luxurious staggered entrance for mobile drawer navigation */
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(1) { transition-delay: 0.12s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(2) { transition-delay: 0.16s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(3) { transition-delay: 0.20s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(4) { transition-delay: 0.24s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(5) { transition-delay: 0.28s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(6) { transition-delay: 0.32s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(7) { transition-delay: 0.36s; }
.header-mobile-drawer.is-open .header-mobile-drawer__links a:nth-child(8) { transition-delay: 0.40s; }

.header-mobile-drawer__links a .drawer-num {
    font-size: 0.75rem;
    color: var(--accent);
    font-weight: 700;
    white-space: nowrap !important;
    display: inline-block;
    flex-shrink: 0;
}

.header-mobile-drawer__links a:hover {
    color: var(--accent);
    padding-left: 0.5rem;
}

/* Responsive navbar links gaps for tablet horizontal view */
@media (max-width: 1280px) {
    .header-navbar__container {
        padding: 1.15rem 1.5rem;
    }
    .header-navbar__container-links {
        gap: 1.4rem;
    }
    .header-navbar__container-links a {
        font-size: 0.78rem;
        letter-spacing: 0.06em;
    }
}

@media (max-width: 1080px) {
    .header-navbar__container {
        padding: 1rem 1.25rem;
    }
    .header-navbar__container-logo {
        gap: 0.35rem;
    }
    .brand-logo-text {
        font-size: 1rem;
    }
    .header-navbar__container-links {
        gap: 0.95rem;
    }
    .header-navbar__container-links a {
        font-size: 0.73rem;
        letter-spacing: 0.04em;
    }
}

@media (max-width: 900px) {
    .header-navbar__container {
        padding: 0.85rem 1rem;
    }
    .header-navbar__container-links {
        gap: 0.6rem;
    }
    .header-navbar__container-links a {
        font-size: 0.69rem;
        letter-spacing: 0.02em;
    }
}

/* Mobile responsive navigation overrides (<= 720px) */
@media (max-width: 720px) {
    .header-navbar__container-links {
        display: none !important;
    }

    .header-navbar {
        transform: none !important;
        pointer-events: none;
    }

    .header-navbar__container {
        padding: 0.85rem 1.25rem !important;
        position: relative !important;
        pointer-events: auto;
        transition: background-color 0.35s ease, border-color 0.35s ease, backdrop-filter 0.35s ease, box-shadow 0.35s ease;
    }

    .header-navbar__container-logo {
        pointer-events: auto;
        transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    }

    /* When scrolling down on mobile: HIDE ONLY THE NAVBAR (LOGO & BAR BACKGROUND) */
    .header-navbar.navbar-hidden .header-navbar__container-logo {
        transform: translateY(-130%);
        opacity: 0;
        pointer-events: none;
    }

    .header-navbar.navbar-hidden .header-navbar__container {
        background-color: transparent !important;
        backdrop-filter: blur(0px) !important;
        -webkit-backdrop-filter: blur(0px) !important;
        border-color: transparent !important;
        box-shadow: none !important;
        pointer-events: none;
    }

    /* MENU BUTTON REMAINS PERMANENTLY VISIBLE AT TOP-RIGHT EVEN WHEN NAVBAR HIDES */
    .header-navbar__container-menu {
        opacity: 1 !important;
        pointer-events: auto !important;
        position: fixed !important;
        top: 0.85rem !important;
        right: 1.25rem !important;
        transform: none !important;
        border: 1px solid var(--border-strong) !important;
        background-color: var(--bg-surface) !important;
        box-shadow: 0 4px 16px -4px rgba(20, 20, 19, 0.16) !important;
        display: flex !important;
        z-index: 1005 !important;
    }
}