:root {
    /* --- BẢNG MÀU ANCARAT (Tông Hồng/Tím) --- */
    --primary-color: #8e2468;
    /* Màu Tím Hồng chủ đạo giống hình */
    --primary-dark: #6a1b49;
    /* Màu tối hơn cho hover hoặc nhấn nhá */

    --group-bg: #fce4ec;
    /* Nền hồng phấn nhạt cho dòng Nhóm */
    --group-text: #8e2468;
    /* Chữ màu tím hồng cho dòng Nhóm */

    --price-buy: #c2185b;
    /* Giá mua: Đỏ hồng đậm */
    --price-sell: #2e7d32;
    /* Giá bán: Xanh lá (giữ nguyên cho chuẩn tài chính) */

    --border-color: #e0e0e0;
    --text-white: #ffffff;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
    background-color: #fff0f5;
    /* Nền web hồng cực nhạt */
}

/* HEADER */
.top-header {
    background-color: var(--primary-color);
    color: var(--text-white);
    padding: 15px 0;
    /* Viền dưới màu xám bạc nhẹ nhàng */
    border-bottom: 4px solid #d8bfd8;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.brand-text h1 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.logo {
    height: 50px;
    margin-right: 10px;
    background: #fff;
    padding: 2px;
    border-radius: 4px;
}

.brand-area {
    display: flex;
    align-items: center;
    flex: 1;
}

.title-area {
    flex: 2;
    text-align: center;
}

.page-title {
    margin: 0;
    font-size: 2.2rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.time-area {
    flex: 1;
    text-align: right;
}

.clock-large {
    font-size: 1.8rem;
    font-weight: 700;
}

.date-small {
    font-size: 0.9rem;
    font-style: italic;
    opacity: 0.9;
}

/* TABLE */
.main-container {
    max-width: 1200px;
    margin: 20px auto;
    background: #fff;
    box-shadow: 0 4px 15px rgba(142, 36, 104, 0.1);
    /* Bóng màu tím nhẹ */
    border-radius: 8px;
    /* Bo góc nhẹ */
    overflow: hidden;
}

table {
    width: 100%;
    border-collapse: collapse;
}

/* Table Header - Màu tím hồng */
thead th {
    background-color: var(--primary-color);
    color: white;
    padding: 15px;
    text-transform: uppercase;
    font-weight: 700;
    border-right: 1px solid rgba(255, 255, 255, 0.3);
    text-align: center;
}

thead th:last-child {
    border-right: none;
}

/* Group Row (Dòng Nhóm) */
.group-row td {
    background-color: var(--group-bg);
    color: var(--group-text);
    font-weight: 700;
    text-transform: uppercase;
    text-align: center;
    padding: 12px;
    font-size: 1.1rem;
    border-bottom: 1px solid #f8bbd0;
    /* Kẻ ngang màu hồng nhạt */
}

/* Item Row */
.item-row td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    color: #333;
    font-size: 1rem;
    vertical-align: middle;
}

.item-row:last-child td {
    border-bottom: none;
}

.item-row td:last-child {
    border-right: none;
}

/* Cột Sản phẩm */
.col-name {
    text-align: left;
    font-weight: 600;
    color: #4a148c;
    /* Tên sản phẩm màu tím đậm */
    padding-left: 20px !important;
}

.sub-text {
    display: block;
    font-size: 0.85rem;
    font-weight: normal;
    color: #888;
    font-style: italic;
    margin-top: 3px;
}

/* Cột Giá */
.col-unit {
    text-align: center;
    color: #555;
}

.col-buy {
    text-align: center;
    font-weight: 700;
    color: var(--price-buy);
    font-size: 1.1rem;
}

.col-sell {
    text-align: center;
    font-weight: 700;
    color: var(--price-sell);
    font-size: 1.1rem;
}

/* FOOTER */
.site-footer {
    background-color: var(--primary-color);
    color: white;
    padding: 20px 0;
    margin-top: auto;
    border-top: 4px solid #d8bfd8;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    padding: 0 15px;
}

.footer-col h4 {
    color: #f8bbd0;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.footer-col p {
    margin: 5px 0;
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .page-title {
        font-size: 1.5rem;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .main-container {
        overflow-x: auto;
    }

    table {
        min-width: 600px;
    }
}