/* Custom CSS Variables */
:root {
    --primary-color: #6366f1;
    --primary-hover: #5855eb;
    --secondary-color: #8b5cf6;
    --text-muted: #64748b;
    --bg-light: #f8fafc;
    --bg-dark: #1e293b;
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --shadow-light: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.12);
    --shadow-heavy: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-content {
    text-align: center;
    color: white;
}

.loading-logo img {
    filter: brightness(0) invert(1);
    animation: pulse 2s infinite;
}

.loading-spinner {
    margin: 2rem 0;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-text {
    font-size: 1.1rem;
    font-weight: 500;
    margin-top: 1rem;
    animation: fadeInOut 2s infinite;
}

/* Custom Bootstrap Overrides */
.btn-primary {
    background: var(--gradient-primary);
    border: none;
    transition: all 0.3s ease;
}

.btn-primary:hover,
.btn-primary:focus {
    background: linear-gradient(135deg, #5855eb 0%, #7c3aed 100%);
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.text-primary {
    color: var(--primary-color) !important;
}

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Navigation Styles */
.navbar {
    transition: all 0.3s ease;
    padding: 1rem 0;
    backdrop-filter: blur(10px);
}

.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.95) !important;
    box-shadow: var(--shadow-light);
}

.logo-animate {
    transition: all 0.3s ease;
}

.logo-animate:hover {
    transform: scale(1.05) rotate(5deg);
}

.nav-link {
    color: #333 !important;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--primary-color) !important;
    transform: translateY(-2px);
}

.pulse-btn {
    animation: pulse 2s infinite;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--bg-light) 0%, #e2e8f0 100%);
    padding-top: 100px;
    position: relative;
    overflow: hidden;
}

.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="%236366f1" opacity="0.3"><animate attributeName="opacity" values="0.3;1;0.3" dur="2s" repeatCount="indefinite"/></circle><circle cx="80" cy="30" r="1.5" fill="%238b5cf6" opacity="0.4"><animate attributeName="opacity" values="0.4;1;0.4" dur="3s" repeatCount="indefinite"/></circle><circle cx="60" cy="70" r="1" fill="%236366f1" opacity="0.5"><animate attributeName="opacity" values="0.5;1;0.5" dur="2.5s" repeatCount="indefinite"/></circle></svg>') repeat;
    animation: float 20s linear infinite;
}

.hero-content h1 {
    line-height: 1.2;
}

.hero-illustration {
    position: relative;
    max-width: 100%;
    bottom: -30px;
}

.illustration-background {
    right: 5%;
    top: -10%;
    position: absolute;
    background: var(--gradient-primary);
    border-radius: 50%;
    width: 70%;
    height: 90%;
    animation: floating 6s ease-in-out infinite;
}

.bounce-animation {
    animation: bounce 3s ease-in-out infinite;
}

.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.element {
    position: absolute;
    width: 20px;
    height: 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
}

.element-1 {
    top: 20%;
    left: 20%;
}

.element-2 {
    top: 60%;
    right: 20%;
}

.element-3 {
    bottom: 20%;
    left: 10%;
}

.float-animation {
    animation: float 3s ease-in-out infinite;
}

/* Hover Effects */
.hover-lift {
    transition: all 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.hover-card {
    transition: all 0.3s ease;
}

.hover-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-heavy);
}

/* Section Dividers */
.section-divider {
    width: 60px;
    height: 4px;
    background: var(--gradient-primary);
    margin: 0 auto 2rem;
    border-radius: 2px;
}

.section-divider-white {
    width: 60px;
    height: 4px;
    background: white;
    margin: 0 auto 2rem;
    border-radius: 2px;
}

/* Service Cards */
.Services {
    background-color: #FDFDFF;
    padding: 100px 0;
    position: relative;
}

.services-background {
    top: 0;
    right: 0;
    height: 20%;
    width: 20%;
}

.services-pattern {
    top: 80%;
    right: 0;
    transform: translateY(-50%);
    width: 60%;
    height: auto;
}

.rotate-animation {
    animation: rotate 20s linear infinite;
}

.service-card {
    transition: all 0.3s ease;
    border-radius: 12px !important;
    position: relative;
    overflow: hidden;
}

.service-card::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 ease;
}

.service-card:hover::before {
    left: 100%;
}

.service-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.icon-bounce:hover {
    animation: bounce 0.6s ease;
}

/* Portfolio Section */
.portfolio-section {
    padding: 100px 0;
    position: relative;
}

.background-decore {
    position: absolute;
    right: -5%;
    top: 10%;
}

.rotate-slow {
    animation: rotate 30s linear infinite;
}
.flip-box-inner {
  transform: rotateY(180deg);
}

.portfolio-item {
    transition: all 0.3s ease;
    margin-bottom: 20px;
    max-height: 200px;
    position: relative;
    overflow: hidden;
}

.portfolio-item img {
    object-fit: cover;
    aspect-ratio: 16 / 9;
    transition: transform 0.3s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    top: 0;
    left: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    opacity: 0;
    transition: all 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.filter-btn {
    border-radius: 25px !important;
    padding: 0.5rem 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    transition: left 0.3s ease;
    z-index: -1;
}

.filter-btn:hover::before,
.filter-btn.active::before {
    left: 0;
}

.filter-btn.active {
    color: white !important;
    border-color: var(--primary-color) !important;
}

/* Team Section */
.team-section {
    padding: 100px 0;
    background: url("../assets/svg/Background-Image.svg") no-repeat center center/cover;
    position: relative;
}

.team-card {
    transition: all 0.3s ease;
    border-radius: 12px !important;
    position: relative;
    overflow: hidden;
}

.team-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(99, 102, 241, 0.1), transparent);
    animation: rotate 10s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.team-card:hover::before {
    opacity: 1;
}

.team-card .card-body {
    position: relative;
    z-index: 2;
}

.team-card .card-body p {
    color: #6C6C72;
}
.profile-ring img {
    width: 120px !important;
    height: 120px !important;
    /* border-radius: 50%; */
    object-fit: cover;
    transition: transform 0.3s ease;
}
.profile-ring {
    --n: 4;
    --d: 10deg;
    --t: 3px;
    --c: var(--primary-color);
    padding: 5px;
    width: 130px;
    height: 130px;
    margin: 0 auto;
    margin-bottom: 2rem;
    position: relative;
    align-items: center;
    justify-content: center;
}

.profile-ring::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    padding: var(--t);
    background: var(--c);
    mask: linear-gradient(#0000 0 0) content-box,
          repeating-conic-gradient(
             from calc(var(--d)/2),
             #000  0 calc(360deg/var(--n) - var(--d)),
             #0000 0 calc(360deg/var(--n))
           );
    mask-composite: intersect;
    /* animation: rotate 3s linear infinite; */
}

.profile-animate:hover {
    transform: scale(1.05);
}

.social-links .btn:hover {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: white !important;
    transform: translateY(-2px) scale(1.1);
}

/* Testimonials Section */
.testimonial {
    position: relative;
    padding: 100px 0;
    background-color: #FDFDFF;
    justify-content: center;
    align-items: center;
}

.testimonial-content {
    padding: 2rem 0;
}

.testimonial-content::before {
    content: '"';
    font-family: "Montserrat", serif;
    font-size: 4rem;
    color: var(--primary-color);
    position: absolute;
    top: -10px;
    left: -20px;
    line-height: 1;
    animation: pulse 3s infinite;
}

.testimonial-content::after {
    content: '"';
    font-size: 4rem;
    font-family: "Montserrat", serif;
    color: var(--primary-color);
    position: absolute;
    bottom: -30px;
    right: 20px;
    line-height: 1;
    animation: pulse 3s infinite 1.5s;
}

.testimonial-decore {
    position: absolute;
    width: 20%;
    height: 20%;
}

.testimonial-decore.first {
    top: 8%;
    left: 0%;
}

.testimonial-decore.last {
    bottom: 8%;
    right: 0%;
}

.testimonial-avatars img {
    transition: all 0.3s ease;
    border: 3px solid white;
    object-fit: cover;
}

.testimonial-avatars img:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: var(--shadow-medium);
}

/* Contact Form */
.contact-form .form-control,
.contact-form .form-select {
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.input-animate:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.25);
    transform: translateY(-2px);
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

/* Footer */
.footer {
    padding: 2rem 0 1rem;
}

.footer-logo {
    filter: brightness(0) invert(1);
    transition: all 0.3s ease;
}

.footer-logo:hover {
    transform: scale(1.05);
}

.newsletter-form .input-group .form-control {
    background: transparent;
    border: 2px solid #334155;
    color: white;
    transition: all 0.3s ease;
}

.newsletter-form .input-group .form-control::placeholder {
    color: #94a3b8;
}

.newsletter-form .input-group .form-control:focus {
    background: transparent;
    border-color: var(--primary-color);
    color: white;
    box-shadow: none;
    transform: translateY(-2px);
}

.hover-link {
    transition: all 0.3s ease;
    position: relative;
}

.hover-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.hover-link:hover::after {
    width: 100%;
}

.hover-link:hover {
    color: var(--primary-color) !important;
    transform: translateX(5px);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: var(--shadow-medium);
}

/* Animations */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.05); }
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

@keyframes bounce {
    0%, 20%, 53%, 80%, 100% { transform: translate3d(0, 0, 0); }
    40%, 43% { transform: translate3d(0, -30px, 0); }
    70% { transform: translate3d(0, -15px, 0); }
    90% { transform: translate3d(0, -4px, 0); }
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes floating {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Adjustments */
@media (max-width: 1200px) {
    .hero-illustration .illustration-background {
        width: 80%;
        height: 95%;
    }
    
    .background-decore {
        right: -10%;
    }
}

@media (max-width: 992px) {
    .hero-section {
        padding-top: 80px;
    }
    
    .hero-content h1 {
        font-size: 2.5rem !important;
    }
    
    .Services, .portfolio-section, .team-section, .testimonial {
        padding: 80px 0;
    }
    
    .testimonial-decore {
        width: 15%;
        height: 15%;
    }
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2rem !important;
        text-align: center;
    }
    
    .hero-illustration {
        text-align: center;
        margin-top: 2rem;
    }
    
    .hero-illustration .illustration-background {
        width: 60%;
        height: 80%;
        right: 20%;
    }
    
    .display-5 {
        font-size: 1.75rem !important;
    }
    
    .testimonial-content::before,
    .testimonial-content::after {
        font-size: 3rem;
    }
    
    .service-icon {
        width: 60px;
        height: 60px;
    }
    
    .service-icon i {
        font-size: 1.5rem !important;
    }
    
    .profile-ring {
        width: 100px;
        height: 100px;
    }
    
    .profile-ring img {
        width: 90px !important;
        height: 90px !important;
    }
    
    .testimonial-decore {
        display: none;
    }
    
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 1.75rem !important;
    }
    
    .display-5 {
        font-size: 1.5rem !important;
    }
    
    .btn-lg {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
    
    .Services, .portfolio-section, .team-section, .testimonial {
        padding: 60px 0;
    }
    
    .section-divider,
    .section-divider-white {
        width: 40px;
        height: 3px;
    }
    
    .service-card,
    .team-card,
    .portfolio-item {
        margin-bottom: 1rem;
    }
    
    .testimonial-avatars img {
        width: 40px !important;
        height: 40px !important;
    }
    
    .loading-logo img {
        height: 40px;
    }
    
    .spinner {
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 400px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-content h1 {
        font-size: 1.5rem !important;
    }
    
    .profile-ring {
        width: 80px;
        height: 80px;
    }
    
    .profile-ring img {
        width: 70px !important;
        height: 70px !important;
    }
    
    .back-to-top {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #5855eb 0%, #7c3aed 100%);
}

/* Selection Color */
::selection {
    background: var(--primary-color);
    color: white;
}

::-moz-selection {
    background: var(--primary-color);
    color: white;
}