body {
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    font-weight: 400;
    background: #e3f6fd;
    margin: 0;
    padding: 0;
}
.container {
    max-width: 1000px;
    margin: 40px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    padding: 32px 24px;
}
h1, h2 {
    color: #0077b6;
    margin-top: 0;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    font-weight: 700;
}
ul, ol {
    padding-left: 24px;
}
ul li, ol li {
    margin-bottom: 8px;
    font-size: 1.1em;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
}
a {
    color: #0096c7;
    text-decoration: none;
    transition: color 0.2s;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
}
a:hover {
    color: #023e8a;
    text-decoration: underline;
}
button {
    background: #90e0ef;
    border: none;
    border-radius: 6px;
    padding: 8px 18px;
    margin-right: 8px;
    margin-bottom: 8px;
    cursor: pointer;
    color: #0077b6;
    font-weight: bold;
    transition: all 0.2s;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    font-size: 14px;
    min-height: 44px;
}

button:hover {
    background: #48cae4;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

button:active {
    transform: translateY(0);
}

/* Mobile buttons */
@media (max-width: 768px) {
    button {
        width: 100%;
        max-width: 200px;
        margin-right: 0;
        margin-bottom: 12px;
        padding: 12px 20px;
        font-size: 15px;
    }
    
    .button-group {
        display: flex;
        flex-direction: column;
        gap: 8px;
        align-items: center;
    }
}

@media (max-width: 480px) {
    button {
        padding: 14px 24px;
        font-size: 16px;
        min-height: 48px;
    }
}
header {
    background: #48cae4 !important;
    color: #fff;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    padding: 16px 24px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

header nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

header nav a {
    color: #fff;
    margin-right: 12px;
    font-weight: 500;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.2s;
}

header nav a:hover {
    color: #023e8a;
    background: rgba(255,255,255,0.1);
}

/* Mobile navigation */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: background 0.2s;
}

.mobile-menu-toggle:hover {
    background: rgba(255,255,255,0.1);
}

.mobile-menu-toggle:active {
    background: rgba(255,255,255,0.2);
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: block;
    }
    
    header nav {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #48cae4;
        padding: 16px;
        box-shadow: 0 4px 12px rgba(0,0,0,0.15);
        border-radius: 0 0 12px 12px;
    }
    
    header nav.active {
        display: flex;
    }
    
    header nav a {
        margin-right: 0;
        text-align: center;
        padding: 12px 16px;
        border-radius: 6px;
        background: rgba(255,255,255,0.1);
        transition: all 0.2s;
    }
    
    header nav a:hover {
        background: rgba(255,255,255,0.2);
        transform: translateX(4px);
    }
    
    header nav a:active {
        background: rgba(255,255,255,0.3);
        transform: scale(0.98);
    }
}

@media (max-width: 480px) {
    header nav {
        padding: 12px;
    }
    
    header nav a {
        padding: 14px 16px;
        font-size: 15px;
    }
}
footer {
    background: #48cae4 !important;
    color: #fff !important;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    padding: 32px 24px;
    margin-top: 48px;
}

footer .footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

footer a {
    color: #fff;
    text-decoration: underline;
    font-family: 'Roboto', 'Arial', 'Helvetica Neue', 'Segoe UI', sans-serif;
    transition: color 0.2s;
}

footer a:hover {
    color: #023e8a;
}

/* Mobile footer */
@media (max-width: 768px) {
    footer {
        padding: 24px 16px;
        margin-top: 32px;
        text-align: center;
    }
    
    footer .footer-content {
        flex-direction: column;
        gap: 16px;
    }
}

/* Hero slider */
.hero-slider { position: relative; overflow: hidden; border-radius: 12px; margin-bottom: 24px; }
.hero-slides { position: relative; height: 420px; }
.hero-slide { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transform: scale(1.03); transition: opacity .5s ease, transform .6s ease; }
.hero-slide.active { opacity: 1; transform: scale(1); }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.35) 35%, rgba(0,0,0,.25) 60%, rgba(0,0,0,0) 100%); }
.hero-content { position: absolute; right: 24px; top: 24px; bottom: 24px; width: min(520px, 60%); color: #fff; display:flex; flex-direction:column; justify-content:center; gap:12px; text-shadow: 0 2px 10px rgba(0,0,0,.45);} 
.hero-title { font-size: 32px; font-weight: 800; letter-spacing:.5px; margin:0; }
.hero-desc { margin:0; line-height:1.6; }
.hero-btn { align-self:flex-start; padding:10px 18px; background:#48cae4; color:#fff; border-radius:8px; text-decoration:none; margin-top:6px; }
.hero-nav { position:absolute; top:50%; transform:translateY(-50%); background:rgba(0,0,0,.35); color:#fff; border:none; width:40px; height:40px; border-radius:50%; cursor:pointer; font-size:22px; }
.hero-nav.prev { left:10px; } .hero-nav.next { right:10px; }
.hero-thumbs { position:absolute; left:24px; bottom:18px; display:flex; gap:10px; }
.hero-thumb { width:60px; height:40px; border-radius:6px; overflow:hidden; opacity:.7; border:2px solid transparent; }
.hero-thumb.active { opacity:1; border-color:#48cae4; }
.hero-thumb img { width:100%; height:100%; object-fit:cover; display:block; }

/* Home story cards */

/* Layout cho desktop - 2 cột */
.main-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 32px;
    align-items: start;
}

.story-section {
    order: 1;
}

.ranking-section {
    order: 2;
}

/* Layout cho mobile - 1 cột */
@media (max-width: 768px) {
    .main-content {
        display: block;
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .story-section {
        order: 1;
        margin-bottom: 24px;
    }
    
    .ranking-section {
        order: 2;
        margin-top: 0;
    }
}

/* CSS cho mobile layout đã được xử lý trong mobile-layout.css */

/* ===== RESPONSIVE DESIGN FOR MOBILE ===== */
@media (max-width: 768px) {
    /* Container adjustments */
    .container {
        max-width: 100%;
        margin: 20px auto;
        padding: 20px 16px;
        border-radius: 8px;
    }
    
    /* Mobile layout đã được xử lý ở trên */
    
    /* Typography adjustments */
    h1 {
        font-size: 24px;
        line-height: 1.3;
        margin-bottom: 16px;
    }
    
    h2 {
        font-size: 20px;
        line-height: 1.4;
        margin-bottom: 12px;
    }
    
    /* Hero slider mobile optimization */
    .hero-slides {
        height: 280px;
    }
    
    .hero-content {
        right: 16px;
        top: 16px;
        bottom: 16px;
        width: calc(100% - 32px);
    }
    
    .hero-title {
        font-size: 20px;
        line-height: 1.3;
    }
    
    .hero-desc {
        font-size: 14px;
        line-height: 1.5;
    }
    
    .hero-btn {
        padding: 8px 16px;
        font-size: 14px;
    }
    
    .hero-nav {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    
    .hero-thumbs {
        left: 16px;
        bottom: 12px;
        gap: 8px;
    }
    
    .hero-thumb {
        width: 50px;
        height: 32px;
    }
    
    /* Story cards mobile layout */
    .story-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    /* Story section mobile */
    .story-section {
        width: 100%;
    }
    
    .story-section h2 {
        text-align: center;
        margin-bottom: 20px;
    }
    
    /* Visual separation cho mobile */
    .story-section::after {
        content: '';
        display: block;
        height: 2px;
        background: linear-gradient(90deg, transparent, #48cae4, transparent);
        margin: 24px 0;
        border-radius: 1px;
    }
    
    .story-card {
        padding: 16px;
        border-radius: 8px;
    }
    
    .story-card img {
        width: 80px;
        height: 80px;
        border-radius: 6px;
    }
    
    .story-info h3 {
        font-size: 16px;
        line-height: 1.4;
        margin-bottom: 8px;
    }
    
    .story-meta {
        font-size: 13px;
        margin-bottom: 8px;
    }
    
    .story-rating {
        font-size: 12px;
    }
    
    /* Navigation mobile optimization */
    header {
        padding: 12px 16px;
    }
    
    header nav {
        flex-direction: column;
        gap: 8px;
    }
    
    header nav a {
        margin-right: 0;
        padding: 8px 12px;
        border-radius: 6px;
        background: rgba(255,255,255,0.1);
    }
    
    /* Footer mobile optimization */
    footer {
        padding: 20px 16px;
        text-align: center;
    }
    
    footer .footer-content {
        flex-direction: column;
        gap: 16px;
    }
    
    /* Button mobile optimization */
    button {
        padding: 10px 18px;
        font-size: 14px;
        margin-bottom: 8px;
        width: 100%;
        max-width: 200px;
    }
    
    /* Form mobile optimization */
input[type="text"], 
input[type="email"], 
input[type="password"],
textarea,
select {
    padding: 12px;
    font-size: 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    border: 2px solid #e9ecef;
    transition: border-color 0.2s;
    width: 100%;
    box-sizing: border-box;
}

input[type="text"]:focus, 
input[type="email"]:focus, 
input[type="password"]:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #48cae4;
    box-shadow: 0 0 0 3px rgba(72, 202, 228, 0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #0077b6;
    font-weight: 500;
    font-size: 14px;
}

/* Mobile forms */
@media (max-width: 768px) {
    input[type="text"], 
    input[type="email"], 
    input[type="password"],
    textarea,
    select {
        padding: 14px;
        font-size: 16px;
        margin-bottom: 20px;
        border-radius: 8px;
    }
    
    .form-group {
        margin-bottom: 24px;
    }
    
    .form-group label {
        font-size: 15px;
        margin-bottom: 10px;
    }
}

@media (max-width: 480px) {
    input[type="text"], 
    input[type="email"], 
    input[type="password"],
    textarea,
    select {
        padding: 16px;
        font-size: 16px;
        margin-bottom: 24px;
    }
    
    .form-group {
        margin-bottom: 28px;
    }
}
    
    /* Table mobile optimization */
table {
    font-size: 14px;
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}

table th,
table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
}

table th {
    background: #f8f9fa;
    color: #0077b6;
    font-weight: 600;
    font-size: 14px;
}

table tr:hover {
    background: #f8f9fa;
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Mobile tables */
@media (max-width: 768px) {
    table {
        font-size: 13px;
        margin-bottom: 20px;
    }
    
    table th,
    table td {
        padding: 10px 8px;
        font-size: 13px;
    }
    
    table th {
        font-size: 13px;
    }
    
    .table-responsive {
        margin: 0 -16px;
        border-radius: 0;
    }
}

@media (max-width: 480px) {
    table {
        font-size: 12px;
        margin-bottom: 16px;
    }
    
    table th,
    table td {
        padding: 8px 6px;
        font-size: 12px;
    }
    
    table th {
        font-size: 12px;
    }
}
    
    /* Card mobile optimization */
.card {
    padding: 20px;
    margin-bottom: 24px;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    border: 1px solid #e9ecef;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.card-header {
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid #e9ecef;
}

.card-title {
    margin: 0;
    color: #0077b6;
    font-size: 18px;
    font-weight: 600;
}

.card-body {
    color: #6c757d;
    line-height: 1.6;
}

/* Mobile cards */
@media (max-width: 768px) {
    .card {
        padding: 16px;
        margin-bottom: 20px;
        border-radius: 8px;
    }
    
    .card-header {
        padding-bottom: 12px;
        margin-bottom: 12px;
    }
    
    .card-title {
        font-size: 16px;
    }
    
    .card-body {
        font-size: 14px;
        line-height: 1.5;
    }
}

@media (max-width: 480px) {
    .card {
        padding: 12px;
        margin-bottom: 16px;
        border-radius: 6px;
    }
    
    .card-header {
        padding-bottom: 10px;
        margin-bottom: 10px;
    }
    
    .card-title {
        font-size: 15px;
    }
    
    .card-body {
        font-size: 13px;
    }
}
    
    /* Grid mobile optimization */
.grid-2 {
    grid-template-columns: 1fr;
    gap: 16px;
}

.grid-3 {
    grid-template-columns: 1fr;
    gap: 16px;
}

.grid-4 {
    grid-template-columns: 1fr;
    gap: 16px;
}

/* Utility classes for mobile */
.text-center-mobile {
    text-align: center;
}

/* Mobile layout utilities */
.mobile-stack {
    display: block;
}

.mobile-stack .story-section,
.mobile-stack .ranking-section {
    width: 100%;
    margin-bottom: 24px;
}

.mobile-stack .ranking-section {
    margin-top: 0;
}

@media (min-width: 769px) {
    .mobile-stack {
        display: grid;
        grid-template-columns: 2fr 1fr;
        gap: 32px;
    }
    
    .mobile-stack .story-section,
    .mobile-stack .ranking-section {
        margin-bottom: 0;
    }
}

.hidden-mobile {
    display: none;
}

.visible-mobile {
    display: block;
}

@media (min-width: 769px) {
    .text-center-mobile {
        text-align: left;
    }
    
    .hidden-mobile {
        display: block;
    }
    
    .visible-mobile {
        display: none;
    }
}

/* Mobile spacing utilities */
.mobile-mt-1 { margin-top: 8px; }
.mobile-mt-2 { margin-top: 16px; }
.mobile-mt-3 { margin-top: 24px; }
.mobile-mb-1 { margin-bottom: 8px; }
.mobile-mb-2 { margin-bottom: 16px; }
.mobile-mb-3 { margin-bottom: 24px; }
.mobile-p-1 { padding: 8px; }
.mobile-p-2 { padding: 16px; }
.mobile-p-3 { padding: 24px; }

@media (min-width: 769px) {
    .mobile-mt-1, .mobile-mt-2, .mobile-mt-3,
    .mobile-mb-1, .mobile-mb-2, .mobile-mb-3,
    .mobile-p-1, .mobile-p-2, .mobile-p-3 {
        margin: 0;
        padding: 0;
    }
}

/* Search and filters mobile optimization */
.search-box {
    position: relative;
    margin-bottom: 24px;
}

.search-box input[type="text"] {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    background: #fff;
    transition: all 0.2s;
}

.search-box input[type="text"]:focus {
    border-color: #48cae4;
    box-shadow: 0 0 0 3px rgba(72, 202, 228, 0.1);
}

.search-box .search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    font-size: 18px;
}

.filter-group {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
}

.filter-btn:hover,
.filter-btn.active {
    background: #48cae4;
    border-color: #48cae4;
    color: #fff;
}

/* Mobile search and filters */
@media (max-width: 768px) {
    .search-box {
        margin-bottom: 20px;
    }
    
    .search-box input[type="text"] {
        padding: 14px 16px 14px 48px;
        font-size: 16px;
    }
    
    .search-box .search-icon {
        left: 16px;
        font-size: 20px;
    }
    
    .filter-group {
        gap: 8px;
        margin-bottom: 16px;
    }
    
    .filter-btn {
        padding: 10px 14px;
        font-size: 14px;
        flex: 1;
        min-width: 80px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .search-box {
        margin-bottom: 16px;
    }
    
    .search-box input[type="text"] {
        padding: 16px 16px 16px 52px;
        font-size: 16px;
    }
    
    .search-box .search-icon {
        left: 18px;
        font-size: 22px;
    }
    
    .filter-group {
        gap: 6px;
        margin-bottom: 14px;
    }
    
    .filter-btn {
        padding: 12px 16px;
        font-size: 15px;
        min-width: 70px;
    }
}

/* Pagination mobile optimization */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 32px;
    margin-bottom: 32px;
}

.pagination a,
.pagination span {
    padding: 10px 14px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    color: #6c757d;
    text-decoration: none;
    transition: all 0.2s;
    min-width: 44px;
    text-align: center;
    font-weight: 500;
}

.pagination a:hover {
    background: #48cae4;
    border-color: #48cae4;
    color: #fff;
    transform: translateY(-1px);
}

.pagination .current {
    background: #48cae4;
    border-color: #48cae4;
    color: #fff;
}

.pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Mobile pagination */
@media (max-width: 768px) {
    .pagination {
        gap: 6px;
        margin-top: 24px;
        margin-bottom: 24px;
        flex-wrap: wrap;
    }
    
    .pagination a,
    .pagination span {
        padding: 12px 16px;
        font-size: 14px;
        min-width: 48px;
    }
}

@media (max-width: 480px) {
    .pagination {
        gap: 4px;
        margin-top: 20px;
        margin-bottom: 20px;
    }
    
    .pagination a,
    .pagination span {
        padding: 14px 18px;
        font-size: 15px;
        min-width: 52px;
    }
}

/* Alerts and notifications mobile optimization */
.alert {
    padding: 16px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid;
    font-weight: 500;
}

.alert-success {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.alert-info {
    background: #d1ecf1;
    border-color: #17a2b8;
    color: #0c5460;
}

.alert-warning {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.alert-danger {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 20px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    border-left: 4px solid #48cae4;
    z-index: 10000;
    max-width: 400px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Mobile alerts and notifications */
@media (max-width: 768px) {
    .alert {
        padding: 14px 16px;
        margin-bottom: 16px;
        font-size: 14px;
    }
    
    .notification {
        top: 16px;
        right: 16px;
        left: 16px;
        max-width: none;
        padding: 14px 16px;
    }
}

@media (max-width: 480px) {
    .alert {
        padding: 12px 14px;
        margin-bottom: 14px;
        font-size: 13px;
    }
    
    .notification {
        top: 12px;
        right: 12px;
        left: 12px;
        padding: 12px 14px;
    }
}

/* Loading and animations mobile optimization */
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
    color: #6c757d;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e9ecef;
    border-top: 4px solid #48cae4;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: 4px;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-text {
    height: 16px;
    margin-bottom: 8px;
}

.skeleton-title {
    height: 24px;
    margin-bottom: 16px;
}

.skeleton-image {
    width: 100px;
    height: 100px;
    border-radius: 8px;
}

/* Mobile loading and animations */
@media (max-width: 768px) {
    .loading {
        padding: 32px 20px;
    }
    
    .loading-spinner {
        width: 36px;
        height: 36px;
        border-width: 3px;
    }
    
    .skeleton-text {
        height: 14px;
        margin-bottom: 6px;
    }
    
    .skeleton-title {
        height: 20px;
        margin-bottom: 12px;
    }
    
    .skeleton-image {
        width: 80px;
        height: 80px;
        border-radius: 6px;
    }
}

@media (max-width: 480px) {
    .loading {
        padding: 24px 16px;
    }
    
    .loading-spinner {
        width: 32px;
        height: 32px;
        border-width: 3px;
    }
    
    .skeleton-text {
        height: 12px;
        margin-bottom: 5px;
    }
    
    .skeleton-title {
        height: 18px;
        margin-bottom: 10px;
    }
    
    .skeleton-image {
        width: 70px;
        height: 70px;
        border-radius: 6px;
    }
}

/* Final mobile utilities */
.mobile-only {
    display: none;
}

.desktop-only {
    display: block;
}

@media (max-width: 768px) {
    .mobile-only {
        display: block;
    }
    
    .desktop-only {
        display: none;
    }
}

/* Mobile touch improvements */
@media (hover: none) and (pointer: coarse) {
    * {
        -webkit-tap-highlight-color: rgba(0,0,0,0.1);
    }
    
    button, a, .clickable {
        cursor: pointer;
        -webkit-tap-highlight-color: rgba(72, 202, 228, 0.2);
    }
    
    button:active, a:active, .clickable:active {
        transform: scale(0.98);
        transition: transform 0.1s;
    }
}

/* Mobile scrollbar */
@media (max-width: 768px) {
    ::-webkit-scrollbar {
        width: 6px;
        height: 6px;
    }
    
    ::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 3px;
    }
    
    ::-webkit-scrollbar-thumb {
        background: #c1c1c1;
        border-radius: 3px;
    }
    
    ::-webkit-scrollbar-thumb:hover {
        background: #a8a8a8;
    }
}

/* Mobile print styles */
@media print {
    .mobile-only,
    .desktop-only,
    .mobile-menu-toggle,
    header,
    footer,
    .pagination,
    .filter-group {
        display: none !important;
    }
    
    .container {
        max-width: none;
        margin: 0;
        padding: 0;
        box-shadow: none;
        border-radius: 0;
    }
    
    .story-card {
        break-inside: avoid;
        margin-bottom: 16px;
        border: 1px solid #ddd;
    }
}
}

/* Extra small devices */
@media (max-width: 480px) {
    .container {
        margin: 10px auto;
        padding: 16px 12px;
    }
    
    /* Extra small mobile layout */
    .main-content {
        gap: 20px;
    }
    
    .story-section {
        margin-bottom: 20px;
    }
    
    .ranking-section {
        margin-top: 0;
    }
    
    /* CSS cho mobile layout đã được xử lý trong mobile-layout.css */
}
    
    h1 {
        font-size: 22px;
    }
    
    h2 {
        font-size: 18px;
    }
    
    .hero-slides {
        height: 240px;
    }
    
    .hero-title {
        font-size: 18px;
    }
    
    .hero-desc {
        font-size: 13px;
    }
    
    .story-card {
        padding: 12px;
    }
    
    .story-card img {
        width: 70px;
        height: 70px;
    }
    
    .story-info h3 {
        font-size: 15px;
    }
    
    button {
        padding: 12px 16px;
        font-size: 15px;
    }
}

/* Landscape orientation for mobile */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-slides {
        height: 200px;
    }
    
    .hero-content {
        top: 12px;
        bottom: 12px;
    }
    
    .hero-title {
        font-size: 18px;
    }
    
    .hero-desc {
        font-size: 13px;
    }
    
    /* Landscape layout vẫn giữ 1 cột */
    .main-content {
        display: block;
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .story-section {
        order: 1;
        margin-bottom: 20px;
    }
    
    .ranking-section {
        order: 2;
        margin-top: 0;
    }
    
    /* CSS cho mobile layout đã được xử lý trong mobile-layout.css */
}

/* Touch device optimization */
@media (hover: none) and (pointer: coarse) {
    button, 
    .hero-nav,
    .hero-thumb {
        min-height: 44px;
        min-width: 44px;
    }
    
    .story-card {
        cursor: pointer;
        -webkit-tap-highlight-color: rgba(0,0,0,0.1);
    }
    
    .story-card:active {
        transform: scale(0.98);
        transition: transform 0.1s;
    }
}

/* Story cards mobile optimization */
.story-card {
    display: flex;
    gap: 16px;
    padding: 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.07);
    transition: transform 0.2s, box-shadow 0.2s;
    border-left: 4px solid #48cae4;
}

.story-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.story-card img {
    width: 100px;
    height: 100px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.story-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.story-info h3 {
    margin: 0 0 8px 0;
    color: #0077b6;
    font-size: 18px;
    line-height: 1.4;
}

.story-meta {
    color: #6c757d;
    font-size: 14px;
    margin-bottom: 8px;
}

.story-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffc107;
    font-size: 14px;
}

.story-rating .stars {
    display: flex;
    gap: 2px;
}

.story-rating .stars i {
    color: #ffc107;
}

/* Mobile story cards */
@media (max-width: 768px) {
    .story-card {
        padding: 16px;
        gap: 12px;
        border-radius: 8px;
    }
    
    .story-card img {
        width: 80px;
        height: 80px;
        border-radius: 6px;
    }
    
    .story-info h3 {
        font-size: 16px;
        line-height: 1.3;
        margin-bottom: 6px;
    }
    
    .story-meta {
        font-size: 13px;
        margin-bottom: 6px;
    }
    
    .story-rating {
        font-size: 12px;
        gap: 6px;
    }
    
    .story-rating .stars {
        gap: 1px;
    }
}

@media (max-width: 480px) {
    .story-card {
        padding: 12px;
        gap: 10px;
    }
    
    .story-card img {
        width: 70px;
        height: 70px;
        border-radius: 6px;
    }
    
    .story-info h3 {
        font-size: 15px;
        line-height: 1.3;
    }
    
    .story-meta {
        font-size: 12px;
    }
    
    .story-rating {
        font-size: 11px;
    }
}
.story-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

/* Ranking section mobile optimization */
.ranking-section {
    background: #f8f9fa;
    padding: 24px;
    border-radius: 12px;
    margin-top: 32px;
}

.ranking-section h3 {
    color: #0077b6;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ranking-section h3 i {
    color: #ffc107;
}

.ranking-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.ranking-filter {
    padding: 8px 16px;
    background: #e9ecef;
    border: none;
    border-radius: 6px;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s;
}

.ranking-filter.active {
    background: #48cae4;
    color: #fff;
}

.ranking-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ranking-item {
    padding: 12px 16px;
    background: #fff;
    border-radius: 8px;
    border-left: 3px solid #48cae4;
    transition: transform 0.2s;
}

.ranking-item:hover {
    transform: translateX(4px);
}

.ranking-item h4 {
    margin: 0;
    color: #0077b6;
    font-size: 16px;
    line-height: 1.4;
}

/* Mobile ranking section */
@media (max-width: 768px) {
    .ranking-section {
        padding: 20px 16px;
        margin-top: 0;
        border-radius: 8px;
        width: 100%;
    }
    
    .ranking-section h3 {
        text-align: center;
        justify-content: center;
    }
    
    .ranking-section h3 {
        font-size: 18px;
        margin-bottom: 12px;
    }
    
    .ranking-filters {
        gap: 8px;
        margin-bottom: 16px;
        flex-wrap: wrap;
    }
    
    .ranking-filter {
        padding: 10px 14px;
        font-size: 14px;
        flex: 1;
        min-width: 80px;
        text-align: center;
    }
    
    .ranking-list {
        gap: 10px;
    }
    
    .ranking-item {
        padding: 10px 14px;
        border-radius: 6px;
    }
    
    .ranking-item h4 {
        font-size: 15px;
        line-height: 1.3;
    }
}

@media (max-width: 480px) {
    .ranking-section {
        padding: 16px 12px;
        margin-top: 0;
    }
    
    .ranking-section h3 {
        font-size: 16px;
        margin-bottom: 10px;
    }
    
    .ranking-filters {
        gap: 6px;
        margin-bottom: 14px;
    }
    
    .ranking-filter {
        padding: 8px 12px;
        font-size: 13px;
        min-width: 70px;
    }
    
    .ranking-list {
        gap: 8px;
    }
    
    .ranking-item {
        padding: 8px 12px;
    }
    
    .ranking-item h4 {
        font-size: 14px;
    }
}

.story-card {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #48cae4;
    align-items: center;
}
.story-card img {
    width: 70px;
    height: 90px;
    object-fit: cover;
    border-radius: 6px;
}
.story-meta { display: flex; flex-direction: column; }
.story-title { font-weight: 700; color: #0077b6; margin-bottom: 4px; }
.story-author { color: #6c757d; font-size: 0.92em; }

.rank-list { counter-reset: rank; list-style: none; padding-left: 0; }
.rank-list li { background:#f8f9fa; border-radius:6px; padding:8px 12px; margin-bottom:8px; }

/* Hệ thống đánh giá sao */
.rating-section {
    margin-top: 16px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.rating-display {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stars {
    display: inline-flex;
    gap: 2px;
}

.star {
    color: #ddd;
    font-size: 18px;
    transition: color 0.2s ease;
}

.star.filled {
    color: #ffc107;
}

.star-label {
    cursor: pointer;
    color: #ddd;
    font-size: 20px;
    margin-right: 4px;
    transition: color 0.2s ease;
}

.star-label:hover {
    color: #ffc107;
}

.rating-form {
    margin-top: 12px;
}

.rating-submit-btn {
    margin-top: 8px;
    padding: 8px 16px;
    background: #48cae4;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.rating-submit-btn:hover {
    background: #3ba8c1;
}

.rating-text {
    color: #6c757d;
    font-size: 14px;
}

/* Hero Slider nâng cao */
.hero-slider {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.hero-slides {
    position: relative;
    height: 420px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.03);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.35) 35%, rgba(0,0,0,.25) 60%, rgba(0,0,0,0) 100%);
}

.hero-content {
    position: absolute;
    right: 24px;
    top: 24px;
    bottom: 24px;
    width: min(520px, 60%);
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
    text-shadow: 0 2px 10px rgba(0,0,0,.45);
}

.hero-title {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: .5px;
    margin: 0;
    animation: slideInRight 0.8s ease;
}

.hero-desc {
    margin: 0;
    line-height: 1.6;
    animation: slideInRight 0.8s ease 0.2s both;
}

.hero-btn {
    align-self: flex-start;
    padding: 12px 24px;
    background: #48cae4;
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    margin-top: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    animation: slideInRight 0.8s ease 0.4s both;
}

.hero-btn:hover {
    background: #3ba8c1;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(72, 202, 228, 0.4);
}

.hero-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,.35);
    color: #fff;
    border: none;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 24px;
    transition: all 0.3s ease;
    z-index: 5;
}

.hero-nav:hover {
    background: rgba(0,0,0,.6);
    transform: translateY(-50%) scale(1.1);
}

.hero-nav.prev {
    left: 16px;
}

.hero-nav.next {
    right: 16px;
}

.hero-thumbs {
    position: absolute;
    left: 24px;
    bottom: 18px;
    display: flex;
    gap: 10px;
    z-index: 5;
}

.hero-thumb {
    width: 60px;
    height: 40px;
    border-radius: 6px;
    overflow: hidden;
    opacity: .7;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    cursor: pointer;
}

.hero-thumb:hover {
    opacity: 1;
    transform: scale(1.05);
}

.hero-thumb.active {
    opacity: 1;
    border-color: #48cae4;
    box-shadow: 0 0 10px rgba(72, 202, 228, 0.6);
}

.hero-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Progress bar cho auto-roll */
.hero-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, #48cae4, #ff6b6b);
    width: 0%;
    transition: width 0.1s linear;
    z-index: 10;
    border-radius: 0 0 12px 12px;
}

/* Animations */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive cho mobile */
@media (max-width: 768px) {
    .hero-slides {
        height: 300px;
    }
    
    .hero-content {
        right: 16px;
        top: 16px;
        bottom: 16px;
        width: calc(100% - 32px);
    }
    
    .hero-title {
        font-size: 24px;
    }
    
    .hero-desc {
        font-size: 14px;
    }
    
    .hero-nav {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .hero-thumbs {
        left: 16px;
        bottom: 16px;
        gap: 8px;
    }
    
    .hero-thumb {
        width: 50px;
        height: 35px;
    }
}

/* Auto-roll indicator */
.hero-auto-roll-indicator {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 6px;
}

.hero-auto-roll-indicator.paused {
    background: rgba(255, 107, 107, 0.8);
}

.hero-auto-roll-indicator .icon {
    width: 12px;
    height: 12px;
    border: 2px solid currentColor;
    border-radius: 50%;
    position: relative;
}

.hero-auto-roll-indicator .icon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    border-left: 4px solid currentColor;
    border-top: 3px solid transparent;
    border-bottom: 3px solid transparent;
}

.hero-auto-roll-indicator.paused .icon::before {
    border-left: none;
    border-top: 4px solid transparent;
    border-bottom: 4px solid transparent;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
}
