/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #1e3a8a;
    --secondary-color: #1e40af;
    --accent-color: #fbbf24;
    --text-dark: #0f172a;
    --text-light: #64748b;
    --bg-light: #f8fafc;
    --bg-dark: #0f172a;
    --border-color: #e2e8f0;
    --success-color: #3b82f6;
    --shadow: 0 2px 10px rgba(15, 23, 42, 0.1);
    --shadow-lg: 0 10px 40px rgba(15, 23, 42, 0.2);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Sarabun', Arial, sans-serif;
    line-height: 1.6;
    color: #e2e8f0;
    background: #0f172a;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: white;
    padding: 10px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 15px rgba(15, 23, 42, 0.4);
    border-bottom: 3px solid #fbbf24;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.logo h1 {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.nav-menu {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.nav-menu a {
    color: white;
    padding: 8px 16px;
    border-radius: 5px;
    transition: background 0.3s;
    font-weight: 500;
}

.nav-menu a:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-admin {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #1a1a1a !important;
    font-weight: 700;
    border: 2px solid #f59e0b;
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 26px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.mobile-menu-toggle span {
    display: block;
    width: 100%;
    height: 2.5px;
    background: white;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: translateY(8.75px) rotate(45deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: translateY(-8.75px) rotate(-45deg);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%);
    color: white;
    padding: 80px 20px;
    text-align: center;
    border-top: 3px solid #fbbf24;
    border-bottom: 3px solid #fbbf24;
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
}

.hero-title {
    font-size: 48px;
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 40px;
    opacity: 0.95;
}

.hero-features {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.hero-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.15);
    padding: 15px 25px;
    border-radius: 50px;
    backdrop-filter: blur(10px);
}

.feature-icon {
    font-size: 24px;
}

/* Top Casinos Section */
.top-casinos {
    padding: 30px 20px 40px;
    background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
}

.section-info {
    text-align: center;
    padding: 40px 20px;
    background: rgba(30, 41, 59, 0.5);
    border-radius: 15px;
    border: 2px solid rgba(251, 191, 36, 0.3);
}

.section-title {
    font-size: 36px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 15px;
    color: #fbbf24;
}

.section-subtitle {
    font-size: 18px;
    text-align: center;
    color: #cbd5e1;
    margin-bottom: 0;
}

.casino-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

.casino-row {
    display: flex;
    align-items: center;
    height: 150px;
    background: linear-gradient(90deg, #1e293b 0%, #334155 100%);
    border: 2px solid #fbbf24;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.casino-row:hover {
    transform: translateX(5px);
    box-shadow: 0 8px 30px rgba(251, 191, 36, 0.4);
    border-color: #f59e0b;
}

.casino-rank {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100px;
    height: 150px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    flex-shrink: 0;
}

.rank-number {
    font-size: 60px;
    font-weight: 900;
    color: #1a1a1a;
    line-height: 1;
}

.casino-banner-link {
    display: block;
    width: 250px;
    height: 150px;
    flex-shrink: 0;
}

.casino-banner {
    width: 100%;
    height: 100%;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.casino-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.casino-banner-link:hover .casino-banner img {
    transform: scale(1.05);
}

.casino-info {
    flex: 1;
    padding: 15px 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.casino-info .casino-name {
    font-size: 24px;
    font-weight: 700;
    color: #fbbf24;
    margin: 0 0 10px 0;
    line-height: 1.2;
}

.casino-info .casino-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.casino-info .casino-features li {
    font-size: 13px;
    color: #cbd5e1;
    line-height: 1.4;
}

.casino-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px 25px;
    gap: 10px;
    flex-shrink: 0;
}

.casino-action .casino-bonus {
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    color: white;
    padding: 8px 15px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}

.casino-action .btn-casino {
    display: inline-block;
    padding: 12px 30px;
    background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 700;
    font-size: 16px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.casino-action .btn-casino:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    transform: scale(1.05);
}

.rank-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #1a1a1a;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(251, 191, 36, 0.5);
    border: 3px solid #fff;
    z-index: 10;
}

.rank-number {
    font-size: 28px;
    line-height: 1;
}

.rank-label {
    font-size: 11px;
}

/* Old card styles removed - now using horizontal row layout */

/* About Section */
.about-section {
    padding: 50px 20px;
    background: #1e293b;
}

.about-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.about-card {
    background: #0f172a;
    padding: 30px;
    border-radius: 10px;
    border-left: 4px solid #fbbf24;
}

.about-card h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 15px;
    color: #fbbf24;
}

.about-card p {
    color: #cbd5e1;
    line-height: 1.8;
}

.about-card strong {
    color: #fbbf24;
    font-weight: 600;
}

/* Keywords Section */
.keywords-section {
    padding: 50px 20px;
    background: #0f172a;
}

.keywords-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.keyword-item {
    background: #1e293b;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    text-align: center;
    transition: transform 0.3s;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.keyword-item:hover {
    transform: translateY(-5px);
    border-color: #fbbf24;
}

.keyword-item h3 {
    font-size: 20px;
    font-weight: 700;
    color: #fbbf24;
    margin-bottom: 10px;
}

.keyword-item p {
    color: #cbd5e1;
    font-size: 14px;
}

/* SEO Content Section */
.seo-content {
    padding: 50px 20px;
    background: #1e293b;
}

.content-box {
    background: #0f172a;
    padding: 40px;
    border-radius: 10px;
    line-height: 1.8;
    color: #cbd5e1;
    border: 1px solid rgba(251, 191, 36, 0.2);
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: white;
    padding: 60px 20px 30px;
    border-top: 3px solid #fbbf24;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h4 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #fbbf24;
}

.footer-section p {
    color: #bbb;
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    padding: 8px 0;
}

.footer-section ul li a {
    color: #bbb;
    transition: color 0.3s;
}

.footer-section ul li a:hover {
    color: #fbbf24;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: #bbb;
    margin-bottom: 10px;
}

.disclaimer {
    font-size: 14px;
    opacity: 0.7;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white;
    border: 2px solid #fbbf24;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(30, 58, 138, 0.4);
    transition: transform 0.3s;
    z-index: 999;
}

.back-to-top:hover {
    transform: translateY(-5px);
}

.back-to-top.show {
    display: flex;
}

/* Responsive Design */
@media (max-width: 768px) {
    /* ลดช่องว่างด้านข้างในมือถือ */
    .container {
        padding: 0 8px;
    }
    
    .header,
    .top-casinos,
    .about-section,
    .keywords-section,
    .seo-content {
        padding-left: 8px;
        padding-right: 8px;
    }
    
    .hero-title {
        font-size: 32px;
    }

    .hero-subtitle {
        font-size: 18px;
    }

    .section-title {
        font-size: 28px;
    }

    /* Mobile: Compact horizontal row layout */
    .casino-row {
        height: auto;
        min-height: 100px;
        gap: 0;
        flex-wrap: wrap;
    }
    
    .casino-rank {
        width: 30px;
        height: 100px;
        flex-shrink: 0;
    }
    
    .rank-number {
        font-size: 32px;
        font-weight: 900;
        text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    }
    
    .casino-banner-link {
        width: calc(100% - 30px);
        height: 100px;
        flex-shrink: 0;
    }
    
    .casino-info {
        width: 60%;
        padding: 8px 10px;
        min-width: 0;
        flex-shrink: 0;
    }
    
    .casino-info .casino-name {
        font-size: 14px;
        margin-bottom: 5px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .casino-info .casino-features {
        flex-direction: column;
        gap: 2px;
    }
    
    .casino-info .casino-features li {
        font-size: 10px;
        line-height: 1.2;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .casino-action {
        flex-direction: column;
        padding: 8px;
        gap: 6px;
        width: 40%;
        justify-content: center;
        flex-shrink: 0;
    }
    
    .casino-action .casino-bonus {
        font-size: 9px;
        padding: 4px 8px;
        white-space: nowrap;
        text-align: center;
    }
    
    .casino-action .btn-casino {
        font-size: 12px;
        padding: 8px 12px;
        white-space: nowrap;
    }
    
    /* Removed scroll hint - no longer needed for vertical list */

    .nav-container {
        position: relative;
        padding: 0 15px;
    }

    .header {
        padding: 8px 0;
    }

    .logo {
        flex: 1;
        max-width: calc(100% - 40px);
    }

    .logo h1 {
        font-size: 15px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 45px;
        left: 0;
        right: 0;
        background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
        flex-direction: column;
        padding: 0 15px;
        gap: 8px;
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        visibility: hidden;
        transition: max-height 0.3s ease, opacity 0.3s ease, padding 0.3s ease;
        box-shadow: 0 5px 15px rgba(15, 23, 42, 0.5);
        border-bottom: 3px solid #fbbf24;
    }

    .nav-menu.active {
        max-height: 400px;
        opacity: 1;
        visibility: visible;
        padding: 15px;
    }

    .nav-menu a {
        padding: 10px 14px;
        text-align: center;
        border-radius: 5px;
    }

    .hero {
        padding: 30px 20px;
    }

    .top-casinos {
        padding: 20px 8px 25px;
    }

    .about-section,
    .keywords-section,
    .seo-content {
        padding: 25px 8px;
    }
    
    .content-box {
        padding: 20px;
    }

    .section-title {
        font-size: 24px;
        margin-bottom: 10px;
    }

    .section-subtitle {
        font-size: 14px;
        margin-bottom: 25px;
    }

    .footer {
        padding: 40px 20px 20px;
    }

    .content-box {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 6px 0;
    }

    .nav-container {
        padding: 0 12px;
    }

    .logo {
        max-width: calc(100% - 35px);
    }

    .logo h1 {
        font-size: 13px;
    }

    .mobile-menu-toggle {
        width: 24px;
        height: 18px;
    }

    .mobile-menu-toggle span {
        height: 2px;
    }

    .mobile-menu-toggle.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .mobile-menu-toggle.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .hero {
        padding: 25px 15px;
    }

    .hero-title {
        font-size: 20px;
        margin-bottom: 10px;
    }

    .hero-subtitle {
        font-size: 14px;
        margin-bottom: 20px;
    }

    .hero-features {
        flex-direction: column;
        gap: 10px;
    }

    .hero-feature {
        padding: 10px 18px;
        font-size: 14px;
    }

    .section-title {
        font-size: 18px;
        line-height: 1.3;
    }

    .section-subtitle {
        font-size: 13px;
        line-height: 1.4;
    }

    .top-casinos {
        padding: 15px 10px 25px;
    }

    .casino-grid {
        padding-bottom: 10px;
    }

    .about-section,
    .keywords-section,
    .seo-content {
        padding: 25px 15px;
    }

    .casino-name {
        font-size: 20px;
    }

    .casino-content {
        padding: 20px;
    }

    .nav-menu {
        top: 35px;
        padding: 0 12px;
        gap: 6px;
    }

    .nav-menu.active {
        padding: 12px;
    }

    .nav-menu a {
        padding: 9px 12px;
        font-size: 14px;
    }

    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
    }
}

/* Print Styles */
@media print {
    .header,
    .back-to-top,
    .btn-casino {
        display: none;
    }

    body {
        background: white;
    }

    .casino-card {
        page-break-inside: avoid;
    }
}

