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

body {
    font-family: 'Inter', 'Arial', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #ffffff;
    /* Performance optimizations */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    /* Improve scrolling performance */
    overflow-x: hidden;
    scroll-behavior: smooth;
    font-display: swap;
}

/* Performance optimizations for all elements */
*, *::before, *::after {
    will-change: auto;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Optimize long content scrolling */
main {
    contain: layout style;
    transform: translateZ(0);
}

/* Optimize text rendering for long articles */
p, h1, h2, h3, h4, h5, h6 {
    contain: layout;
    text-rendering: optimizeSpeed;
}

/* Reduce repaints for sections */
.section {
    contain: layout style;
    transform: translateZ(0);
}

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

/* Header and Navigation */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e5e7eb;
    z-index: 1000;
    transition: all 0.3s ease;
}

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

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    text-decoration: none;
    margin: 0;
}

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

.logo a:hover {
    text-decoration: none;
    color: #3b82f6;
}

.logo a h1 {
    transition: color 0.3s ease;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: #4b5563;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-menu a:hover {
    color: #3b82f6;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #3b82f6;
    transition: width 0.3s ease;
}

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

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: transform 0.2s ease, opacity 0.2s ease, visibility 0.2s ease;
    z-index: 1000;
    list-style: none;
    padding: 8px 0;
    margin-top: 10px;
    /* Performance optimizations */
    will-change: transform, opacity;
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) translateZ(0);
}

.dropdown-menu li {
    margin: 0;
}

.dropdown-menu a {
    display: block;
    padding: 12px 20px;
    color: #4b5563;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.15s ease, color 0.15s ease, padding-left 0.15s ease;
    border-radius: 0;
    /* Performance optimizations */
    will-change: background-color, padding-left;
    transform: translateZ(0);
}

.dropdown-menu a:hover {
    background: #f3f4f6;
    color: #3b82f6;
    padding-left: 24px;
}

.dropdown-menu a::after {
    display: none;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #4b5563;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    margin-top: 70px;
    min-height: 90vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="%23ffffff" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>') repeat;
    opacity: 0.3;
}

.hero-content {
    flex: 1;
    max-width: 600px;
    padding: 0 20px;
    z-index: 2;
    position: relative;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    line-height: 1.5;
}

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

.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.game-icons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    animation: float 6s ease-in-out infinite;
}

.game-icon {
    font-size: 4rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease;
}

.game-icon:hover {
    transform: scale(1.1);
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: #3b82f6;
    color: white;
    border-color: #3b82f6;
}

.btn-primary:hover {
    background: #2563eb;
    border-color: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.3);
}

.btn-secondary {
    background: transparent;
    color: white;
    border-color: white;
}

.btn-secondary:hover {
    background: white;
    color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.3);
}

/* Sections */
.section {
    padding: 80px 0;
}

.section-dark {
    background: #1f2937;
    color: white;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: inherit;
}

.section-subtitle {
    text-align: center;
    font-size: 1.125rem;
    margin-bottom: 3rem;
    opacity: 0.8;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Article Layout with Sidebar */
.article-layout {
    display: flex;
    gap: 3rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 100px 20px 80px;
    align-items: flex-start;
}

.article-sidebar {
    flex: 0 0 280px;
    position: sticky;
    top: 100px;
    background: #f8fafc;
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid #e5e7eb;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.sidebar-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e5e7eb;
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav li {
    margin-bottom: 0.5rem;
}

.sidebar-nav a {
    display: block;
    padding: 0.75rem 1rem;
    color: #4b5563;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.sidebar-nav a:hover {
    background: #e5e7eb;
    color: #3b82f6;
    border-left-color: #3b82f6;
    transform: translateX(4px);
}

.sidebar-nav a.active {
    background: #dbeafe;
    color: #3b82f6;
    border-left-color: #3b82f6;
    font-weight: 600;
}

.sidebar-section {
    margin-bottom: 2rem;
}

.sidebar-section:last-child {
    margin-bottom: 0;
}

.sidebar-section-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
    padding-left: 1rem;
}

.article-content {
    flex: 1;
    min-width: 0;
}

/* Article Typography */
.article-content .section-title {
    text-align: left;
    font-size: 2.25rem;
    margin-bottom: 1.5rem;
    color: #1f2937;
    line-height: 1.2;
}

.article-content h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1f2937;
    margin: 2.5rem 0 1rem 0;
    line-height: 1.3;
    scroll-margin-top: 100px;
}

.article-content h3 {
    font-size: 1.375rem;
    font-weight: 600;
    color: #374151;
    margin: 2rem 0 0.75rem 0;
    line-height: 1.4;
    scroll-margin-top: 100px;
}

.article-content .intro {
    font-size: 1.25rem;
    line-height: 1.7;
    color: #4b5563;
    margin-bottom: 2.5rem;
    padding: 1.5rem;
    background: #f0f9ff;
    border-left: 4px solid #3b82f6;
    border-radius: 0 8px 8px 0;
    font-style: italic;
}

.article-content p {
    font-size: 1.125rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: #374151;
}

.article-content ul {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.article-content li {
    font-size: 1.125rem;
    line-height: 1.7;
    margin-bottom: 0.75rem;
    color: #374151;
}

.article-content strong {
    color: #1f2937;
    font-weight: 600;
}

.article-content em {
    color: #3b82f6;
    font-style: italic;
}

/* Reading Progress Bar */
.reading-progress {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    height: 3px;
    background: #e5e7eb;
    z-index: 999;
}

.reading-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6);
    width: 0%;
    transition: width 0.1s ease;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text p {
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.stats {
    display: grid;
    gap: 2rem;
}

.stat {
    text-align: center;
    padding: 2rem;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.stat h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #3b82f6;
    margin-bottom: 0.5rem;
}

.stat p {
    color: #6b7280;
    font-weight: 500;
}

/* Problem Section */
.problem-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.problem-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    transition: transform 0.3s ease;
}

.problem-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.08);
}

.problem-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.problem-item h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #f9fafb;
}

.problem-item p {
    opacity: 0.8;
    line-height: 1.6;
}

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

.action-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.action-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.action-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.action-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    flex: 1;
}

.action-badge {
    background: #e5e7eb;
    color: #4b5563;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.action-badge.priority {
    background: #fef3c7;
    color: #d97706;
}

.action-card p {
    margin-bottom: 1.5rem;
    line-height: 1.6;
    color: #6b7280;
}

.spread-word {
    background: #f8fafc;
    padding: 3rem;
    border-radius: 16px;
    text-align: center;
    border: 1px solid #e5e7eb;
}

.spread-word h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2937;
}

.spread-word p {
    font-size: 1.125rem;
    margin-bottom: 2rem;
    color: #6b7280;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.share-btn {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.share-btn:hover {
    background: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.3);
}

/* Progress Section */
.timeline {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(-50%);
}

.timeline-item {
    display: flex;
    align-items: center;
    margin-bottom: 3rem;
    position: relative;
}

.timeline-item:nth-child(odd) {
    flex-direction: row;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-marker {
    width: 20px;
    height: 20px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    border: 4px solid #1f2937;
}

.timeline-marker.active {
    background: #3b82f6;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

.timeline-content {
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: calc(50% - 40px);
    margin: 0 20px;
}

.timeline-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #f9fafb;
}

.timeline-content p {
    opacity: 0.8;
    line-height: 1.6;
}



/* Content Page Styles */
.section .intro {
    font-size: 1.2rem;
    font-weight: 300;
    text-align: center;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 40px;
    color: var(--text-light);
}

.section p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 20px;
    color: var(--text-light);
}

.section ul {
    list-style: none;
    padding-left: 20px;
    margin-bottom: 20px;
}

.section ul li {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 15px;
    position: relative;
    padding-left: 25px;
    color: var(--text-light);
}

.section ul li::before {
    content: '✔';
    position: absolute;
    left: 0;
    top: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.section a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.section a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* Blog Section */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.blog-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
    height: fit-content;
}

.blog-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.1);
    border-color: #3b82f6;
}

.blog-header {
    margin-bottom: 1rem;
}

.blog-category {
    display: inline-block;
    background: #3b82f6;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.blog-card h3 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.3;
}

.blog-card h3 a {
    color: #1f2937;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-card h3 a:hover {
    color: #3b82f6;
}

.blog-excerpt {
    color: #6b7280;
    line-height: 1.6;
    margin: 1rem 0 1.5rem 0;
}

.blog-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.blog-tag {
    background: #f3f4f6;
    color: #4b5563;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
}

.blog-read-more {
    display: inline-flex;
    align-items: center;
    color: #3b82f6;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.blog-read-more:hover {
    color: #2563eb;
    transform: translateX(4px);
}

/* Footer */
.footer {
    background: #111827;
    color: white;
    padding: 3rem 0 1rem;
}

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

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
    color: #f9fafb;
}

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

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #3b82f6;
}

.footer-bottom {
    border-top: 1px solid #374151;
    padding-top: 2rem;
    text-align: center;
    color: #9ca3af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .hero {
        flex-direction: column;
        text-align: center;
        padding: 2rem 0;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .actions-grid {
        grid-template-columns: 1fr;
    }
    
    .timeline::before {
        left: 20px;
    }
    
    .timeline-item {
        flex-direction: row !important;
    }
    
    .timeline-marker {
        left: 20px;
        transform: translateX(-50%);
    }
    
    .timeline-content {
        width: calc(100% - 60px);
        margin-left: 40px;
        margin-right: 0;
    }
    
    .share-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .share-btn {
        width: 200px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .game-icons {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .game-icon {
        font-size: 3rem;
        padding: 1.5rem;
    }
    
    .action-card,
    .spread-word {
        padding: 1.5rem;
    }
}

/* Article Layout Responsive Design */
@media (max-width: 1024px) {
    .article-layout {
        gap: 2rem;
        padding: 100px 15px 80px;
    }
    
    .article-sidebar {
        flex: 0 0 250px;
        padding: 1.5rem;
    }
}

@media (max-width: 768px) {
    .article-layout {
        flex-direction: column;
        gap: 2rem;
        padding: 90px 15px 60px;
    }
    
    .article-sidebar {
        position: static;
        flex: none;
        width: 100%;
        max-height: none;
        order: -1;
        margin-bottom: 1rem;
    }
    
    .sidebar-title {
        font-size: 1.125rem;
        margin-bottom: 1rem;
    }
    
    .sidebar-nav {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 0.5rem;
    }
    
    .sidebar-nav a {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
        text-align: center;
    }
    
    .article-content .section-title {
        font-size: 1.875rem;
        text-align: center;
    }
    
    .article-content h2 {
        font-size: 1.5rem;
        margin: 2rem 0 0.75rem 0;
    }
    
    .article-content h3 {
        font-size: 1.25rem;
        margin: 1.5rem 0 0.5rem 0;
    }
    
    .article-content .intro {
        font-size: 1.125rem;
        padding: 1.25rem;
    }
    
    .article-content p {
        font-size: 1rem;
    }
    
    .article-content li {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .article-layout {
        padding: 80px 10px 50px;
    }
    
    .article-sidebar {
        padding: 1rem;
        border-radius: 8px;
    }
    
    .sidebar-nav {
        grid-template-columns: 1fr;
    }
    
    .article-content .section-title {
        font-size: 1.625rem;
    }
    
    .article-content h2 {
        font-size: 1.375rem;
    }
    
    .article-content .intro {
        font-size: 1rem;
        padding: 1rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease-out;
}

/* Focus styles for accessibility */
.btn:focus,
.nav-menu a:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 1000;
    will-change: transform, opacity;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.back-to-top:active {
    transform: translateY(0);
}

.back-to-top svg {
    width: 24px;
    height: 24px;
    transition: transform 0.2s ease;
}

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

/* Mobile responsive for back to top */
@media (max-width: 768px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
    
    .back-to-top svg {
        width: 20px;
        height: 20px;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .hero {
        background: #000;
    }
    
    .section-dark {
        background: #000;
    }
    
    .btn-primary {
        background: #000;
        border-color: #fff;
    }
}