/* KreativKlar Platform - Professional Navigation */

.main-navigation {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.nav-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: white;
    font-weight: 700;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.nav-logo:hover {
    transform: translateY(-1px);
    text-decoration: none;
    color: white;
}

.nav-logo i {
    font-size: 2rem;
    margin-right: 0.75rem;
    background: linear-gradient(45deg, #ff6b6b, #feca57);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.25rem;
    color: rgb(255 96 6 / 90%) !important;
    text-decoration: none;
    border-radius: 0.5rem;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-link:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.nav-link:hover:before {
    left: 100%;
}

.nav-link:hover {
    color: rgb(255 96 6) !important;
    background: rgba(255, 96, 6, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    text-decoration: none;
}

.nav-link.active {
    background: rgba(255, 96, 6, 0.2);
    color: rgb(255 96 6) !important;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nav-link i {
    margin-right: 0.5rem;
    font-size: 1.1rem;
}

/* Mobile Navigation */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.3s ease;
}

.nav-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* User Menu */
.user-menu {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(45deg, #ff6b6b, #feca57);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.user-avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Breadcrumb */
.breadcrumb {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.breadcrumb-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
}

.breadcrumb-nav a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-nav a:hover {
    color: white;
    text-decoration: none;
}

.breadcrumb-separator {
    color: rgba(255, 255, 255, 0.5);
    margin: 0 0.25rem;
}

/* Module Navigation */
.module-nav {
    padding: 1rem;
    display: flex;
    align-items: center;
    background: #fff;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    z-index: 100;
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.2s;
}

.back-btn:hover {
    background: #f5f5f5;
}

.back-btn i {
    font-size: 1.2rem;
}

/* Mobile Navigation Toggle */
.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.mobile-nav-toggle i {
    transition: var(--transition);
}

.mobile-nav-toggle:hover i {
    transform: scale(1.1);
}

/* Login and Register button styling */
.login-btn {
    background: rgba(34, 197, 94, 0.15) !important;
    color: rgb(34, 197, 94) !important;
    border: 1px solid rgba(34, 197, 94, 0.3) !important;
}

.login-btn:hover {
    background: rgba(34, 197, 94, 0.25) !important;
    color: rgb(34, 197, 94) !important;
    border-color: rgba(34, 197, 94, 0.5) !important;
}

.register-btn {
    background: rgba(59, 130, 246, 0.15) !important;
    color: rgb(59, 130, 246) !important;
    border: 1px solid rgba(59, 130, 246, 0.3) !important;
}

.register-btn:hover {
    background: rgba(59, 130, 246, 0.25) !important;
    color: rgb(59, 130, 246) !important;
    border-color: rgba(59, 130, 246, 0.5) !important;
}

/* Enhanced responsive navigation */
@media (max-width: 768px) {
    .mobile-nav-toggle {
        display: block;
    }
    
    .header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 1rem;
        position: relative;
    }
    
    .nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-color);
        border: 1px solid var(--border-color);
        border-radius: var(--radius-md);
        box-shadow: var(--shadow-lg);
        z-index: 1000;
        flex-direction: column;
        gap: 0;
        padding: 1rem;
    }
    
    .nav.active {
        display: flex;
    }
    
    .nav-link {
        justify-content: flex-start;
        padding: 0.75rem 1rem;
        border-radius: var(--radius-md);
        margin-bottom: 0.5rem;
    }
    
    .nav-link:hover {
        background: var(--hover-bg);
    }
    
    .nav-link.active {
        background: var(--accent-color);
        color: white;
    }
    
    .nav-link.upgrade-btn {
        background: linear-gradient(135deg, var(--accent-color), #f97316) !important;
        color: white !important;
        margin-top: 0.5rem;
        margin-bottom: 0;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .nav-toggle {
        display: block;
    }
    
    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        flex-direction: column;
        padding: 1rem;
        gap: 0.5rem;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
        transform: translateY(-10px);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-link {
        width: 100%;
        justify-content: flex-start;
        padding: 1rem;
        border-radius: 0.5rem;
    }
    
    .user-menu {
        gap: 0.5rem;
    }
    
    .breadcrumb-container {
        padding: 0 1rem;
    }
    
    .header {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
    
    .logo {
        text-align: center;
    }
    
    .nav {
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
    }
    
    .nav-link {
        justify-content: center;
        padding: 0.75rem;
        font-size: 0.9rem;
    }
    
    .nav-link.upgrade-btn {
        background: linear-gradient(135deg, var(--accent-color), #f97316) !important;
        color: white !important;
        border: none;
        padding: 0.75rem 1.5rem;
        border-radius: var(--radius-md);
        font-weight: 600;
        cursor: pointer;
        transition: var(--transition);
        display: flex;
        align-items: center;
        gap: 0.5rem;
        justify-content: center;
    }
    
    .nav-link.upgrade-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    }
}

@media (max-width: 480px) {
    .nav-container {
        height: 60px;
    }
    
    .nav-logo {
        font-size: 1.25rem;
    }
    
    .nav-logo i {
        font-size: 1.5rem;
        margin-right: 0.5rem;
    }
    
    .user-avatar {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    
    .header {
        padding: 0.75rem;
    }
    
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .nav {
        gap: 0.25rem;
    }
    
    .nav-link {
        padding: 0.5rem;
        font-size: 0.8rem;
    }
    
    .nav-link i {
        font-size: 1rem;
    }
}

/* Fix for mobile navigation overlap */
@media (max-width: 768px) {
    .container {
        padding-top: 0;
    }
    
    .main-content {
        margin-top: 1rem;
    }
    
    .demo-notice {
        position: relative;
        margin-bottom: 1rem;
    }
}

/* Hamburger menu for very small screens */
@media (max-width: 600px) {
    .nav {
        position: relative;
    }
    
    .nav::before {
        content: "☰";
        display: block;
        position: absolute;
        top: -40px;
        right: 0;
        font-size: 1.5rem;
        cursor: pointer;
        color: var(--text-color);
        z-index: 1000;
    }
    
    .nav {
        display: none;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        background: var(--bg-color);
        border: 1px solid var(--border-color);
        border-radius: var(--radius-md);
        box-shadow: var(--shadow-lg);
        z-index: 999;
    }
    
    .nav.active {
        display: flex;
    }
}

