:root {
    --primary-red: #e63946;
    --primary-blue: #1d3557;
    --dark-bg: #0d1117;
    --light-text: #f1faee;
    --accent-color: #a8dadc;
}

* {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.copyable {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--dark-bg);
    color: var(--light-text);
    overflow-x: hidden;
    font-size: 16px;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6, .navbar-brand {
    font-family: 'Poppins', sans-serif;
}

.navbar-brand {
    font-size: 1.5rem;
}

section {
    padding: 70px 0;
}

/* Hero Section with Background Image */
.hero-section {
    background: linear-gradient(rgba(13, 17, 23, 0.75), rgba(13, 17, 23, 0.85)), url('../images/background.jpg') center/cover no-repeat fixed;
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 30% 50%, rgba(230, 57, 70, 0.15) 0%, transparent 50%);
    animation: pulseGlow 8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes pulseGlow {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.05); }
}

.hero-content {
    position: relative;
    z-index: 1;
    animation: fadeInUp 1s ease-out;
}

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

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--primary-red), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: fadeInUp 1s ease-out 0.2s both;
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    margin-bottom: 1.5rem;
    color: var(--accent-color);
    animation: fadeInUp 1s ease-out 0.4s both;
}

.hero-section .lead {
    animation: fadeInUp 1s ease-out 0.6s both;
}

.hero-section .d-flex {
    animation: fadeInUp 1s ease-out 0.8s both;
}

.hero-image {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Profile Circle */
.profile-circle {
    position: absolute;
    top: -30px;
    right: 20px;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    overflow: hidden;
    border: 5px solid var(--primary-red);
    box-shadow: 0 10px 40px rgba(230, 57, 70, 0.4);
    animation: profileFloat 4s ease-in-out infinite, fadeInScale 1s ease-out 0.5s both;
    z-index: 10;
}

@keyframes profileFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(5deg); }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.profile-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.profile-circle:hover img {
    transform: scale(1.1);
}

.btn-primary-custom {
    background-color: var(--primary-red);
    border: none;
    padding: 14px 35px;
    font-weight: 600;
    border-radius: 50px;
    transition: all 0.4s ease;
    font-size: 1rem;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary-custom::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s;
    z-index: -1;
}

.btn-primary-custom:hover::before {
    left: 100%;
}

.btn-primary-custom:hover {
    background-color: #c1121f;
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 25px rgba(230, 57, 70, 0.4);
}

.btn-outline-light {
    padding: 14px 35px;
    border-radius: 50px;
    border: 2px solid var(--light-text);
    transition: all 0.4s ease;
    font-weight: 600;
}

.btn-outline-light:hover {
    background-color: var(--light-text);
    color: var(--dark-bg);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 25px rgba(241, 250, 238, 0.3);
}

.section-title {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 700;
    margin-bottom: 3.5rem;
    text-align: center;
    position: relative;
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.section-title::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-red), var(--accent-color));
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 2px;
}

.about-section, .projects-section {
    background-color: var(--dark-bg);
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(168, 218, 220, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(230, 57, 70, 0.05) 0%, transparent 50%);
}

.about-content {
    font-size: 1rem;
    line-height: 1.9;
    color: var(--light-text);
    animation: fadeInUp 0.8s ease-out;
    text-align: justify;
    position: relative;
}

.quote-icon {
    position: absolute;
    top: -15px;
    left: -35px;
    font-size: 3rem;
    color: var(--primary-red);
    opacity: 0.2;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.2; }
    50% { transform: scale(1.1); opacity: 0.3; }
}

.about-content p {
    margin-bottom: 1.2rem;
    font-weight: 400;
    color: var(--light-text);
}

.highlight {
    color: var(--light-text);
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

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

.highlight:hover {
    color: var(--primary-red);
}

.highlight:hover::after {
    width: 100%;
}

.flag-icon {
    font-size: 1.2em;
    margin: 0 3px;
    display: inline-block;
    animation: wave 2s ease-in-out infinite;
}

@keyframes wave {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(10deg); }
    75% { transform: rotate(-10deg); }
}

.services-section, .integrations-section, .contact-section {
    background: linear-gradient(135deg, rgba(29, 53, 87, 0.3) 0%, rgba(13, 17, 23, 0.9) 100%);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(168, 218, 220, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(230, 57, 70, 0.08) 0%, transparent 40%);
}

.hobbies-section {
    background-color: var(--dark-bg);
    background-image: 
        radial-gradient(circle at 50% 50%, rgba(168, 218, 220, 0.05) 0%, transparent 50%);
}

.service-card, .hobby-item, .project-card, .integration-item, .contact-form {
    animation: fadeInUp 0.6s ease-out both;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }
.service-card:nth-child(4) { animation-delay: 0.4s; }

.hobby-item:nth-child(1) { animation-delay: 0.1s; }
.hobby-item:nth-child(2) { animation-delay: 0.2s; }
.hobby-item:nth-child(3) { animation-delay: 0.3s; }
.hobby-item:nth-child(4) { animation-delay: 0.4s; }
.hobby-item:nth-child(5) { animation-delay: 0.5s; }
.hobby-item:nth-child(6) { animation-delay: 0.6s; }

.service-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    padding: 35px;
    height: 100%;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(230, 57, 70, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.service-card:hover::before {
    opacity: 1;
    animation: rotate 10s linear infinite;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.service-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(230, 57, 70, 0.2);
    border-color: var(--primary-red);
    background: rgba(255, 255, 255, 0.05);
}

.service-icon {
    font-size: 3.5rem;
    color: var(--primary-red);
    margin-bottom: 25px;
    transition: all 0.4s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    color: var(--accent-color);
    filter: drop-shadow(0 0 20px var(--primary-red));
}

.gradient-title {
    background: linear-gradient(135deg, var(--primary-red), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 600;
    margin-bottom: 15px;
}

.project-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    height: 100%;
}

.project-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border-color: var(--primary-red);
}

.project-img {
    height: 220px;
    background: linear-gradient(135deg, var(--primary-blue), rgba(29, 53, 87, 0.8));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
    overflow: hidden;
    position: relative;
}

.project-img img {
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.project-card:hover .project-img img {
    transform: scale(1.15) rotate(2deg);
}

.project-content {
    padding: 25px;
}

.integrations-slider {
    position: relative;
    overflow: hidden;
    padding: 30px 0;
}

.integrations-track {
    display: flex;
    animation: scroll 35s linear infinite;
    width: calc(230px * 10);
}

.integration-item {
    width: 200px;
    flex-shrink: 0;
    margin: 0 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    padding: 25px;
    text-align: center;
    transition: all 0.4s ease;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
}

.integration-item:hover {
    transform: translateY(-10px) scale(1.05);
    border-color: var(--primary-red);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 15px 30px rgba(230, 57, 70, 0.2);
}

.integration-logo {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
}

.integration-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.integration-item:hover .integration-logo img {
    transform: scale(1.15) rotate(5deg);
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-230px * 5)); }
}

.integrations-slider:hover .integrations-track {
    animation-play-state: paused;
}

.hobby-item {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    transition: all 0.4s ease;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    height: 100%;
}

.hobby-item:hover {
    transform: translateY(-10px) scale(1.03);
    border-color: var(--primary-red);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 15px 30px rgba(230, 57, 70, 0.2);
}

.hobby-icon {
    font-size: 3rem;
    color: var(--primary-red);
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.hobby-item:hover .hobby-icon {
    transform: scale(1.2) rotate(10deg);
    color: var(--accent-color);
    filter: drop-shadow(0 0 15px var(--primary-red));
}

.contact-form {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
}

.form-control {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--light-text);
    padding: 15px 20px;
    font-size: 1rem;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.form-control:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-red);
    color: var(--light-text);
    box-shadow: 0 0 0 0.2rem rgba(230, 57, 70, 0.25);
    transform: translateY(-2px);
}

.form-control::placeholder {
    color: rgba(241, 250, 238, 0.5);
}

#formMessage {
    padding: 15px;
    border-radius: 10px;
    font-weight: 500;
}

#formMessage.success {
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid rgba(40, 167, 69, 0.5);
    color: #28a745;
}

#formMessage.error {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.5);
    color: #dc3545;
}

footer {
    background-color: #0a0d12;
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.social-icons a {
    display: inline-block;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    text-align: center;
    line-height: 45px;
    margin-right: 12px;
    transition: all 0.4s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.social-icons a:hover {
    background-color: var(--primary-red);
    transform: translateY(-5px) rotate(360deg);
    box-shadow: 0 10px 20px rgba(230, 57, 70, 0.3);
    border-color: var(--primary-red);
}

.navbar {
    background: rgba(13, 17, 23, 0.95);
    backdrop-filter: blur(20px);
    padding: 20px 0;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.navbar.scrolled {
    padding: 15px 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.navbar-brand {
    font-weight: 700;
    color: var(--light-text) !important;
    transition: all 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.navbar-brand span {
    color: var(--primary-red);
}

.nav-link {
    color: var(--light-text) !important;
    font-weight: 500;
    margin: 0 8px;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 12px !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-red);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 80%;
}

.nav-link:hover {
    color: var(--primary-red) !important;
    transform: translateY(-2px);
}

.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 55px;
    height: 55px;
    background: linear-gradient(135deg, var(--primary-red), #c1121f);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: all 0.4s ease;
    z-index: 1000;
    box-shadow: 0 5px 20px rgba(230, 57, 70, 0.4);
}

.scroll-top.active {
    opacity: 1;
}

.scroll-top:hover {
    transform: translateY(-5px) scale(1.1) rotate(360deg);
    box-shadow: 0 10px 30px rgba(230, 57, 70, 0.5);
}

/* Mobile Responsiveness */
@media (max-width: 991px) {
    section {
        padding: 50px 0;
    }
    
    .hero-section {
        min-height: 100vh;
        padding: 80px 0 60px;
    }
    
    .navbar-collapse {
        background: rgba(13, 17, 23, 0.98);
        padding: 20px;
        border-radius: 15px;
        margin-top: 15px;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav-link {
        padding: 12px 15px !important;
        margin: 5px 0;
    }
    
    .profile-circle {
        width: 150px;
        height: 150px;
        top: -20px;
        right: 10px;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 2.5rem;
    }
    
    .about-content {
        font-size: 0.95rem;
    }
    
    .quote-icon {
        left: -20px;
        font-size: 2rem;
    }
    
    .service-card, .hobby-item {
        padding: 25px;
        margin-bottom: 20px;
    }
    
    .service-icon, .hobby-icon {
        font-size: 2.5rem;
    }
    
    .btn-primary-custom, .btn-outline-light {
        padding: 12px 28px;
        font-size: 0.95rem;
    }
    
    .contact-form {
        padding: 30px 20px;
    }
    
    .hero-image i {
        font-size: 10rem !important;
    }
    
    .scroll-top {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
    }
    
    .profile-circle {
        width: 120px;
        height: 120px;
        top: -10px;
        right: 5px;
        border: 3px solid var(--primary-red);
    }
}

@media (max-width: 576px) {
    .hero-section {
        padding: 100px 0 60px;
    }
    
    .navbar-brand {
        font-size: 1.3rem;
    }
    
    .d-flex.flex-wrap.gap-3 {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn-primary-custom, .btn-outline-light {
        width: 100%;
        text-align: center;
    }
    
    .integration-item {
        width: 180px;
    }
    
    .profile-circle {
        width: 100px;
        height: 100px;
        top: 0;
        right: 5px;
    }
}
