/* ==========================================================================
   1. Global Styles & Resets
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background-color: #f7f7f7;
    color: #333;
    padding-top: 110px; /* Offset for fixed header */
    top: 0px !important; /* Fix for Google Translate layout shift */
}

/* ==========================================================================
   2. Fixed Green Header Section
   ========================================================================== */
header {
    background-color: #2e7d32;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 30px;
    max-width: 1300px;
    margin: 0 auto;
}

/* --- Logo and Brand Name --- */
.nav-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.brand-logo {
    width: 55px;
    height: 55px;
    object-fit: cover;
    border: none;
    background: transparent;
}

.brand-title {
    font-size: 24px;
    font-weight: bold;
    color: #ffffff;
    letter-spacing: 0.5px;
}

/* --- Search Bar in the Center --- */
.nav-center {
    flex: 1.5;
    display: flex;
    justify-content: center;
    padding: 0 30px;
}

.search-form {
    position: relative;
    width: 100%;
    max-width: 600px;
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    padding: 11px 18px 11px 45px;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    background-color: #fff;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1);
}

.search-icon {
    position: absolute;
    left: 18px;
    color: #666;
    font-size: 15px;
}

/* --- Right Side Elements (Language Selector, Login, Signup) --- */
.nav-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.lang-container {
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    background: rgba(255, 255, 255, 0.15);
    padding: 6px 10px;
    border-radius: 20px;
}

.lang-select {
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 13px;
    outline: none;
}

.lang-select option {
    color: #333;
}

.btn-login {
    padding: 7px 16px;
    border: 1px solid white;
    color: white;
    background: transparent;
    border-radius: 20px;
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
    transition: background 0.2s;
}

.btn-login:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.btn-signup {
    padding: 7px 16px;
    background-color: #d70f64;
    color: #fff;
    border-radius: 20px;
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
    transition: background 0.2s;
}

.btn-signup:hover {
    background-color: #b00b50;
}

/* ==========================================================================
   3. Sub Navbar Section (Full-width white background, centered items)
   ========================================================================== */
.sub-navbar {
    background-color: #ffffff;
    border-top: 1px solid #e0e0e0;
    width: 100%; /* Stretches white background across full screen width */
    padding: 8px 40px;
    display: flex;
    justify-content: center; /* Center-align navigation items */
    align-items: center;
    gap: 20px; /* Comfortable spacing between items */
}

.sub-nav-item {
    text-decoration: none;
    color: #555;
    font-weight: 600;
    font-size: 14px;
    padding: 6px 14px;
    border-radius: 20px;
    transition: all 0.2s;
}

.sub-nav-item.active, .sub-nav-item:hover {
    background-color: #2e7d32;
    color: #fff;
}

/* --- Partner Dropdown Menu --- */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropbtn {
    background: transparent;
    border: none;
    color: #555; /* 恢复适配白色背景子导航栏的灰色 */
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    padding: 6px 14px;
    border-radius: 20px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.dropbtn:hover {
    background-color: #f1f1f1;
    color: #2e7d32;
}

.dropdown-content {
    display: none;
    position: absolute;
    left: 0;
    top: 100%; /* 保证菜单紧贴着导航栏下方出现 */
    background-color: #ffffff;
    min-width: 220px;
    box-shadow: 0px 8px 24px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    z-index: 1000;
    padding: 8px 0;
    margin-top: 0px; /* 消除物理间隔 */
}

/* 核心桥梁：向上方按钮延伸 10px 隐藏的 Hover 热区，防止移动时瞬间闭合 */
.dropdown-content::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
    background: transparent;
}

.dropdown-content a {
    color: #333333;
    padding: 10px 20px;
    text-decoration: none;
    display: block;
    font-size: 14px;
    white-space: nowrap;
    transition: background 0.2s ease, color 0.2s ease;
}

.dropdown-content a:hover {
    background-color: #f1f8e9; /* 浅绿背景 */
    color: #2e7d32; /* 深绿文字 */
}

.dropdown:hover .dropdown-content {
    display: block;
}

.sub-link-item {
    text-decoration: none;
    color: #555;
    font-weight: 600;
    font-size: 14px;
    padding: 6px 14px;
    border-radius: 20px;
    transition: all 0.2s;
}

.sub-link-item:hover {
    background-color: #f1f1f1;
    color: #2e7d32;
}

/* ==========================================================================
   4. Main Content Area Styles
   ========================================================================== */
.main-content {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 20px;
}

.section-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
}

.cuisines-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.cuisine-card {
    background: white;
    padding: 15px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    cursor: pointer;
    transition: transform 0.2s;
}

.cuisine-card:hover {
    transform: translateY(-5px);
}

.cuisine-card img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    border-radius: 50%;
    margin-bottom: 10px;
}

.cuisine-card span {
    font-size: 14px;
    font-weight: 600;
    color: #d70f64;
}

/* ==========================================================================
   5. Grab-Style Footer Section
   ========================================================================== */
.site-footer {
    background-color: #2e7d32; /* Matches header background color */
    color: #ffffff;
    padding: 40px 30px 20px 30px;
    margin-top: 50px;
    font-size: 14px;
    flex-shrink: 0;
    position: relative;
    z-index: 10;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-layout {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 30px; /* Controls spacing between left brand column and right link columns */
}

/* --- Left Column: Brand, SSM, Address & Contacts --- */
.footer-left-col {
    flex: 1.2;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-logo-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-logo {
    width: 45px;
    height: 45px;
    object-fit: cover;
    border: none;
    background: transparent;
    border-radius: 8px;
}

.footer-company-name {
    font-size: 18px;
    font-weight: bold;
    letter-spacing: 0.5px;
}

.footer-ssm-info p {
    font-size: 13px;
    font-weight: 600;
    opacity: 0.95;
}

.footer-address-block {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 12px; /* Smaller font size for professional address look */
    opacity: 0.9;
    line-height: 1.5;
}

.footer-contact-lines {
    font-size: 12px;
    line-height: 1.6;
}

/* Footer Links: No underline by default, underline on hover */
.footer-address-block a,
.footer-contact-lines a {
    color: #ffffff;
    text-decoration: none;
    transition: opacity 0.2s;
}

.footer-address-block a:hover,
.footer-contact-lines a:hover {
    text-decoration: underline;
    opacity: 1;
}

/* --- Right Columns: Company, Policies, Corporate --- */
.footer-right-cols {
    display: flex;
    gap: 45px; /* Spacing between navigation columns */
    flex-wrap: wrap;
}

.footer-col h4 {
    font-size: 15px;
    margin-bottom: 12px;
    font-weight: bold;
    color: #ffffff;
    letter-spacing: 0.5px;
}

.footer-col ul {
    list-style: none;
    padding: 0;
}

.footer-col ul li {
    margin-bottom: 8px;
}

.footer-col ul li a {
    color: #ffffff;
    text-decoration: none;
    opacity: 0.85;
    font-size: 13px;
    transition: opacity 0.2s;
}

.footer-col ul li a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* --- Bottom Copyright Section --- */
.footer-divider {
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    margin: 30px 0 15px 0;
}

.footer-bottom {
    text-align: center;
    font-size: 12px;
    opacity: 0.8;
}

/* ==========================================================================
   6. Google Translate Widget Overrides & Anti-Tooltip Shield
   ========================================================================== */
.goog-te-banner-frame.skiptranslate,
.skiptranslate > iframe,
iframe.goog-te-banner-frame {
    display: none !important; /* Hide Google Translate top notification banner */
}

.goog-tooltip,
.goog-tooltip:hover,
#goog-gt-tt,
.goog-te-balloon-frame {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.goog-text-highlight {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* --- Sticky Footer Layout Fix --- */
html, body {
    min-height: 100vh;
}

body {
    display: flex;
    flex-direction: column;
}

.main-content {
    flex: 1 0 auto; /* Pushes footer to the bottom when content is short, while expanding naturally */
    width: 100%;
}

/* ==========================================================================
   7. Modern UI Polish & Spacing Fixes
   ========================================================================== */
.content-card {
    background: #ffffff;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    margin-bottom: 50px;
}

.content-card h1.section-title {
    font-size: 28px;
    color: #1b4d2e;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e8f5e9;
}

.content-card h2 {
    font-size: 20px;
    color: #2e7d32;
    margin-top: 25px;
    margin-bottom: 12px;
}

.content-card p, .content-card li {
    font-size: 15px;
    line-height: 1.7;
    color: #444;
    margin-bottom: 12px;
}
/* ==========================================================================
   8. Tab Navigation & Dynamic Content Styles
   ========================================================================== */
.nav-tab { transition: all 0.3s ease; }
.nav-tab:hover:not(.active) { background-color: #f1f1f1; color: #2e7d32; }

/* Grid System for Cards */
.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.card-item {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.2s;
    cursor: pointer;
}
.card-item:hover { transform: translateY(-5px); }
.card-img { width: 100%; height: 150px; object-fit: cover; background: #eee; }
.card-body { padding: 15px; }
.card-title { font-weight: bold; margin-bottom: 5px; color: #222; font-size: 15px; }
.card-meta { font-size: 12px; color: #777; display: flex; justify-content: space-between; align-items: center; }

/* Dietary Tag Active State */
.dietary-tag.active {
    background-color: #2e7d32 !important;
    color: white !important;
    border-color: #2e7d32 !important;
}

/* Voucher Specific Styles */
.voucher-card { border-left: 5px solid #d70f64; }
.code-container {
    background: #f9f9f9;
    border: 1px dashed #ccc;
    padding: 10px;
    border-radius: 6px;
    margin-top: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.copy-btn {
    background: #2e7d32;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: background 0.2s;
}
.copy-btn:hover { background: #1b4d2e; }
.copy-btn.copied { background: #4caf50; }

/* Menu Detail View */
.menu-detail-header {
    display: flex;
    gap: 30px;
    background: white;
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.detail-img { width: 250px; height: 250px; object-fit: cover; border-radius: 12px; }