/* --- CSS Variables --- */
:root {
    --primary-color: #5e72e4;
    --secondary-color: #8965e0;
    --accent-color: #f5365c;
    --text-color: #e9ecef;
    --text-dark: #2d3748;
    --card-bg-color: rgba(255, 255, 255, 0.1);
    --card-border-color: rgba(255, 255, 255, 0.25);
    --shadow-color: rgba(0, 0, 0, 0.1);
    --gradient-start: #5e72e4;
    --gradient-end: #f5365c;
}

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

body {
    font-family: 'Rubik', sans-serif;
    color: var(--text-color);
    background-color: #172b4d;
    overflow-x: hidden;
    line-height: 1.6;
}

/* --- Background Gradient --- */
.background-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(45deg, var(--gradient-start), var(--secondary-color), var(--accent-color), #ffd600);
    background-size: 400% 400%;
    animation: gradient-animation 15s ease infinite;
}

@keyframes gradient-animation {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* --- Navigation --- */
.main-nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(23, 43, 77, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.nav-logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-logo a:hover {
    color: var(--primary-color);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
}

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

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-color);
    margin: 3px 0;
    transition: 0.3s;
}

/* --- Header --- */
.main-header {
    text-align: center;
    padding: 8rem 2rem 4rem;
    margin-top: 80px;
}

.main-header h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px var(--shadow-color);
}

.main-header p {
    font-size: 1.3rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.header-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary, .btn-secondary {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 4px 15px rgba(94, 114, 228, 0.4);
}

.btn-primary:hover {
    background: #4a5cc3;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(94, 114, 228, 0.6);
}

.btn-secondary {
    background: transparent;
    color: var(--text-color);
    border-color: var(--text-color);
}

.btn-secondary:hover {
    background: var(--text-color);
    color: var(--text-dark);
    transform: translateY(-2px);
}

/* --- Content Container --- */
.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* --- Section Titles --- */
.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    text-shadow: 2px 2px 4px var(--shadow-color);
}

/* --- Hero Section --- */
.hero-section {
    text-align: center;
    margin-bottom: 4rem;
}

.hero-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.hero-content p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
    opacity: 0.9;
}

/* --- Featured Projects --- */
.featured-projects {
    margin-bottom: 4rem;
}

/* Featured Project Section Styles */
.featured-project-section {
    margin-bottom: 4rem;
}

.featured-project-card {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 3rem;
    background: var(--card-bg-color);
    border-radius: 20px;
    border: 1px solid var(--card-border-color);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 8px 32px 0 var(--shadow-color);
    padding: 3rem;
    margin-bottom: 3rem;
}

.project-image {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 6rem;
    color: var(--primary-color);
}

.project-details h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.project-description {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.project-features {
    margin-bottom: 2rem;
}

.project-features h4 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.project-features ul {
    list-style: none;
    padding-left: 0;
}

.project-features li {
    padding: 0.5rem 0;
    position: relative;
    padding-left: 1.5rem;
}

.project-features li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.project-tech {
    margin-bottom: 2.5rem;
}

.project-tech h4 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.tech-tags {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.tech-tag {
    background: rgba(94, 114, 228, 0.2);
    color: var(--text-color);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-size: 0.9rem;
    border: 1px solid rgba(94, 114, 228, 0.3);
    transition: all 0.3s ease;
}

.tech-tag:hover {
    background: rgba(94, 114, 228, 0.3);
    border-color: rgba(94, 114, 228, 0.5);
}

.project-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    justify-items: center;
}

.project-card {
    width: 100%;
    max-width: 400px;
    background: var(--card-bg-color);
    border-radius: 20px;
    border: 1px solid var(--card-border-color);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 8px 32px 0 var(--shadow-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.project-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 16px 40px 0 rgba(0, 0, 0, 0.2);
}

.project-card.featured {
    border-color: var(--primary-color);
}

.project-card.coming-soon {
    border-color: var(--accent-color);
}

.project-content {
    text-align: center;
}

.project-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.project-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.project-description {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    min-height: 80px;
}

.project-tags {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
}

.tag {
    background: rgba(94, 114, 228, 0.2);
    color: var(--text-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    border: 1px solid rgba(94, 114, 228, 0.3);
}

.project-button {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(94, 114, 228, 0.4);
}

.project-button:hover {
    background-color: #4a5cc3;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(94, 114, 228, 0.6);
}

.coming-soon-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--accent-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* --- Skills Section --- */
.skills-section {
    margin-bottom: 4rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skill-item {
    background: var(--card-bg-color);
    border-radius: 15px;
    border: 1px solid var(--card-border-color);
    backdrop-filter: blur(12px);
    padding: 2rem;
    text-align: center;
    transition: transform 0.3s ease;
}

.skill-item:hover {
    transform: translateY(-5px);
}

.skill-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.skill-item h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.skill-item p {
    opacity: 0.9;
    font-size: 0.9rem;
}

/* --- About Preview --- */
.about-preview {
    background: var(--card-bg-color);
    border: 1px solid var(--card-border-color);
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.about-preview:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px var(--shadow-color);
}

.about-preview h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.about-preview p {
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

/* --- Page Header --- */
.page-header {
    text-align: center;
    padding: 8rem 2rem 4rem;
    background: linear-gradient(135deg, rgba(94, 114, 228, 0.1), rgba(137, 101, 224, 0.1));
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--card-border-color);
}

.page-header h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* --- Contact Form Section --- */
.contact-form-section {
    margin: 3rem 0;
}

.form-container {
    max-width: 800px;
    margin: 0 auto;
    background: var(--card-bg-color);
    border: 1px solid var(--card-border-color);
    border-radius: 20px;
    padding: 3rem;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 1rem;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 0 3px rgba(94, 114, 228, 0.2);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-group select {
    cursor: pointer;
}

.form-group select option {
    background: #172b4d;
    color: var(--text-color);
}

.checkbox-group {
    flex-direction: row;
    align-items: flex-start;
    gap: 0.75rem;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 0.9rem;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin: 0;
    cursor: pointer;
}

.submit-btn {
    width: 100%;
    padding: 1.2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(94, 114, 228, 0.3);
}

/* --- Services Section --- */
.services-section {
    margin: 4rem 0;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.service-card {
    background: var(--card-bg-color);
    border: 1px solid var(--card-border-color);
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.service-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.service-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.service-card p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

/* --- FAQ Section --- */
.faq-section {
    margin: 4rem 0;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.faq-item {
    background: var(--card-bg-color);
    border: 1px solid var(--card-border-color);
    border-radius: 15px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.faq-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.faq-item h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.faq-item p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

/* --- CTA Section --- */
.cta-section {
    margin: 4rem 0;
    text-align: center;
    background: linear-gradient(135deg, rgba(94, 114, 228, 0.1), rgba(137, 101, 224, 0.1));
    border-radius: 20px;
    padding: 3rem 2rem;
    backdrop-filter: blur(10px);
    border: 1px solid var(--card-border-color);
}

.cta-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.cta-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* --- Success Page --- */
.success-section {
    margin: 3rem 0;
    text-align: center;
}

.success-container {
    max-width: 600px;
    margin: 0 auto;
    background: var(--card-bg-color);
    border: 1px solid var(--card-border-color);
    border-radius: 20px;
    padding: 3rem 2rem;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.success-icon {
    margin-bottom: 2rem;
}

.success-icon i {
    font-size: 4rem;
    color: #10b981;
    animation: successPulse 2s ease-in-out infinite;
}

@keyframes successPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.success-container h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--text-color);
    background: linear-gradient(45deg, #10b981, var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.success-container p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

.success-details {
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.detail-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-item i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.detail-item span {
    color: var(--text-color);
    font-weight: 500;
}

.success-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.success-actions .btn-primary,
.success-actions .btn-secondary {
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.success-actions .btn-primary:hover,
.success-actions .btn-secondary:hover {
    transform: translateY(-2px);
}

.success-note {
    margin-top: 2rem;
    padding: 1.5rem;
    background: rgba(94, 114, 228, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(94, 114, 228, 0.2);
}

.success-note p {
    margin: 0;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.success-note i {
    color: var(--primary-color);
}

/* --- Footer --- */
.main-footer {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    padding: 3rem 2rem 1rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.footer-section p,
.footer-section li {
    opacity: 0.9;
    margin-bottom: 0.5rem;
}

.footer-section ul {
    list-style: none;
}

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

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

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: rgba(94, 114, 228, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

.social-links i {
    font-size: 1.2rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.7;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    .main-header h1 {
        font-size: 2.5rem;
    }
    
    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .header-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .featured-project-card {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 2rem;
    }
    
    .project-image {
        font-size: 4rem;
    }
    
    .project-details h3 {
        font-size: 2rem;
    }
    
    .project-links {
        flex-direction: column;
        align-items: stretch;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .faq-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .form-container {
        padding: 2rem;
        margin: 0 1rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .success-container {
        padding: 2rem 1.5rem;
        margin: 0 1rem;
    }
    
    .success-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .main-header {
        padding: 6rem 1rem 3rem;
    }
    
    .page-header {
        padding: 6rem 1rem 3rem;
    }
    
    .content-container {
        padding: 1rem;
    }
    
    .project-card {
        padding: 1.5rem;
    }
    
    .form-container {
        padding: 1.5rem;
        margin: 0 0.5rem;
    }
    
    .cta-section {
        padding: 2rem 1rem;
    }
    
    .success-container {
        padding: 1.5rem 1rem;
        margin: 0 0.5rem;
    }
    
    .success-container h1 {
        font-size: 2rem;
    }
    
    .success-actions .btn-primary,
    .success-actions .btn-secondary {
        padding: 0.875rem 1.5rem;
        font-size: 0.95rem;
    }
}

/* --- Animations --- */
.main-header, .content-container, .main-footer {
    animation: fadeInAnimation 0.8s ease-out forwards;
    opacity: 0;
}

.main-header { animation-delay: 0.2s; }
.content-container { animation-delay: 0.4s; }
.main-footer { animation-delay: 0.6s; }

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