/* 通用樣式 */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f7fa;
    color: #333;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 20px auto;
    text-align: center;
}

/* 搜尋區樣式 */
.search-section {
    margin-bottom: 40px;
}

.search-section h1 {
    font-size: 2rem;
    color: #3498db;
    margin-bottom: 20px;
}

.search-bar {
    display: flex;
    justify-content: center;
    gap: 10px;
}

#stock-input {
    width: 300px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

#search-button {
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

#addStock-button {
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

/* 靜態指標樣式 */
#key-indicators {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 30px;
}

#current-date {
    margin-top: 30px;
    font-size: 1rem;
    color: #666;
    font-style: bold;
}


.indicator-card {
    flex: 1;
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.indicator-card h3 {
    margin: 0;
    font-size: 1rem;
    color: #333;
}

.indicator-card p {
    margin: 5px 0 0;
    font-size: 1.5rem;
    font-weight: bold;
    color: #3498db;
}

/* 圖表展示區樣式 */
.tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
}

.tab-button {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    background-color: #f1f1f1;
    font-size: 1rem;
    color: #333;
}

.tab-button.active {
    background-color: #3498db;
    color: white;
}

.tab-content {
    position: relative;
    /* width: 100%; */
    /* height: 100px; */
    width: 80%;            /* 設置寬度，例如 80% */
    max-width: 900px;      /* 設置最大寬度 */
    height: auto;          /* 自動調整高度 */
    margin: 0 auto;        /* 保持居中 */
}

.tab {
    display: none;
    width: 100%;
    height: 100%;
}

.tab.active {
    display: block;
}

/* 響應式樣式 */
@media (max-width: 768px) {
    #key-indicators {
        flex-direction: column;
    }
}
