:root {
    --primary: #035AFF;
    --light: #F0F0F1;
    --black: #404041;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: var(--primary);
    color: var(--light);
    overflow-x: hidden;
}

.hero {
    background-image: url(/Image/Web_Banner_background.png);
    background-size: cover;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 16px 8%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    z-index: 1000;
}

/* === LOGO === */
.logo {
    background-image: url(/Image/Boxel_Logo.png);
    background-size: cover;
    height: 60px;
    width: 250px;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.logo i {
    color: var(--light);
    margin-right: 10px;
    font-size: 32px;
}

/* === NAV LINKS === */
.nav-links {
    display: flex;
    align-items: center;
    gap: 45px;
}

.nav-links a {
    text-decoration: none;
    color: var(--black);
    font-weight: 600;
    font-size: 17px;
    position: relative;
    transition: color 0.3s ease;
}

.nav-links a::after {
    content: "";
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--primary);
}

#contact-us-a {
    display: none;
}

/* === CONTACT BUTTON === */
.contact-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary);
    border-radius: 30px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.contact-btn a {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.contact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 3px 7px var(--black);
}

.contact-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.contact-btn:hover::before {
    left: 100%;
}

/* === MENU TOGGLE (MOBILE) === */
.menu-toggle {
    display: none;
    font-size: 26px;
    color: var(--black);
    cursor: pointer;
    transition: 0.3s ease;
}

.menu-toggle.active i {
    transform: rotate(90deg);
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 10%;
    position: relative;
}

.hero-content {
    max-width: 600px;
}

.hero h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero h1 span {
    color: var(--primary);
}

.hero p {
    font-size: 18px;
    margin-bottom: 30px;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--light);
    color: var(--primary);
    border-radius: 30px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 2px 7px var(--black);
}


.btn:hover::before {
    left: 100%;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--light);
    color: var(--light);
    margin-left: 15px;
}

.btn-outline:hover {
    background: var(--light);
    color: var(--primary);
}


/* Animated 3D Box */
.hero-3d {
    display: flex;
    align-items: center;
    justify-content: space-between;
    /* or center if both in middle */
    position: absolute;
    top: 38%;
    right: 15%;
    width: 350px;
    height: 350px;
    perspective: 1000px;
}

.boxel-box {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    animation: rotate 20s infinite linear;
    transform: scale(0.9);
}

.box-face {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(0, 212, 255, 0.05);
    border: 1px solid rgba(0, 212, 255, 0.2);
    backdrop-filter: blur(5px);
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: all 0.5s ease;
    overflow: hidden;
}

.box-face::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 212, 255, 0.5), transparent);
    transition: 0.5s;
}

.box-face:hover::before {
    left: 100%;
}

.box-face img {
    height: 120px;
    width: 120px;
    color: var(--light);
    opacity: 0.8;
}

.box-front {
    transform: translateZ(175px);
    background: rgba(106, 17, 203, 0.1);
}

.box-back {
    transform: rotateY(180deg) translateZ(175px);
    background: rgba(37, 117, 252, 0.1);
}

.box-right {
    transform: rotateY(90deg) translateZ(175px);
    background: rgba(255, 123, 37, 0.1);
}

.box-left {
    transform: rotateY(-90deg) translateZ(175px);
    background: rgba(255, 77, 125, 0.1);
}

.box-top {
    transform: rotateX(90deg) translateZ(175px);
    background: rgba(46, 204, 113, 0.1);
}

.box-bottom {
    transform: rotateX(-90deg) translateZ(175px);
    background: rgba(255, 212, 0, 0.1);
}

@keyframes rotate {
    0% {
        transform: rotateX(0) rotateY(0) scale(0.9);
    }

    100% {
        transform: rotateX(360deg) rotateY(360deg) scale(0.9);
    }
}


/* Services Section */
.services {
    padding: 100px 10%;
    background: var(--light);
    color: var(--black);

}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 36px;
    margin-bottom: 15px;
}

.section-title h2 span {
    color: var(--primary);
}

.section-title p {
    max-width: 700px;
    margin: 0 auto;
    opacity: 0.8;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    width: auto;
    background: rgba(16, 7, 7, 0.05);
    border-radius: 15px;
    padding: 40px 30px;

    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid rgba(214, 214, 214, 0.1);
    transform-style: preserve-3d;
    transform: perspective(1000px);
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-10px) perspective(1000px) rotateX(5deg) rotateY(5deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    background: rgba(108, 92, 231, 0.1);
    border-color: var(--primary);
}

.service-icon {
    width: 80px;
    height: 80px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 25px;
    font-size: 32px;
    color: var(--primary);
    transition: all 0.3s ease;
}

.service-card:hover .service-icon {
    background: var(--primary);
    color: var(--light);
    transform: rotateY(180deg);
}

.service-card h3 {
    font-size: 22px;
    margin-bottom: 15px;
}

.service-card p {
    opacity: 0.8;
    margin-bottom: 20px;
}

/* Portfolio Section */
.portfolio {
    padding: 50px 3%;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.portfolio-grid a {
    text-decoration: none;
    color: var(--light);
}

/* Portfolio Item */
.portfolio-item {
    border-radius: 15px;
    overflow: hidden;
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    transform-style: preserve-3d;
    perspective: 1000px;
    background-size: cover;
    background-position: center;
}

.portfolio-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 30px;
    transform: translateZ(30px);
    transition: all 0.5s ease;
}

.portfolio-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary);
    opacity: 0;
    transition: all 0.5s ease;
    mix-blend-mode: multiply;
}

.portfolio-item:hover::before {
    opacity: 0.9;
    background: linear-gradient(to top, rgba(0, 0, 0, 1), transparent);
}

.portfolio-item:hover .portfolio-content {
    transform: translateZ(50px);
}

.portfolio-item h3 {
    font-size: 22px;
    margin-bottom: 10px;
    transform: translateY(20px);
    transition: all 0.5s ease;
    opacity: 0;
}

.portfolio-item:hover h3 {
    transform: translateY(0);
    opacity: 1;
}

/* Portfolio Section images */
#thumbnail-3d {
    background-image: url(/Image/portfolio/cover/Scrap\ Revolver.webp);
    background-size: cover;
}

#thumbnail-Graphic {
    background-image: url(/Image/portfolio/cover/Packaging\ Design.webp);
    background-size: cover;
}

#thumbnail-uiux {
    background-image: url(/Image/portfolio/cover/Go\ Saudi\ Go.webp);
    background-size: cover;
}

#thumbnail-web {
    background-image: url(/Image/portfolio/cover/Sysilscorp.webp);
    background-size: cover;
}

#thumbnail-social {
    background-image: url(/Image/portfolio/cover/Social\ Media.webp);
    background-size: cover;
}

#thumbnail-3d-printing {
    background-image: url(/Image/portfolio/cover/3D\ Printing\ Ready\ Models.webp);
    background-size: cover;
}

/* ===== Testimonials Section ===== */
.testimonials {
    background: var(--light);
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    justify-content: center;
    align-items: start;
    padding: 0 50px 0 50px;
    align-items: stretch;
    
}

/* ===== Testimonial Card ===== */
.testimonial-card {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    position: relative;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: 0.3s;
    margin-top: 50px;
    display: flex;          
    flex-direction: column; 
    justify-content: space-between;
    height: 90%;           
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.profile {
    display: flex;
    align-items: center;
    gap: 10px;
}

.profile img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    object-fit: cover;
}

.author-name {
    font-size: 17px;
    font-weight: 600;
    color: #000;
    white-space: nowrap;
}

.stars img {
    width: 180px;
    height: auto;
    display: block;
}

.review-text {
    color: #555;
    font-size: 15px;
    line-height: 1.7;
    margin: 15px 0 20px;
}

.trustpilot-logo img {
    width: 140px;
    height: auto;
    display: block;
}


/* Contact Section */
.contact-section {
    padding: 100px 10%;
    background: var(--light);
    color: var(--black);
}

.contact-container {
    display: flex;
    gap: 50px;
    max-width: 1200px;
    margin: 0 auto;
}

.contact-info {
    flex: 1;
}

.contact-info h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.contact-info p {
    margin-bottom: 40px;
    opacity: 0.8;
}

.info-items {
    margin-bottom: 40px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 30px;
}

.info-icon {
    width: 50px;
    height: 50px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 20px;
    font-size: 20px;
    color: var(--primary);
    flex-shrink: 0;
}

.info-content h3 {
    font-size: 20px;
    margin-bottom: 5px;
}

.info-content p {
    margin: 0;
    opacity: 0.8;
    font-size: 16px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgb(89, 0, 255);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 18px;
    transition: all 0.3s ease;
}




.social-link:hover {
    background: var(--primary);
    transform: translateY(-5px);
}

.contact-form {
    flex: 1;
    background: rgba(16, 7, 7, 0.05);
    color: var(--black);
    padding: 40px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-form h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.contact-form h2 span {
    color: var(--primary);
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 15px;
    background: var(--light);
    border: 1px solid var(--light);
    border-radius: 8px;
    color: var(--black);
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.1);
    color: var(--black);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

.error-message {
    color: var(--black);
    font-size: 14px;
    margin-top: 5px;
    display: none;
}

.contact-form button {
    background-color: var(--primary);
    color: var(--light);
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contact-form button .btn-icon {
    transform: translateX(0);
    transition: all 0.3s ease;
}

.contact-form button:hover .btn-icon {
    transform: translateX(5px);
}

/* profile-online whatsapp link  */
.profile-online {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    transition: all 0.5s ease;
    transform-style: preserve-3d;
    perspective: 1000px;
    border: 3px solid transparent;
    position: fixed;
    right: 20px;
    bottom: 125px;
}

.profile-online img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    transition: all 0.5s ease;
}

.profile-online:hover {
    transform: translateY(-10px) rotateX(5deg) rotateY(5deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: #25D366;
}

.profile-online:hover img {
    transform: scale(1.05) rotateY(5deg);
    filter: brightness(1.1);
}

/* zoom metting  */
.zoom-meet-btn {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    transition: all 0.5s ease;
    transform-style: preserve-3d;
    perspective: 1000px;
    border: 3px solid transparent;
    position: fixed;
    right: 20px;
    bottom: 20px;
}

.zoom-meet-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    transition: all 0.5s ease;
}

.zoom-meet-btn:hover {
    transform: translateY(-10px) rotateX(5deg) rotateY(5deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: #25D366;
}

.zoom-meet-btn:hover img {
    transform: scale(1.05) rotateY(5deg);
    filter: brightness(1.1);
}

/* Footer */
footer {
    background-image: url(/Image/Web_Footer.png);
    background-size: cover;
    padding: 50px 10% 20px;
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--light);
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--light);
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(225, 0, 0, 0.05);
    border-radius: 50%;
    text-decoration: none;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 18px;
    color: var(--light);
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--light);
    color: var(--primary);
    transform: translateY(-5px);
}

.copyright {
    opacity: 0.7;
    font-size: 14px;
}

/* Screen popup */

/* Popup styles */
.popup {
    display: none;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    overflow-y: scroll;
}

.popup-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 0;
}

.popup-content img {
    width: 100%;
    height: auto;
    max-width: none;
    object-fit: contain;
    margin: 20px 0;
}

.close-btn {
    position: fixed;
    top: 20px;
    right: 30px;
    font-size: 30px;
    color: white;
    cursor: pointer;
    font-weight: bold;
}

/* Responsive Styles */

@media (min-width: 1400px) {
    .services-grid {
        grid-template-columns: 1fr 1fr 1fr;
    }

}

@media (max-width: 1340px) {
    .hero-3d {
        display: none;
    }
}
@media (max-width: 1200px) {
        .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
        /* 2 columns on tablet */
    }
        .testimonials {
        grid-template-columns: repeat(2, 1fr);
        padding: 0 30px 0 30px;
    }
}

@media (max-width: 992px) {
    header {
        padding: 14px 6%;
    }

    .nav-links {
        gap: 30px;
    }

    .contact-btn a {
        padding: 10px 22px;
        font-size: 15px;
    }

    .arrow-circle {
        width: 40px;
        height: 40px;
    }

    .boxel-box {
        display: none;
    }

    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 150px;
        height: auto;
    }

    .hero-content {
        margin-bottom: 50px;
    }

    .hero-3d {
        position: relative;
        right: auto;
        margin-bottom: 50px;
    }

    .about {
        flex-direction: column;
    }

    .about-3d {
        margin-top: 50px;
    }

    .contact-container {
        flex-direction: column;
    }

    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
        /* 2 columns on tablet */
    }

    .testimonials {
        grid-template-columns: repeat(2, 1fr);
    }

    #testimonial-card-3 {
        margin-top: 0;
    }
}

/* --- Mobile (max 860px) --- */
@media (max-width: 860px) {
    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: rgba(0, 0, 0, 0.90);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 30px;
        transition: all 0.5s ease;
    }

    .nav-links a {
        color: var(--light);
        position: relative;
        left: 1px;
    }

    .nav-links.active {
        left: 0;
    }

    .contact-btn {
        display: none;
    }

    .nav-links a {
        font-size: 20px;
    }

    #contact-us-a {
        display: block;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: rgba(0, 0, 0, 0.90);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 30px;
        transition: all 0.5s ease;
    }

    .nav-links a {
        color: var(--light);
        position: relative;
        left: 1px;
    }

    .nav-links.active {
        left: 0;
    }

    .logo {
        position: relative;
        right: 10%;
    }

    #contact-us-a {
        display: block;
    }

    .hero {
        background-image: url(/Image/mobile_Banner.png);
    }

    .hero h1 {
        font-size: 36px;
    }

    .hero-3d {
        height: 0%;
        width: 0%;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .testimonials {
        grid-template-columns: 1fr;
    }

    #testimonial-card-2 {
        margin-top: 0;
    }

    /* footer */

    footer {
        background-image: url(/Image/footer\ mobile.png);
        background-size: cover;
    }

    .hero-3d {
        display: none;

    }
}

@media (max-width: 576px) {
    .hero h1 {
        font-size: 32px;
    }

    .hero p {
        font-size: 16px;
    }

    .section-title h2 {
        font-size: 28px;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    #contact-us-a {
        display: block;
    }
}

/* --- Small Mobile (max 480px) --- */
@media (max-width: 480px) {
    .logo img {
        height: 38px;
    }

    .nav-links a {
        font-size: 18px;
    }

    #contact-us-a {
        display: block;
    }
}