/* --- ตั้งค่าพื้นฐาน --- */
:root {
    --primary-color: #ff5722;
    --text-dark: #333;
    --text-light: #777;
    --bg-light: #f5f6fa;
}
body {
    font-family: 'Prompt', sans-serif;
    margin: 0;
    background-color: var(--bg-light);
    color: var(--text-dark);
    scroll-behavior: smooth; /* ทำให้การเลื่อนหน้าเว็บนุ่มนวล */
}
a { text-decoration: none; color: inherit; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* --- แถบนำทาง (Navbar) --- */
nav {
    background-color: white;
    padding: 15px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}
.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo { font-size: 24px; font-weight: 700; color: var(--primary-color); }
.menu { display: flex; gap: 20px; }
.menu a { font-weight: 500; transition: color 0.3s; }
.menu a:hover { color: var(--primary-color); }

/* --- ส่วนหัว (Hero & Search) --- */
.hero {
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('https://images.unsplash.com/photo-1504674900247-0877df9cc836?ixlib=rb-1.2.1&auto=format&fit=crop&w=1920&q=80') center/cover;
    color: white;
    text-align: center;
    padding: 80px 20px;
}
.hero h1 { font-size: 36px; margin-bottom: 10px; }
.hero p { font-size: 18px; margin-bottom: 30px; font-weight: 300; }

.search-box {
    display: flex;
    max-width: 600px;
    margin: 0 auto;
    background: white;
    border-radius: 50px;
    overflow: hidden;
    padding: 5px;
}
.search-box input {
    flex: 1;
    padding: 15px 25px;
    border: none;
    outline: none;
    font-size: 16px;
    font-family: 'Prompt', sans-serif;
}
.search-box button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0 30px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 16px;
    font-family: 'Prompt', sans-serif;
    font-weight: 600;
}

/* --- หมวดหมู่อาหาร (Categories) --- */
.categories {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: -25px auto 30px;
    flex-wrap: wrap;
}
.cat-btn {
    background: white;
    border: 1px solid #ddd;
    padding: 12px 25px;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    font-family: 'Prompt', sans-serif;
    font-weight: 500;
    transition: all 0.2s;
}
.cat-btn.active, .cat-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* --- หัวข้อ Section --- */
.section-title {
    font-size: 24px;
    border-left: 5px solid var(--primary-color);
    padding-left: 15px;
    margin: 40px 0 20px;
}

/* --- การ์ดบทความ (Articles Grid) --- */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}
.article-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.article-card img { width: 100%; height: 160px; object-fit: cover; }
.article-info { padding: 15px; }
.article-info h4 { margin: 0 0 10px; font-size: 16px; line-height: 1.4; }
.article-info .date { font-size: 12px; color: var(--text-light); }

/* --- การ์ดร้านอาหาร (Restaurant Grid) --- */
.restaurant-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 60px;
}
.res-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: relative;
}
.res-card img { width: 100%; height: 200px; object-fit: cover; }
.rating-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.8);
    color: #ffd700;
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: 600;
    font-size: 14px;
}
.res-info { padding: 20px; }
.res-info .type { color: var(--primary-color); font-size: 13px; font-weight: 600; }
.res-info h3 { margin: 5px 0 10px; font-size: 18px; }
.res-info p { margin: 0; color: var(--text-light); font-size: 14px; line-height: 1.5; }

.no-result { grid-column: 1 / -1; text-align: center; padding: 40px; color: var(--text-light); }

/* --- ส่วน About & Social --- */
.about-section {
    background-color: white;
    padding: 60px 20px;
    text-align: center;
    border-top: 1px solid #eaeaea;
}
.about-section h2 { margin-top: 0; color: var(--text-dark); }
.about-section p { color: var(--text-light); max-width: 600px; margin: 0 auto 30px; line-height: 1.6; }

.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
}
.social-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    color: white;
    font-size: 24px;
    transition: transform 0.3s;
}
.social-btn:hover { transform: translateY(-5px); }

/* สีของแต่ละแพลตฟอร์ม */
.btn-facebook { background-color: #1877F2; }
.btn-instagram { background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.btn-tiktok { background-color: #000000; }

footer {
    background-color: #2d3436;
    color: #b2bec3;
    text-align: center;
    padding: 20px;
    font-size: 14px;
}