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

:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --card-bg: #1a1a1a;
    --card-hover: #242424;
    --text-primary: #ffffff;
    --text-secondary: #b8b8b8;
    --text-muted: #808080;
    --border-color: #333333;
    --border-light: #555555;
    --accent-secondary: #cccccc;
    --shadow-md: 0 4px 20px 0 rgba(255, 255, 255, 0.1);
    --shadow-xl: 0 20px 40px 0 rgba(255, 255, 255, 0.2);
    --glow: 0 0 20px rgba(255, 255, 255, 0.1);
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated Background */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(ellipse at top, #1a1a1a 0%, #0a0a0a 100%);
}

/* Navigation */
.navbar {
    background: rgba(10, 10, 10, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    padding: 0.5rem 0;
    background: rgba(10, 10, 10, 0.98) !important;
    box-shadow: var(--shadow-md);
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--text-primary) !important;
    transition: color 0.3s ease;
}

.navbar-brand:hover {
    color: var(--accent-secondary) !important;
}

.nav-link {
    font-weight: 500;
    color: var(--text-secondary) !important;
    margin: 0 0.5rem;
    padding: 0.75rem 1.25rem !important;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: var(--text-primary) !important;
    background: rgba(255, 255, 255, 0.1);
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
}

.hero-content {
    z-index: 2;
    position: relative;
}

.avatar {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--border-light);
    margin-bottom: 2rem;
    transition: all 0.4s ease;
    box-shadow: var(--shadow-xl);
}

.avatar:hover {
    transform: scale(1.05);
    border-color: var(--accent-secondary);
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.hero-description {
    font-size: 1.3rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.btn-primary-custom {
    background: var(--text-primary);
    border: 2px solid var(--text-primary);
    padding: 18px 40px;
    border-radius: 50px;
    font-weight: 600;
    color: var(--bg-primary);
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

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

.btn-primary-custom:hover {
    color: var(--bg-primary);
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
}

.btn-primary-custom:hover::before {
    left: 0;
}

/* Sections */
section {
    padding: 80px 0;
}

.section-title {
    font-size: 3rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-primary);
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background: var(--text-primary);
    margin: 1rem auto;
    border-radius: 2px;
}

/* Section Animation */
.section-animate {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.section-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Cards */
.modern-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
}

.modern-card:hover {
    transform: translateY(-5px);
    border-color: var(--border-light);
    box-shadow: var(--shadow-md);
    background: var(--card-hover);
}

/* About Section */
#about {
    background: var(--bg-secondary);
}

.about-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
}

.about-text strong {
    color: var(--text-primary);
    font-weight: 700;
}

/* Skills Section */
.skill-card {
    text-align: center;
    padding: 1.5rem;
}

.skill-card i {
    font-size: 3rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.skill-card:hover i {
    transform: scale(1.1);
    color: var(--accent-secondary);
}

.skill-card h4 {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1.2rem;
}

/* Projects Section */
#projects {
    background: var(--bg-secondary);
    padding: 80px 0;
}

.carousel {
    position: relative;
    padding: 0 10vw;
    max-width: 100%;
    margin: 0 auto;
}

.carousel-control-prev,
.carousel-control-next {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    transition: all 0.3s ease;
    z-index: 10;/
}

.carousel-control-prev {
    left: 5px;
}

.carousel-control-next {
    right: 5px; 
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-size: 18px 18px;
}

.project-img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 12px;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    cursor: pointer;
}

.project-img:hover {
    transform: scale(0.98);
    border-color: var(--border-light);
}

.project-content {
    padding: 2rem;
    max-height: 300px;
    overflow-y: auto;
}

.project-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.project-description {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}

/* Carousel */
.carousel-indicators {
    position: relative;
    bottom: 0;
    margin-top: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.carousel-indicators [data-bs-target] {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--text-muted);
    opacity: 0.5;
    transition: all 0.3s ease;
    margin: 0;
    border: none;
}

.carousel-indicators .active {
    background-color: var(--text-primary);
    opacity: 1;
    transform: scale(1.2);
}

/* Fullscreen Modal */
.modal {
    --bs-modal-bg: rgba(0, 0, 0, 0.85);
    z-index: 1060 !important;
}

.modal-backdrop {
    z-index: 1050 !important;
    background-color: rgba(0, 0, 0, 0.2);
}

.modal-dialog {
    max-width: 90vw;
    max-height: 90vh;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: transparent;
    border: none;
    box-shadow: none;
}

.modal-body {
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    max-height: 100vh;
    overflow: hidden;
}

.image-container {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.fullscreen-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: var(--shadow-md);
    cursor: default;
}

/* Contact Section */
#contact {
    background: var(--bg-primary);
}

.contact-card {
    text-align: center;
    padding: 2rem;
}

.contact-card i {
    font-size: 2.5rem;
    color: var(--text-primary);
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.contact-card h5 {
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-size: 1.2rem;
}

.contact-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.contact-card-link:hover .contact-card {
    transform: translateY(-5px);
    border-color: var(--border-light);
    box-shadow: var(--shadow-xl);
    background: var(--card-hover);
}

.contact-card-link:hover .contact-card i,
.contact-card-link:hover .contact-card h5,
.contact-card-link:hover .contact-card p {
    color: var(--text-primary);
}

.contact-text {
    color: var(--text-secondary);
    font-size: 1rem;
    word-break: break-all;
    user-select: text;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
}

/* Footer */
footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1.5rem;
}

.footer-section h5 {
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-size: 1.2rem;
}

.footer-section p,
.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--text-primary);
}

.footer-contact-link {
    color: var(--text-secondary);
    user-select: text;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
}

.footer-contact-link:hover {
    color: var(--text-primary);
}

.social-icon {
    color: var(--text-secondary);
    font-size: 2rem;
    margin: 0 5px;
    transition: all 0.3s ease;
    display: inline-block;
}

.social-icon:hover {
    color: var(--text-primary);
    transform: translateY(-3px);
}

/* Scroll Progress */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--text-primary);
    z-index: 9999;
    transition: width 0.1s ease;
}

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

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

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

::-webkit-scrollbar-thumb:hover {
    background: var(--text-primary);
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    .hero-subtitle {
        font-size: 1.5rem;
    }
    .hero-description {
        font-size: 1.1rem;
    }
    .section-title {
        font-size: 2rem;
    }
    section {
        padding: 60px 0;
    }
    .modern-card {
        padding: 1.5rem;
    }
    .carousel {
        padding: 0 5vw;
    }
    .carousel-control-prev,
    .carousel-control-next {
        width: 35px;
        height: 35px;
        background: rgba(255, 255, 255, 0.15);
    }
    .carousel-control-prev {
        left: 5px;
    }
    .carousel-control-next {
        right: 5px;
    }
    .carousel-control-prev-icon,
    .carousel-control-next-icon {
        background-size: 16px 16px;
    }
    .project-img {
        height: 200px;
    }
    .project-content {
        max-height: 250px;
        padding: 1.5rem;
    }
    .avatar {
        width: 120px;
        height: 120px;
    }
    .contact-text {
        font-size: 0.9rem;
        word-break: break-word;
    }
    .contact-card {
        padding: 1.5rem;
    }
    .contact-card i {
        font-size: 2rem;
    }
    .contact-card h5 {
        font-size: 1.1rem;
    }
    .modal-dialog {
        max-width: 95vw;
        max-height: 95vh;
        margin: 0 auto;
    }
    .modal-body {
        min-height: 100vh;
        max-height: 95vh;
    }
    .fullscreen-img {
        max-height: 85vh;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }
    .section-title {
        font-size: 1.8rem;
    }
    .carousel {
        padding: 0 3vw;
    }
    .carousel-control-prev,
    .carousel-control-next {
        width: 30px;
        height: 30px;
        background: rgba(255, 255, 255, 0.2);
    }
    .carousel-control-prev {
        left: 2px;
    }
    .carousel-control-next {
        right: 2px;
    }
    .carousel-control-prev-icon,
    .carousel-control-next-icon {
        background-size: 14px 14px;
    }
    .modal-dialog {
        max-width: 98vw;
        margin: 0 auto;
    }
    .fullscreen-img {
        max-height: 80vh;
    }
    .contact-text {
        font-size: 0.85rem;
    }
    .social-icon {
        font-size: 1.8rem;
        margin: 0 8px;
    }
}