/*
 * Updated on: 2025-01-08
 * Description: Enhanced styling for 叶之缘珠宝
 */

/* Base Styles */
body {
    margin: 0;
    padding: 0;
    font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: #f8f8f8;
    color: #333;
    line-height: 1.6;
}

/* Layout */
.div1 {
    width: 100%;
    margin-bottom: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: white;
}

.div1:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.div3 {
    width: 98%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

/* Header Styles */
.div3_1 {
    padding: 10px 0;
    width: 100%;
    min-height: 50px;
    text-align: center;
    background: linear-gradient(135deg, #c12c2a 0%, #a01f1d 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/*
  标题需要在整个 .div3_1 宽度内"绝对居中"，
  不受右侧 div3_1_2（开盘/停盘）宽度影响。
*/
.div3_1_1.div3_1_title {
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    transform: translateY(-50%);

    width: 100%;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 42px;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
    padding: 10px 15px;
    margin: 0;

    /* 避免标题层挡住右侧点击/交互 */
    pointer-events: none;
}

/* 右侧状态固定在最右侧 */
.div3_1_2 {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    text-align: right;
}

/* Table Styles */
.div3_2 {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

th, td {
    padding: 15px 8px;
    text-align: center;
    border: 1px solid #f0f0f0;
    transition: all 0.2s ease;
    font-size: 20px;
}

th {
    background-color: #333;
    color: #fff;
    font-weight: 600;
    font-size: 20px;
    letter-spacing: 0.5px;
}

tr:nth-child(even) {
    background-color: #f9f9f9;
}



/* Section Headers */
.div3_1_4, .div3_4 {
    width: 100%;
    padding: 12px 0;
    font-size: 34px;
    text-align: center;
    background: linear-gradient(135deg, #c12c2a 0%, #a01f1d 100%);
    color: #fff;
    margin: 0;
    font-weight: 600;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

/* Content Sections */
.div3_3 {
    width: calc(100% - 30px);
    padding: 15px;
    font-size: 17px;
    color: #d32f2f;
    margin: 15px auto;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    line-height: 1.6;
}

.div3_5 {
    padding: 20px;
    width: calc(100% - 40px);
    font-size: 18px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    line-height: 1.8;
}

/* Footer */
.div3_6 {
    width: 100%;
    padding: 15px 0;
    text-align: center;
    font-size: 16px;
    color: #666;
    background-color: #f5f5f5;
    border-top: 1px solid #eee;
    margin-top: 20px;
}

/* Links */
a {
    color: #c12c2a;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: #a01f1d;
    text-decoration: underline;
}

/* Status indicator */
#stop_flag {
    transition: all 0.3s ease;
    color: #fff;
    font-size: 20px;
    display: block;
    line-height: 1.4;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .div3_1_1 {
        font-size: 28px;
        padding: 5px 10px;
    }
    
    .div3_1_4, .div3_4 {
        font-size: 24px;
        padding: 10px 0;
    }
    
    th, td {
        padding: 10px 5px;
        font-size: 17px;

    }
    
    .div3_5 {
        font-size: 16px;
        padding: 12px;
        width: calc(100% - 24px);
    }
    
    #stop_flag {
        font-size: 18px;
    }
}

/* Animation for price changes */
@keyframes highlight {
    0% { background-color: rgba(233, 30, 99, 0.1); }
    100% { background-color: transparent; }
}

.price-up {
    color: #e91e63;
    font-weight: bold;
    animation: highlight 2s ease-out;
}

.price-down {
    color: #4caf50;
    font-weight: bold;
    animation: highlight 2s ease-out;
}

/* Table cell specific styles */
.div3_2 table {
    border: none;
}

.div3_2 table td {
    border: 1px solid #f0f0f0;
}

/* Header specific adjustments */
.div3_1_1[style*='width:10%'] {
    min-width: 50px;
}

/* Ensure table rows have consistent height */
tr {
    height: 60px;
}

/* Make sure the time display is properly aligned */
#stop_flag br {
    display: none;
}

/* Improve footer links */
.div3_6 a {
    margin: 0 5px;
    color: #666;
}

.div3_6 a:hover {
    color: #c12c2a;
}

/* Ensure images in footer are properly aligned */
.div3_6 img {
    vertical-align: middle;
    margin: 0 2px;
}