/* ══════════════════════════════════════════════════════════
   WEBECTAK NAVBAR  —  shared stylesheet
   ══════════════════════════════════════════════════════════ */

/* ── CSS variable fallbacks (dark = default) ─────────────── */
:root {
    --txt:    #e2e8f0;
    --txt2:   #9fb3cf;
    --txt3:   #6b7f99;
    --mint:   #10b981;
    --mint-h: #4ade80;
    --mint-l: rgba(16,185,129,.1);
    --bg:     #050a14;
    --bg2:    #0a1220;
    --card:   rgba(12,22,40,.85);
    --border: rgba(100,140,200,.12);
}
[data-theme="light"] {
    --txt:    #1a2332;
    --txt2:   #4a5d75;
    --txt3:   #8195ad;
    --mint-l: rgba(16,185,129,.08);
    --bg:     #f8fafc;
    --bg2:    #fff;
    --card:   rgba(255,255,255,.96);
    --border: rgba(0,0,0,.08);
}

/* ── Outer nav ───────────────────────────────────────────── */
.wbt-nav {
    position: relative;
    z-index: 900;
    border-bottom: 1px solid rgba(100,140,200,.08);
}
[data-theme="light"] .wbt-nav { border-color: rgba(0,0,0,.07); }

.landing-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: .85rem 1.5rem;
    gap: 1.5rem;
}

/* ── Brand ───────────────────────────────────────────────── */
.nav-brand {
    display: flex;
    align-items: center;
    gap: .6rem;
    text-decoration: none;
    flex-shrink: 0;
}
.nav-brand img  { width: 36px; height: 36px; border-radius: 10px; object-fit: contain; }
.nav-brand span { font-size: 1.05rem; font-weight: 700; color: var(--txt); white-space: nowrap; }

/* ── Nav links container ─────────────────────────────────── */
.nav-links { display: flex; align-items: center; gap: .08rem; }

/* ── Base nav button / link ──────────────────────────────── */
.nav-link-btn {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    padding: .48rem .85rem;
    border-radius: 9px;
    font-size: .875rem;
    font-weight: 500;
    font-family: inherit;
    color: var(--txt2);
    text-decoration: none;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: color .18s, background .18s;
    white-space: nowrap;
    line-height: 1;
}
.nav-link-btn:hover         { color: var(--mint-h); background: rgba(16,185,129,.06); }
.nav-link-btn:focus-visible { outline: 2px solid var(--mint-h); outline-offset: 2px; }
.nav-link-btn.active        { color: var(--mint-h); }

/* Solid CTA */
.nav-link-btn.solid {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff !important;
    padding: .52rem 1.1rem;
    font-weight: 600;
    border-radius: 10px;
    margin-left: .25rem;
    box-shadow: 0 3px 12px rgba(16,185,129,.22);
}
.nav-link-btn.solid:hover {
    filter: brightness(1.09);
    background: linear-gradient(135deg, #10b981, #059669);
    box-shadow: 0 5px 18px rgba(16,185,129,.32);
}

/* ── Services chevron ────────────────────────────────────── */
.nav-svc-btn .chevron {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    flex-shrink: 0;
    transition: transform .22s ease;
}
.nav-svc-toggle.open .nav-svc-btn .chevron { transform: rotate(180deg); }
.nav-svc-btn { padding-right: .7rem; }

/* ── Theme toggle ────────────────────────────────────────── */
.theme-toggle {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    border: 1px solid var(--border);
    background: var(--card);
    color: var(--txt2);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .88rem;
    transition: all .2s;
    margin-left: .2rem;
    font-family: inherit;
    flex-shrink: 0;
}
.theme-toggle:hover { color: var(--mint-h); border-color: rgba(16,185,129,.3); }

/* ── Hamburger ───────────────────────────────────────────── */
.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
    padding: .45rem .35rem;
    border: none;
    background: transparent;
    flex-shrink: 0;
}
.nav-hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--txt);
    border-radius: 2px;
    transition: all .28s ease;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ══════════════════════════════════════════════════════════
   MEGA DROPDOWN  (desktop)
   ══════════════════════════════════════════════════════════ */
.svc-mega {
    display: none;
    position: absolute;
    top: calc(100% + .45rem);
    left: 50%;
    transform: translateX(-50%);
    width: min(900px, 95vw);
    background: rgba(7,13,27,.98);
    border: 1px solid rgba(100,140,200,.14);
    border-radius: 20px;
    padding: 1.85rem;
    box-shadow: 0 28px 70px rgba(0,0,0,.6),
                0 0 0 1px rgba(255,255,255,.02) inset;
    backdrop-filter: blur(24px) saturate(1.5);
    z-index: 950;
    animation: megaIn .2s cubic-bezier(.22,.78,.44,1);
}
[data-theme="light"] .svc-mega {
    background: rgba(255,255,255,.99);
    border-color: rgba(0,0,0,.08);
    box-shadow: 0 20px 60px rgba(0,0,0,.14);
}
.svc-mega.open { display: block; }

@keyframes megaIn {
    from { opacity: 0; transform: translateX(-50%) translateY(-10px) scale(.98); }
    to   { opacity: 1; transform: translateX(-50%) translateY(0)     scale(1);   }
}

.svc-mega-inner {
    display: grid;
    grid-template-columns: 1fr 1fr 230px;
    gap: 1.75rem;
    align-items: start;
}

/* Column headings */
.svc-mega-heading {
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--txt3);
    margin-bottom: .85rem;
    padding-bottom: .6rem;
    border-bottom: 1px solid rgba(100,140,200,.08);
}
[data-theme="light"] .svc-mega-heading { border-color: rgba(0,0,0,.07); }

/* Mega items */
.svc-mega-item {
    display: flex;
    align-items: flex-start;
    gap: .85rem;
    padding: .68rem .65rem;
    border-radius: 11px;
    text-decoration: none;
    transition: background .14s;
    margin-bottom: .08rem;
}
.svc-mega-item:hover { background: rgba(16,185,129,.07); }
[data-theme="light"] .svc-mega-item:hover { background: rgba(16,185,129,.05); }

.svc-mega-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .95rem;
    margin-top: .05rem;
}
.svc-mega-title {
    font-size: .875rem;
    font-weight: 600;
    color: var(--txt);
    margin-bottom: .18rem;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: .4rem;
    flex-wrap: wrap;
}
.svc-mega-desc { font-size: .77rem; color: var(--txt3); line-height: 1.5; }

/* ── Featured panel ──────────────────────────────────────── */
.svc-mega-featured {
    display: flex;
    flex-direction: column;
    gap: .7rem;
    padding-left: 1.25rem;
    border-left: 1px solid rgba(100,140,200,.1);
}
[data-theme="light"] .svc-mega-featured { border-color: rgba(0,0,0,.07); }

.svc-feat-card {
    background: linear-gradient(145deg, rgba(16,185,129,.1), rgba(14,165,233,.06));
    border: 1px solid rgba(16,185,129,.18);
    border-radius: 16px;
    padding: 1.25rem 1.1rem;
    flex: 1;
}
[data-theme="light"] .svc-feat-card {
    background: linear-gradient(145deg, rgba(16,185,129,.06), rgba(14,165,233,.03));
}
.svc-feat-icon {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    background: linear-gradient(135deg, #10b981, #0d9488);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: .95rem;
    box-shadow: 0 6px 18px rgba(16,185,129,.35);
}
.svc-feat-title { font-size: .95rem; font-weight: 700; color: var(--txt); margin-bottom: .35rem; }
.svc-feat-desc  { font-size: .78rem; color: var(--txt2); line-height: 1.55; margin-bottom: .95rem; }

.svc-feat-bullets { list-style: none; padding: 0; margin: 0 0 1rem; }
.svc-feat-bullets li {
    font-size: .77rem;
    color: var(--txt2);
    padding: .2rem 0;
    display: flex;
    align-items: center;
    gap: .5rem;
}
.svc-feat-bullets li::before {
    content: '';
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--mint-h);
    flex-shrink: 0;
}
.svc-feat-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    width: 100%;
    padding: .6rem .9rem;
    border-radius: 10px;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    font-size: .82rem;
    font-weight: 600;
    text-decoration: none;
    transition: filter .18s;
    border: none;
    cursor: pointer;
    font-family: inherit;
    box-shadow: 0 4px 14px rgba(16,185,129,.28);
}
.svc-feat-cta:hover { filter: brightness(1.08); color: #fff; }

.svc-mega-all-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .4rem;
    font-size: .79rem;
    font-weight: 600;
    color: var(--txt2);
    padding: .52rem .75rem;
    border-radius: 9px;
    text-decoration: none;
    transition: all .15s;
    border: 1px solid rgba(100,140,200,.1);
    background: transparent;
}
[data-theme="light"] .svc-mega-all-link { border-color: rgba(0,0,0,.09); }
.svc-mega-all-link:hover {
    color: var(--mint-h);
    border-color: rgba(16,185,129,.28);
    background: rgba(16,185,129,.04);
}

/* ── Badges ──────────────────────────────────────────────── */
.badge-new {
    display: inline-block;
    background: #10b981;
    color: #fff;
    font-size: .57rem;
    font-weight: 700;
    padding: .1rem .42rem;
    border-radius: 5px;
    line-height: 1.6;
    vertical-align: middle;
}
.badge-purple { background: #8b5cf6; }

/* ══════════════════════════════════════════════════════════
   MOBILE NAV  (≤ 880px)
   ══════════════════════════════════════════════════════════ */
@media (max-width: 880px) {
    .nav-hamburger { display: flex; }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: .04rem;
        background: rgba(7,12,25,.98);
        border-bottom: 1px solid rgba(100,140,200,.1);
        padding: .6rem .9rem 1.1rem;
        backdrop-filter: blur(22px) saturate(1.4);
        z-index: 899;
        max-height: 80vh;
        overflow-y: auto;
    }
    [data-theme="light"] .nav-links { background: rgba(248,250,253,.99); }

    .nav-links.open { display: flex; animation: mobileNavIn .22s ease; }
    @keyframes mobileNavIn {
        from { opacity: 0; transform: translateY(-8px); }
        to   { opacity: 1; transform: translateY(0); }
    }

    .nav-link-btn { width: 100%; border-radius: 10px; padding: .72rem 1rem; justify-content: flex-start; }
    .nav-link-btn.solid { margin-top: .45rem; margin-left: 0; justify-content: center; }
    .nav-svc-toggle { width: 100%; display: block; }
    .nav-svc-btn    { width: 100%; justify-content: space-between; }
    .nav-links .theme-toggle { margin: .5rem 0 0; }

    /* Desktop mega never shown on mobile — JS opens modal instead */
    .svc-mega { display: none !important; }
}

/* ══════════════════════════════════════════════════════════
   SERVICES MODAL  (mobile)
   ══════════════════════════════════════════════════════════ */
.svc-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1100;
    background: rgba(0,0,0,.55);
    backdrop-filter: blur(5px);
    align-items: flex-end;
}
.svc-modal-overlay.open { display: flex; animation: overlayIn .22s ease; }
@keyframes overlayIn { from { opacity: 0; } to { opacity: 1; } }

.svc-modal {
    background: #090f1d;
    border-radius: 22px 22px 0 0;
    width: 100%;
    padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 1.25rem);
    border-top:   1px solid rgba(100,140,200,.12);
    border-left:  1px solid rgba(100,140,200,.08);
    border-right: 1px solid rgba(100,140,200,.08);
    max-height: 90vh;
    overflow-y: auto;
    animation: modalUp .3s cubic-bezier(.34,1.08,.64,1);
    box-shadow: 0 -24px 80px rgba(0,0,0,.55);
}
[data-theme="light"] .svc-modal { background: #f9fafb; border-color: rgba(0,0,0,.1); }
@keyframes modalUp {
    from { transform: translateY(110%); }
    to   { transform: translateY(0); }
}

.svc-modal-handle {
    width: 38px;
    height: 4px;
    border-radius: 2px;
    background: rgba(100,140,200,.18);
    margin: .9rem auto .1rem;
}
[data-theme="light"] .svc-modal-handle { background: rgba(0,0,0,.12); }

.svc-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .8rem 1.2rem 1rem;
}
.svc-modal-header h3 { font-size: 1rem; font-weight: 700; color: var(--txt); margin: 0; }

.svc-modal-close {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(100,140,200,.1);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--txt2);
    font-size: .8rem;
    transition: all .18s;
    font-family: inherit;
}
[data-theme="light"] .svc-modal-close { background: rgba(0,0,0,.07); }
.svc-modal-close:hover { background: rgba(100,140,200,.2); color: var(--txt); }

.svc-modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .65rem;
    padding: 0 1.1rem 1.25rem;
}

.svc-modal-card {
    display: flex;
    flex-direction: column;
    gap: .45rem;
    padding: .95rem .9rem;
    border-radius: 14px;
    background: rgba(255,255,255,.03);
    border: 1px solid rgba(100,140,200,.09);
    text-decoration: none;
    transition: border-color .16s, background .16s;
}
[data-theme="light"] .svc-modal-card { background: rgba(0,0,0,.025); border-color: rgba(0,0,0,.07); }
.svc-modal-card:hover,
.svc-modal-card:active { border-color: rgba(16,185,129,.28); background: rgba(16,185,129,.04); }

.svc-modal-card-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
}
.svc-modal-card-name { font-size: .88rem; font-weight: 700; color: var(--txt); line-height: 1.2; }
.svc-modal-card-desc { font-size: .74rem; color: var(--txt3); line-height: 1.45; flex: 1; }
.svc-modal-card-arr  { font-size: .71rem; color: var(--txt3); display: flex; align-items: center; gap: .3rem; margin-top: .15rem; }
.svc-modal-card:hover  .svc-modal-card-arr,
.svc-modal-card:active .svc-modal-card-arr { color: var(--mint-h); }

.svc-modal-footer { padding: 0 1.1rem; display: flex; flex-direction: column; gap: .6rem; }

.svc-modal-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    padding: .82rem 1.5rem;
    border-radius: 13px;
    font-size: .9rem;
    font-weight: 600;
    background: linear-gradient(135deg, #10b981, #059669);
    color: #fff;
    text-decoration: none;
    transition: filter .18s;
    box-shadow: 0 6px 22px rgba(16,185,129,.28);
    border: none;
    cursor: pointer;
    font-family: inherit;
}
.svc-modal-cta:hover { filter: brightness(1.08); color: #fff; }

.svc-modal-view-all {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .45rem;
    padding: .75rem 1.5rem;
    border-radius: 13px;
    font-size: .88rem;
    font-weight: 500;
    color: var(--txt2);
    text-decoration: none;
    transition: all .18s;
    border: 1px solid rgba(100,140,200,.12);
    background: transparent;
}
[data-theme="light"] .svc-modal-view-all { border-color: rgba(0,0,0,.1); }
.svc-modal-view-all:hover { color: var(--mint-h); border-color: rgba(16,185,129,.28); }
