/* Modern CSS Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Global Styles */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --text-color: #333;
    --light-text: #fff;
    --background-color: #f9f9f9;
    --transition-speed: 0.3s;
    --navbar-height: 80px;
    --navbar-height-mobile: 70px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    overflow-x: hidden;
    padding-top: var(--navbar-height); /* Add padding for fixed navbar */
    transition: padding var(--transition-speed);
}

body.menu-open {
    overflow: hidden; /* Prevent scrolling when mobile menu is open */
}

/* Navbar Styles */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--navbar-height);
    background-color: var(--primary-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: all var(--transition-speed) ease;
}

.navbar-container {
    max-width: 1200px;
    height: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.navbar-logo {
    height: 100%;
    display: flex;
    align-items: center;
}

.navbar-logo img {
    height: 40px;
    transition: transform var(--transition-speed);
}

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

.navbar-links {
    display: flex;
    list-style: none;
}

.navbar-links li {
    margin-left: 30px;
}

.navbar-links a {
    color: var(--light-text);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    position: relative;
    transition: color var(--transition-speed);
}

.navbar-links a:hover {
    color: var(--accent-color);
}

.navbar-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width var(--transition-speed);
}

.navbar-links a:hover::after {
    width: 100%;
}

.navbar-toggle {
    display: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.bar {
    display: block;
    width: 30px;
    height: 3px;
    margin: 6px auto;
    background-color: var(--light-text);
    transition: all var(--transition-speed);
    border-radius: 2px;
}

/* Navbar scroll effect */
.navbar.scrolled {
    background-color: rgba(44, 62, 80, 0.95);
    height: var(--navbar-height-mobile);
    backdrop-filter: blur(5px);
}

/* Mobile navbar styles */
@media (max-width: 768px) {
    body {
        padding-top: var(--navbar-height-mobile);
    }
    
    .navbar {
        height: var(--navbar-height-mobile);
    }
    
    .navbar-menu {
        position: fixed;
        left: -100%;
        top: var(--navbar-height-mobile);
        flex-direction: column;
        background-color: rgba(44, 62, 80, 0.95);
        width: 100%;
        height: auto;
        min-height: calc(100vh - var(--navbar-height-mobile));
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 10px rgba(0, 0, 0, 0.1);
        z-index: 999;
        display: block;
        backdrop-filter: blur(5px);
    }

    .navbar-menu.active {
        left: 0;
        z-index: 1000;
        opacity: 1;
        visibility: visible;
    }

    .navbar-links {
        flex-direction: column;
        width: 100%;
        padding: 40px 0;
    }

    .navbar-links li {
        margin: 20px 0;
    }
    
    .navbar-links a {
        font-size: 1.3rem;
        padding: 10px;
        display: inline-block;
    }

    .navbar-toggle {
        display: block;
    }

    .navbar-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .navbar-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }

    .navbar-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}

/* Typography */
h1, h2, h3 {
    margin-bottom: 1rem;
    line-height: 1.2;
}

h1 {
    font-size: 3.5rem;
    font-weight: 700;
}

h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
}

.about h2, .services h2 {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--accent-color), var(--secondary-color), var(--primary-color));
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 5s infinite linear;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(44, 62, 80, 0.7), rgba(52, 152, 219, 0.7)), url('assets/lighting_image.jpg');
    background-size: cover;
    background-position: center;
    color: var(--light-text);
    padding: 100px 20px;
    text-align: center;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
}

/* About Section */
.about {
    padding: 100px 20px;
    background-color: var(--background-color);
}

.about-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-text {
    flex: 1;
    position: relative;
    z-index: 1;
}

.about-image {
    flex: 1;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    height: 400px;
    background-image: url('https://images.unsplash.com/photo-1522071820081-009f0129c71c');
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}

.services-list {
    list-style: none;
    margin-top: 1.5rem;
}

.services-list li {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.services-list li:hover {
    transform: translateX(10px);
    color: var(--accent-color);
}

/* Portfolio Carousel - Redesigned */
.portfolio {
    padding: 100px 20px;
    background-color: #fff;
}

.carousel-container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.carousel {
    display: flex;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    height: 500px;
    will-change: transform;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-perspective: 1000;
    perspective: 1000;
}

.carousel-item {
    min-width: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transform: translate3d(0, 0, 0);
    -webkit-transform-style: preserve-3d;
    transform-style: preserve-3d;
}

.project-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: top center;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

.carousel-item:nth-child(1) .project-image {
    background-image: url('assets/noraandaman-img.jpg');
}

.carousel-item:nth-child(2) .project-image {
    background-image: url('assets/sinaroptik-img.jpg');
}

.carousel-item:nth-child(3) .project-image {
    background-image: url('assets/yayasanpeace-img.jpg');
}

.carousel-item:nth-child(4) .project-image {
    background-image: url('assets/slay-img.jpg');
}

.carousel-item:nth-child(5) .project-image {
    background-image: url('assets/slay-img.jpg');
}

.project-description {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    padding: 2rem;
    transform: translateY(0);
    transition: transform 0.3s ease;
}

.project-description h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.carousel-item:hover .project-image {
    transform: scale(1.05);
}

/* Carousel Controls */
.carousel-controls {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 10px;
    z-index: 10;
}

.carousel-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.carousel-dot.active {
    background-color: white;
    transform: scale(1.2);
}

.carousel-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
    backdrop-filter: blur(4px);
    -webkit-tap-highlight-color: transparent;
}

.carousel-control:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: translate3d(0, -50%, 0) scale(1.1);
    opacity: 1;
}

.carousel-control.prev {
    left: 20px;
}

.carousel-control.next {
    right: 20px;
}

/* Services Section */
.services {
    padding: 100px 20px;
    background: linear-gradient(135deg, #2c3e50, #1a252f);
    color: var(--light-text);
    position: relative;
    overflow: hidden;
}

.services::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://images.unsplash.com/photo-1451187580459-43490279c0fa') center/cover no-repeat;
    opacity: 0.15;
    z-index: 0;
}

.services-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 30px;
    position: relative;
    z-index: 1;
}

.services-text {
    grid-column: 1 / 8;
    position: relative;
    z-index: 1;
}

.services-text h2 {
    text-align: left;
    color: var(--light-text);
    font-size: 2.8rem;
    margin-bottom: 1.5rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.services-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    margin-bottom: 2rem;
    max-width: 90%;
}

.services-text ul li {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    font-size: 1.1rem;
    transition: transform 0.3s ease, color 0.3s ease;
}

.services-text ul li::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background-color: var(--accent-color);
    border-radius: 50%;
    margin-right: 15px;
}

.services-text ul li:hover {
    transform: translateX(10px);
    color: var(--accent-color);
}

.services-image {
    grid-column: 8 / 13;
    position: relative;
    height: 450px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1;
}

.services-image::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(52, 152, 219, 0.2);
    border-radius: 50%;
    filter: blur(50px);
    z-index: -1;
    animation: pulse 4s infinite ease-in-out;
}

.tech-icons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 30px;
    width: 100%;
    height: 100%;
    padding: 20px;
}

.tech-icon {
    position: relative;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    border-radius: 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 3rem;
    color: white;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    overflow: hidden;
}

.tech-icon::before {
    content: attr(data-tech);
    position: absolute;
    bottom: 15px;
    font-size: 0.9rem;
    font-weight: bold;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.tech-icon:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 0.2);
}

.tech-icon:hover::before {
    opacity: 1;
    transform: translateY(0);
}

.tech-icon:hover i {
    transform: translateY(-10px);
}

.tech-icon i {
    transition: transform 0.3s ease;
}

.tech-icon:nth-child(1) { animation: fadeInRotate 0.5s 0.1s both; }
.tech-icon:nth-child(2) { animation: fadeInRotate 0.5s 0.2s both; }
.tech-icon:nth-child(3) { animation: fadeInRotate 0.5s 0.3s both; }
.tech-icon:nth-child(4) { animation: fadeInRotate 0.5s 0.4s both; }
.tech-icon:nth-child(5) { animation: fadeInRotate 0.5s 0.5s both; }
.tech-icon:nth-child(6) { animation: fadeInRotate 0.5s 0.6s both; }

.tech-icon:nth-child(1) i { color: #E44D26; } /* HTML5 */
.tech-icon:nth-child(2) i { color: #264DE4; } /* CSS3 */
.tech-icon:nth-child(3) i { color: #F7DF1E; } /* JavaScript */
.tech-icon:nth-child(4) i { color: #61DAFB; } /* React */
.tech-icon:nth-child(5) i { color: #68A063; } /* Node.js */
.tech-icon:nth-child(6) i { color: #21759B; } /* WordPress */

.decorative-element {
    width: 100%;
    height: 400px;
    background: linear-gradient(45deg, var(--secondary-color), var(--accent-color));
    border-radius: 10px;
    position: relative;
    overflow: hidden;
    transition: transform 0.5s ease;
}

.decorative-element::before {
    content: '';
    position: absolute;
    width: 150%;
    height: 150%;
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(45deg);
    top: -25%;
    left: -25%;
}

/* Contact Section */
.contact {
    padding: 100px 20px;
    background-color: #fff;
}

.contact-header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-content {
    max-width: 1200px;
    margin: 0 auto;
}

.contact-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

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

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.contact-text h3 {
    margin-bottom: 0.5rem;
}

.contact-text a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color var(--transition-speed);
}

.contact-text a:hover {
    color: var(--accent-color);
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: var(--light-text);
    padding: 50px 20px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.footer-logo {
    margin-bottom: 2rem;
}

.footer-logo-img {
    max-width: 200px;
}

.social-links {
    margin-bottom: 2rem;
}

.social-links a {
    color: var(--light-text);
    font-size: 1.5rem;
    margin: 0 10px;
    transition: color var(--transition-speed);
}

.social-links a:hover {
    color: var(--accent-color);
}

.footer-links a {
    color: var(--light-text);
    text-decoration: none;
    margin: 0 15px;
    transition: color var(--transition-speed);
}

.footer-links a:hover {
    color: var(--accent-color);
}

.copyright {
    margin-top: 2rem;
    font-size: 0.9rem;
    opacity: 0.8;
}

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

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes shimmer {
    0% {
        background-position: -100% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

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

@keyframes rotateIn {
    from {
        opacity: 0;
        transform: rotate(-15deg) scale(0.9);
    }
    to {
        opacity: 1;
        transform: rotate(0) scale(1);
    }
}

@keyframes fadeInRotate {
    from {
        opacity: 0;
        transform: translateY(30px) rotate(10deg);
    }
    to {
        opacity: 1;
        transform: translateY(0) rotate(0);
    }
}

/* Utility Classes */
.cta-button {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: var(--accent-color);
    color: var(--light-text);
    text-decoration: none;
    border-radius: 5px;
    transition: transform var(--transition-speed), background-color var(--transition-speed);
    font-weight: 600;
}

.cta-button:hover {
    transform: translateY(-3px);
    background-color: #c0392b;
}

.whatsapp-btn {
    background-color: #25D366;
}

.whatsapp-btn:hover {
    background-color: #128C7E;
}

/* Responsive Design */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .about-content {
        flex-direction: column;
    }

    .carousel {
        height: 400px;
        touch-action: pan-y pinch-zoom;
    }

    .carousel-container {
        margin: 0 -20px;
        border-radius: 0;
    }

    .project-description {
        padding: 1.5rem;
    }

    .carousel-control {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
        opacity: 0.8;
    }

    .carousel-control.prev {
        left: 10px;
    }

    .carousel-control.next {
        right: 10px;
    }

    .carousel-dot {
        width: 8px;
        height: 8px;
    }
    
    .services-content {
        grid-template-columns: 1fr;
    }
    
    .services-text {
        grid-column: 1 / -1;
        text-align: center;
    }
    
    .services-text h2 {
        text-align: center;
    }
    
    .services-text p {
        max-width: 100%;
    }
    
    .services-text ul {
        padding: 0;
        max-width: 600px;
        margin: 0 auto;
        list-style: none;
    }

    .services-text ul li {
        justify-content: flex-start;
        text-align: left;
        padding: 0 25px;
        margin: 0 0 1.5rem;
        position: relative;
        line-height: 1.4;
    }
    
    .services-image {
        grid-column: 1 / -1;
        margin-top: 2rem;
        height: 350px;
    }
    
    .tech-icons {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
        gap: 20px;
    }

    .about-image {
        margin-top: 2rem;
    }

    .contact-details {
        grid-template-columns: 1fr;
    }

    .carousel-control {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .carousel {
        height: 400px;
    }
    
    .project-description {
        padding: 1.5rem;
    }
    
    .project-description h3 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 80px 20px;
    }

    h1 {
        font-size: 2rem;
    }
    
    .services {
        padding: 70px 20px;
    }
    
    .services-text h2 {
        font-size: 1.8rem;
    }
    
    .services-text ul li {
        font-size: 1rem;
        margin-bottom: 1rem;
    }
    
    .services-text ul li::before {
        width: 6px;
        height: 6px;
        margin-right: 12px;
        flex-shrink: 0;
        position: absolute;
        left: 10px;
        top: 8px;
    }
    
    .services-image {
        height: 300px;
    }
    
    .tech-icons {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(3, 1fr);
        gap: 15px;
        padding: 10px;
    }
    
    .tech-icon {
        font-size: 2rem;
        border-radius: 10px;
    }
    
    .tech-icon::before {
        font-size: 0.7rem;
        bottom: 10px;
    }

    .contact-item {
        flex-direction: column;
        text-align: center;
    }

    .footer-links a {
        display: block;
        margin: 10px 0;
    }
    
    .carousel {
        height: 350px;
    }
    
    .project-description {
        padding: 1rem;
    }
    
    .project-description h3 {
        font-size: 1.3rem;
    }
    
    .carousel-control {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
}
