/* ================= RESET ================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

/* ================= BODY ================= */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ================= HEADER ================= */
/* DEFAULT HEADER (SEMUA PAGE selain index) */
header {
    background: rgba(212, 212, 212, 0.3);
    backdrop-filter: blur(2px);
    color: #0a2d52;
    padding: 20px 40px;
    height: 125px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

/* HEADER KHAS UNTUK INDEX SAHAJA */
body.home header {
    background: rgba(212, 212, 212, 0.3);
    backdrop-filter: blur(4px);
    color: #0a2d52;
    padding: 20px 40px;
    height: 125px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
    font-size: 14px;
  
    margin-right: 25px;
}

nav ul li a {
    color: rgb(10, 45, 82);
    text-decoration: none;
}

nav ul li a:hover {
    color: #d58413;
}

/* ================= LOGO ================= */
.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo img {
    height: 75px;
    filter: drop-shadow(1px 1px 1.5px rgba(212, 224, 254, 0.349));

}

.logo span {
    font-size: 50px;
    font-weight: bold;
    text-shadow: 1px 1px 1px #0a2d52;
}

/* ================= HERO ================= */
.hero {
    position: relative;
    height: 150vh;
    overflow: hidden;
    padding-top: 20px;
}

/* SLIDESHOW IMAGE */
.slideshow {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
}

.slideshow img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 1.5s ease-in-out;
}

/* DARK OVERLAY HERO*/
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1;
}

/* TEXT HERO*/
.hero-text {
    position: relative;
    z-index: 2;
    color: white;
    text-align: center;
    top: 50%;
    transform: translateY(-50%);
    padding: 0 20px;
}

.hero-text h2 {
    font-size: 48px;
    margin-bottom: 10px;
}

.hero-text p {
    font-size: 18px;
    margin: 5px 0;
}

/* ================= FOOTER ALL PAGE ================= */
.footer {
    background-color: #0a2d52;
    color: #f8ca8a;
    padding: 50px 20px 20px;
}

/* TOP CENTER */
.footer-top {
    text-align: center;
    margin-bottom: 40px;
}

.footer-top h3 {
    font-size: 25px;
    margin-bottom: 10px;
}

/* FLEX 2 COLUMN */
.footer-container {
    max-width: 1100px;
    text-align: center;
    margin: auto;
    display: flex;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
    font-size: 15px;
}

/* LEFT & RIGHT */
.footer-left,
.footer-right {
    flex: 1;
    min-width: 300px;
}

/* TEXT */
.footer p {
    margin-bottom: 10px;
    line-height: 1.6;
}

/* SOCIAL ICON */
.social-icons {
    margin-top: 10px;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-right: 10px;
    border-radius: 50%;
    background: white;
    color: #0a2d52;
    font-size: 16px;
    text-decoration: none;
    transition: 0.3s;
}

/* Hover effect */
.social-icons a:hover {
    transform: translateY(-3px);
}

.social-icons a:nth-child(1):hover {
    background: #1877f2; /* Facebook */
    color: white;
}

.social-icons a:nth-child(2):hover {
    background: #e1306c; /* Instagram */
    color: white;
}

.social-icons a:nth-child(3):hover {
    background: #0077b5; /* LinkedIn */
    color: white;
}

/* QR */
.qr-section img {
    width: 70px;
    margin: 5px;
}

/* BOTTOM */
.footer-bottom {
    text-align: center;
    margin-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.3);
    padding-top: 10px;
    font-size: 14px;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 768px) {

    header {
        flex-direction: column;
        height: auto;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }

    .hero-text h2 {
        font-size: 28px;
    }
}

/* ================= PAGE HERO (ABOUT) ================= */
.page-hero {
    height: 500px;

    background: linear-gradient(rgba(0, 0, 0, 0.403), rgba(0, 0, 0, 0.49)),
                url("../images/SYIL-CNC.jpg");

    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    text-align: center;
    color: white;
}


/* BOX STYLE */
.about-box {
    max-width: 900px;
    width: 100%;
    background: white;
    padding: 30px;
    margin-bottom: 25px;
    border-left: 5px solid #ff3b3b;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: 0.3s;
}

.about-box:hover {
    transform: translateY(-5px);
}

/* TEXT */
.about-box h2 {
    color: #004080;
    margin-bottom: 15px;
}

.about-box p {
    line-height: 1.7;
    color: #333;
}

/* ================= ABOUT SECTION (BACKGROUND MACHINE) ================= */
.about-section {
    padding: 80px 20px;
    background: #fffcf6; /* plain grey background */

    display: flex;
    justify-content: center;
    align-items: center;
}

/* CARD CENTER */
.about-card {
    max-width: 900px;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    padding: 50px 40px;
    border-radius: 12px;

    text-align: center;

    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* TITLE */
.about-card h2 {
    color: #FFAA33;
    margin-bottom: 20px;
}

/* SUBTITLE */
.about-card h3 {
    margin-top: 25px;
    color: #FFAA33;
}

/* TEXT */
.about-card p {
    line-height: 1.8;
    color: #333;
    margin-bottom: 10px;
}

.page-hero h1::after {
    content: "";
    display: block;
    width: 60px;
    height: 3px;
    background: #FFAA33;
    margin: 10px auto;
}

.about-section {
    margin-top: -50px;
}


/* ================= CONTACT SECTION ================= */
.contact-section {
    padding: 80px 20px 60px; /* fix: remove over padding */
    background: #f4f6f9;
}

.contact-container {
    max-width: 1100px;
    margin: auto;
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
    margin-bottom: 30px; /* fix spacing supaya tak langgar footer */
}

.contact-info {
    flex: 1;
    min-width: 280px;
}

/* TITLE BIG */
.contact-info .title {
    font-size: 28px;
    color: #004080;
    margin-bottom: 5px;
}

/* SUBTITLE SMALL */
.contact-info .subtitle {
    font-size: 16px;
    font-weight: 400;
    color: #777;
    margin-bottom: 25px;
}

.contact-info h2 {
    color: #004080;
    margin-bottom: 20px;
}

.contact-info p {
    margin-bottom: 15px;
    line-height: 1.6;
}

/* RIGHT FORM */
.contact-form {
    flex: 1;
    min-width: 280px;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.contact-form h2 {
    margin-bottom: 20px;
    color: #004080;
}

/* INPUT */
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
}

/* ================= MAP SECTION (CENTERED + SPACED) ================= */
.map-section {
    width: 100%;
    padding: 80px 20px;
    background: #f4f6f9;
    display: flex;
    justify-content: center;
}

.map-section iframe {
    width: 100%;
    max-width: 1100px;
    height: 420px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.contact-grid {
    display: flex;
    flex-direction: column;
}

/* GROUP 2 COLUMN */
.form-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

/* INPUT STYLE */
.contact-grid input,
.contact-grid select,
.contact-grid textarea {
    width: 100%;
    padding: 12px;

    border: 1px solid #ddd;
    border-radius: 6px;

    font-size: 14px;
    background: #fff;
}

/* TEXTAREA FULL WIDTH */
.contact-grid textarea {
    margin-bottom: 15px;
    resize: none;
}

/* BUTTON */
.contact-grid button {
    background: #004080;
    color: white;
    padding: 14px;
    border: none;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.contact-grid button:hover {
    background: #e69500;
}

/* MOBILE RESPONSIVE */
@media (max-width: 768px) {
    .form-group {
        grid-template-columns: 1fr;
    }
}

footer {
    width: 100%;
    display: block;
    clear: both;
}

.contact-section {
    padding: 80px 20px 120px; /* tambah bottom padding */
    background: #f4f6f9;
}

.contact-container {
    margin-bottom: 50px;
}

html, body {
    width: 100%;
    overflow-x: hidden;
}

/* ================= EVENTS ================= */
.events-section {
    padding: 80px 20px;
    background: #fafbfd;

    display: flex;
    justify-content: center;
    align-items: center;
}

/* CARD */
.events-card {
    max-width: 900px;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    padding: 80px 40px;
    border-radius: 12px;

    text-align: center;

    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* TITLE */
.events-card h1 {
    font-size: 80px;
    color: #004080;
    font-weight: 900;
}

/* TEXT */
.events-card p {
    margin-top: 15px;
    font-size: 18px;
    color: #555;
}

.events-card h1 {
    font-size: 80px;
    color: #004080;
    font-weight: 900;
    letter-spacing: 5px;

    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* ================= CAREER FIXED (PROPER LAYOUT) ================= */

.career-section {
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
    padding: 40px 20px;
}

.career-section h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 15px;
}

.career-section p {
    font-size: 18px;
    line-height: 1.6;
}

/* CAREER CARD */

.career-card {
    max-width: 500px;
    margin: 40px auto;
    background: #e8b379;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
}

.career-card h3 {
    margin-bottom: 10px;
    font-size: 20px;
}

.career-card p {
    margin: 5px 0;
    font-size: 16px;
}

/* ================= DROPDOWN ================= */

/* IMPORTANT: fix flex issue */
nav > ul {
    display: flex;
    gap: 20px;
    list-style: none;
}

.dropdown {
    position: relative;
}

/* dropdown box */
.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;

    background: #0a2d52;
    width: 260px;

    list-style: none;
    padding: 10px 0;
}

/* item jadi vertical */
.dropdown-menu li {
    display: block;
}

/* full clickable */
.dropdown-menu li a {
    display: block;
    padding: 12px 20px;
    color: #de942c;
}

/* hover */
.dropdown-menu li:hover {
    background: #ccc;
}

/* show dropdown */
.dropdown:hover .dropdown-menu {
    display: block;
}

/* ================= PRODUCT PAGE ================= */

.product-section {
    padding: 80px 20px;
    background: #f5f7fa;

    display: flex;
    flex-direction: column;
    gap: 40px;

    max-width: 1000px;
    margin: auto;
}

/* CARD */
.product-card {
    display: flex;
    gap: 30px;

    background: white;
    padding: 25px;
    border-radius: 12px;

    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    align-items: center;
}

/* IMAGE */
.product-card img {
    width: 300px;
    border-radius: 10px;
}

/* INFO */
.product-info {
    flex: 1;
}

.product-info h2 {
    color: #004080;
    margin-bottom: 10px;
}

.product-info p {
    margin-bottom: 10px;
    color: #555;
}

/* SPEC LIST */
.product-info ul {
    padding-left: 20px;
}

.product-info li {
    margin-bottom: 5px;
}

/* MOBILE */
@media (max-width: 768px) {
    .product-card {
        flex-direction: column;
        text-align: center;
    }

    .product-card img {
        width: 100%;
    }
}

/* ================= PRODUCTS VIDEO + CARD ================= */

.products-section {
    padding: 120px 20px 80px;
    max-width: 1100px;
    margin: auto;
}

/* TITLE */
.section-title {
    text-align: center;
    font-size: 40px;
    color: #004080;
    margin-bottom: 40px;
}

/* VIDEO */
.video-container {
    display: center;
    width: 55%;
    margin-bottom: 35px;
    margin-top: 35px;
    margin-left: 33%; 
}

.video-container iframe {
    display: center;
    width: 55%;
    height: 255px;
    border-radius: 8px;
}


/* CARD GRID */
.product-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

/* CARD */
.card {
    background: rgb(235, 187, 128);
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 35px;
    margin-left: 10px;
    margin-right: 10px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.31);
    transition: 0.3s;
}

.card:hover {
    transform: translateY(-5px);
}

/* TITLE */
.card h3 {
    color: #004080;
    margin-bottom: 10px;
}

/* TEXT */
.card p {
    font-size: 14px;
    color: #555;
    margin-bottom: 15px;
}

/* LINK */
.card a {
    text-decoration: none;
    color: #004080;
    font-weight: bold;
}

.card a:hover {
    color: #e69500;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .product-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .product-cards {
        grid-template-columns: 1fr;
    }

    .video-container iframe {
        height: 250px;
    }
}

.products-section {
    padding: 80px 20px;
    background: #f5f7fa;

    display: grid; /* tukar dari flex */
    grid-template-columns: repeat(2, 1fr); /* 2 column */
    gap: 30px;

    max-width: 1100px;
    margin: auto;
}

.products-card {
    display: grid;
    flex-direction: column; /* susun atas bawah */
    text-align: center;

    background: white;
    padding: 25px;
    border-radius: 12px;

    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.products-card img {
    width: 100%;
    max-width: 250px;
    margin: auto;
    border-radius: 10px;
}

@media (max-width: 768px) {
    .product-section {
        grid-template-columns: 1fr; /* jadi 1 column */
    }
}

.machine-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 2 column */
    gap: 30px;
}

.machine-card {
    display: flex;
    gap: 15px;
    align-items: center;
    margin-top: 30px;
    margin-left: 20px;
    margin-right: 20px;
    margin-bottom: 30px;
    background: white;
    padding: 20px;
    border-radius: 10px;

    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.338);
}

/* kecilkan imej */
.machine-card img {
    width: 250px;
    border-radius: 10px;
}

@media (max-width: 768px) {
    .machine-grid {
        grid-template-columns: 1fr;
    }

    .machine-card {
        flex-direction: column;
        text-align: center;
    }

    .machine-card img {
        width: 100%;
    }
}

.machine-card {
    transition: 0.3s;
}

.machine-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.2);
}