/* css/layout.css */

/* --- Default Desktop Styles --- */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 40px;
}

.header-inner {
    width: 100%;
    max-width: 1400px;
    display: flex;
    justify-content: space-between; /* กระจาย 3 ส่วน: ซ้าย กลาง ขวา */
    align-items: center;
}

.header-logo {
    font-family: var(--font-tech);
    font-weight: 700;
    letter-spacing: 2px;
    font-size: 1.2rem;
    flex: 1; 
}

.nav-links {
    display: flex;
    justify-content: flex-end;
    gap: 30px;
    align-items: center;
    flex: 1; 
}

.header-toggle {
    flex: 0 1 auto;
}

.header-status {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mobile-menu-btn {
    display: none;
}

/* 🔥 เพิ่ม CSS Footer ตรงนี้ เพื่อให้มันอยู่ตรงกลาง */
.site-footer {
    position: relative; 
    width: 100%;
    /* ลด Padding ลงจาก 40px เหลือ 20px จะได้ไม่ดูสูง/หนาเกินไป */
    padding: 20px 20px; 
    background: rgba(11, 1, 20, 0.95);
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: center;
    text-align: center;
    z-index: 100;
}

.footer-inner {
    max-width: 800px;
    width: 100%;
}

.footer-text {
    /* ลดขนาดตัวหนังสือเล็กน้อย ให้ดู Modern */
    font-size: 0.8rem; 
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 5px;
}

/* --- Mobile Responsive (ต่ำกว่า 992px) --- */
@media (max-width: 992px) {
    .site-header {
        padding: 0 20px;
    }

    .header-status {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
        flex-direction: column;
        gap: 6px;
        background: none;
        border: none;
        cursor: pointer;
        z-index: 1001;
    }

    .mobile-menu-btn span {
        width: 25px;
        height: 2px;
        background-color: var(--electric-blue);
        transition: 0.3s;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%; /* เปลี่ยนเป็น 100% เต็มจอไปเลยในมือถือ */
        height: 100vh;
        background: rgba(11, 1, 20, 0.98);
        flex-direction: column;
        justify-content: center;
        transition: 0.4s ease;
        z-index: 1000; /* ต้องน้อยกว่าปุ่ม (1001) */
    }

    .nav-links.active {
        right: 0;
    }

    /* Animation ปุ่ม Hamburger */
    .mobile-menu-btn.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }
    .mobile-menu-btn.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}

/* ... Style ย่อยอื่นๆ เก็บไว้เหมือนเดิม ... */
.logo-highlight { color: var(--electric-blue); text-shadow: 0 0 10px rgba(0, 180, 216, 0.5); }
.nav-links a { color: rgba(255, 255, 255, 0.7); text-decoration: none; font-size: 0.9rem; transition: 0.3s; }
.nav-links a:hover, .nav-links a.active { color: var(--electric-blue); }
.nav-portal-btn { padding: 6px 16px; border: 1px solid var(--glass-border); border-radius: 4px; transition: 0.3s; }
.nav-portal-btn:hover { background: var(--electric-blue); color: var(--bg-dark) !important; }