/* We The Forsaken - Website Styles */
/* Color palette extracted from logo */

:root {
    /* Logo colors */
    --lava-core: #E64A19;
    --flame-edge: #FFB300;
    --stone-shadow: #3E2723;
    --cool-rim: #1976D2;
    --cold-shadow: #0D47A1;
    --bg-pure-black: #0B0B0D;

    /* UI colors */
    --primary-accent: #E64A19;      /* Lava core red for buttons */
    --secondary-accent: #1976D2;    /* Cool rim blue for links */
    --bg-dark: #0F0F10;             /* Matte black background */
    --bg-card: #1A1A1D;             /* Slightly lighter panels */
    --text-light: #EAEAEA;          /* Off-white text */
    --text-muted: #9E9E9E;          /* Grey for labels */
    --border-color: #2a2a2a;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg-dark);
    color: var(--text-light);
    line-height: 1.6;
}

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

/* Hero Header with Logo */
header {
    background: radial-gradient(ellipse at center, rgba(230, 74, 25, 0.15) 0%, var(--bg-pure-black) 70%);
    padding: 60px 20px 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(25, 118, 210, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(230, 74, 25, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.logo-container {
    position: relative;
    margin-bottom: 30px;
    filter: drop-shadow(0 0 30px rgba(230, 74, 25, 0.5));
}

.logo-container img {
    max-width: 500px;
    width: 100%;
    height: auto;
    animation: logoGlow 4s ease-in-out infinite;
}

@keyframes logoGlow {
    0%, 100% {
        filter: drop-shadow(0 0 20px rgba(230, 74, 25, 0.6)) drop-shadow(0 0 40px rgba(25, 118, 210, 0.3));
    }
    50% {
        filter: drop-shadow(0 0 30px rgba(230, 74, 25, 0.8)) drop-shadow(0 0 50px rgba(25, 118, 210, 0.5));
    }
}

.game-title {
    font-size: 1.82rem;
    color: var(--text-light);
    margin-bottom: 15px;
    margin-top: 20px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 15px rgba(230, 74, 25, 0.5);
}

.tagline {
    font-size: 1.4rem;
    color: var(--text-light);
    margin-bottom: 30px;
    font-weight: 500;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.9rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-accent), var(--lava-core));
    color: white;
    box-shadow: 0 4px 15px rgba(233, 113, 96, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(233, 113, 96, 0.6);
    filter: brightness(1.1);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-light);
    border-color: var(--secondary-accent);
}

.btn-secondary:hover {
    background: var(--secondary-accent);
    color: var(--bg-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(97, 167, 153, 0.4);
}

.links {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 20px;
}

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

.section h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: var(--text-light);
    position: relative;
    padding-bottom: 15px;
}

.section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-accent), var(--secondary-accent));
    border-radius: 2px;
}

/* Downloads Section */
.download-category {
    margin-bottom: 50px;
}

.download-category h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.badge {
    font-size: 0.75rem;
    padding: 4px 12px;
    border-radius: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-nightly {
    background: var(--flame-edge);
    color: #000;
}

.badge-stable {
    background: var(--secondary-accent);
    color: #000;
}

.description {
    color: var(--text-muted);
    margin-bottom: 25px;
    font-size: 1.1rem;
}

.builds-container {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 30px;
    border: 1px solid var(--border-color);
}

.build-info {
    background: var(--bg-dark);
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    border-left: 3px solid var(--primary-accent);
}

.build-info p {
    margin: 0;
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.build-info .commit {
    color: var(--secondary-accent);
    font-weight: 600;
}

.downloads {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.download-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
    background: linear-gradient(135deg, #1a1a1d 0%, #252528 100%);
    border: 2px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-light);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.download-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(230, 74, 25, 0.15), transparent);
    transition: left 0.5s ease;
}

.download-button:hover::before {
    left: 100%;
}

.download-button:hover {
    border-color: var(--primary-accent);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(230, 74, 25, 0.4);
    background: linear-gradient(135deg, #252528 0%, #2a2a2d 100%);
}

.download-button::after {
    content: '↓';
    font-size: 1.8rem;
    color: var(--secondary-accent);
    font-weight: bold;
}

.loading {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
    font-style: italic;
}

.error {
    background: rgba(230, 74, 25, 0.1);
    border: 1px solid var(--lava-core);
    border-radius: 8px;
    padding: 20px;
    color: var(--primary-accent);
}

/* Info Box */
.info-box {
    background: rgba(255, 179, 0, 0.08);
    border-left: 4px solid var(--flame-edge);
    padding: 20px;
    border-radius: 8px;
    margin-top: 25px;
}

.info-box strong {
    color: var(--flame-edge);
}

.info-box code {
    display: block;
    margin-top: 10px;
    padding: 10px;
    background: var(--bg-dark);
    border-radius: 6px;
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.85rem;
    color: var(--secondary-accent);
}

/* About Grid */
.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.about-card {
    background: var(--bg-card);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.about-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 0;
    background: linear-gradient(180deg, var(--primary-accent), var(--secondary-accent));
    transition: height 0.3s ease;
}

.about-card:hover::before {
    height: 100%;
}

.about-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(233, 113, 96, 0.2);
}

.about-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--text-light);
}

/* Features List */
.features-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 15px;
}

.features-list li {
    background: var(--bg-card);
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid var(--primary-accent);
    transition: all 0.3s ease;
}

.features-list li:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(233, 113, 96, 0.2);
}

.features-list li::before {
    content: '✓';
    color: var(--secondary-accent);
    font-weight: bold;
    margin-right: 10px;
}

/* Controls Grid */
.controls-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.control-item {
    background: var(--bg-card);
    padding: 25px;
    border-radius: 8px;
    text-align: center;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.control-item:hover {
    border-color: var(--secondary-accent);
    box-shadow: 0 4px 15px rgba(97, 167, 153, 0.2);
}

.control-item kbd {
    display: block;
    background: var(--bg-dark);
    padding: 12px 20px;
    border-radius: 6px;
    font-weight: 600;
    margin-bottom: 12px;
    border: 2px solid var(--secondary-accent);
    font-size: 1.1rem;
    color: var(--text-light);
}

.control-item span {
    color: var(--text-muted);
}

/* Tech Grid */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.tech-item {
    background: var(--bg-card);
    padding: 25px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.tech-item:hover {
    border-color: var(--primary-accent);
    box-shadow: 0 4px 15px rgba(233, 113, 96, 0.2);
}

.tech-item h4 {
    color: var(--secondary-accent);
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.tech-item p {
    color: var(--text-muted);
}

/* Footer */
footer {
    background: var(--bg-card);
    padding: 40px 20px;
    text-align: center;
    border-top: 2px solid var(--primary-accent);
    margin-top: 60px;
}

footer p {
    color: var(--text-muted);
    margin: 10px 0;
}

footer a {
    color: var(--secondary-accent);
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--primary-accent);
}

/* Responsive */
@media (max-width: 768px) {
    .logo-container img {
        max-width: 300px;
    }

    .tagline {
        font-size: 1.1rem;
    }

    .section h2 {
        font-size: 2rem;
    }

    .downloads {
        grid-template-columns: 1fr;
    }

    .about-grid,
    .controls-grid,
    .tech-grid,
    .features-list {
        grid-template-columns: 1fr;
    }
}

/* Smooth Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section {
    animation: fadeIn 0.6s ease-out;
}

/* Glow effects for interactive elements */
.btn-primary:hover,
.download-button:hover {
    filter: drop-shadow(0 0 10px rgba(230, 74, 25, 0.5));
}

.btn-secondary:hover {
    filter: drop-shadow(0 0 10px rgba(25, 118, 210, 0.5));
}

/* Download Modal */
.download-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(11, 11, 13, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
    backdrop-filter: blur(5px);
}

.download-modal.show {
    opacity: 1;
}

.modal-content {
    background: var(--bg-card);
    border-radius: 12px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    border: 2px solid var(--border-color);
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.download-modal.show .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 2rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(230, 74, 25, 0.2);
    color: var(--primary-accent);
}

.modal-body {
    padding: 40px 30px;
}

.modal-body h3 {
    color: var(--flame-edge);
    margin-bottom: 20px;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-body p {
    color: var(--text-light);
    margin-bottom: 15px;
    line-height: 1.8;
}

.modal-body ol {
    color: var(--text-light);
    margin-left: 20px;
    line-height: 2;
}

.modal-body ol li {
    margin-bottom: 12px;
}

.modal-body ol li strong {
    color: var(--secondary-accent);
}

.modal-body pre {
    background: var(--bg-dark);
    padding: 15px;
    border-radius: 8px;
    border-left: 3px solid var(--secondary-accent);
    color: var(--secondary-accent);
    font-family: 'Monaco', 'Courier New', monospace;
    font-size: 0.9rem;
    overflow-x: auto;
    margin: 15px 0;
    user-select: all;
}

.modal-body pre:hover {
    background: rgba(25, 118, 210, 0.1);
}

.modal-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.modal-actions .btn {
    flex: 1;
    justify-content: center;
    min-width: 150px;
}

.modal-actions button {
    cursor: pointer;
}

/* Responsive modal */
@media (max-width: 768px) {
    .modal-body {
        padding: 30px 20px;
    }

    .modal-body h3 {
        font-size: 1.3rem;
    }

    .modal-actions {
        flex-direction: column;
    }

    .modal-actions .btn {
        width: 100%;
    }
}
