/* Modern Rules Page CSS with Aqua Accent Color */
:root {
    --primary-color: #00FFFF;      /* Aqua */
    --primary-dark: #00CCCC;       /* Darker Aqua */
    --primary-light: #66FFFF;      /* Lighter Aqua */
    --secondary-color: #1a1a1a;    /* Dark Gray */
    --background: #0f0f0f;         /* Very Dark Background */
    --surface: #1e1e1e;            /* Slightly lighter surface */
    --surface-light: #2a2a2a;      /* Even lighter surface */
    --text-primary: #ffffff;        /* White text */
    --text-secondary: #b3b3b3;     /* Light gray text */
    --border-color: #333333;       /* Border color */
    --success-color: #44ff44;      /* Success green */
    --warning-color: #ffaa00;      /* Warning orange */
    --danger-color: #ff4444;       /* Danger red */
    --info-color: #4488ff;         /* Info blue */
    --shadow: 0 4px 20px rgba(0, 255, 255, 0.1);
    --shadow-hover: 0 8px 30px rgba(0, 255, 255, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(15, 15, 15, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-logo a {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-logo a:hover {
    color: var(--primary-light);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
    z-index: 1001;
    position: relative;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    transition: all 0.3s ease;
    border-radius: 2px;
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(15, 15, 15, 0.98);
    backdrop-filter: blur(10px);
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.mobile-menu-nav a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.mobile-menu-nav a:hover,
.mobile-menu-nav a.active {
    color: var(--primary-color);
}

.mobile-menu-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    margin-top: 2rem;
}

/* Buttons */
.btn-primary,
.btn-secondary {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--background);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

/* Rules Page */
.rules-page {
    padding-top: 120px;
    padding-bottom: 4rem;
    min-height: 100vh;
}

/* Page Header */
.page-header {
    text-align: center;
    margin-bottom: 4rem;
    padding: 3rem 0;
    background: var(--surface);
    border-radius: 16px;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
}

.header-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-header p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.breadcrumb {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--primary-light);
}

.breadcrumb i {
    font-size: 0.7rem;
}

/* Rules Content */
.rules-content {
    max-width: 1000px;
    margin: 0 auto;
}

/* Rules Intro */
.rules-intro {
    margin-bottom: 3rem;
}

.intro-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    border-left: 4px solid var(--warning-color);
}

.intro-icon {
    font-size: 2rem;
    color: var(--warning-color);
    min-width: 60px;
    text-align: center;
}

.intro-text h3 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.intro-text p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Rules Grid */
.rules-grid {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.rule-category {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.rule-category:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow);
}

.rule-category.active {
    border-color: var(--primary-color);
}

.rule-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: var(--surface-light);
}

.rule-header:hover {
    background: var(--background);
}

.rule-icon {
    font-size: 1.5rem;
    color: var(--primary-color);
    min-width: 40px;
    text-align: center;
}

.rule-header h3 {
    flex: 1;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    text-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
    transition: text-shadow 0.3s ease;
}

.rule-category:hover .rule-header h3 {
    text-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

.rule-category.active .rule-header h3 {
    color: var(--primary-color);
    text-shadow: 0 0 20px rgba(0, 255, 255, 0.6);
}

.toggle-icon {
    font-size: 1rem;
    color: var(--text-secondary);
    transition: transform 0.3s ease;
}

.rule-category.active .toggle-icon {
    transform: rotate(180deg);
}

.rule-content {
    display: none;
    padding: 1.5rem 2rem 2rem 2rem;
}

.rule-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--background);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.rule-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-color);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.rule-item:hover::before {
    opacity: 1;
}

.rule-item:hover {
    background: var(--surface-light);
    transform: translateX(8px);
}

.rule-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.rule-number {
    min-width: 65px;
    height: 45px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: var(--background);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
    font-family: 'Inter', sans-serif;
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.rule-number::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    right: 2px;
    bottom: 2px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
    border-radius: 10px;
    pointer-events: none;
}

.rule-item:hover .rule-number {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 255, 255, 0.4);
}

/* For terms section with abbreviations */
[data-category="terms"] .rule-number {
    min-width: 55px;
    height: 55px;
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    box-shadow: 0 4px 15px rgba(0, 255, 255, 0.25);
}

[data-category="terms"] .rule-number::before {
    border-radius: 50%;
}

.rule-text h4 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.rule-text p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Rules Footer */
.rules-footer {
    margin-top: 4rem;
}

.footer-card {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2.5rem;
    text-align: center;
    border-left: 4px solid var(--danger-color);
}

.footer-content-rules {
    display: grid;
    gap: 1rem;
    padding: 1rem 1% 1rem 1%;
    max-width: none;
}

.footer-icon {
    font-size: 2.5rem;
    color: var(--danger-color);
    margin-bottom: 0.5rem;
}

.footer-content-rules h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.4rem;
}

.footer-content-rules p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.contact-btn {
    background: var(--primary-color);
    color: var(--background);
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    align-items: center;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.contact-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .nav {
        padding: 1rem;
    }
    
    .nav-menu,
    .nav-actions {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .rules-page {
        padding-top: 100px;
    }
    
    .page-header {
        padding: 2rem 1.5rem;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
    
    .intro-card {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }
    
    .rule-header {
        padding: 1.25rem 1.5rem;
    }
    
    .rule-content {
        padding: 0 1.5rem 1.5rem 1.5rem;
    }
    
    .rule-item {
        flex-direction: column;
        gap: 1rem;
    }
    
    .rule-number {
        align-self: flex-start;
    }
    
    .footer-card {
        padding: 2rem 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.8rem;
    }
    
    .rule-header h3 {
        font-size: 1.1rem;
    }
    
    .breadcrumb {
        flex-wrap: wrap;
    }
}

/* Smooth scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Loading animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.rule-category {
    animation: fadeInUp 0.6s ease forwards;
}

.rule-category:nth-child(2) { animation-delay: 0.1s; }
.rule-category:nth-child(3) { animation-delay: 0.2s; }
.rule-category:nth-child(4) { animation-delay: 0.3s; }
.rule-category:nth-child(5) { animation-delay: 0.4s; }
.rule-category:nth-child(6) { animation-delay: 0.5s; }
