/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

*,
*::before,
*::after {
    max-width: 100%;
}

html,
body {
    max-width: 100vw;
    overflow-x: hidden;
}

:root {
    --bg-primary: #121212;
    --bg-secondary: #1a1a1a;
    --accent-blue: #4A90E2;
    --accent-emerald: #00FF88;
    --text-primary: #FFFFFF;
    --text-secondary: #B0B0B0;
    --text-muted: #707070;
    --border-color: #2a2a2a;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
}

body {
    font-family: 'Inter', 'Montserrat', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    max-width: 100%;
    width: 100%;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Improve touch scrolling on mobile */
    -webkit-overflow-scrolling: touch;
}

/* Custom Scrollbar Styles */
/* Webkit browsers (Chrome, Safari, Edge) */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-color);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--accent-blue), var(--accent-emerald));
    border-radius: 6px;
    border: 2px solid var(--bg-secondary);
    transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--accent-emerald), var(--accent-blue));
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.5);
}

/* Firefox */
html {
    scrollbar-width: thin;
    scrollbar-color: var(--accent-blue) var(--bg-secondary);
}

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-emerald));
    z-index: 9999;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.5);
}

.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Particle Canvas Background */
#particleCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    max-width: 100%;
    z-index: -1;
    opacity: 0.3;
    overflow: hidden;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100vw;
    background: rgba(18, 18, 18, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--accent-blue);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-emerald));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover {
    color: var(--accent-blue);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-blue);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 60px;
    position: relative;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-headline {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--text-primary), var(--accent-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subheadline {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    border: 2px solid transparent;
    cursor: pointer;
    /* Improve touch targets on mobile */
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-emerald));
    color: var(--text-primary);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(74, 144, 226, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--accent-blue);
    border-color: var(--accent-blue);
}

.btn-secondary:hover {
    background: var(--accent-blue);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.btn-cv {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-color: var(--border-color);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-cv:hover {
    background: var(--bg-primary);
    border-color: var(--accent-emerald);
    color: var(--accent-emerald);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 255, 136, 0.2);
}

.btn-cv svg {
    transition: transform 0.3s ease;
}

.btn-cv:hover svg {
    transform: translateY(-2px);
}

.hero-image {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.profile-image-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--accent-blue);
    box-shadow: 0 0 40px rgba(74, 144, 226, 0.5);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.profile-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.05);
}

/* 3D Avatar Styles */
.avatar-3d {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    border-radius: 50%;
    overflow: visible;
}

.avatar-face {
    position: relative;
    width: 60%;
    height: 60%;
    background: linear-gradient(135deg, #4A90E2, #00FF88);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2;
    animation: avatarPulse 3s ease-in-out infinite;
}

@keyframes avatarPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 20px rgba(74, 144, 226, 0.5);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 40px rgba(74, 144, 226, 0.8);
    }
}

.avatar-eyes {
    display: flex;
    gap: 20%;
    margin-bottom: 15%;
}

.eye {
    width: 20%;
    height: 20%;
    background: #121212;
    border-radius: 50%;
    position: relative;
    animation: blink 4s infinite;
}

@keyframes blink {
    0%, 90%, 100% {
        height: 20%;
    }
    95% {
        height: 2%;
    }
}

.avatar-mouth {
    width: 30%;
    height: 15%;
    border: 3px solid #121212;
    border-top: none;
    border-radius: 0 0 50% 50%;
}

.avatar-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(74, 144, 226, 0.3), transparent 70%);
    animation: glowRotate 4s linear infinite;
}

@keyframes glowRotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.stats-counter {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 12px;
    min-width: 120px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: scale(1.05);
    border-color: var(--accent-blue);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent-blue);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Section Styles */
section {
    padding: 80px 0;
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-emerald));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Tech Section */
.tech-section {
    background: var(--bg-secondary);
}

.tech-icons {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    margin-top: 3rem;
}

.tech-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 2rem;
    background: var(--bg-primary);
    border-radius: 16px;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    cursor: pointer;
    min-width: 150px;
}

.tech-icon:hover {
    transform: translateY(-10px) scale(1.05);
    border-color: var(--accent-blue);
    box-shadow: 0 10px 40px rgba(74, 144, 226, 0.3);
}

.tech-icon svg {
    width: 60px;
    height: 60px;
    transition: all 0.3s ease;
    color: var(--accent-blue);
}

.tech-icon .tech-logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
    transition: all 0.3s ease;
    /* Show logos in their original colors */
    filter: none;
    opacity: 0.9;
}

.tech-icon:hover .tech-logo {
    opacity: 1;
    transform: rotate(360deg) scale(1.15);
    filter: drop-shadow(0 0 10px rgba(74, 144, 226, 0.5));
}

.tech-icon:hover svg {
    color: var(--accent-emerald);
    transform: rotate(360deg);
}

.tech-icon span {
    font-weight: 600;
    color: var(--text-primary);
}

/* Projects Section */
.projects-scroll {
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    padding: 2rem 0;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-blue) var(--bg-secondary);
    /* Improve touch scrolling on mobile */
    -webkit-overflow-scrolling: touch;
    /* Hide scrollbar on mobile but keep functionality */
    scrollbar-width: thin;
}

@media (max-width: 768px) {
    .projects-scroll {
        scrollbar-width: none;
        -ms-overflow-style: none;
    }
    
    .projects-scroll::-webkit-scrollbar {
        display: none;
    }
}

.projects-scroll::-webkit-scrollbar {
    height: 8px;
}

.projects-scroll::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 4px;
}

.projects-scroll::-webkit-scrollbar-thumb {
    background: var(--accent-blue);
    border-radius: 4px;
}

.project-card {
    min-width: 350px;
    background: var(--bg-secondary);
    border-radius: 20px;
    overflow: hidden;
    border: 2px solid var(--border-color);
    transition: all 0.4s ease;
    scroll-snap-align: start;
    position: relative;
    cursor: pointer;
}

.project-card:hover {
    transform: translateY(-10px) rotateY(5deg);
    border-color: var(--accent-blue);
    box-shadow: 0 20px 60px rgba(74, 144, 226, 0.4);
}

.project-image {
    height: 250px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-emerald));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.project-preview {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    z-index: 1;
    text-align: center;
    line-height: 1.3;
    padding: 0 1rem;
    word-wrap: break-word;
    white-space: normal;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
    width: 100%;
}

.project-card:hover .project-image::after {
    content: '';
    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;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.project-content {
    padding: 2rem;
}

.project-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--accent-blue);
}

.project-description {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.project-highlight {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(74, 144, 226, 0.2);
    border: 1px solid var(--accent-blue);
    border-radius: 20px;
    color: var(--accent-blue);
    font-size: 0.9rem;
    font-weight: 600;
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    background: var(--bg-secondary);
    padding: 2.5rem;
    border-radius: 16px;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
    text-align: center;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--accent-emerald);
    box-shadow: 0 15px 50px rgba(0, 255, 136, 0.2);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    display: block;
}

.service-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--accent-emerald);
}

.service-description {
    color: var(--text-secondary);
    line-height: 1.8;
}

/* Workflow Section */
.workflow-section {
    background: var(--bg-secondary);
}

.workflow-timeline {
    max-width: 900px;
    margin: 3rem auto 0;
    position: relative;
    padding-left: 2rem;
}

.workflow-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--accent-blue), var(--accent-emerald));
}

.timeline-item {
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    position: relative;
    align-items: flex-start;
}

.timeline-marker {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-emerald));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    flex-shrink: 0;
    position: absolute;
    left: -2rem;
    transform: translateX(-50%);
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.5);
}

.timeline-content {
    margin-left: 3rem;
    padding: 1.5rem;
    background: var(--bg-primary);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    flex: 1;
    transition: all 0.3s ease;
}

.timeline-content:hover {
    border-color: var(--accent-blue);
    transform: translateX(10px);
}

.timeline-content h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--accent-blue);
}

.timeline-content p {
    color: var(--text-secondary);
}

/* Footer */
.footer {
    background: var(--bg-secondary);
    padding: 60px 0 30px;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin-bottom: 3rem;
}

.footer-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--accent-blue);
}

.footer-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.contact-info {
    margin-bottom: 2rem;
}

.phone-link {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.5rem;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.phone-link:hover {
    border-color: var(--accent-blue);
    background: rgba(74, 144, 226, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(74, 144, 226, 0.2);
}

.phone-link svg {
    width: 24px;
    height: 24px;
    color: var(--accent-blue);
    transition: all 0.3s ease;
}

.phone-link:hover svg {
    color: var(--accent-emerald);
    transform: rotate(15deg);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    position: relative;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.2);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
}

.form-group textarea {
    max-width: 100%;
    max-height: 200px;
    resize: vertical;
    min-height: 120px;
}

.social-links {
    display: flex;
    gap: 1.5rem;
}

.social-link {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary);
    border: 2px solid var(--border-color);
    border-radius: 50%;
    color: var(--accent-blue);
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--accent-blue);
    color: var(--text-primary);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(74, 144, 226, 0.4);
}

.social-link svg {
    width: 24px;
    height: 24px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    flex-wrap: wrap;
    gap: 1rem;
}

.performance-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--bg-primary);
    border: 2px solid var(--accent-emerald);
    border-radius: 25px;
    color: var(--accent-emerald);
    font-weight: 600;
    position: relative;
    cursor: pointer;
}

.performance-badge:hover .badge-tooltip {
    opacity: 1;
    visibility: visible;
}

.badge-tooltip {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.85rem;
    white-space: nowrap;
    margin-bottom: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.footer-copyright {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-copyright #currentYear {
    color: var(--text-primary);
    font-weight: 600;
}

/* WhatsApp Floating Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 20px;
    right: 20px;
    max-width: calc(100vw - 40px);
    background: #25D366;
    color: #FFFFFF;
    border-radius: 50%;
    text-align: center;
    font-size: 30px;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
    animation: whatsappPulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(37, 211, 102, 0.6);
    background: #20BA5A;
}

.whatsapp-float svg {
    width: 35px;
    height: 35px;
    fill: #FFFFFF;
}

.whatsapp-tooltip {
    position: absolute;
    bottom: 70px;
    right: 50%;
    transform: translateX(50%);
    background: var(--bg-secondary);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
    pointer-events: none;
    /* Ensure tooltip stays within viewport */
    max-width: calc(100vw - 40px);
    left: auto;
}

.whatsapp-tooltip::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: var(--arrow-left, 50%);
    right: var(--arrow-right, auto);
    transform: translateX(var(--arrow-translate, -50%)) rotate(45deg);
    width: 10px;
    height: 10px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.whatsapp-float:hover .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
}

@keyframes whatsappPulse {
    0% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
    50% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4), 0 0 0 10px rgba(37, 211, 102, 0.1);
    }
    100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
}

/* Responsive WhatsApp Button */
@media (max-width: 768px) {
    .whatsapp-float {
        width: 55px;
        height: 55px;
        bottom: 15px;
        right: 15px;
    }

    .whatsapp-float svg {
        width: 30px;
        height: 30px;
    }

    .whatsapp-tooltip {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
        bottom: 65px;
    }
}

/* Mobile-First Responsive Design */
/* Base styles are mobile-first, then we enhance for larger screens */

/* Small Mobile Devices (up to 480px) */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .navbar {
        padding: 0.75rem 0;
    }

    .navbar .container {
        flex-wrap: wrap;
    }

    .nav-brand {
        font-size: 1.25rem;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(18, 18, 18, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 1rem 0;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
        border-top: 1px solid var(--border-color);
    }

    .nav-links.active {
        max-height: 400px;
        padding: 1rem 0;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links a {
        display: block;
        padding: 0.875rem 1.5rem;
        text-align: center;
        font-size: 0.95rem;
        border-bottom: 1px solid var(--border-color);
    }

    .nav-links a:hover {
        background: rgba(74, 144, 226, 0.1);
    }

    .nav-links a::after {
        display: none;
    }

    .hero {
        min-height: auto;
        padding: 100px 0 40px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .hero-headline {
        font-size: 1.75rem;
        line-height: 1.3;
        margin-bottom: 1rem;
    }

    .hero-subheadline {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }

    .hero-cta {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
        text-align: center;
        padding: 0.875rem 1.5rem;
        font-size: 0.95rem;
    }

    .profile-image-wrapper {
        width: 220px;
        height: 220px;
    }

    .stats-counter {
        flex-direction: column;
        width: 100%;
        gap: 1rem;
    }

    .stat-item {
        width: 100%;
        min-width: auto;
    }

    .stat-number {
        font-size: 2rem;
    }

    .stat-label {
        font-size: 0.85rem;
    }

    section {
        padding: 50px 0;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .section-subtitle {
        font-size: 0.95rem;
        margin-bottom: 2rem;
    }

    .tech-icons {
        gap: 1rem;
        margin-top: 2rem;
    }

    .tech-icon {
        min-width: 100px;
        padding: 1.25rem;
        flex: 1 1 calc(50% - 0.5rem);
        max-width: calc(50% - 0.5rem);
    }

    .tech-icon svg {
        width: 45px;
        height: 45px;
    }

    .tech-icon span {
        font-size: 0.85rem;
    }

    .projects-scroll {
        gap: 1.25rem;
        padding: 1.5rem 0;
    }

    .project-card {
        min-width: 280px;
    }

    .project-image {
        height: 200px;
    }

    .project-preview {
        font-size: 1.5rem;
        padding: 0 0.75rem;
        line-height: 1.2;
    }

    .project-content {
        padding: 1.5rem;
    }

    .project-title {
        font-size: 1.25rem;
    }

    .project-description {
        font-size: 0.9rem;
    }

    .services-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-top: 2rem;
    }

    .service-card {
        padding: 2rem;
    }

    .service-icon {
        font-size: 2.5rem;
    }

    .service-title {
        font-size: 1.25rem;
    }

    .service-description {
        font-size: 0.9rem;
    }

    .workflow-timeline {
        padding-left: 1.25rem;
        margin-top: 2rem;
    }

    .timeline-item {
        margin-bottom: 2rem;
    }

    .timeline-marker {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
        left: 0;
        transform: translateX(-50%);
    }

    .workflow-timeline::before {
        left: 17.5px !important;
    }

    .timeline-content {
        margin-left: 2rem;
        padding: 1.25rem;
    }

    .timeline-content h3 {
        font-size: 1.1rem;
    }

    .timeline-content p {
        font-size: 0.9rem;
    }

    .footer {
        padding: 40px 0 20px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2.5rem;
        margin-bottom: 2rem;
    }

    .footer-title {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .footer-subtitle {
        font-size: 1rem;
        margin-bottom: 1.25rem;
    }

    .contact-info {
        margin-bottom: 1.5rem;
    }

    .phone-link {
        padding: 0.75rem 1.25rem;
        font-size: 1rem;
        gap: 0.625rem;
    }

    .phone-link svg {
        width: 20px;
        height: 20px;
    }

    .contact-form {
        gap: 1.25rem;
    }

    .form-group input,
    .form-group textarea {
        padding: 0.875rem;
        font-size: 0.95rem;
    }

    .form-group textarea {
        max-height: 150px;
        min-height: 100px;
    }

    .social-links {
        justify-content: center;
        gap: 1rem;
    }

    .social-link {
        width: 45px;
        height: 45px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
        padding-top: 1.5rem;
    }

    .performance-badge {
        padding: 0.625rem 1.25rem;
        font-size: 0.85rem;
    }

    .footer-copyright {
        font-size: 0.8rem;
    }
}

/* Tablet Devices (481px to 768px) */
@media (min-width: 481px) and (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(18, 18, 18, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 1rem 0;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
        border-top: 1px solid var(--border-color);
    }

    .nav-links.active {
        max-height: 400px;
        padding: 1rem 0;
    }

    .nav-links li {
        width: 100%;
    }

    .nav-links a {
        display: block;
        padding: 0.875rem 1.5rem;
        text-align: center;
        border-bottom: 1px solid var(--border-color);
    }

    .nav-links a:hover {
        background: rgba(74, 144, 226, 0.1);
    }

    .nav-links a::after {
        display: none;
    }
    .hero-headline {
        font-size: 2.25rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .tech-icons {
        gap: 1.5rem;
    }

    .tech-icon {
        min-width: 130px;
        padding: 1.75rem;
        flex: 1 1 calc(33.333% - 1rem);
        max-width: calc(33.333% - 1rem);
    }

    .project-card {
        min-width: 320px;
    }

    .profile-image-wrapper {
        width: 260px;
        height: 260px;
    }

    .stats-counter {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    .stat-item {
        flex: 1 1 calc(50% - 0.75rem);
        min-width: 140px;
    }

    .workflow-timeline {
        padding-left: 1.75rem;
    }

    .timeline-marker {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }

    .timeline-content {
        margin-left: 2.5rem;
    }
}

/* Desktop and Large Tablets (769px to 968px) */
@media (min-width: 769px) and (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero-headline {
        font-size: 2.75rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .nav-links {
        gap: 1.5rem;
        font-size: 0.95rem;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large Desktop (969px and above) */
@media (min-width: 969px) {
    .hero-content {
        grid-template-columns: 1fr 1fr;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Extra Large Desktop (1200px and above) */
@media (min-width: 1200px) {
    .services-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

