/* betmatchcore.pro - Shared Stylesheet */
:root {
    --bg-color: #0a0c12;
    --bg-card: #121622;
    --bg-card-hover: #1a2032;
    --accent-color: #44ddff;
    --accent-glow: rgba(68, 221, 255, 0.15);
    --accent-glow-strong: rgba(68, 221, 255, 0.4);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: #1e293b;
    --border-accent: rgba(68, 221, 255, 0.3);
    --success: #10b981;
    --danger: #ef4444;
    --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.02em;
    color: #ffffff;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
}

h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    position: relative;
    padding-bottom: 0.75rem;
    margin-bottom: 2rem;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 4px;
    background-color: var(--accent-color);
    border-radius: 2px;
    box-shadow: 0 0 10px var(--accent-color);
}

h3 {
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
}

p {
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: #ffffff;
    text-shadow: 0 0 8px var(--accent-color);
}

/* Layout Containers */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(10, 12, 18, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.75rem;
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo span {
    color: var(--accent-color);
    text-shadow: 0 0 15px var(--accent-glow-strong);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    padding: 0.5rem 0;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--accent-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent-color);
    transition: var(--transition);
    box-shadow: 0 0 8px var(--accent-color);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Burger Menu */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
    z-index: 1001;
}

.burger-menu span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: #ffffff;
    border-radius: 3px;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    padding: 160px 0 100px;
    position: relative;
    background: radial-gradient(circle at 80% 20%, var(--accent-glow) 0%, transparent 50%),
                radial-gradient(circle at 20% 80%, rgba(30, 41, 59, 0.5) 0%, transparent 50%);
    border-bottom: 1px solid var(--border-color);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.hero-content {
    max-width: 680px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--accent-glow);
    border: 1px solid var(--border-accent);
    color: var(--accent-color);
    padding: 0.5rem 1rem;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 15px var(--accent-glow);
}

.hero-title {
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-desc {
    font-size: 1.15rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.85rem 2rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition);
    cursor: pointer;
}

.btn-primary {
    background-color: var(--accent-color);
    color: var(--bg-color);
    box-shadow: 0 4px 20px rgba(68, 221, 255, 0.3);
}

.btn-primary:hover {
    background-color: #ffffff;
    color: var(--bg-color);
    box-shadow: 0 4px 25px rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: #ffffff;
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.05);
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

/* Image Wrapper and Fallbacks */
.image-wrapper {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    background-color: var(--bg-card);
    aspect-ratio: 16 / 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.image-fallback {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    text-align: center;
    background: linear-gradient(135deg, #121622 0%, #0a0c12 100%);
    z-index: 1;
}

.image-fallback svg {
    width: 64px;
    height: 64px;
    margin-bottom: 1rem;
    color: var(--accent-color);
    filter: drop-shadow(0 0 10px var(--accent-color));
}

.image-fallback h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.image-fallback p {
    font-size: 0.85rem;
    max-width: 280px;
    margin-bottom: 0;
}

/* Sections General */
section {
    padding: 100px 0;
    border-bottom: 1px solid var(--border-color);
}

.section-header {
    max-width: 700px;
    margin-bottom: 4rem;
}

.section-subtitle {
    color: var(--accent-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    display: block;
}

/* Section 2: Mechanics Grid */
.mechanics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2rem;
    margin-bottom: 4rem;
}

.mechanic-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2.5rem 2rem;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.mechanic-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    transform: translateX(-100%);
    transition: var(--transition);
}

.mechanic-card:hover {
    background-color: var(--bg-card-hover);
    border-color: var(--border-accent);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(68, 221, 255, 0.05);
}

.mechanic-card:hover::before {
    transform: translateX(100%);
    transition: all 0.8s ease;
}

.mechanic-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    background-color: var(--accent-glow);
    border: 1px solid var(--border-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--accent-color);
}

.mechanic-icon svg {
    width: 24px;
    height: 24px;
}

.mechanic-formula {
    background-color: rgba(10, 12, 18, 0.6);
    border-left: 3px solid var(--accent-color);
    padding: 0.75rem 1rem;
    border-radius: 0 6px 6px 0;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9rem;
    color: #ffffff;
    margin: 1rem 0;
}

.mechanic-example {
    font-size: 0.85rem;
    color: var(--text-muted);
    border-top: 1px solid var(--border-color);
    padding-top: 0.75rem;
    margin-top: 1rem;
}

/* Section 3: Statistics Tables */
.stats-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100%, 1fr));
    gap: 2.5rem;
}

@media (min-width: 992px) {
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.table-wrapper {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    overflow-x: auto;
}

.table-title-container {
    margin-bottom: 1.5rem;
}

.table-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
    margin-bottom: 0;
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}

th {
    background-color: rgba(10, 12, 18, 0.4);
    color: var(--accent-color);
    font-weight: 700;
    padding: 1rem;
    border-bottom: 2px solid var(--border-color);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.02);
}

.badge-stat {
    background-color: rgba(68, 221, 255, 0.1);
    color: var(--accent-color);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Section 4: Calculation Examples */
.calculations-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .calculations-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .calc-card:nth-child(5) {
        grid-column: span 2;
    }
}

@media (min-width: 1024px) {
    .calculations-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .calc-card:nth-child(4), .calc-card:nth-child(5) {
        grid-column: span 1;
    }
}

.calc-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.calc-num {
    font-size: 2.5rem;
    font-weight: 900;
    color: rgba(68, 221, 255, 0.15);
    line-height: 1;
    margin-bottom: 1rem;
}

.calc-steps {
    background-color: rgba(10, 12, 18, 0.5);
    border: 1px dashed var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    margin-top: auto;
}

.calc-step-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    padding: 0.35rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.calc-step-item:last-child {
    border-bottom: none;
    font-weight: 700;
    color: var(--accent-color);
}

/* Section 5: Community Research */
.community-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}

.community-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    position: relative;
}

.community-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-color) 0%, #1e293b 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--bg-color);
}

.author-info h4 {
    font-size: 1rem;
    margin-bottom: 0.1rem;
}

.author-info span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.community-formula {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.85rem;
    color: var(--accent-color);
    background-color: rgba(68, 221, 255, 0.05);
    padding: 0.5rem;
    border-radius: 4px;
    text-align: center;
    margin-top: 1rem;
    border: 1px solid rgba(68, 221, 255, 0.1);
}

/* Legal Pages Styling */
.legal-page {
    padding: 140px 0 80px;
}

.legal-container {
    max-width: 800px;
    margin: 0 auto;
}

.legal-header {
    text-align: center;
    margin-bottom: 4rem;
}

.legal-header h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

.legal-meta {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.legal-content section {
    padding: 2.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.legal-content section:last-child {
    border-bottom: none;
}

.legal-content h2 {
    font-size: 1.5rem;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
}

.legal-content h2::after {
    width: 40px;
    height: 3px;
}

.legal-content p {
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.legal-content ul {
    margin-bottom: 1.5rem;
    padding-left: 1.5rem;
}

.legal-content li {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

/* Footer */
footer {
    background-color: #05060a;
    border-top: 1px solid var(--border-color);
    padding: 50px 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    margin-bottom: 3rem;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr;
    }
}

.footer-brand p {
    margin-top: 1rem;
    max-width: 320px;
}

.footer-links h4 {
    font-size: 1.1rem;
    margin-bottom: 1.25rem;
    color: #ffffff;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-links h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 25px;
    height: 2px;
    background-color: var(--accent-color);
}

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

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--accent-color);
    padding-left: 4px;
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
    }
}

.footer-bottom p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0;
}

.footer-bottom-links {
    display: flex;
    gap: 1.5rem;
}

.footer-bottom-links a {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-bottom-links a:hover {
    color: var(--accent-color);
}

/* Responsive Navigation Implementation */
@media (max-width: 768px) {
    .burger-menu {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background-color: var(--bg-color);
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        padding-top: 3rem;
        gap: 2.5rem;
        transition: var(--transition);
        border-top: 1px solid var(--border-color);
        z-index: 999;
    }

    .nav-links.active {
        left: 0;
    }

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

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

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

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }

    .hero-content {
        margin: 0 auto;
    }

    .hero-actions {
        justify-content: center;
    }
}
