/*
Theme Name: BandRoom 香港排練室
Theme URI: http://band.uhom.net/
Author: Your Name
Description: 針對Band房、鼓房、練習室的預訂網站主題
Version: 1.0
*/

/* ===== 全局變數 ===== */
:root {
    --bg-body: #F4F6F9;
    --bg-card: #FFFFFF;
    --bg-dark-section: #2C3E50;
    --bg-footer: #1F2A36;
    --white: #FFFFFF;
    --primary: #FF6B4A;
    --primary-hover: #E55A3A;
    --secondary: #5B6C84;
    --accent: #8E44AD;
    --text-dark: #2C3E50;
    --text-light: #F4F6F9;
    --text-muted: #7B8A9B;
    --link-color: #FF6B4A;
    --border-light: #E1E8EF;
    --shadow: 0 2px 8px rgba(0,0,0,0.06);
    --success: #27AE60;
    --error: #E74C3C;
}

/* ===== 基礎重置 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Microsoft JhengHei', sans-serif;
    background: var(--bg-body);
    color: var(--text-dark);
    line-height: 1.6;
}

a {
    color: var(--link-color);
    text-decoration: none;
    transition: 0.3s;
}
a:hover {
    color: var(--primary-hover);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.container p {line-height:200%;}
.container li {line-height:200%;}

/* ===== 頭部導航（跨瀏覽器兼容） ===== */
header {
    background: var(--white);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 2px solid var(--primary);
    box-shadow: var(--shadow);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary);
    flex-shrink: 0;
}
.logo span {
    color: var(--text-dark);
}

nav {
    flex-shrink: 0;
}

nav ul {
    list-style: none;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    margin: 0;
    padding: 0;
}

nav ul li {
    flex: 0 0 auto;
    margin: 0 10px;
}
nav ul li:first-child {
    margin-left: 0;
}
nav ul li:last-child {
    margin-right: 0;
}

nav a {
    color: var(--text-dark);
    font-weight: 500;
    padding: 5px 0;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
    display: inline-block;
    transition: 0.3s;
}
nav a:hover {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}
.hamburger div {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    margin: 3px 0;
    transition: 0.3s;
}

/* ===== 下拉選單 ===== */
.menu-list li {
    position: relative;
}
.menu-list ul.sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    min-width: 200px;
    padding: 10px 0;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-radius: 4px;
    z-index: 999;
    list-style: none;
    flex-direction: column;
}
.menu-list ul.sub-menu li {
    margin: 0;
    padding: 0 20px;
    flex: 0 0 auto;
}
.menu-list ul.sub-menu a {
    padding: 8px 0;
    white-space: nowrap;
    border-bottom: none;
    display: block;
}
.menu-list ul.sub-menu a:hover {
    color: var(--primary);
    background: #f5f5f5;
}
.menu-list li:hover > ul.sub-menu {
    display: block;
}
.menu-list li.menu-item-has-children > a::after {
    content: " ▾";
    font-size: 0.8em;
    color: #999;
}
.no-click > a {
    pointer-events: none;
    cursor: default;
}

/*====== 底部 ======*/
/* 针对您的 ul 元素（使用 class 选择器，更稳妥） */
.footer-menu {
  display: flex;                /* 启用 Flex 布局 */
  justify-content: center;      /* 水平居中对齐 */
  align-items: center;          /* 垂直居中（可选） */
  list-style: none;            /* 去除默认圆点 */
  padding: 0;                  /* 清除默认内边距 */
  margin: 0 0 30px 0;                   /* 清除默认外边距 */
}

/* 如果 li 本身还有额外边距，可一并重置 */
.footer-menu li {
  margin: 0 10px;              /* 可选：给每项之间添加间距 */
  /* 不需要额外设置 display，因为 flex 容器内的子项自动成为 flex 项目 */
}
/* ===== 頁面 Hero ===== */
.page-hero {
    background: linear-gradient(rgba(44, 62, 80, 0.8), rgba(44, 62, 80, 0.8)), url('/images/260706.webp');
    background-size: cover;
    background-position: center;
    padding: 100px 20px;
    text-align: center;
    color: var(--white);
}
.page-hero h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--white);
    font-weight: 700;
}
.page-hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
    color: rgba(255,255,255,0.9);
}

/* ===== 按鈕 ===== */
.btn-primary {
    background: var(--primary);
    color: #fff;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    display: inline-block;
    transition: 0.3s;
    text-align: center;
}
.btn-primary:hover {
    background: var(--primary-hover);
}
.btn-secondary {
    background: transparent;
    color: var(--text-dark);
    border: 2px solid var(--secondary);
    padding: 10px 25px;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    display: inline-block;
}
.btn-secondary:hover {
    background: var(--secondary);
    color: var(--white);
    border-color: var(--secondary);
}
.btn-wa {
    background: #25D366;
    color: #fff;
    padding: 12px 30px;
    border-radius: 5px;
    font-weight: bold;
    display: inline-block;
    margin: 10px;
}
.btn-signal {
    background: var(--accent);
    color: #fff;
    padding: 12px 30px;
    border-radius: 5px;
    font-weight: bold;
    display: inline-block;
    margin: 10px;
}

/* ===== 卡片（使用 margin 代替 gap） ===== */
.cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin: -15px;          /* 抵消子元素的 margin */
}
.card {
    background: var(--bg-card);
    border-radius: 10px;
    overflow: hidden;
    width: 300px;
    box-shadow: var(--shadow);
    transition: 0.3s;
    margin: 15px;           /* 每個卡片四周 15px 間距 */
}
.whyus {
    width: 500px;
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.1);
}
.card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}
.card-body {
    padding: 20px;
}
.card-body h3 {
    color: var(--primary);
    margin-bottom: 10px;
}
.card-body p {
    color: var(--text-muted);
}

/* ===== 房間詳情（使用 margin 代替 gap） ===== */
.room-detail {
    display: flex;
    flex-wrap: wrap;
    background: var(--bg-card);
    border-radius: 10px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: var(--shadow);
    align-items: flex-start;  /* 頂部對齊 */
}
.room-detail img {
    width: 100%;
    max-width: 400px;
    border-radius: 10px;
    object-fit: cover;
    margin-right: 30px;      /* 圖片右邊距（相容） */
    margin-bottom: 30px;     /* 換行時的下邊距 */
    flex-shrink: 0;
}
.room-info {
    flex: 1;
    min-width: 200px;
}

.room-info h2 {
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 10px;
}
.room-info ul {
    list-style: none;
    margin: 15px 0;
}
.room-info ul li {
    margin-bottom: 8px;
}

/* ===== 表格 ===== */
.pricing-table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    background: var(--bg-card);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
}
.pricing-table th,
.pricing-table td {
    padding: 15px;
    text-align: center;
    border-bottom: 1px solid var(--border-light);
}
.pricing-table th {
    background: var(--bg-dark-section);
    color: var(--white);
    font-weight: bold;
}
.pricing-table tr:last-child td {
    border-bottom: none;
}

/* 備註框 */
.note {
    background: var(--bg-card);
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--primary);
}

/* ===== 圖集（使用 margin 代替 gap） ===== */
.gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin: -10px;          /* 抵消子元素 margin */
}
.gallery img {
    width: 300px;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
    transition: 0.3s;
    box-shadow: var(--shadow);
    margin: 10px;           /* 四周 10px 間距 */
}
.gallery img:hover {
    transform: scale(1.05);
}

/* ===== 內容塊 ===== */
.content-block {
    background: var(--bg-card);
    border-radius: 10px;
    padding: 30px;
    margin: 30px 0;
    box-shadow: var(--shadow);
}
.content-block h2 {
    color: var(--primary);
    margin: 20px 0 10px;
}

.faq-item {
    margin-bottom: 15px;
}
.faq-question {
    font-weight: bold;
    color: var(--primary);
    cursor: pointer;
}
.faq-answer {
    margin-top: 5px;
    padding-left: 15px;
    border-left: 2px solid var(--accent);
    color: var(--text-muted);
}

/* ===== 頁腳 ===== */
footer {
    background: var(--bg-footer);
    padding: 40px 20px;
    text-align: center;
    color: var(--text-muted);
    border-top: 2px solid var(--primary);
}
footer a {
    color: var(--primary);
}
footer a:hover {
    color: var(--primary-hover);
}

/* 工具類 */
.text-center {
    text-align: center;
}
.mt-3 {
    margin-top: 20px;
}
.section-title {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 40px;
    color: var(--text-dark);
    position: relative;
}
.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--primary);
    margin: 10px auto 0;
}

/* ===== 移動端適配 ===== */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    nav {
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        display: none;
        padding: 20px 0;
        box-shadow: var(--shadow);
        border-top: 1px solid var(--border-light);
        flex-shrink: 1;
    }
    nav.active {
        display: flex;
    }
    nav ul {
        flex-direction: column;
        flex-wrap: nowrap;
        align-items: stretch;
        width: 100%;
    }
    nav ul li {
        margin: 0;
        border-bottom: 1px solid #eee;
        flex: 1 1 auto;
    }
    nav ul li:first-child,
    nav ul li:last-child {
        margin: 0;
    }
    nav a {
        padding: 12px 20px;
        white-space: normal;
        display: block;
        border-bottom: none;
    }

    .menu-list ul.sub-menu {
        position: static;
        box-shadow: none;
        padding-left: 20px;
        background: #f9f9f9;
        display: none;
        border-radius: 0;
        min-width: auto;
    }
    .menu-list ul.sub-menu.open {
        display: block;
    }
    .menu-list ul.sub-menu li {
        padding: 0;
        margin: 0;
    }
    .menu-list ul.sub-menu a {
        padding: 10px 20px;
        white-space: normal;
    }
    .menu-list li.menu-item-has-children > a::after {
        float: right;
        margin-right: 20px;
    }

    /* 移動端 room-detail 圖片取消右邊距，改為下邊距 */
    .room-detail img {
        margin-right: 0;
        margin-bottom: 20px;
        max-width: 100%;
    }
    .room-detail {
        padding: 20px;
    }

    /* 卡片在移動端寬度自動 */
    .card {
        width: 100%;
        max-width: 400px;
        margin: 10px 0;
    }
    .cards {
        margin: 0;
    }
}