/**
 * Developer Portfolio - Main Stylesheet
 * Modern, responsive design with animations
 */

:root {
    --primary-color: #4361ee;
    --secondary-color: #3a0ca3;
    --accent-color: #f72585;
    --success-color: #4cc9f0;
    --dark-color: #1a1a2e;
    --light-color: #f8f9fa;
    --gray-color: #6c757d;
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

.highlight {
    color: var(--accent-color);
}

/* Navigation */
.navbar {
    background-color: rgba(26, 26, 46, 0.95);
    padding: 1rem 0;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

.navbar-brand {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--light-color) !important;
}

.navbar-brand i {
    color: var(--success-color);
}

.nav-link {
    color: var(--light-color) !important;
    font-weight: 500;
    margin: 0 0.5rem;
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--success-color) !important;
}

.nav-link.active {
    color: var(--success-color) !important;
}

.btn-admin {
    background-color: var(--accent-color);
    color: white !important;
    border-radius: 30px;
    padding: 0.5rem 1.5rem !important;
    transition: var(--transition);
}

.btn-admin:hover {
    background-color: #d1146a;
    transform: translateY(-2px);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--dark-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 10rem 0 6rem;
    margin-top: 76px;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-stats {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
}

.stat-item h3 {
    font-size: 2.5rem;
    color: var(--success-color);
    margin-bottom: 0.5rem;
}

.stat-item p {
    font-size: 1rem;
    opacity: 0.8;
}

.hero-buttons .btn {
    padding: 0.8rem 2rem;
    border-radius: 30px;
    font-weight: 600;
}

.hero-image img {
    max-width: 100%;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* Section Styling */
.section-header {
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--gray-color);
    max-width: 600px;
    margin: 0 auto;
}

/* Project Cards */
.project-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    height: 100%;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.project-image {
    position: relative;
    overflow: hidden;
    height: 200px;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-body {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
    color: var(--dark-color);
}

.project-description {
    color: var(--gray-color);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.project-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    font-weight: 500;
}

.project-tech {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tech-badge {
    background-color: #e9ecef;
    color: var(--dark-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Review Cards */
.review-card {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
    height: 100%;
    transition: var(--transition);
}

.review-card:hover {
    transform: translateY(-5px);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.reviewer-name {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.review-date {
    font-size: 0.85rem;
    color: var(--gray-color);
}

.review-comment {
    font-style: italic;
    color: #555;
}

.star-rating {
    color: #ffc107;
    font-size: 0.9rem;
}

/* Form Styling */
.card {
    border: none;
    border-radius: 15px;
    overflow: hidden;
}

.card-header {
    border-bottom: none;
    padding: 1.5rem;
}

.form-control, .form-select {
    padding: 0.8rem 1rem;
    border-radius: 10px;
    border: 1px solid #ddd;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(67, 97, 238, 0.25);
}

.btn {
    padding: 0.8rem 1.5rem;
    border-radius: 10px;
    font-weight: 600;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    transform: translateY(-2px);
}

.btn-success {
    background-color: var(--success-color);
    border-color: var(--success-color);
}

.btn-success:hover {
    background-color: #3aa8d0;
    border-color: #3aa8d0;
}

/* Contact Section */
.contact-section {
    background-color: var(--dark-color);
}

.contact-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 2rem;
    border-radius: 15px;
    transition: var(--transition);
}

.contact-card:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.contact-icon {
    color: var(--success-color);
}

/* Footer */
.footer {
    background-color: #0d0d1a;
    color: white;
}

.footer-brand {
    font-size: 1.8rem;
    margin-bottom: 1rem;
}

.footer-text {
    opacity: 0.8;
    margin-bottom: 1.5rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
}

.social-link:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

.footer-title {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    color: white;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--success-color);
    padding-left: 5px;
}

.newsletter-form .input-group {
    border-radius: 30px;
    overflow: hidden;
}

.footer-divider {
    border-color: rgba(255, 255, 255, 0.1);
    margin: 2rem 0;
}

.copyright {
    opacity: 0.7;
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

.whatsapp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: white;
    border-radius: 50%;
    font-size: 2rem;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    transition: var(--transition);
    text-decoration: none;
}

.whatsapp-btn:hover {
    background-color: #1da851;
    color: white;
    transform: scale(1.1);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

/* Filter Buttons */
.filter-buttons {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.filter-btn.active {
    background-color: var(--primary-color);
    color: white;
}

/* Responsive Design */
@media (max-width: 992px) {
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-section {
        padding: 8rem 0 4rem;
    }
    
    .filter-buttons {
        justify-content: flex-start;
        margin-top: 1rem;
    }
    
    .navbar-brand {
        font-size: 1.5rem;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .btn {
        padding: 0.6rem 1.2rem;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 1s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Additional Improvements */

/* Navbar scroll effect */
.navbar-scrolled {
    background-color: rgba(26, 26, 46, 0.98) !important;
    padding: 0.7rem 0 !important;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2) !important;
}

/* Improved project cards */
.project-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15) !important;
}

.project-image {
    overflow: hidden;
    border-radius: 10px 10px 0 0;
    height: 200px;
}

.project-image img {
    transition: transform 0.5s ease;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-card:hover .project-image img {
    transform: scale(1.05);
}

.project-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-tech {
    margin-top: auto;
    padding-top: 10px;
}

/* Better form styling */
.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(67, 97, 238, 0.25);
}

/* Improved buttons */
.btn {
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    transform: translateY(-2px);
}

/* Hero section improvements */
.hero-stats {
    display: flex;
    gap: 2rem;
    margin: 2rem 0;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    min-width: 120px;
}

.stat-item h3 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: var(--success-color);
}

/* Review cards enhancement */
.review-card {
    transition: transform 0.3s ease;
    height: 100%;
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1) !important;
}

/* Contact cards */
.contact-card {
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    transition: transform 0.3s ease;
}

.contact-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.1);
}

.contact-icon {
    color: var(--success-color);
}

/* Footer improvements */
.footer {
    background: var(--dark-color);
    color: white;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--success-color);
    padding-left: 5px;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .hero-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stat-item {
        min-width: auto;
        width: 100%;
    }
    
    .filter-buttons {
        flex-wrap: wrap;
    }
    
    .project-image {
        height: 180px;
    }
}

/* Print styles */
@media print {
    .navbar, .whatsapp-float, .back-to-top, .btn-admin {
        display: none !important;
    }
}