/* ============================================
   SIGNATURE NAVIGATION - Floating Pill Design
   DentalVoicePro Iconic Nav
   ============================================ */

/* Main container - floating pill */
.nav-signature {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0.75rem 1rem;
}

.nav-signature-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1100px;
    margin: 0 auto;
    height: 52px;
    padding: 0 1.25rem;
    border-radius: 9999px;

    /* Glass morphism */
    background: rgba(15, 23, 42, 0.88);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);

    /* Deep floating shadow */
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 2px 8px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);

    /* Subtle border */
    border: 1px solid rgba(255, 255, 255, 0.08);

    /* Smooth transitions */
    transition: all 0.3s ease;
}

/* Glass highlight - top edge */
.nav-signature-inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 2rem;
    right: 2rem;
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.15) 30%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0.15) 70%,
        transparent 100%
    );
    border-radius: 9999px;
}

/* Emerald glow - bottom edge */
.nav-signature-inner::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 3rem;
    right: 3rem;
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(16, 185, 129, 0.3) 30%,
        rgba(16, 185, 129, 0.4) 50%,
        rgba(16, 185, 129, 0.3) 70%,
        transparent 100%
    );
    border-radius: 9999px;
}

/* Hover lift effect */
.nav-signature-inner:hover {
    transform: translateY(-2px);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.5),
        0 4px 12px rgba(0, 0, 0, 0.25),
        0 0 30px rgba(16, 185, 129, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(16, 185, 129, 0.2);
}

/* Enhanced emerald glow on hover */
.nav-signature-inner:hover::after {
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(16, 185, 129, 0.5) 30%,
        rgba(16, 185, 129, 0.6) 50%,
        rgba(16, 185, 129, 0.5) 70%,
        transparent 100%
    );
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.4);
}

/* ============================================
   LEFT: Logo Section
   ============================================ */

.nav-sig-logo {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    text-decoration: none;
    flex-shrink: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-sig-logo:hover {
    transform: translateY(-1px);
}

.nav-sig-logo .logo-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-sig-logo:hover .logo-icon {
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.5), 0 0 30px rgba(16, 185, 129, 0.2);
    transform: scale(1.05);
}

.nav-sig-logo-text {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.95);
    white-space: nowrap;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-sig-logo:hover .nav-sig-logo-text {
    color: #ffffff;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

/* Pulse dot next to logo */
.nav-sig-pulse {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.8);
    animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 8px rgba(16, 185, 129, 0.8);
    }
    50% {
        opacity: 0.6;
        box-shadow: 0 0 12px rgba(16, 185, 129, 1);
    }
}

/* ============================================
   CENTER: Waveform Accent
   ============================================ */

.nav-sig-waveform {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 3px;
    height: 20px;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.nav-signature-inner:hover .nav-sig-waveform {
    opacity: 0.8;
}

.nav-sig-waveform span {
    width: 2px;
    border-radius: 1px;
    background: linear-gradient(to top,
        rgba(16, 185, 129, 0.3) 0%,
        rgba(16, 185, 129, 0.7) 50%,
        rgba(103, 232, 249, 0.8) 100%
    );
    animation: waveform-pulse 1.5s ease-in-out infinite;
}

.nav-sig-waveform span:nth-child(1) { height: 6px; animation-delay: 0s; }
.nav-sig-waveform span:nth-child(2) { height: 12px; animation-delay: 0.15s; }
.nav-sig-waveform span:nth-child(3) { height: 8px; animation-delay: 0.3s; }
.nav-sig-waveform span:nth-child(4) { height: 16px; animation-delay: 0.45s; }
.nav-sig-waveform span:nth-child(5) { height: 10px; animation-delay: 0.6s; }
.nav-sig-waveform span:nth-child(6) { height: 14px; animation-delay: 0.75s; }

@keyframes waveform-pulse {
    0%, 100% {
        transform: scaleY(1);
        opacity: 0.7;
    }
    50% {
        transform: scaleY(1.4);
        opacity: 1;
    }
}

/* ============================================
   RIGHT: Navigation Links
   ============================================ */

.nav-sig-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-sig-links a {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.4rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    border-radius: 9999px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

/* Glow dot indicator */
.nav-sig-links a::before {
    content: '';
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(100, 116, 139, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

/* Underline accent - slides in from left */
.nav-sig-links a::after {
    content: '';
    position: absolute;
    bottom: 6px;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #10b981, #67e8f9);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
    opacity: 0;
}

/* Hover state */
.nav-sig-links a:hover {
    color: #ffffff;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.12) 0%, rgba(103, 232, 249, 0.08) 100%);
    transform: translateY(-1px);
}

.nav-sig-links a:hover::before {
    background: #10b981;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.8), 0 0 20px rgba(16, 185, 129, 0.4);
    transform: scale(1.2);
}

.nav-sig-links a:hover::after {
    width: 60%;
    opacity: 1;
}

/* Active/current page state */
.nav-sig-links a.active,
.nav-sig-links a[aria-current="page"] {
    color: rgba(255, 255, 255, 0.95);
    background: rgba(16, 185, 129, 0.12);
}

.nav-sig-links a.active::before,
.nav-sig-links a[aria-current="page"]::before {
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.8);
}

/* Live Demo - compact pill - HIGH SPECIFICITY */
.nav-signature .nav-signature-inner .nav-sig-links a.nav-live-demo,
.nav-sig-links a.nav-live-demo {
    color: #10b981 !important;
    font-weight: 600 !important;
    font-size: 0.7rem !important;
    padding: 0.3rem 0.6rem !important;
    white-space: nowrap !important;
    height: 26px !important;
    max-height: 26px !important;
    min-height: 26px !important;
    line-height: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    box-sizing: border-box !important;
    border-radius: 9999px !important;
    border: 1px solid rgba(16, 185, 129, 0.3) !important;
    background: rgba(16, 185, 129, 0.08) !important;
    overflow: hidden !important;
}

.nav-signature .nav-sig-links a.nav-live-demo::before,
.nav-sig-links a.nav-live-demo::before {
    width: 3px !important;
    height: 3px !important;
    min-width: 3px !important;
    background: #10b981 !important;
    box-shadow: 0 0 3px rgba(16, 185, 129, 0.6) !important;
    animation: pulse-glow 2s ease-in-out infinite !important;
    flex-shrink: 0 !important;
}

.nav-signature .nav-sig-links a.nav-live-demo:hover,
.nav-sig-links a.nav-live-demo:hover {
    background: rgba(16, 185, 129, 0.2) !important;
    border-color: rgba(16, 185, 129, 0.6) !important;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.4), inset 0 0 8px rgba(16, 185, 129, 0.1) !important;
    transform: translateY(-1px) !important;
    color: #34d399 !important;
}

.nav-signature .nav-sig-links a.nav-live-demo:hover::before,
.nav-sig-links a.nav-live-demo:hover::before {
    box-shadow: 0 0 8px rgba(16, 185, 129, 1), 0 0 16px rgba(16, 185, 129, 0.6) !important;
    transform: scale(1.3) !important;
}

/* Sign In - compact pill button - HIGH SPECIFICITY */
.nav-signature .nav-signature-inner .nav-sig-links a.btn-nav-cta,
.nav-sig-links a.btn-nav-cta {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    color: white !important;
    font-weight: 600 !important;
    font-size: 0.7rem !important;
    padding: 0.3rem 0.75rem !important;
    margin-left: 0.25rem !important;
    height: 26px !important;
    max-height: 26px !important;
    min-height: 26px !important;
    line-height: 1 !important;
    display: inline-flex !important;
    align-items: center !important;
    white-space: nowrap !important;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.3) !important;
    box-sizing: border-box !important;
    border-radius: 9999px !important;
    border: none !important;
    overflow: hidden !important;
}

.nav-signature .nav-sig-links a.btn-nav-cta::before,
.nav-sig-links a.btn-nav-cta::before {
    display: none !important;
    content: none !important;
}

.nav-signature .nav-sig-links a.btn-nav-cta:hover,
.nav-sig-links a.btn-nav-cta:hover {
    background: linear-gradient(135deg, #34d399 0%, #10b981 100%) !important;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.5), 0 0 20px rgba(16, 185, 129, 0.3) !important;
    transform: translateY(-2px) scale(1.02) !important;
}

/* Shimmer sweep on Sign In */
.nav-sig-links a.btn-nav-cta::after {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: -100% !important;
    width: 100% !important;
    height: 100% !important;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent) !important;
    transition: left 0.5s ease !important;
}

.nav-sig-links a.btn-nav-cta:hover::after {
    left: 100% !important;
}

/* ============================================
   THEME TOGGLE - Compact Sun/Moon
   ============================================ */

.nav-sig-theme-toggle {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 24px !important;
    height: 24px !important;
    max-width: 24px !important;
    max-height: 24px !important;
    min-width: 24px !important;
    min-height: 24px !important;
    margin-left: 0.5rem !important;
    padding: 0 !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.08) !important;
    cursor: pointer;
    transition: all 0.25s ease;
    position: relative;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
}

.nav-sig-theme-toggle:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(103, 232, 249, 0.5);
    box-shadow: 0 0 12px rgba(103, 232, 249, 0.3), 0 0 20px rgba(103, 232, 249, 0.15);
    transform: scale(1.08) rotate(15deg);
}

/* Theme icon - Moon (dark mode) */
.nav-sig-theme-toggle .theme-icon {
    width: 11px !important;
    height: 11px !important;
    position: relative;
    transition: all 0.25s ease;
}

.nav-sig-theme-toggle .theme-icon::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, #e2e8f0 0%, #f8fafc 100%);
    box-shadow: 0 0 4px rgba(248, 250, 252, 0.4);
}

/* Moon crescent */
.nav-sig-theme-toggle .theme-icon::after {
    content: '';
    position: absolute;
    top: -1px;
    right: -1px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.95);
}

/* ============================================
   MOBILE MENU BUTTON
   ============================================ */

.nav-sig-mobile-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    width: 32px;
    height: 32px;
    padding: 6px;
    border: none;
    background: transparent;
    cursor: pointer;
}

.nav-sig-mobile-btn span {
    display: block;
    width: 100%;
    height: 2px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 1px;
    transition: all 0.25s ease;
}

/* ============================================
   LIGHT THEME OVERRIDES
   ============================================ */

[data-theme="light"] .nav-signature-inner {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(15, 23, 42, 0.08);
    box-shadow:
        0 8px 32px rgba(15, 23, 42, 0.12),
        0 2px 8px rgba(15, 23, 42, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

[data-theme="light"] .nav-signature-inner:hover {
    box-shadow:
        0 12px 40px rgba(15, 23, 42, 0.15),
        0 4px 12px rgba(15, 23, 42, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

[data-theme="light"] .nav-signature-inner::before {
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(15, 23, 42, 0.08) 30%,
        rgba(15, 23, 42, 0.1) 50%,
        rgba(15, 23, 42, 0.08) 70%,
        transparent 100%
    );
}

[data-theme="light"] .nav-sig-logo-text {
    color: rgba(15, 23, 42, 0.9);
}

[data-theme="light"] .nav-sig-links a {
    color: rgba(15, 23, 42, 0.7);
}

[data-theme="light"] .nav-sig-links a:hover {
    color: rgba(15, 23, 42, 0.95);
    background: rgba(15, 23, 42, 0.06);
}

[data-theme="light"] .nav-sig-links a::before {
    background: rgba(100, 116, 139, 0.4);
}

[data-theme="light"] .nav-sig-links a.active,
[data-theme="light"] .nav-sig-links a[aria-current="page"] {
    color: rgba(15, 23, 42, 0.95);
    background: rgba(16, 185, 129, 0.1);
}

[data-theme="light"] .nav-sig-theme-toggle {
    border-color: rgba(15, 23, 42, 0.1);
    background: rgba(15, 23, 42, 0.05);
}

[data-theme="light"] .nav-sig-theme-toggle:hover {
    background: rgba(15, 23, 42, 0.08);
    border-color: rgba(251, 191, 36, 0.5);
    box-shadow: 0 0 12px rgba(251, 191, 36, 0.3);
}

/* Sun icon (light mode) */
[data-theme="light"] .nav-sig-theme-toggle .theme-icon::before {
    background: linear-gradient(135deg, #fbbf24 0%, #fcd34d 100%);
    box-shadow: 0 0 8px rgba(251, 191, 36, 0.6);
}

/* Hide moon crescent - show full sun */
[data-theme="light"] .nav-sig-theme-toggle .theme-icon::after {
    opacity: 0;
}

[data-theme="light"] .nav-sig-mobile-btn span {
    background: rgba(15, 23, 42, 0.8);
}

/* ============================================
   MOBILE RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .nav-signature {
        padding: 0.5rem 0.75rem;
    }

    .nav-signature-inner {
        height: 48px;
        padding: 0 1rem;
    }

    .nav-sig-logo-text {
        font-size: 0.6rem;
        letter-spacing: 0.12em;
    }

    .nav-sig-waveform {
        display: none;
    }

    .nav-sig-links {
        display: none;
    }

    .nav-sig-mobile-btn {
        display: flex;
    }

    .nav-sig-theme-toggle {
        margin-left: 0.5rem;
    }

    /* Mobile menu open state */
    .nav-sig-links.mobile-open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: calc(100% + 0.5rem);
        left: 1rem;
        right: 1rem;
        padding: 1rem;
        border-radius: 1rem;
        background: rgba(15, 23, 42, 0.95);
        backdrop-filter: blur(16px);
        border: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    }

    [data-theme="light"] .nav-sig-links.mobile-open {
        background: rgba(255, 255, 255, 0.95);
        border-color: rgba(15, 23, 42, 0.1);
        box-shadow: 0 12px 40px rgba(15, 23, 42, 0.15);
    }

    .nav-sig-links.mobile-open a {
        width: 100%;
        padding: 0.75rem 1rem;
        justify-content: flex-start;
    }

    .nav-sig-links.mobile-open a.btn-nav-cta {
        margin: 0.5rem 0 0 0;
        justify-content: center;
    }
}

/* Hide original nav when signature is active */
.nav-signature ~ .nav {
    display: none;
}

/* Spacer for fixed nav */
body {
    padding-top: 76px;
}

@media (max-width: 768px) {
    body {
        padding-top: 68px;
    }
}
