/* ===== Base Styles ===== */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #10b981;
    --dark: #1e293b;
    --darker: #0f172a;
    --light: #f8fafc;
    --gray: #94a3b8;
    --danger: #ef4444;
    --success: #10b981;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background-color: var(--light);
    overflow-x: hidden;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    font-size: 2.5rem;
    color: var(--darker);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--primary);
    border-radius: 2px;
}

.bg-light {
    background-color: #f1f5f9;
}

/* ===== Header & Navigation ===== */
.main-nav {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    padding: 20px 0;
    transition: all 0.3s ease;
}

.main-nav.scrolled {
    padding: 15px 0;
    background-color: rgba(255,255,255,0.98);
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary);
}

.nav-cta {
    background-color: var(--primary);
    color: white !important;
    padding: 8px 20px;
    border-radius: 5px;
    transition: all 0.3s;
}

.nav-cta:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===== Hero Section ===== */
.hero {
    background: linear-gradient(135deg, var(--darker), var(--dark));
    color: white;
    text-align: center;
    padding: 180px 0 100px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('images/background.jpg') no-repeat center center/cover;
    opacity: 0.2;
    z-index: 0;
}

.hero .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 15px;
    animation: fadeInDown 1s ease;
}

.hero h2 {
    font-size: 1.8rem;
    font-weight: 400;
    margin-bottom: 25px;
    animation: fadeInDown 1s ease 0.3s both;
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 40px;
    animation: fadeIn 1s ease 0.6s both;
}

.cta-button {
    display: inline-block;
    background-color: var(--primary);
    color: white;
    padding: 12px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    animation: fadeInUp 1s ease 0.9s both;
}

.cta-button:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

/* ===== About Section ===== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.profile-img {
    width: 100%;
    max-width: 400px;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.profile-img:hover {
    transform: scale(1.02);
}

.about-content p {
    margin-bottom: 30px;
    font-size: 1.1rem;
    line-height: 1.8;
}

.experience-boxes {
    display: flex;
    gap: 20px;
    margin-top: 30px;
}

.exp-box {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    text-align: center;
    flex: 1;
    transition: transform 0.3s;
}

.exp-box:hover {
    transform: translateY(-5px);
}

.exp-box .number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 5px;
}

.exp-box .label {
    font-size: 1rem;
    color: var(--gray);
}

/* ===== Skills Section ===== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.skill-category {
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.skill-category:hover {
    transform: translateY(-5px);
}

.skill-category h3 {
    color: var(--primary);
    margin-bottom: 20px;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
}

.skill-category h3 i {
    margin-right: 10px;
    font-size: 1.2rem;
}

.skill-category ul {
    list-style: none;
}

.skill-category li {
    margin-bottom: 10px;
    position: relative;
    padding-left: 25px;
}

.skill-category li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: var(--primary);
}

/* ===== Experience Section ===== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 30px;
    height: 100%;
    width: 2px;
    background: var(--primary);
}

.timeline-item {
    position: relative;
    padding-left: 80px;
    margin-bottom: 50px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-item h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--darker);
}

.timeline-item .date {
    display: inline-block;
    background-color: var(--primary);
    color: white;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.timeline-item ul {
    list-style-position: inside;
    padding-left: 5px;
}

.timeline-item li {
    margin-bottom: 8px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 22px;
    top: 5px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: white;
    border: 4px solid var(--primary);
    z-index: 1;
}

/* ===== Portfolio Section ===== */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.portfolio-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    height: 250px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-item .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(37, 99, 235, 0.9);
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s;
    padding: 20px;
    text-align: center;
}

.portfolio-item:hover .overlay {
    opacity: 1;
}

.portfolio-item .overlay h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

/* ===== Contact Section ===== */
.contact-form-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-form {
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.submit-btn {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.submit-btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.form-status {
    margin-top: 20px;
    padding: 10px;
    border-radius: 5px;
    display: none;
}

.form-status.success {
    background-color: rgba(16, 185, 129, 0.1);
    color: var(--success);
    display: block;
}

.form-status.error {
    background-color: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    display: block;
}

.contact-info {
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.contact-info h3 {
    color: var(--primary);
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.contact-info p {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.contact-info i {
    margin-right: 10px;
    color: var(--primary);
    width: 20px;
    text-align: center;
}

/* ===== Footer ===== */
.main-footer {
    background-color: var(--darker);
    color: white;
    padding: 60px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-about h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: white;
}

.footer-about p {
    opacity: 0.8;
    line-height: 1.7;
}

.footer-links h3,
.footer-contact h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: white;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.footer-contact p {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    opacity: 0.8;
}

.footer-contact i {
    margin-right: 10px;
    color: var(--primary);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 20px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.footer-bottom p {
    opacity: 0.7;
    font-size: 0.9rem;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.social-links a:hover {
    background-color: var(--primary);
    transform: translateY(-3px);
}

/* ===== Mobile Menu ===== */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    max-width: 300px;
    height: 100vh;
    background-color: white;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    z-index: 1001;
    padding: 80px 30px;
    transition: left 0.3s ease;
}

.mobile-menu.active {
    left: 0;
}

.mobile-menu ul {
    list-style: none;
}

.mobile-menu li {
    margin-bottom: 20px;
}

.mobile-menu a {
    text-decoration: none;
    color: var(--dark);
    font-size: 1.1rem;
    transition: color 0.3s;
}

.mobile-menu a:hover {
    color: var(--primary);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Responsive Styles ===== */
@media (max-width: 992px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .profile-img {
        max-width: 100%;
    }
    
    .contact-form-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero h2 {
        font-size: 1.5rem;
    }
    
    section {
        padding: 60px 0;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .experience-boxes {
        flex-direction: column;
    }
    
    .hero {
        padding: 150px 0 80px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
}