/* (L)TravelCal - v0.40.3 - Classic Style Restoration */

:root {
    --primary: #E3193F; /* 經典紅 */
    --bg: #050505; 
    --card: #141414;
    --text: #FFFFFF; 
    --text-dim: #8E8E93; 
    --border: #2C2C2E;
    --savings: #4CD964;
}

body { 
    background-color: var(--bg); 
    color: var(--text); 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; 
    margin: 0; 
    padding: 0; 
    overflow-x: hidden; 
}

/* 頂部橫幅 Banner */
.app-banner {
    width: 100%; height: 260px; 
    background-image: url('banner.jpg'); /* 如果無圖，會顯示背景色 */
    background-color: #1a1a1a;
    background-size: cover; 
    background-position: center; 
    position: relative;
}

.banner-overlay {
    position: absolute; bottom: 0; left: 0; right: 0; padding: 40px 20px;
    background: linear-gradient(to top, #050505 15%, rgba(5,5,5,0.6) 50%, transparent 100%);
}

.banner-overlay h1 { font-size: 32px; font-weight: 800; margin: 0; text-shadow: 0 4px 15px rgba(0,0,0,0.9); }
.banner-overlay p { font-size: 13px; color: var(--text-dim); margin-top: 5px; }

.logout-btn-top {
    position: absolute; top: 20px; right: 20px; background: rgba(0,0,0,0.4);
    border: none; color: white; padding: 8px; border-radius: 50%; cursor: pointer;
    backdrop-filter: blur(5px);
}

/* 容器與卡片 */
.app-container { 
    max-width: 500px; 
    margin: -30px auto 0; 
    position: relative; 
    z-index: 2; 
    padding: 0 16px 140px; 
    box-sizing: border-box; 
}

.card { 
    background: var(--card); 
    border-radius: 18px; 
    padding: 18px; 
    margin-bottom: 12px; 
    border: 1px solid var(--border); 
}

.card-header { display: flex; align-items: center; gap: 8px; margin-bottom: 15px; }
.card-header label { font-size: 11px; font-weight: 700; color: var(--text-dim); text-transform: uppercase; letter-spacing: 1px; }

/* 輸入控制項 */
.node-input, input[type="datetime-local"], select {
    width: 100%; background: #1C1C1E; border: 1px solid var(--border); border-radius: 12px;
    padding: 12px; color: white; font-size: 14px; box-sizing: border-box; color-scheme: dark; margin-bottom: 8px;
    outline: none;
}
.node-input:focus { border-color: var(--primary); }

.setting-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.setting-item span { font-size: 13px; color: var(--text-dim); white-space: nowrap; min-width: 65px; }

/* 按鈕樣式 */
.action-row { display: flex; gap: 10px; margin-top: 10px; }
.secondary-btn {
    flex: 1; height: 44px; background: #2C2C2E; color: white; border: none;
    border-radius: 12px; font-size: 13px; display: flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer;
}
.secondary-btn.active { background: #2C1014; color: var(--primary); border: 1px solid var(--primary); }

/* 隧道按鈕網格 */
.tunnel-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.t-btn {
    background: #1C1C1E; border: 1px solid var(--border);
    padding: 12px 4px; border-radius: 10px; color: #EEE; font-size: 11px; text-align: center; cursor: pointer;
}
.t-btn.active { background: #2C1014; border-color: var(--primary); color: var(--primary); font-weight: bold; }

/* 地圖顯示 */
#map { 
    height: 0; width: 100%; border-radius: 16px; margin: 0; 
    border: none; transition: height 0.4s ease; overflow: hidden;
}
#map.active { height: 280px; margin: 15px 0; border: 1px solid var(--border); }

/* 數據網格 */
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.stat-card { background: var(--card); padding: 15px; border-radius: 16px; border: 1px solid var(--border); text-align: center; }
.stat-card span { display: block; font-size: 10px; color: var(--text-dim); text-transform: uppercase; }
.stat-card b { font-size: 18px; font-weight: 700; }

/* 底部導航區 - 恢復左對齊 */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; right: 0;
    background: rgba(10, 10, 10, 0.98); backdrop-filter: blur(25px);
    border-top: 1px solid var(--border); padding: 12px 16px 35px; z-index: 100;
}
.nav-content { max-width: 460px; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; }

.total-display-group { flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; }
.label-top { font-size: 10px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.5px; }
.main-currency { font-size: 26px; font-weight: 900; color: var(--primary); line-height: 1.1; }

.primary-btn { 
    padding: 12px 24px; background: var(--primary); color: white; 
    border: none; border-radius: 12px; font-weight: bold; font-size: 14px; cursor: pointer;
}

/* 輔助類別 */
.conditional-show { display: none !important; }
.conditional-show.visible { display: block !important; }