* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background-color: #ffffff;
    color: #333333;
    font-size: 13px;
    line-height: 1.4;
    overflow-x: hidden;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 10px;
}

/* Header */
.header-main {
    padding: 12px 0 8px;
    background: #ffffff;
}

.brand-area {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ball-logo {
    width: 38px;
    height: 38px;
    background: radial-gradient(circle at 30% 30%, #ff5252, #b71c1c);
    border-radius: 50%;
    color: #ffffff;
    font-weight: 800;
    font-size: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: inset -2px -2px 4px rgba(0,0,0,0.4), 0 2px 4px rgba(0,0,0,0.2);
}

.logo-text h1 {
    font-size: 26px;
    font-weight: 800;
    color: #e65100;
    letter-spacing: -0.5px;
}

/* Navigation */
.main-nav {
    background-color: #e65100;
}

.nav-scroll {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.main-nav a {
    color: #ffffff;
    text-decoration: none;
    font-weight: bold;
    font-size: 12px;
    padding: 8px 14px;
    display: inline-block;
    transition: background 0.15s;
}

.main-nav a:hover,
.main-nav a.active {
    background-color: #bf360c;
}

/* Layout 2 Columns */
.layout-wrapper {
    display: grid;
    grid-template-columns: 1fr 310px;
    gap: 20px;
    margin-top: 15px;
    margin-bottom: 30px;
}

.tag-title {
    color: #e65100;
    font-weight: bold;
    font-size: 13px;
    margin-bottom: 6px;
}

/* Cards & Tables */
.card-box {
    border: 1px solid #d0d7de;
    border-radius: 4px;
    overflow: hidden;
    background-color: #ffffff;
}

.mt-20 {
    margin-top: 20px;
}

.card-header-orange {
    background-color: #d84315;
    color: #ffffff;
    text-align: center;
    padding: 6px 10px;
}

.card-header-orange h2 {
    font-size: 16px;
    font-weight: bold;
}

.card-header-orange h3 {
    font-size: 14px;
    font-weight: bold;
}

.card-sub-header {
    background-color: #fff8e1;
    color: #e65100;
    text-align: center;
    padding: 6px;
    font-weight: bold;
    font-size: 12px;
    border-bottom: 1px solid #e0e0e0;
}

.lottery-statistics {
    width: 100%;
}

.result-table {
    width: 100%;
    border-collapse: collapse;
    background-color: #ffffff;
}

.result-table td {
    border: 1px solid #e0e0e0;
    padding: 8px 6px;
    text-align: center;
    font-weight: bold;
    font-size: 13px;
}

.col-prize {
    width: 130px;
    color: #333333;
    font-weight: bold !important;
    background-color: #fafafa;
}

/* Prize text colors */
#resultG1, #resultG1History,
#resultG7_1, #resultG7_2, #resultG7_3, #resultG7_4,
#resultG7_1History, #resultG7_2History, #resultG7_3History, #resultG7_4History {
    color: #d32f2f;
    font-weight: 800;
    font-size: 15px;
}

#resultDB, #resultDBHistory {
    color: #222222;
    font-weight: 800;
    font-size: 15px;
}

/* Date Picker History */
.date-select-wrapper {
    background-color: #f5f5f5;
    padding: 8px 12px;
    border-bottom: 1px solid #e0e0e0;
}

#datePickerHistory {
    padding: 5px 8px;
    font-size: 13px;
    border: 1px solid #cccccc;
    border-radius: 3px;
    outline: none;
    width: 100%;
    max-width: 220px;
}

/* News List */
.news-list-box {
    margin-top: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.news-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.news-thumb {
    width: 140px;
    height: 75px;
    border-radius: 4px;
    flex-shrink: 0;
    color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 4px;
    position: relative;
}

.bg-pink {
    background: linear-gradient(135deg, #d81b60, #ad1457);
}

.bg-red {
    background: linear-gradient(135deg, #e53935, #c62828);
}

.news-thumb strong {
    font-size: 12px;
    line-height: 1.1;
}

.news-thumb span {
    font-size: 11px;
}

.date-badge {
    background-color: #ffffff;
    color: #c62828;
    font-size: 9px;
    font-weight: bold;
    padding: 1px 6px;
    border-radius: 8px;
    margin-top: 3px;
}

.news-desc {
    flex: 1;
}

.news-title {
    color: #0277bd;
    font-weight: bold;
    font-size: 12px;
    text-decoration: none;
    line-height: 1.3;
}

.news-title:hover {
    text-decoration: underline;
}

.news-desc p {
    font-size: 11px;
    color: #555555;
    margin-top: 3px;
    line-height: 1.3;
}

/* Sidebar Styling */
.sidebar-card {
    border: 1px solid #d0d7de;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 15px;
    background-color: #ffffff;
}

.province-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 12px;
    padding: 10px 12px;
}

.prov-item {
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
    color: #333333;
}

.dot-red {
    width: 6px;
    height: 6px;
    background-color: #d32f2f;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.check-green {
    color: #2e7d32;
    font-size: 11px;
    font-weight: bold;
    margin-left: 2px;
}

/* Loading Spinner */
.loading {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid #e0e0e0;
    border-radius: 50%;
    border-top: 2px solid #0288d1;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer Orange */
.footer-orange {
    background-color: #e65100;
    color: #ffffff;
    padding: 18px 0;
    font-size: 11px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-left p {
    margin-bottom: 8px;
}

.footer-socials {
    display: flex;
    gap: 8px;
}

.social-circle {
    width: 24px;
    height: 24px;
    background-color: #ffffff;
    color: #e65100;
    border-radius: 50%;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    font-size: 12px;
    cursor: pointer;
}

.social-circle.fb {
    background-color: #1877f2;
    color: #ffffff;
}

.social-circle.yt {
    background-color: #ff0000;
    color: #ffffff;
}

.footer-right {
    text-align: right;
    line-height: 1.5;
}

.dmca-badge {
    margin-top: 6px;
    display: inline-flex;
    font-size: 9px;
    font-weight: bold;
}

.dmca-prot {
    background-color: #0288d1;
    padding: 2px 5px;
    border-radius: 2px 0 0 2px;
}

.dmca-logo {
    background-color: #333333;
    padding: 2px 5px;
    border-radius: 0 2px 2px 0;
}

/* Responsive */
@media (max-width: 820px) {
    .layout-wrapper {
        grid-template-columns: 1fr;
    }
    .sidebar-right {
        order: 2;
    }
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    .footer-right {
        text-align: center;
        width: 100%;
    }
    .footer-socials {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .news-item {
        flex-direction: column;
    }
    .news-thumb {
        width: 100%;
        height: 60px;
    }
    .col-prize {
        width: 90px;
        font-size: 11px;
    }
    .result-table td {
        padding: 6px 2px;
        font-size: 11px;
    }
}