/*
Theme Name: Fun88 Theme
Theme URI: https://fun88-theme.com
Author: Fun88 Developer
Author URI: https://fun88-theme.com
Description: Chủ đề WordPress chuyên nghiệp cho Fun88 - Trải nghiệm cá cược và casino trực tuyến hàng đầu
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: fun88-theme
Domain Path: /languages
Tags: responsive, custom-menu, featured-images, theme-options
*/

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.site-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border-bottom: 2px solid #e94560;
}

/* 重置 WordPress 菜单默认样式 */
.site-header ul,
.site-header ol {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.site-header ul li {
    list-style: none !important;
}

.site-header a {
    text-decoration: none !important;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    height: 70px;
}

.nav-desktop {
    display: flex;
    gap: 5px;
    align-items: center;
}

.nav-desktop ul {
    display: flex;
    gap: 5px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-desktop > ul {
    display: flex;
    flex-direction: row;
}

.nav-desktop li {
    position: relative;
    list-style: none;
    display: inline-block;
}

/* WordPress 菜单覆盖样式 */
.nav-desktop .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #1a1a2e;
    min-width: 200px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    padding: 10px 0;
    z-index: 1000;
}

.nav-desktop li:hover > .sub-menu {
    display: block;
}

.nav-desktop .sub-menu li {
    display: block;
    width: 100%;
}

.nav-desktop .sub-menu a {
    padding: 10px 20px;
    border-radius: 0;
}

.nav-desktop .sub-menu a:hover {
    background-color: rgba(233, 69, 96, 0.2);
}

.nav-desktop a {
    color: #ffffff;
    font-weight: 600;
    font-size: 15px;
    padding: 12px 20px;
    transition: all 0.3s ease;
    display: block;
    border-radius: 5px;
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.nav-desktop a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #e94560, #ff6b6b);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-desktop a:hover {
    color: #ffffff;
    background-color: rgba(233, 69, 96, 0.15);
    transform: translateY(-2px);
}

.nav-desktop a:hover::before {
    width: 80%;
}

.nav-desktop li.current-menu-item a,
.nav-desktop li.current_page_item a {
    background-color: #e94560;
    color: #ffffff;
}

.nav-desktop li.current-menu-item a::before,
.nav-desktop li.current_page_item a::before {
    width: 0;
}

.auth-buttons {
    display: flex;
    gap: 12px;
    align-items: center;
}

.btn {
    padding: 10px 28px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    display: inline-block;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-login {
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
}

.btn-login:hover {
    border-color: #ffffff;
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.2);
}

.btn-register {
    background: linear-gradient(135deg, #e94560 0%, #ff6b6b 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.4);
}

.btn-register:hover {
    background: linear-gradient(135deg, #ff6b6b 0%, #e94560 100%);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(233, 69, 96, 0.6);
}

.menu-toggle {
    display: none;
    background: linear-gradient(135deg, #e94560 0%, #ff6b6b 100%);
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(233, 69, 96, 0.3);
}

.menu-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(233, 69, 96, 0.5);
}

.menu-toggle span {
    display: block;
    width: 22px;
    height: 2.5px;
    background-color: #ffffff;
    margin: 4px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

.nav-mobile {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border-bottom: 2px solid #e94560;
    animation: slideDown 0.3s ease;
    z-index: 999;
}

.nav-mobile ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav-mobile.active {
    display: block;
}

.nav-mobile li {
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    list-style: none;
}

.nav-mobile li:last-child {
    border-bottom: none;
}

.nav-mobile a {
    color: #ffffff;
    display: block;
    padding: 12px 15px;
    border-radius: 5px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.nav-mobile a:hover {
    background-color: rgba(233, 69, 96, 0.15);
    color: #ffffff;
    padding-left: 20px;
}

.nav-mobile li.current-menu-item a,
.nav-mobile li.current_page_item a {
    background-color: #e94560;
    color: #ffffff;
}

.site-content {
    min-height: calc(100vh - 400px);
    padding: 40px 0;
}

.main-content {
    display: flex;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.content-area {
    flex: 1;
    background-color: #ffffff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.sidebar {
    width: 300px;
    background-color: #ffffff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    height: fit-content;
}

.widget {
    margin-bottom: 30px;
}

.widget-title {
    font-size: 18px;
    margin-bottom: 15px;
    color: #1a1a2e;
    border-bottom: 2px solid #e94560;
    padding-bottom: 10px;
}

.site-footer {
    background-color: #1a1a2e;
    color: #ffffff;
    padding: 60px 0 30px;
    margin-top: 60px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 40px;
}

.footer-section h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: #e94560;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #cccccc;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #e94560;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #333;
    color: #999;
}

.hero-section {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    color: #ffffff;
    padding: 80px 0;
    text-align: center;
    margin-bottom: 40px;
}

.hero-section h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.hero-section p {
    font-size: 20px;
    max-width: 800px;
    margin: 0 auto 30px;
}

.content-section {
    padding: 60px 0;
    background-color: #ffffff;
}

.content-section h2 {
    font-size: 36px;
    margin-bottom: 30px;
    color: #1a1a2e;
}

.content-section p {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 20px;
    color: #555;
}

.cta-section {
    background: linear-gradient(135deg, #e94560 0%, #ff6b6b 100%);
    color: #ffffff;
    padding: 60px 0;
    text-align: center;
    margin: 40px 0;
}

.cta-section h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.cta-section .btn {
    background-color: #ffffff;
    color: #e94560;
    font-size: 18px;
    padding: 15px 40px;
    margin-top: 20px;
}

.cta-section .btn:hover {
    background-color: #1a1a2e;
    color: #ffffff;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-card {
    background-color: #f8f9fa;
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.feature-card h3 {
    font-size: 24px;
    margin-bottom: 15px;
    color: #1a1a2e;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

.post-list {
    display: grid;
    gap: 30px;
}

.post-item {
    background-color: #ffffff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.post-item:hover {
    transform: translateY(-5px);
}

.post-item h2 {
    font-size: 28px;
    margin-bottom: 15px;
    color: #1a1a2e;
}

.post-meta {
    color: #999;
    font-size: 14px;
    margin-bottom: 15px;
}

.post-excerpt {
    color: #555;
    line-height: 1.8;
    margin-bottom: 20px;
}

.read-more {
    color: #e94560;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.read-more:hover {
    gap: 10px;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 40px;
}

.pagination a,
.pagination span {
    padding: 10px 15px;
    background-color: #ffffff;
    border-radius: 5px;
    color: #1a1a2e;
    transition: all 0.3s ease;
}

.pagination a:hover,
.pagination .current {
    background-color: #e94560;
    color: #ffffff;
}

.single-post {
    background-color: #ffffff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.single-post h1 {
    font-size: 42px;
    margin-bottom: 20px;
    color: #1a1a2e;
}

.single-post-meta {
    color: #999;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.single-post-content {
    font-size: 18px;
    line-height: 1.8;
    color: #333;
}

.single-post-content h2 {
    font-size: 32px;
    margin: 40px 0 20px;
    color: #1a1a2e;
}

.single-post-content p {
    margin-bottom: 20px;
}

.related-posts {
    margin-top: 60px;
}

.related-posts h3 {
    font-size: 28px;
    margin-bottom: 30px;
    color: #1a1a2e;
}

.search-form {
    display: flex;
    gap: 10px;
}

.search-form input[type="search"] {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid #e94560;
    border-radius: 5px;
    font-size: 16px;
}

.search-form input[type="submit"] {
    padding: 12px 30px;
    background-color: #e94560;
    color: #ffffff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.search-form input[type="submit"]:hover {
    background-color: #ff6b6b;
}

@media (max-width: 768px) {
    .nav-desktop {
        display: none;
    }

    .menu-toggle {
        display: block;
    }

    .auth-buttons {
        display: none;
    }

    .header-container {
        flex-wrap: wrap;
        padding: 0 20px;
    }

    .main-content {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
    }

    .hero-section h1 {
        font-size: 32px;
    }

    .hero-section p {
        font-size: 16px;
    }

    .content-section h2 {
        font-size: 28px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    .single-post h1 {
        font-size: 32px;
    }

    .single-post {
        padding: 20px;
    }

    .content-area {
        padding: 20px;
    }
}

.site-header.scrolled {
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.site-header.scrolled .header-container {
    height: 60px;
}

@media (max-width: 480px) {
    .hero-section {
        padding: 40px 0;
    }

    .content-section {
        padding: 30px 0;
    }

    .btn {
        padding: 8px 20px;
        font-size: 14px;
    }
}
