/* Custom Styles for Portfolio Website */

/* Utility Classes */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Navigation Styles */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.dark .navbar {
    background: rgba(17, 24, 39, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.dark .navbar.scrolled {
    background: rgba(17, 24, 39, 0.98);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

/* Button Styles */
.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    box-shadow: 0 4px 14px 0 rgba(59, 130, 246, 0.4);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
    box-shadow: 0 6px 20px 0 rgba(59, 130, 246, 0.6);
}

.btn-secondary {
    border: 2px solid currentColor;
    background: transparent;
}

.btn-secondary:hover {
    background: currentColor;
    color: white;
}

/* Card Hover Effects */
.project-card:hover,
.blog-card:hover,
.service-card:hover,
.team-card:hover,
.testimonial-card:hover {
    transform: translateY(-8px);
}

/* Skill Bar Animation */
.skill-bar {
    width: 0;
    transition: width 1.5s ease-in-out;
}

.skill-bar.animate {
    width: var(--width);
}

/* Custom Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }
}

.float-animation {
    animation: float 3s ease-in-out infinite;
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Loading States */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        left: -100%;
    }

    100% {
        left: 100%;
    }
}

/* Mobile Menu Animation */
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Notification Badge */
.notification-badge {
    animation: pulse 2s infinite;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.dark ::-webkit-scrollbar-track {
    background: #1e293b;
}

.dark ::-webkit-scrollbar-thumb {
    background: #475569;
}

.dark ::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* Focus States */
.focus-visible:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Active navigation state using Devora brand color */
.nav-active {
    color: #8130a7 !important;
    /* Devora brand color */
    font-weight: 600;
    /* ensure semibold */
}

.dark .nav-active {
    color: #8130a7 !important;
}

/* Print Styles */
@media print {

    .navbar,
    .footer,
    .btn-primary,
    .btn-secondary {
        display: none !important;
    }

    body {
        background: white !important;
        color: black !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .btn-primary {
        background: #000;
        border: 2px solid #000;
    }

    .btn-secondary {
        border: 2px solid #000;
        color: #000;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Dark mode transitions */
* {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

html,
body {
    overflow-x: hidden;
}

/* Custom form styles */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    ring: 2px;
    ring-color: #3b82f6;
    border-color: transparent;
}

/* Notification dropdown */
.notification-dropdown {
    max-height: 400px;
    overflow-y: auto;
}

.notification-item {
    border-bottom: 1px solid #e5e7eb;
}

.dark .notification-item {
    border-bottom: 1px solid #374151;
}

.notification-item:last-child {
    border-bottom: none;
}

/* User dropdown */
.user-dropdown {
    min-width: 200px;
}

/* Mobile menu animation */
.mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.mobile-menu.show {
    max-height: 500px;
}

/* Responsive images */
img {
    max-width: 100%;
    height: auto;
}

/* Accessibility improvements */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Skip to content link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #3b82f6;
    color: white;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
}

.skip-link:focus {
    top: 6px;
}

/*Image header*/
.imageheader {
    max-width: 48px;
    /* mobile default */
    height: auto;
    padding: 4px;
    display: inline-block;
}

@media (min-width: 768px) {
    .imageheader {
        max-width: 64px;
        /* tablet+ */
    }
}
/*Preloader*/
.preloader {
    height: 100% !important;
    width: 100% !important;
}