/* ===========================
   VARIÁVEIS DE TEMA
============================ */
:root {
    --primary: #0088ff;
    --primary-light: #4da6ff;
    --primary-dark: #0066cc;
    --secondary: #ffcc00;
    --accent: #ff3c00;
    --success: #00cc66;
    --error: #ff4444;
    --warning: #ffaa00;

    /* DARK THEME */
    --dark-bg: #0d0d0d;
    --dark-card: rgba(30, 30, 30, 0.95);
    --dark-text: #ffffff;

    /* LIGHT THEME */
    --light-bg: #f2f2f2;
    --light-card: rgba(255, 255, 255, 0.95);
    --light-text: #111111;

    --transition: .35s ease;
}

html[data-theme='dark'] {
    --bg: var(--dark-bg);
    --card: var(--dark-card);
    --text: var(--dark-text);
}

html[data-theme='light'] {
    --bg: var(--light-bg);
    --card: var(--light-card);
    --text: var(--light-text);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    padding: 0;
    background: var(--bg) url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiPjxkZWZzPjxwYXR0ZXJuIGlkPSJwYXR0ZXJuIiB3aWR0aD0iNDAiIGhlaWdodD0iNDAiIHBhdHRlcm5Vbml0cz0idXNlclNwYWNlT25Vc2UiIHBhdHRlcm5UcmFuc2Zvcm09InJvdGF0ZSg0NSkiPjxyZWN0IHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgZmlsbD0icmdiYSgwLCAwLCAwLCAwLjA1KSIvPjwvcGF0dGVybj48L2RlZnM+PHJlY3Qgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsbD0idXJsKCNwYXR0ZXJuKSIvPjwvc3ZnPg==');
    color: var(--text);
    font-family: "Segoe UI", sans-serif;
    overflow-x: hidden;
    transition: background var(--transition), color var(--transition);
    min-height: 100vh;
}
body::before {
    content: '';
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background:
        radial-gradient(circle at 20% 80%, rgba(0, 136, 255, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 60, 0, 0.06) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(0, 0, 0, 0.12) 0%, transparent 50%);
    z-index: -1;
}

header {
    padding: 40px 20px 30px;
    text-align: center;
    background: url('./imagens/header.png') no-repeat center center;
    background-size: cover;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    animation: fadeIn 1.5s ease;
    position: relative;
    min-height: 250px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
header::after {
    content: '';
    position: absolute; top:0; left:0; width:100%; height:100%;
    background: rgba(0,0,0,0.35); z-index:1;
}
header > * { position: relative; z-index:2; }
header img { width: 280px; height: auto; filter: drop-shadow(0 0 10px rgba(0,0,0,0.7)); }

h1,h2,h3 { text-align:center; margin-top:0; }
.container { width:90%; max-width:1000px; margin:auto; padding:20px 0; }

section {
    background: var(--card);
    padding: 20px;
    border-radius: 12px;
    margin: 20px 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    animation: fadeUp .8s ease;
    transition: background var(--transition);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.04);
}

.language-selector { position: fixed; top:20px; right:20px; z-index:1000; }
.language-selector select {
    background: var(--card); color: var(--text); border:1px solid var(--primary);
    padding:8px 12px; border-radius:6px; font-size:14px; cursor:pointer; backdrop-filter: blur(6px);
}

.description { text-align:center; margin:20px 0 0; font-size:1.1rem; line-height:1.6; max-width:700px; margin-left:auto; margin-right:auto; }

.download-section { display:flex; flex-direction:column; align-items:center; gap:15px; margin:20px 0; }
.download-title { font-size:1.4rem; margin-bottom:5px; color: var(--primary) }
.download-subtitle { font-size:0.95rem; margin-bottom:15px; text-align:center; opacity:0.95; }

.download-buttons { display:flex; flex-wrap:wrap; justify-content:center; gap:12px; }

.download-btn {
    display:flex; align-items:center; gap:8px;
    background: linear-gradient(145deg, var(--primary), var(--primary-dark));
    color:white; border:none; padding:10px 16px; border-radius:8px; font-size:14px; font-weight:bold;
    cursor:pointer; transition: all 0.3s ease; box-shadow: 0 4px 8px rgba(0,0,0,0.25); animation: pulse 2s infinite;
}
.download-btn:hover { transform: translateY(-3px); box-shadow:0 6px 12px rgba(0,0,0,0.35); background:linear-gradient(145deg,var(--primary-light),var(--primary)); }
.download-btn:active { transform: translateY(1px); }
.download-btn.coming-soon { background: linear-gradient(145deg, #555, #777); cursor:not-allowed; }

.download-btn i { font-size:18px; }
.media-section { text-align:center; }
.media-container { position:relative; width:100%; max-width:700px; margin:0 auto; overflow:hidden; border-radius:10px; box-shadow: 0 0 20px rgba(0,0,0,0.35); }
.media-item { display:none; width:100%; height:auto; }
.media-item.active { display:block; animation: fadeIn 0.5s ease; }
.media-item iframe { width:100%; height:350px; border:none; }

.media-controls { display:flex; justify-content:center; gap:10px; margin-top:15px; }
.media-btn { background: var(--primary); color:white; border:none; padding:8px 12px; border-radius:6px; cursor:pointer; transition:all 0.3s ease; font-size:14px; }
.media-btn:hover { background: var(--primary-light); }
.media-indicators { display:flex; justify-content:center; gap:8px; margin-top:12px; }
.indicator { width:10px; height:10px; border-radius:50%; background:#555; cursor:pointer; transition:background 0.3s ease; }
.indicator.active { background: var(--primary); }

.discord-section { text-align:center; margin:25px 0; }
.discord-btn { display:inline-flex; align-items:center; gap:8px; background:#5865F2; color:white; border:none; padding:10px 20px; border-radius:8px; font-size:15px; font-weight:bold; cursor:pointer; transition:all 0.3s ease; box-shadow: 0 4px 8px rgba(0,0,0,0.3); }
.discord-btn:hover { background:#4752c4; transform: translateY(-3px); box-shadow: 0 6px 12px rgba(0,0,0,0.4); }

#themeToggle { position: fixed; bottom:20px; right:20px; background:var(--primary); border:none; padding:10px 14px; border-radius:999px; cursor:pointer; color:white; font-size:14px; box-shadow:0 0 10px rgba(0,0,0,0.4); transition:transform .3s; z-index:1000; }
#themeToggle:hover { transform: scale(1.1); }

@media (max-width:600px) {
    .media-item iframe { height:200px; }
    header img { width:200px; }
    header { padding:30px 20px 20px; min-height:200px; }
    .download-buttons { flex-direction:column; align-items:center; }
    .download-btn { width:200px; }
    .container { width:95%; }
    section { padding:15px; }
}

@keyframes fadeIn { from {opacity:0;} to{opacity:1;} }
@keyframes fadeUp { from {opacity:0; transform:translateY(20px);} to {opacity:1; transform:translateY(0);} }
@keyframes pulse { 0% { box-shadow:0 0 0 0 rgba(0,136,255,0.35);} 70%{box-shadow:0 0 0 8px rgba(0,136,255,0);} 100%{box-shadow:0 0 0 0 rgba(0,136,255,0);} }

/* ===========================
   MODAL STYLES
============================ */
#createAccountModal {
    display: none;
    position: fixed;
    top:0; left:0;
    width:100%; height:100%;
    background: rgba(0,0,0,0.7);
    justify-content: center;
    align-items: center;
    z-index: 2000;
}
#createAccountModal .modal-card {
    background: var(--card);
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    max-width: 420px;
    color: var(--text);
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
    text-align: left;
    border: 1px solid rgba(255,255,255,0.1);
}
#createAccountModal label {
    display: block;
    margin: 15px 0 5px;
    font-weight: 600;
    color: var(--text);
}
#createAccountModal input {
    width: 100%;
    padding: 12px;
    margin: 5px 0;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(0,0,0,0.2);
    color: var(--text);
    font-size: 14px;
    transition: all 0.3s ease;
}
#createAccountModal input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(0, 136, 255, 0.2);
}
#createAccountModal input.error {
    border-color: var(--error);
    box-shadow: 0 0 0 2px rgba(255, 68, 68, 0.2);
}
#createAccountModal input.success {
    border-color: var(--success);
}

#createAccountModal .actions { 
    display:flex; 
    gap:12px; 
    justify-content:flex-end; 
    margin-top:20px; 
}
#createAccountModal .actions button {
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}
#createAccountModal .actions button:first-child {
    background: rgba(255,255,255,0.1);
    color: var(--text);
}
#createAccountModal .actions button.primary-btn {
    background: var(--primary);
    color: white;
}
#createAccountModal .actions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

/* Status Messages */
.status-message {
    font-size: 14px;
    margin-top: 12px;
    min-height: 20px;
    padding: 8px 12px;
    border-radius: 6px;
    text-align: center;
    font-weight: 500;
}
.status-message.success {
    background: rgba(0, 204, 102, 0.1);
    color: var(--success);
    border: 1px solid var(--success);
}
.status-message.error {
    background: rgba(255, 68, 68, 0.1);
    color: var(--error);
    border: 1px solid var(--error);
}
.status-message.info {
    background: rgba(0, 136, 255, 0.1);
    color: var(--primary);
    border: 1px solid var(--primary);
}
.status-message.warning {
    background: rgba(255, 170, 0, 0.1);
    color: var(--warning);
    border: 1px solid var(--warning);
}

/* Loading State */
.loading {
    opacity: 0.7;
    pointer-events: none;
    position: relative;
}
.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* =======================
   MODAL DA WIKI
======================= */
#wikiModal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(3px);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.wiki-card {
    width: 900px;
    height: 600px;
    background: var(--bg-card);
    border-radius: 12px;
    padding: 15px;
    overflow-y: auto;
}

.wiki-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-wiki {
    background: red;
    color: white;
    border: none;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
}

.wiki-content {
    margin-top: 15px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.wiki-item {
    background: #222;
    padding: 10px;
    border-radius: 8px;
    text-align: center;
}

.wiki-item img {
    width: 64px;
    height: 64px;
    object-fit: contain;
}
