/* 
 * Websly Ultra-Modern Navbar Styles (v5.1)
 * High-performance visual effects for premium navigation components.
 */

/* --- 1. Navbar Styles --- */

/* Neon Wide */
.websly-nav-neon {
    border-bottom: 2px solid var(--theme-accent);
    box-shadow: 0 4px 20px -5px rgba(var(--theme-accent-rgb), 0.4);
    transition: box-shadow 0.6s ease, border-color 0.6s ease;
}

#navbar.scrolled.websly-nav-neon {
    box-shadow: 0 10px 40px -10px rgba(var(--theme-accent-rgb), 0.6);
}

/* Kinetic Minimalist */
.websly-nav-kinetic {
    backdrop-filter: blur(0px); /* Transition to blur on scroll */
}

#navbar.scrolled.websly-nav-kinetic {
    backdrop-filter: blur(20px);
    background: color-mix(in srgb, var(--bg-theme-base) 80%, transparent);
}

/* --- 2. Menu Item Hover Animations --- */

.websly-nav-links-wrap li {
    position: relative;
    list-style: none;
}

/* Base nav link — clean text, no chrome at rest.
   Explicitly resets background/border from any button class that may be
   applied via the customizer (e.g. btn-soft saved from a previous default).
   Opacity 0.75 at rest keeps links visually lighter than headings;
   full opacity on hover signals interactivity without any colour change.
*/
.websly-nav-link {
    display: flex;
    align-items: center;
    padding: 0.4rem 0.85rem;
    position: relative;
    isolation: isolate;
    z-index: 1;
    color: inherit !important;
    text-decoration: none;
    border-radius: 999px;
    background: none !important;
    border: none !important;
    box-shadow: none !important;
    opacity: 0.75;
    transition: opacity 0.2s ease;
}

.websly-nav-link-inner {
    position: relative;
    z-index: 1;
}

.websly-nav-link:hover {
    opacity: 1;
    background: none !important;
}

/* Active page — full opacity, no colour override */
.websly-nav-links-wrap .current-menu-item > .websly-nav-link,
.websly-nav-links-wrap .current-page-ancestor > .websly-nav-link {
    opacity: 1;
}

/* ── Magnet Glow (default) ────────────────────────────────────────────────
   Uses currentColor so the pill is always visible regardless of dark/light surface.
   Separate in/out transitions: spring on enter, ease-out on leave.
*/
.websly-hover-magnet-glow .websly-nav-link::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: color-mix(in srgb, currentColor 9%, transparent);
    opacity: 0;
    transform: scale(0.82);
    /* Mouse-out: fast ease-out — no spring bounce on exit */
    transition: opacity 0.18s ease-out, transform 0.2s ease-out;
    z-index: 0;
}

.websly-hover-magnet-glow .websly-nav-link:hover::before {
    opacity: 1;
    transform: scale(1);
    /* Mouse-in: spring — feels magnetic and alive */
    transition: opacity 0.18s ease-in, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Active: persistent dim pill */
.websly-hover-magnet-glow .current-menu-item > .websly-nav-link::before,
.websly-hover-magnet-glow .current-page-ancestor > .websly-nav-link::before {
    opacity: 0.55;
    transform: scale(1);
}

/* ── Kinetic Underscore ────────────────────────────────────────────────── */
.websly-hover-kinetic-underscore .websly-nav-link::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0%;
    height: 1.5px;
    background: currentColor;
    opacity: 0.5;
    transition: width 0.32s cubic-bezier(0.8, 0, 0.2, 1), left 0.32s cubic-bezier(0.8, 0, 0.2, 1);
    border-radius: 99px;
}

.websly-hover-kinetic-underscore .websly-nav-link:hover::after,
.websly-hover-kinetic-underscore .current-menu-item > .websly-nav-link::after {
    width: 60%;
    left: 20%;
    opacity: 0.9;
}

/* ── Ambient Pulse ─────────────────────────────────────────────────────── */
.websly-hover-ambient-pulse .websly-nav-link::before {
    content: "";
    position: absolute;
    inset: 0;
    background: currentColor;
    opacity: 0;
    transform: scale(0.8);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
    z-index: 0;
    border-radius: 8px;
    filter: blur(14px);
}

.websly-hover-ambient-pulse .websly-nav-link:hover::before {
    opacity: 0.08;
    transform: scale(1.15);
}

/* --- 3. Interaction Mechanics (JavaScript Driven) --- */

/* Scrolled state for all navbars */
#navbar.scrolled {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
    box-shadow: 0 20px 50px -10px rgba(0,0,0,0.1);
}

/* Pill Capsule specific transition */
#navbar[data-nav-style="pill-capsule"].scrolled {
    width: 85% !important;
    border-radius: 999px !important;
}

/* --- 4. 5.1 Surface Engine Bridges --- */

/* Material Overrides */
.ws-mat-glass {
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
}

.ws-mat-solid {
    backdrop-filter: none;
    background-color: var(--bg-theme-surface) !important;
}

.ws-mat-transparent {
    backdrop-filter: none;
    background-color: transparent !important;
    border-color: transparent !important;
    box-shadow: none !important;
}

/* Tone Overrides */
.ws-tone-accent {
    --text-theme-text-rgb: 255, 255, 255;
    background-color: var(--theme-accent) !important;
    color: var(--text-on-accent) !important;
}

/* ── Frame color token ───────────────────────────────────────────────────────
   --nav-frame-color is set as an inline CSS var on the <nav> element by PHP
   (navbar.php) based on the websly_navbar_frame_color customizer setting.
   Fallback: var(--theme-accent) so it always works even without customizer.
   All accent/glow/neon/gradient frames read from this single token.
   Neutral frames use currentColor so they always contrast with the navbar text.
*/

/* Frame Overrides — neutral (currentColor, always readable) */
.ws-frame-none        { border: none !important; }
.ws-frame-subtle      { border: 1px solid color-mix(in srgb, currentColor 9%,  transparent) !important; }
.ws-frame-strong      { border: 2px solid color-mix(in srgb, currentColor 22%, transparent) !important; }
.ws-frame-thick       { border: 3px solid color-mix(in srgb, currentColor 28%, transparent) !important; }
.ws-frame-thick-heavy { border: 4px solid color-mix(in srgb, currentColor 36%, transparent) !important; }

/* Frame Overrides — themed color (uses --nav-frame-color) */
.ws-frame-accent {
    border: 1px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 55%, transparent) !important;
}
.ws-frame-accent-strong {
    border: 2px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 75%, transparent) !important;
}
.ws-frame-accent-thick {
    border: 3px solid var(--nav-frame-color, var(--theme-accent)) !important;
}
.ws-frame-accent-heavy {
    border: 4px solid var(--nav-frame-color, var(--theme-accent)) !important;
}
.ws-frame-accent-bottom {
    border: none !important;
    border-bottom: 2px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 65%, transparent) !important;
}
.ws-frame-accent-bottom-thick {
    border: none !important;
    border-bottom: 3px solid var(--nav-frame-color, var(--theme-accent)) !important;
}
.ws-frame-accent-bottom-glow {
    border: none !important;
    border-bottom: 2px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 80%, transparent) !important;
    box-shadow: 0 4px 18px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 45%, transparent),
                0 1px 6px  color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 60%, transparent) !important;
}

/* ─────────────────────────────────────────────────────────────────────────────
   5. PREMIUM MATERIAL VARIANTS
   Each adds backdrop, background, and shadow. Applied via ws-mat-{slug}.
   ───────────────────────────────────────────────────────────────────────────── */

/* Glass Frost — heavy blur, maximum frosting. Great over images/video heroes. */
.ws-mat-glass-frost {
    backdrop-filter: blur(48px) saturate(220%) brightness(1.08);
    -webkit-backdrop-filter: blur(48px) saturate(220%) brightness(1.08);
    background: rgba(255, 255, 255, 0.10) !important;
}
[data-theme="dark"] .ws-mat-glass-frost,
.dark .ws-mat-glass-frost {
    background: rgba(0, 0, 0, 0.28) !important;
}

/* Glass Silk — feather-light blur. Barely-there, ultra-refined. */
.ws-mat-glass-silk {
    backdrop-filter: blur(18px) saturate(160%);
    -webkit-backdrop-filter: blur(18px) saturate(160%);
    background: rgba(255, 255, 255, 0.05) !important;
    box-shadow: 0 1px 0 rgba(255,255,255,0.08) inset;
}
[data-theme="dark"] .ws-mat-glass-silk,
.dark .ws-mat-glass-silk {
    background: rgba(255, 255, 255, 0.04) !important;
}

/* Glass Dark — smoked tinted glass. Strong dark contrast over any bg. */
.ws-mat-glass-dark {
    backdrop-filter: blur(32px) saturate(180%) brightness(0.75);
    -webkit-backdrop-filter: blur(32px) saturate(180%) brightness(0.75);
    background: rgba(0, 0, 0, 0.42) !important;
    color: #fff !important;
    --text-theme-text-rgb: 255, 255, 255;
}

/* Glass Aurora — glass tinted with theme accent, slow breathing animation. */
.ws-mat-glass-aurora {
    backdrop-filter: blur(28px) saturate(200%);
    -webkit-backdrop-filter: blur(28px) saturate(200%);
    background: linear-gradient(
        135deg,
        rgba(var(--theme-accent-rgb), 0.12) 0%,
        rgba(var(--accent-secondary-rgb, var(--theme-accent-rgb)), 0.07) 50%,
        rgba(var(--theme-accent-rgb), 0.04) 100%
    ) !important;
    background-size: 200% 200% !important;
    animation: ws-aurora-drift 10s ease infinite;
}
@keyframes ws-aurora-drift {
    0%, 100% { background-position: 0% 50%; }
    50%       { background-position: 100% 50%; }
}

/* Gradient Brand — primary → secondary theme gradient. Fully opaque. */
.ws-mat-gradient-brand {
    backdrop-filter: none;
    background: linear-gradient(
        135deg,
        var(--theme-accent) 0%,
        var(--accent-secondary, color-mix(in srgb, var(--theme-accent) 60%, #fff)) 100%
    ) !important;
    color: #fff !important;
    --text-theme-text-rgb: 255, 255, 255;
}

/* Gradient Primary — monochrome shades of the primary accent color. */
.ws-mat-gradient-primary {
    backdrop-filter: none;
    background: linear-gradient(
        135deg,
        color-mix(in srgb, var(--theme-accent) 70%, #000) 0%,
        var(--theme-accent) 50%,
        color-mix(in srgb, var(--theme-accent) 70%, #fff) 100%
    ) !important;
    color: #fff !important;
    --text-theme-text-rgb: 255, 255, 255;
}

/* Gradient Secondary — monochrome shades of the secondary accent. */
.ws-mat-gradient-secondary {
    backdrop-filter: none;
    background: linear-gradient(
        135deg,
        color-mix(in srgb, var(--accent-secondary, var(--theme-accent)) 70%, #000) 0%,
        var(--accent-secondary, var(--theme-accent)) 50%,
        color-mix(in srgb, var(--accent-secondary, var(--theme-accent)) 70%, #fff) 100%
    ) !important;
    color: #fff !important;
    --text-theme-text-rgb: 255, 255, 255;
}

/* Gradient Mesh — radial accent blobs over a semi-transparent base. */
.ws-mat-gradient-mesh {
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    background:
        radial-gradient(ellipse at 15% 50%, rgba(var(--theme-accent-rgb), 0.22) 0%, transparent 55%),
        radial-gradient(ellipse at 85% 50%, rgba(var(--accent-secondary-rgb, var(--theme-accent-rgb)), 0.16) 0%, transparent 55%),
        rgba(var(--bg-theme-base-rgb, 15,15,15), 0.72) !important;
}

/* Neumorphic — soft inset/outset shadows on the surface colour.
   Works best when navbar is over a section with a matching base tone. */
.ws-mat-neumorphic {
    backdrop-filter: none;
    background: var(--bg-theme-surface, #1a1a2e) !important;
    box-shadow:
        8px 8px 16px rgba(0,0,0,0.22),
        -8px -8px 16px rgba(255,255,255,0.04),
        inset 0 1px 0 rgba(255,255,255,0.06) !important;
    border: none !important;
}

/* Noise — matte solid with subtle grain texture for depth.
   Uses an SVG data-URI noise overlay via ::after. */
.ws-mat-noise {
    backdrop-filter: none;
    background: var(--bg-theme-surface) !important;
    position: relative;
    overflow: hidden;
}
.ws-mat-noise::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
    background-size: 180px 180px;
    opacity: 0.6;
    pointer-events: none;
    z-index: 0;
}

/* ─────────────────────────────────────────────────────────────────────────────
   6. PREMIUM FRAME / BORDER VARIANTS
   ───────────────────────────────────────────────────────────────────────────── */

/* Glow — themed shadow halo + soft inner highlight */
.ws-frame-glow {
    border: 1px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 35%, transparent) !important;
    box-shadow:
        0 0 18px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 18%, transparent),
        0 0 40px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 8%,  transparent),
        inset 0 1px 0 rgba(255,255,255,0.10) !important;
}

/* Gradient — border visually changes from accent to secondary */
.ws-frame-gradient {
    border: 1px solid transparent !important;
    background-clip: padding-box, border-box;
    background-image: none, linear-gradient(135deg,
        rgba(var(--theme-accent-rgb), 0.65),
        rgba(var(--accent-secondary-rgb, var(--theme-accent-rgb)), 0.35));
    background-origin: padding-box, border-box;
}
/* Fallback for glass elements where background-image is already set */
.ws-mat-glass.ws-frame-gradient,
.ws-mat-glass-frost.ws-frame-gradient,
.ws-mat-glass-silk.ws-frame-gradient,
.ws-mat-glass-aurora.ws-frame-gradient,
.ws-mat-gradient-mesh.ws-frame-gradient {
    border: 1px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 50%, transparent) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.12), 0 0 12px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 10%, transparent) !important;
    background-image: none !important;
}

/* Neon — high-intensity glow, use sparingly for hero/landing pages */
.ws-frame-neon {
    border: 1px solid color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 60%, transparent) !important;
    box-shadow:
        0 0 6px  color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 50%, transparent),
        0 0 20px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 25%, transparent),
        0 0 50px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 10%, transparent),
        inset 0 0 6px color-mix(in srgb, var(--nav-frame-color, var(--theme-accent)) 6%, transparent) !important;
}

/* Inner Glow — subtle inward highlight, no outer shadow. Elegant restraint. */
.ws-frame-inner {
    border: 1px solid rgba(255,255,255,0.08) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.14), inset 0 -1px 0 rgba(0,0,0,0.08) !important;
}

/* ─────────────────────────────────────────────────────────────────────────────
   7. PREMIUM HOVER ANIMATION VARIANTS
   ───────────────────────────────────────────────────────────────────────────── */

/* Accent Pill — accent-tinted background blooms in on hover */
.websly-hover-accent-pill .websly-nav-link::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent-default, currentColor) 16%, transparent);
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.18s ease-out, transform 0.2s ease-out;
    z-index: 0;
}
.websly-hover-accent-pill .websly-nav-link:hover::before {
    opacity: 1;
    transform: scale(1);
    transition: opacity 0.18s ease-in, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.websly-hover-accent-pill .current-menu-item > .websly-nav-link::before {
    opacity: 0.65;
    transform: scale(1);
}

/* Gradient Sweep — diagonal gradient sweeps across the link on hover */
.websly-hover-gradient-sweep .websly-nav-link {
    overflow: hidden;
}
.websly-hover-gradient-sweep .websly-nav-link::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: linear-gradient(
        105deg,
        transparent 0%,
        rgba(var(--theme-accent-rgb), 0.15) 45%,
        rgba(var(--accent-secondary-rgb, var(--theme-accent-rgb)), 0.10) 55%,
        transparent 100%
    );
    opacity: 0;
    transform: translateX(-110%);
    transition: transform 0.55s cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 0.2s ease;
    z-index: 0;
}
.websly-hover-gradient-sweep .websly-nav-link:hover::before {
    opacity: 1;
    transform: translateX(110%);
}
.websly-hover-gradient-sweep .current-menu-item > .websly-nav-link::before {
    opacity: 1;
    transform: translateX(0);
    background: rgba(var(--theme-accent-rgb), 0.10);
}

/* Dot Indicator — small accent dot rises under the active/hovered link */
.websly-hover-dot-indicator .websly-nav-link::after {
    content: "";
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%) scale(0) translateY(4px);
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--theme-accent);
    box-shadow: 0 0 6px rgba(var(--theme-accent-rgb), 0.6);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s ease;
    opacity: 0;
}
.websly-hover-dot-indicator .websly-nav-link:hover::after,
.websly-hover-dot-indicator .current-menu-item > .websly-nav-link::after {
    transform: translateX(-50%) scale(1) translateY(0);
    opacity: 1;
}

/* Glow Bloom — item glows outward with a soft accent shadow */
.websly-hover-glow-bloom .websly-nav-link {
    transition: opacity 0.2s ease, text-shadow 0.3s ease, filter 0.3s ease;
}
.websly-hover-glow-bloom .websly-nav-link:hover {
    filter: drop-shadow(0 0 8px rgba(var(--theme-accent-rgb), 0.45));
    opacity: 1;
}
.websly-hover-glow-bloom .current-menu-item > .websly-nav-link {
    filter: drop-shadow(0 0 5px rgba(var(--theme-accent-rgb), 0.3));
    opacity: 1;
}

/* ─────────────────────────────────────────────────────────────────────────────
   8. NEW NAVBAR SHAPE STYLES
   ───────────────────────────────────────────────────────────────────────────── */

/* Island Wide — floating bar wider than pill-capsule, square-ish ends on desktop */
#navbar[data-nav-style="island-wide"].scrolled {
    width: 92% !important;
}

/* Glass Bar — full-width topbar, gains blur on scroll from transparent start */
#navbar[data-nav-style="glass-bar"] {
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
    transition:
        backdrop-filter 0.5s ease,
        background-color 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        border-color 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}
#navbar[data-nav-style="glass-bar"].scrolled {
    backdrop-filter: blur(32px) saturate(200%);
    -webkit-backdrop-filter: blur(32px) saturate(200%);
}

/* ─────────────────────────────────────────────────────────────────────────────
   9. BORDER / FRAME AT PAGE TOP
   Suppresses border and shadow when at the very top, before any scrolling.
   JS adds .is-scrolled once the user has scrolled past 50px.
   ───────────────────────────────────────────────────────────────────────────── */
#navbar[data-hide-border-top="true"]:not(.is-scrolled) {
    border-color: transparent !important;
    box-shadow: none !important;
}

/* ─────────────────────────────────────────────────────────────────────────────
   10. SMART HIDE — slide off on scroll-down, slide back on scroll-up
   JS adds .nav-hidden when scrolling down, removes it when scrolling up.
   ───────────────────────────────────────────────────────────────────────────── */
#navbar {
    will-change: transform;
}

#navbar.nav-hidden {
    transform: translateY(-24px);
    opacity: 0;
    pointer-events: none;
}

/* Unified transition — covers smart-hide fade, scroll material change, and top-gap shift */
#navbar {
    transition:
        transform 0.38s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.32s ease,
        background-color 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        border-color 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        top 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        color 0.3s ease,
        box-shadow 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        backdrop-filter 0.45s ease;
}

/* ─────────────────────────────────────────────────────────────────────────────
   11. NAVBAR VISUAL PRESETS (External Style Adoption System)
   Each preset is a distinct visual personality applied via .ws-nav-preset-{slug}.
   All presets use Websly semantic tokens so they respect the active theme.
   ───────────────────────────────────────────────────────────────────────────── */

/* ── Preset: SVG Outline ─────────────────────────────────────────────────────
   Adapted from uiverse.io/SelfMadeSystem/ancient-donkey-33.
   A single animated SVG rect traces the border of the hovered nav item.
   The highlight moves dynamically via JS (websly-main.js).
   Uses --nav-frame-color so it inherits the user's chosen frame color.
*/
.ws-nav-svg-outline-container {
    position: relative;
}

/* The SVG overlay sits behind nav link text */
.ws-nav-preset-svg-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    pointer-events: none;
    z-index: 0;
}

/* The animated rect — hidden at rest */
.ws-nav-preset-svg-rect {
    stroke-dashoffset: 5;
    stroke-dasharray: 0 0 0 1000;
    transition: stroke-dasharray 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                stroke-dashoffset 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                x 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                y 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                width 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                height 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    opacity: 0;
    transition: opacity 0.25s ease, x 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                y 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                width 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                height 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Active rect — shown when a link is hovered (JS adds .is-active) */
.ws-nav-svg-outline-container:hover .ws-nav-preset-svg-rect,
.ws-nav-preset-svg-rect.is-active {
    opacity: 1;
}

/* When preset is svg-outline: remove default nav link backgrounds to avoid double effects */
.ws-nav-preset-svg-outline .websly-nav-link::before,
.ws-nav-preset-svg-outline .websly-nav-link::after {
    display: none !important;
}

/* ── Preset: Ambient Halo ─────────────────────────────────────────────────────
   An accent-tinted ambient glow blooms beneath the navbar.
   Creates a premium "floating above light" effect. 100% CSS, no JS.
*/
.ws-nav-preset-ambient-halo {
    position: relative;
}

.ws-nav-preset-ambient-halo::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 40px;
    background: radial-gradient(
        ellipse at center,
        rgba(var(--theme-accent-rgb), 0.28) 0%,
        rgba(var(--theme-accent-rgb), 0.12) 40%,
        transparent 70%
    );
    filter: blur(16px);
    pointer-events: none;
    z-index: -1;
    transition: opacity 0.5s ease;
}

/* At top of page, halo is stronger; fades slightly on scroll */
#navbar[data-hide-border-top="true"]:not(.is-scrolled).ws-nav-preset-ambient-halo::after {
    opacity: 0.9;
}
#navbar.is-scrolled.ws-nav-preset-ambient-halo::after {
    opacity: 0.5;
    width: 60%;
}

/* ── Preset: Minimal Line ─────────────────────────────────────────────────────
   Ultra-clean editorial style. Removes all borders/frames, adds a single 1px
   bottom line that fades in on scroll. Inspired by high-end agency sites.
*/
.ws-nav-preset-minimal-line {
    border: none !important;
    box-shadow: none !important;
    border-bottom: 1px solid transparent !important;
    transition:
        border-bottom-color 0.4s ease,
        background-color 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        top 0.45s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

#navbar.is-scrolled.ws-nav-preset-minimal-line {
    border-bottom-color: color-mix(in srgb, currentColor 18%, transparent) !important;
}

/* Nav links for minimal-line: letter-spacing + small caps feel */
.ws-nav-preset-minimal-line .websly-nav-link {
    letter-spacing: 0.08em;
    border-radius: 0 !important;
    padding-left: 0.65rem;
    padding-right: 0.65rem;
}

/* ── Preset: Aurora Trail ─────────────────────────────────────────────────────
   An animated aurora gradient flows across the full width of the navbar.
   Uses @keyframes for a slow, breathing accent movement.
*/
@keyframes ws-nav-aurora-flow {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.ws-nav-preset-aurora-trail::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: linear-gradient(
        105deg,
        rgba(var(--theme-accent-rgb), 0) 0%,
        rgba(var(--theme-accent-rgb), 0.15) 25%,
        rgba(var(--accent-secondary-rgb, var(--theme-accent-rgb)), 0.12) 50%,
        rgba(var(--theme-accent-rgb), 0.08) 75%,
        rgba(var(--theme-accent-rgb), 0) 100%
    );
    background-size: 300% 100%;
    animation: ws-nav-aurora-flow 8s ease infinite;
    pointer-events: none;
    z-index: 0;
    opacity: 0.6;
    border: 1px solid rgba(var(--theme-accent-rgb), 0.12);
}

/* Extra glow pulse on the aurora trail */
.ws-nav-preset-aurora-trail {
    overflow: visible;
}

/* ── Preset: Spotlight Bar ────────────────────────────────────────────────────
   A moving spotlight illuminates the hovered menu item from above.
   Pure CSS spotlight cone via radial-gradient, positioned via JS custom property.
*/
.ws-nav-preset-spotlight-bar .websly-nav-links-wrap {
    position: relative;
}

.ws-nav-preset-spotlight-bar .websly-nav-links-wrap::before {
    content: '';
    position: absolute;
    top: -28px;
    left: var(--spotlight-x, 50%);
    transform: translateX(-50%);
    width: 80px;
    height: 56px;
    background: radial-gradient(
        ellipse at top,
        rgba(var(--nav-frame-color-rgb, var(--theme-accent-rgb)), 0.45) 0%,
        rgba(var(--nav-frame-color-rgb, var(--theme-accent-rgb)), 0.15) 40%,
        transparent 70%
    );
    filter: blur(8px);
    pointer-events: none;
    transition: left 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                opacity 0.25s ease;
    opacity: 0;
    z-index: 2;
}

.ws-nav-preset-spotlight-bar .websly-nav-links-wrap:hover::before {
    opacity: 1;
}
