:root {
    --primary-color: #3498db;
    --secondary-color: #2c3e50;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --animation-speed: 0.5s;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: var(--light-color);
    color: var(--dark-color);
    overflow-x: hidden;
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--light-color);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.preloader.fade-out {
    opacity: 0;
}

.loader {
    width: 50px;
    height: 50px;
    border: 5px solid var(--primary-color);
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

/* Header */
header {
    background-color: var(--secondary-color);
    color: white;
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all var(--animation-speed) ease;
}

header.scrolled {
    padding: 0.5rem 0;
    background-color: rgba(44, 62, 80, 0.95);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.logo span {
    color: var(--primary-color);
}

.logo i {
    margin-right: 10px;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 2rem;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: color var(--animation-speed) ease;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    bottom: -5px;
    left: 0;
    transition: width var(--animation-speed) ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.hamburger div {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 5px;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('https://images.unsplash.com/photo-1605106702734-205df224ecce?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1470&q=80') no-repeat center center/cover;
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 0 20px;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    animation: fadeInDown 1s ease;
}

.hero h1 span {
    color: var(--primary-color);
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 1s ease 0.3s forwards;
    opacity: 0;
}

.hero-btns {
    display: flex;
    justify-content: center;
    gap: 1rem;
    animation: fadeInUp 1s ease 0.6s forwards;
    opacity: 0;
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all var(--animation-speed) ease;
    cursor: pointer;
}

.btn:hover {
    background: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
}

.social-icons {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 1rem;
    z-index: 2;
    animation: fadeIn 1s ease 0.9s forwards;
    opacity: 0;
}

.social-icons a {
    color: white;
    font-size: 1.5rem;
    transition: all var(--animation-speed) ease;
}

.social-icons a:hover {
    color: var(--primary-color);
    transform: translateY(-5px);
}

/* About Section */
.section {
    padding: 5rem 0;
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

.section-title h2 {
    font-size: 2.5rem;
    color: var(--secondary-color);
    display: inline-block;
    position: relative;
}

.section-title h2::after {
    content: '';
    position: absolute;
    width: 70%;
    height: 3px;
    background: var(--primary-color);
    bottom: -10px;
    left: 15%;
}

.about-content {
    display: flex;
    align-items: center;
    gap: 3rem;
}

.about-img {
    flex: 1;
    position: relative;
    animation: fadeInLeft 1s ease;
}

.about-img img {
    width: 100%;
    max-width: 400px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all var(--animation-speed) ease;
}

.about-img:hover img {
    transform: scale(1.03);
}

.about-img::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border: 3px solid var(--primary-color);
    border-radius: 10px;
    top: 20px;
    left: 20px;
    z-index: -1;
    transition: all var(--animation-speed) ease;
}

.about-img:hover::before {
    top: 15px;
    left: 15px;
}

.about-text {
    flex: 1;
    animation: fadeInRight 1s ease;
}

.about-text h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

.about-text h3 span {
    color: var(--primary-color);
}

.about-text p {
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.skills {
    margin-top: 2rem;
}

.skills h4 {
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.skill-card {
    margin-bottom: 1rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    padding: 1rem;
    border-radius: 5px;
    background: white;
}

.skill-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Interests Section */
.interests {
    background-color: var(--secondary-color);
    color: white;
}

.interests .section-title h2 {
    color: white;
}

.interests-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.interest-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    transition: all var(--animation-speed) ease;
    transform: translateY(50px);
    opacity: 0;
}

.interest-card.animate {
    transform: translateY(0);
    opacity: 1;
}

.interest-card:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-10px);
}

.interest-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.interest-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.interest-card p {
    line-height: 1.6;
}

/* Projects Section */
.projects-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all var(--animation-speed) ease;
    transform: scale(0.9);
    opacity: 0;
}

.project-card.animate {
    transform: scale(1);
    opacity: 1;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.project-img {
    height: 200px;
    overflow: hidden;
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.project-card:hover .project-img img {
    transform: scale(1.1);
}

.project-info {
    padding: 1.5rem;
}

.project-info h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}

.project-info p {
    margin-bottom: 1rem;
    color: #666;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-tag {
    background: var(--light-color);
    color: var(--secondary-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-links a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: color var(--animation-speed) ease;
}

.project-links a:hover {
    color: var(--primary-color);
}

/* Contact Section */
.contact {
    background-color: var(--light-color);
}

.contact-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.contact-info {
    animation: fadeInLeft 1s ease;
}

.contact-info h3 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
}

.contact-info p {
    margin-bottom: 2rem;
    line-height: 1.6;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
    width: 50px;
    height: 50px;
    background: rgba(52, 152, 219, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.contact-item-text h4 {
    font-size: 1.2rem;
    margin-bottom: 0.3rem;
    color: var(--secondary-color);
}

.contact-item-text p, .contact-item-text a {
    color: #666;
    text-decoration: none;
    transition: color var(--animation-speed) ease;
}

.contact-item-text a:hover {
    color: var(--primary-color);
}

.contact-form {
    animation: fadeInRight 1s ease;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--secondary-color);
}

.form-control {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    transition: all var(--animation-speed) ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

textarea.form-control {
    min-height: 150px;
    resize: vertical;
}

.submit-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--animation-speed) ease;
}

.submit-btn:hover {
    background: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.submit-btn:disabled {
    background: #95a5a6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Video Ad Styling */
.video-ad-container {
    position: relative;
    max-width: 100%;
    margin: 20px 0;
}

.video-ad {
    max-width: 100%;
    height: auto;
    display: block;
}

.close-button {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.close-button:hover {
    background: rgba(0, 0, 0, 0.9);
}

.mute-button {
    position: absolute;
    top: 5px;
    right: 35px; /* Position to the left of the close button */
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.mute-button:hover {
    background: rgba(0, 0, 0, 0.9);
}

/* Footer */
footer {
    background-color: var(--secondary-color);
    color: white;
    padding: 2rem 0;
    text-align: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

footer p a {
    text-decoration: underline;
    color: #3498db;
    font-weight: 600;
    transition: color var(--animation-speed) ease;
}

.copyright {
    margin-top: 1.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    text-decoration: none;
    opacity: 0;
    visibility: hidden;
    transition: all var(--animation-speed) ease;
    z-index: 999;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: #2980b9;
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive Styles */
@media (max-width: 992px) {
    .about-content {
        flex-direction: column;
    }

    .about-img, .about-text {
        flex: none;
        width: 100%;
        max-width: 600px;
    }

    .about-img {
        margin-bottom: 2rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--secondary-color);
        flex-direction: column;
        align-items: center;
        padding: 2rem 0;
        clip-path: circle(0px at 90% -10%);
        transition: all 0.5s ease-out;
    }

    .nav-links.active {
        clip-path: circle(1000px at 90% -10%);
    }

    .nav-links li {
        margin: 1rem 0;
    }

    .hamburger {
        display: block;
    }

    .hamburger.active div:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }

    .hamburger.active div:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active div:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .hero-btns {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 80%;
        text-align: center;
    }

    .section-title h2 {
        font-size: 2rem;
    }

    .nav-links .btn.btn-outline {
        display: block;
        margin: 1rem 0 0 0;
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 576px) {
    .hero h1 {
        font-size: 2rem;
    }

    .section {
        padding: 3rem 0;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }
}

/* Admin Login Button Custom Style */
.nav-links .btn.btn-outline {
    padding: 0.5rem 1.2rem;
    border: 2px solid var(--primary-color);
    border-radius: 25px;
    background: transparent;
    color: var(--primary-color);
    font-weight: 600;
    transition: background 0.3s, color 0.3s;
    margin-left: 1rem;
}

.nav-links .btn.btn-outline:hover {
    background: var(--primary-color);
    color: #fff;
}

/* Admin Login Modal Styles */
#adminModal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}
#adminModal .modal-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(44, 62, 80, 0.7);
    z-index: 1;
}
#adminModal .modal-content {
    position: relative;
    z-index: 2;
    background: #fff;
    border-radius: 12px;
    padding: 2rem 1.5rem;
    box-shadow: 0 8px 32px rgba(44,62,80,0.2);
    min-width: 260px;
    max-width: 340px;
    width: 100%;
    animation: fadeInDown 0.4s;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}
#adminModal h2 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    text-align: center;
}
#adminModal .form-group {
    margin-bottom: 1.2rem;
}
#adminModal label {
    display: block;
    margin-bottom: 0.4rem;
    color: var(--secondary-color);
    font-weight: 500;
}
#adminModal input[type="text"],
#adminModal input[type="password"] {
    width: 100%;
    padding: 0.6rem 1rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1rem;
    outline: none;
    transition: border 0.2s;
}
#adminModal input[type="text"]:focus,
#adminModal input[type="password"]:focus {
    border: 1.5px solid var(--primary-color);
}
#adminModal .submit-btn {
    width: 100%;
    margin-top: 0.5rem;
}
#adminModal .close-modal {
    position: absolute;
    top: 1rem;
    right: 1.2rem;
    font-size: 1.5rem;
    color: var(--accent-color);
    cursor: pointer;
    font-weight: bold;
    transition: color 0.2s;
}
#adminModal .close-modal:hover {
    color: var(--primary-color);
}
@media (max-width: 480px) {
    #adminModal .modal-content {
        padding: 1rem 0.5rem;
        min-width: 90vw;
        max-width: 95vw;
    }
}