/* --- CSS VARIABLES: THE MANA HUES & VOID --- */
:root {
    --void-bg: #070202; /* Fundo original do Farpas */
    --glass-bg: rgba(17, 17, 17, 0.4);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-highlight: rgba(255, 255, 255, 0.15);
    
    /* Cores Farpas para o Brilho Ambiente */
    --farpas-red: rgba(255, 77, 77, 0.12);
    --farpas-orange: rgba(242, 101, 34, 0.12);
    --farpas-dark: rgba(26, 26, 26, 0.4);
    
    --text-primary: #f2f2f7;
    --text-secondary: #98989d;
    --liquid-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- AMBIENT BACKGROUND: PIERCING MANA HUES --- */
.ambient-void {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    
    /* O linear-gradient escurece a imagem. Troque 'sua-imagem.jpg' pelo nome do seu arquivo */
    background: 
        linear-gradient(rgba(7, 2, 2, 0.75), rgba(7, 2, 2, 0.95)), 
        url('/hero-header.png') center center / cover no-repeat;
    
    /* OPCIONAL: Se a imagem tiver muitos detalhes e atrapalhar a leitura, 
       descomente a linha abaixo para dar um desfoque elegante nela */
    /* filter: blur(8px); */
    
    /* Mantém uma animação de zoom extremamente suave e luxuosa */
    animation: slow-zoom 20s ease-in-out infinite alternate;
}

@keyframes slow-zoom {
    0% { transform: scale(1); }
    100% { transform: scale(1.05); }
}

/* --- GLASS SEARCH & TABS --- */
.glass-search {
    background: var(--glass-bg) !important;
    border: 1px solid var(--glass-border) !important;
    backdrop-filter: blur(12px);
    color: #fff !important;
    font-family: 'Inter', sans-serif;
}
.glass-search:focus {
    border-color: rgba(255, 77, 77, 0.5) !important;
    box-shadow: 0 0 20px rgba(255, 77, 77, 0.15) !important;
}

.glass-tab-btn.mode-btn {
    margin: 0;
    border: none;
    background: transparent;
    padding: 10px 24px; /* Aumentado de 6px 16px para dar mais volume */
    border-radius: 40px;
    transition: all 0.3s var(--liquid-ease);
    display: flex;
    align-items: center;
    justify-content: center;
}

.glass-tab-btn.mode-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Estado Inativo (Cinza) */
.glass-tab-btn.mode-btn[data-mode="clm"] {
    color: rgba(242, 101, 34, 0.7);
}

.glass-tab-btn.mode-btn[data-mode="clm"] .meta-icon {
    height: 26px; /* Ícone levemente maior já que está sozinho */
    width: auto;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s var(--liquid-ease);
}

/* Hover no estado Inativo */
.glass-tab-btn.mode-btn[data-mode="clm"]:hover {
    background: rgba(242, 101, 34, 0.1);
}

/* --- ESTADO ATIVO (LARANJA BRILHANTE) --- */
.glass-tab-btn.mode-btn[data-mode="clm"].active {
    background: rgba(242, 101, 34, 0.25);
    box-shadow: inset 0 0 0 1px rgba(242, 101, 34, 0.6), 0 0 15px rgba(242, 101, 34, 0.2); 
}

.glass-tab-btn.mode-btn[data-mode="clm"].active .meta-icon {
    filter: grayscale(0%);
    opacity: 1;
}
/* --- SECTION TITLES --- */
.section-title-glass {
    display: flex;
    align-items: baseline;
    gap: 15px;
    margin: 1rem 0 1rem 0;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--glass-border);
}

.section-title-glass h3 {
    font-size: 2rem;
    color: #fff;
    text-transform: uppercase;
}

.section-title-glass .subtitle {
    color: var(--text-secondary);
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    font-size: 0.8rem;
}

/* --- GLASSMORPHISM ARTIFACTS (THE CARDS) --- */
.exhibition-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.8rem; 
    perspective: 1000px;
}

.artifact-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), inset 0 1px 0 var(--glass-highlight);
    transition: transform 0.8s var(--liquid-ease), border-color 0.8s var(--liquid-ease), box-shadow 0.8s var(--liquid-ease);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    text-decoration: none;
}

.artifact-card:hover {
    transform: translateY(-8px) scale(1.02);
    border-color: rgba(255, 77, 77, 0.4);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 77, 77, 0.2);
}

.card-art {
    width: 100%;
    height: 180px;
    position: relative;
    border-bottom: 1px solid var(--glass-border);
    overflow: hidden;
}

.card-art-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 20%;
    transition: transform 1.2s var(--liquid-ease);
}

.artifact-card:hover .card-art-bg {
    transform: scale(1.1);
}

.card-art::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 80px;
    background: linear-gradient(to bottom, rgba(7, 2, 2, 0) 0%, rgba(7, 2, 2, 0.8) 100%);
    pointer-events: none;
}

.glass-rank {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255,255,255,0.1);
    backdrop-filter: blur(8px);
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 1.2rem;
    font-weight: 800;
    padding: 4px 12px;
    border-radius: 8px;
    z-index: 2;
}

.card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    flex-grow: 1;
}

.card-header {
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
    text-align: center;
}

.card-header h2 {
    font-size: 1.0rem;
    margin-bottom: 0;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- SIMETRIA NA BASE DOS CARDS --- */
.stats-grid {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 48%;
}

.stat-label {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
}

.stat-value {
    font-family: 'Inter', sans-serif;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 4px;
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1.2s var(--liquid-ease), transform 1.2s var(--liquid-ease);
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.gallery-container {
    max-width: 1400px;
    margin: 2rem auto 4rem auto;
    padding: 1rem 1rem 2rem 1rem;
    
    background: rgba(12, 12, 14, 0.55);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

/* --- TOGGLE CLM ESTILO iPHONE --- */

/* Envoltório do botão e do ícone */
.ios-toggle-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 16px !important;
    margin-bottom: 0;
}

/* Ícone do CLM (Começa apagado/cinza) */
.ios-toggle-icon {
    height: 22px;
    filter: grayscale(100%);
    opacity: 0.5;
    transition: all 0.3s ease;
}

/* O Interruptor (Trilho) */
.ios-switch {
    position: relative;
    width: 50px;
    height: 28px;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 30px;
    border: none;
    cursor: pointer;
    outline: none;
    padding: 0;
    transition: background-color 0.3s ease;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.3);
}

/* A bolinha deslizante (Thumb) */
.ios-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 24px;
    height: 24px;
    background-color: #888;
    border-radius: 50%;
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1), background-color 0.3s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.4);
}

.ios-switch.active {
    background-color: #f26522; 
}

.ios-switch.active::after {
    transform: translateX(22px);
    background-color: #ffffff;
}

.ios-toggle-wrapper:has(.ios-switch.active) .ios-toggle-icon {
    filter: grayscale(0%);
    opacity: 1;
}