/* CSS Variables for consistent theming */
:root {
    --primary-color: #3498db;
    --accent-color: #e74c3c;
    --dark-bg: #000000;
    --darker-bg: #111314;
    --text-primary: #fff;
    --text-secondary: #bbabab;
    --card-bg: rgba(3, 6, 19, 0.63);
    --header-bg: rgba(14, 19, 29, 0.95);
    --header-bg-scrolled: rgba(9, 12, 19, 0.98);
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    line-height: 1.6;
    padding-top: 80px;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.sub-title {
    font-size: 2.5rem;
    margin-bottom: 30px;
    text-align: center;
    color: var(--text-primary);
    position: relative;
    padding-bottom: 15px;
}

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

section {
    padding: 80px 0;
}

/* Home/Hero Section */
#home {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    padding: 80px 0;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    gap: 40px;
}

.multiple-text {
    font-weight: 600;
    color: var(--accent-color);
    min-height: 1.5em;
    display: inline-block;
}

.typed-cursor {
    font-weight: 400;
    color: var(--primary-color);
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
    line-height: 1.2;
    animation: slideTop 1s ease forwards;
}

.highlight {
    color: #b96c64;
    position: relative;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 30px;
    color: var(--text-secondary);
    line-height: 1.6;
    animation: slideLeft 1s ease forwards;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    margin-top: 30px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    text-align: center;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, #161f25, #31181e);
    color: var(--text-primary);
    box-shadow: 0 4px 15px rgba(53, 27, 27, 0.822);
    animation: slideLeft 1s ease forwards;
}

@keyframes slideLeft {
    0% {
        transform: translateX(100px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

.btn-primary:hover,
.btn-primary:focus {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(82, 46, 46, 0.904);
    outline: none;
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid #271212;
    animation: slideTop 1s ease forwards;
}

@keyframes slideTop {
    0% {
        transform: translateY(100px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.btn-secondary:hover,
.btn-secondary:focus {
    background: #1c2022;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.3);
    outline: none;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.image-container {
    position: relative;
    width: 70%;
    max-width: 550px;
}

.image-container img {
    width: 100%;
    border-radius: 80px;
    box-shadow: 0 20px 40px rgba(29, 15, 15, 0.986);
    transition: transform 0.5s ease;
}

.image-container:hover img {
    transform: scale(1.03);
}

/* Header Styles */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--header-bg);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 0;
    transition: all 0.3s ease;
}

.header.scrolled {
    background-color: var(--header-bg-scrolled);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.15);
    padding: 0.5rem 0;
}

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

/* Logo styles */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #b6b5b5;
    font-weight: 700;
    font-size: 1.5rem;
    transition: color 0.3s ease;
    z-index: 1002;
    animation: slideRight 1s ease forwards;
}

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

.logo-text {
    margin-right: 0.3rem;
}

.logo-subtext {
    margin-left: 0.3rem;
    color: var(--accent-color);
}

.logo i {
    font-size: 1.3rem;
    color: var(--primary-color);
}

/* Navigation styles */
.navbar {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #b6d1ec;
    font-weight: 500;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.3s ease;
    /* Animation properties */
    opacity: 0;
    transform: translateY(-20px);
    transition: transform 0.6s cubic-bezier(0.35, 1, 0.32, 1), 
                opacity 0.6s cubic-bezier(0.30, 1, 0.32, 1),
                color 0.3s ease;
}

.nav-link.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.nav-link:hover,
.nav-link:focus {
    color: #b54769;
    outline: none;
}

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

.nav-link:hover::after,
.nav-link:focus::after {
    width: 100%;
}

.nav-link.active {
    color: var(--primary-color);
}

.nav-link.active::after {
    width: 100%;
}

/* Mobile menu toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    background: none;
    border: none;
    width: 30px;
    height: 30px;
    cursor: pointer;
    padding: 0;
    z-index: 1002;
}

.menu-toggle:hover,
.menu-toggle:focus {
    outline: none;
    opacity: 0.8;
}

.hamburger-line {
    width: 100%;
    height: 3px;
    background-color: var(--text-primary);
    margin: 2px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* About Section */
#about {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    color: #d3cccc;
}

.row {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}

.about-col-1 {
    flex-basis: 35%;
}

.about-col-1 img {
    width: 100%;
    border-radius: 80px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-top: 25%;
}

.about-col-2 {
    flex-basis: 60%;
}

.tab-titles {
    display: flex;
    margin: 20px 0 40px;
}

.tab-links {
    margin-right: 50px;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    position: relative;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

.tab-links:hover {
    color: var(--primary-color);
}

.tab-links::after {
    content: '';
    width: 0;
    height: 3px;
    background: var(--primary-color);
    position: absolute;
    left: 0;
    bottom: -8px;
    transition: 0.5s;
}

.tab-links.active-link::after {
    width: 50%;
}

.tab-contents ul li {
    list-style: none;
    margin: 10px 0;
}

.tab-contents ul li span {
    color: var(--accent-color);
    font-size: 14px;
    font-weight: 600;
}

.tab-contents {
    display: none;
}

.tab-contents.active-tab {
    display: block;
    animation: fadeIn 0.5s ease;
}

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

/* Services Section */
#services {
    padding-bottom: 30px;
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
}

.services-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    grid-gap: 40px;
    margin-top: 50px;
    color: var(--text-primary);
}

.services-list div {
    background: var(--card-bg);
    padding: 40px;
    font-size: 13px;
    font-weight: 300;
    border-radius: 50px;
    transition: transform 0.5s, box-shadow 0.5s;
    box-shadow: 0 5px 15px rgba(189, 132, 132, 0.1);
    position: relative;
    opacity: 0;
    transform: translateY(20px);
}

.services-list div.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.services-list div i {
    font-size: 50px;
    margin-bottom: 30px;
    color: var(--primary-color);
}

.services-list div h2 {
    font-size: 30px;
    font-weight: 500;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.services-list div:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(110, 65, 65, 0.1);
}

.service-btn {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--primary-color), #2980b9);
    color: var(--text-primary);
    text-decoration: none;
    border-radius: 30px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.service-btn:hover,
.service-btn:focus {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
    outline: none;
}

/* Portfolio Section */
#portfolio {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
}

.work-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    grid-gap: 40px;
    margin-top: 50px;
}

.work {
    border-radius: 10px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.work.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.work img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 10px;
    display: block;
    transition: transform 0.5s;
}

.layer {
    width: 100%;
    height: 0;
    background: linear-gradient(rgba(0,0,0,0.6), #051420);
    border-radius: 10px;
    position: absolute;
    left: 0;
    bottom: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0 40px;
    text-align: center;
    font-size: 14px;
    transition: height 0.5s;
}

.layer h3 {
    font-weight: 500;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.layer p {
    color: var(--text-primary);
    margin-bottom: 15px;
}

.layer a {
    margin-top: 20px;
    color: var(--primary-color);
    text-decoration: none;
    font-size: 18px;
    line-height: 40px;
    background: var(--text-primary);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    text-align: center;
    transition: all 0.3s ease;
}

.layer a:hover,
.layer a:focus {
    transform: scale(1.1);
    outline: none;
}

.work:hover img {
    transform: scale(1.1);
}

.work:hover .layer {
    height: 100%;
}

.portfolio-cta {
    text-align: center;
    margin-top: 50px;
}

/* Contact Section */
#contact {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    padding: 60px 0 30px;
}

.contact-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 50px;
    margin-top: 30px;
}

.contact-info {
    color: var(--text-primary);
}

.contact-info p {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.contact-info i {
    color: wheat;
    font-size: 20px;
    width: 30px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-form input,
.contact-form textarea {
    padding: 15px;
    border: none;
    border-radius: 5px;
    background: rgb(27, 24, 24);
    color: #cfc6c6;
    font-size: 16px;
    transition: box-shadow 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-color);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #ccc;
}

.contact-form textarea {
    resize: vertical;
    min-height: 120px;
}

.contact-form button {
    align-self: flex-end;
}

.center {
    text-align: center;
    margin-top: 60px;
}

.social-icons {
    margin-top: 40px;
    display: flex;
    justify-content: left;
    gap: 15px;
    animation: slideRight 1s ease forwards;
}

@keyframes slideRight {
    0% {
        transform: translateX(-100px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

.social-icons a {
    text-decoration: none;
    font-size: 42px;
    display: inline-block;
    transition: all 0.3s ease;
    width: 50px;
    height: 50px;
    padding: 15px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #080b0e, #291218);
    color: var(--text-primary);
    box-shadow: 0 4px 15px rgba(23, 24, 12, 0.932);
}

.social-icons a:hover,
.social-icons a:focus {
    color: #050f18;
    transform: translateY(-8px) scale(1.1);
    background: rgb(9, 11, 29);
    box-shadow: 0 10px 25px rgba(22, 57, 61, 0.918);
    outline: none;
}

/* Form Feedback Styles */
#form-feedback {
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 15px;
    display: none;
    text-align: center;
}

#form-feedback.success {
    display: block;
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

#form-feedback.error {
    display: block;
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.copyright {
    width: 100%;
    text-align: center;
    padding: 25px 0;
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    color: var(--text-primary);
    margin-top: 20px;
}

.copyright p {
    margin-bottom: 5px;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: var(--text-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover,
.back-to-top:focus {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    outline: none;
}

/* Responsive design */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .services-list {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 70px;
    }
    
    .header-container {
        padding: 0.8rem 1.5rem;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .navbar {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: rgba(0, 0, 0, 0.95);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        gap: 2.5rem;
        backdrop-filter: blur(10px);
    }
    
    .navbar.active {
        right: 0;
    }
    
    .menu-toggle.active .hamburger-line:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
        background-color: var(--text-primary);
    }
    
    .menu-toggle.active .hamburger-line:nth-child(2) {
        opacity: 0;
    }
    
    .menu-toggle.active .hamburger-line:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
        background-color: var(--text-primary);
    }
    
    .hero {
        flex-direction: column;
        text-align: center;
        padding: 40px 20px;
        gap: 30px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .sub-title {
        font-size: 2rem;
    }
    
    .about-col-1, .about-col-2 {
        flex-basis: 100%;
    }
    
    .about-col-1 {
        margin-bottom: 30px;
    }
    
    .about-col-2 {
        font-size: 14px;
    }
    
    .tab-titles {
        flex-direction: column;
        gap: 15px;
    }
    
    .tab-links {
        margin-right: 0;
        font-size: 16px;
    }
    
    .services-list div {
        padding: 30px 20px;
    }
    
    .work-list {
        grid-template-columns: 1fr;
    }
    
    .contact-container {
        grid-template-columns: 1fr;
    }
    
    /* Mobile navbar animation */
    .navbar .nav-link {
        opacity: 0;
        transform: translateY(-20px);
        transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1), 
                    opacity 0.6s cubic-bezier(0.23, 1, 0.32, 1);
    }
    
    .navbar.active .nav-link {
        opacity: 1;
        transform: translateY(0);
    }
    
    .navbar.active .nav-link:nth-child(1) { transition-delay: 0.1s; }
    .navbar.active .nav-link:nth-child(2) { transition-delay: 0.2s; }
    .navbar.active .nav-link:nth-child(3) { transition-delay: 0.3s; }
    .navbar.active .nav-link:nth-child(4) { transition-delay: 0.4s; }
    .navbar.active .nav-link:nth-child(5) { transition-delay: 0.5s; }
}

@media (max-width: 480px) {
    .header-container {
        padding: 0.8rem 1rem;
    }
    
    .logo {
        font-size: 1.3rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .sub-title {
        font-size: 1.8rem;
    }
    
    .services-list div h2 {
        font-size: 24px;
    }
    
    .services-list div i {
        font-size: 40px;
    }
    
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
    }
    
    .social-icons a {
        font-size: 36px;
        width: 40px;
        height: 40px;
    }
}

/* Animation keyframes for navbar */
@keyframes slideInFromTop {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}