/* ===== VARIÁVEIS E CORES TEMÁTICAS ===== */
:root {
    --primary-color: #c4a747;
    --secondary-color: #8b7355;
    --accent-color: #e8d4b8;
    --dark-bg: #1a1a2e;
    --light-text: #f0e6d2;
    --glow-color: #ffd700;
    --spirit-color: #ff69b4;
    --shadow-color: rgba(0, 0, 0, 0.5);
}

/* ===== RESET E ESTILOS GLOBAIS ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--dark-bg);
    color: var(--light-text);
    overflow-x: hidden;
}

/* ===== ANIMAÇÃO DE FUNDO ===== */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
}

.particles {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.particles::before,
.particles::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, #c4a747, rgba(196, 167, 71, 0)),
        radial-gradient(2px 2px at 60px 70px, #ffd700, rgba(255, 215, 0, 0)),
        radial-gradient(1px 1px at 50px 50px, #ff69b4, rgba(255, 105, 180, 0)),
        radial-gradient(1px 1px at 130px 80px, #e8d4b8, rgba(232, 212, 184, 0));
    background-repeat: repeat;
    background-size: 200px 200px;
    animation: float 20s infinite linear;
}

.particles::after {
    animation-delay: -10s;
    opacity: 0.5;
}

.floating-spirits {
    position: absolute;
    width: 100%;
    height: 100%;
}

.floating-spirits::before,
.floating-spirits::after {
    content: '✨';
    position: absolute;
    font-size: 2rem;
    opacity: 0.3;
    animation: float-spirit 8s infinite ease-in-out;
}

.floating-spirits::after {
    content: '🌸';
    animation-delay: 2s;
    font-size: 1.5rem;
}

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

@keyframes float-spirit {
    0%, 100% { transform: translateY(0px) translateX(0px); opacity: 0.3; }
    50% { transform: translateY(-30px) translateX(20px); opacity: 0.6; }
}

.ambient-lights {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: 
        radial-gradient(circle at 20% 50%, rgba(196, 167, 71, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 105, 180, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

/* ===== CONTAINER PRINCIPAL ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    position: relative;
    z-index: 1;
}

/* ===== HEADER/HERO SECTION ===== */
.hero-section {
    text-align: center;
    margin-bottom: 60px;
    padding: 40px 20px;
    background: linear-gradient(135deg, rgba(196, 167, 71, 0.1) 0%, rgba(232, 212, 184, 0.05) 100%);
    border-radius: 20px;
    border: 2px solid rgba(196, 167, 71, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

.chihiro-emblem {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
    0%, 100% { text-shadow: 0 0 10px var(--glow-color); }
    50% { text-shadow: 0 0 20px var(--glow-color), 0 0 30px var(--spirit-color); }
}

.main-title {
    font-size: 3rem;
    font-weight: 900;
    margin-bottom: 20px;
    letter-spacing: 2px;
}

.glitch {
    position: relative;
    color: var(--primary-color);
    text-shadow: 2px 2px 0px var(--spirit-color), 4px 4px 0px var(--secondary-color);
}

.glitch::before {
    content: attr(data-text);
    position: absolute;
    left: -2px;
    top: -2px;
    width: 100%;
    color: var(--accent-color);
    clip: rect(0, 900px, 0, 0);
    animation: glitch-anim 0.3s infinite;
}

@keyframes glitch-anim {
    0% { clip: rect(0, 900px, 0, 0); }
    20% { clip: rect(10px, 900px, 20px, 0); }
    40% { clip: rect(5px, 900px, 15px, 0); }
    60% { clip: rect(20px, 900px, 5px, 0); }
    80% { clip: rect(0, 900px, 0, 0); }
    100% { clip: rect(0, 900px, 0, 0); }
}

.holographic {
    display: block;
    font-size: 1.5rem;
    color: var(--accent-color);
    font-weight: 300;
    letter-spacing: 3px;
    margin-top: 10px;
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0%, 100% { color: var(--accent-color); }
    50% { color: var(--glow-color); }
}

.subtitle {
    font-size: 1.1rem;
    color: var(--accent-color);
    margin-top: 15px;
    font-weight: 300;
}

/* ===== SEÇÃO DE UPLOAD ===== */
.upload-section {
    margin-bottom: 60px;
    padding: 40px;
    background: linear-gradient(135deg, rgba(139, 115, 85, 0.2) 0%, rgba(196, 167, 71, 0.1) 100%);
    border-radius: 20px;
    border: 2px dashed rgba(196, 167, 71, 0.5);
    transition: all 0.3s ease;
}

.upload-section:hover {
    border-color: var(--glow-color);
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
}

.upload-area {
    position: relative;
    text-align: center;
    padding: 40px;
}

.upload-icon {
    font-size: 5rem;
    margin-bottom: 20px;
    animation: bounce 2s infinite;
}

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

.upload-btn {
    display: inline-block;
    cursor: pointer;
    padding: 20px 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border: none;
    border-radius: 15px;
    color: var(--dark-bg);
    font-weight: bold;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(196, 167, 71, 0.4);
}

.upload-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(196, 167, 71, 0.6);
}

.upload-btn:active {
    transform: translateY(-1px);
}

.btn-text {
    display: block;
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.btn-subtext {
    display: block;
    font-size: 0.85rem;
    opacity: 0.8;
}

#fileInput {
    display: none;
}

.upload-effects {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 200px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    opacity: 0;
    animation: ripple 1.5s infinite;
}

@keyframes ripple {
    0% {
        width: 200px;
        height: 200px;
        opacity: 1;
    }
    100% {
        width: 400px;
        height: 400px;
        opacity: 0;
    }
}

.submit-btn {
    display: block;
    margin: 30px auto 0;
    padding: 15px 50px;
    background: linear-gradient(135deg, var(--spirit-color) 0%, #ff1493 100%);
    border: none;
    border-radius: 25px;
    color: white;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(255, 105, 180, 0.4);
}

.submit-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 105, 180, 0.6);
}

.submit-btn:active {
    transform: scale(0.98);
}

.btn-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    animation: glow-pulse 1.5s infinite;
}

@keyframes glow-pulse {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

/* ===== BARRA DE PROGRESSO ===== */
.progress-container {
    margin: 30px 0;
    padding: 20px;
    background: rgba(196, 167, 71, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(196, 167, 71, 0.3);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(196, 167, 71, 0.2);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--glow-color) 100%);
    width: 0%;
    transition: width 0.3s ease;
    box-shadow: 0 0 10px var(--glow-color);
}

.progress-text {
    text-align: center;
    font-size: 0.9rem;
    color: var(--accent-color);
}

/* ===== SEÇÃO DE ARQUIVOS ===== */
.files-section {
    margin-bottom: 60px;
}

.section-title {
    font-size: 1.8rem;
    margin-bottom: 30px;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.title-icon {
    font-size: 2rem;
    animation: rotate 3s infinite linear;
}

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

.files-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.file-card {
    background: linear-gradient(135deg, rgba(196, 167, 71, 0.15) 0%, rgba(232, 212, 184, 0.1) 100%);
    border: 2px solid rgba(196, 167, 71, 0.3);
    border-radius: 15px;
    padding: 15px;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.file-card:hover {
    transform: translateY(-5px);
    border-color: var(--glow-color);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.3);
}

.file-image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 10px;
}

.file-name {
    font-size: 0.9rem;
    color: var(--accent-color);
    word-break: break-word;
    margin-bottom: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-link {
    display: block;
    font-size: 0.8rem;
    color: var(--primary-color);
    text-decoration: none;
    word-break: break-all;
    margin-bottom: 10px;
    padding: 8px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    transition: all 0.3s ease;
}

.file-link:hover {
    background: rgba(196, 167, 71, 0.3);
    color: var(--glow-color);
}

.file-actions {
    display: flex;
    gap: 10px;
}

.copy-link-btn,
.delete-btn {
    flex: 1;
    padding: 8px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: bold;
    transition: all 0.3s ease;
}

.copy-link-btn {
    background: var(--primary-color);
    color: var(--dark-bg);
}

.copy-link-btn:hover {
    background: var(--glow-color);
    box-shadow: 0 0 10px var(--glow-color);
}

.delete-btn {
    background: rgba(255, 105, 180, 0.5);
    color: white;
}

.delete-btn:hover {
    background: rgba(255, 105, 180, 0.8);
}

.empty-message {
    text-align: center;
    padding: 40px;
    color: var(--accent-color);
    font-style: italic;
}

/* ===== SEÇÃO DE CÓDIGO ===== */
.code-section {
    margin-bottom: 60px;
}

.code-container {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.4) 0%, rgba(139, 115, 85, 0.2) 100%);
    border: 2px solid rgba(196, 167, 71, 0.3);
    border-radius: 15px;
    overflow: hidden;
}

.code-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: rgba(196, 167, 71, 0.2);
    border-bottom: 1px solid rgba(196, 167, 71, 0.3);
}

.code-title {
    font-weight: bold;
    color: var(--primary-color);
}

.copy-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 15px;
    background: var(--primary-color);
    color: var(--dark-bg);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: var(--glow-color);
    transform: scale(1.05);
}

.copy-icon {
    font-size: 1rem;
}

.copy-text {
    font-size: 0.9rem;
}

.code-block {
    padding: 20px;
    overflow-x: auto;
    background: rgba(0, 0, 0, 0.3);
}

.code-block code {
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    color: var(--accent-color);
    line-height: 1.6;
}

.code-footer {
    padding: 15px 20px;
    background: rgba(196, 167, 71, 0.1);
    border-top: 1px solid rgba(196, 167, 71, 0.3);
}

.code-description {
    font-size: 0.9rem;
    color: var(--accent-color);
    line-height: 1.6;
}

/* ===== RODAPÉ ===== */
.footer {
    text-align: center;
    padding: 30px 20px;
    border-top: 2px solid rgba(196, 167, 71, 0.3);
    color: var(--accent-color);
    font-size: 0.9rem;
}

/* ===== EFEITO DE CURSOR ===== */
.cursor-trail {
    position: fixed;
    width: 10px;
    height: 10px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    display: none;
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 768px) {
    .main-title {
        font-size: 2rem;
    }

    .holographic {
        font-size: 1rem;
    }

    .upload-section {
        padding: 20px;
    }

    .upload-area {
        padding: 20px;
    }

    .upload-icon {
        font-size: 3rem;
    }

    .files-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .section-title {
        font-size: 1.4rem;
    }

    .code-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }

    .copy-btn {
        width: 100%;
        justify-content: center;
    }

    .hero-section {
        padding: 20px;
    }

    .chihiro-emblem {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 20px 10px;
    }

    .main-title {
        font-size: 1.5rem;
    }

    .subtitle {
        font-size: 0.95rem;
    }

    .upload-btn {
        padding: 15px 30px;
        font-size: 1rem;
    }

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

    .file-card {
        padding: 10px;
    }

    .file-image {
        height: 120px;
    }
}
