/*
 Theme Name:   Applied Reverse Engineering
 Theme URI:    https://appreveng.com
 Description:  Child theme profesional para Applied Reverse Engineering sobre GeneratePress. Incluye header/footer personalizados, tema oscuro cyber-ops y soporte bilingüe ES/EN.
 Author:       Imppulsa Comunicación
 Author URI:   https://imppulsa.com
 Template:     generatepress
 Version:      1.0.0
 Text Domain:  appreveng-child
 License:      All rights reserved
*/

/* ============================================================
   1. DESIGN TOKENS (Variables CSS)
   ============================================================ */
:root {
    --bg-primary: #09090b;
    --bg-card: #121214;
    --bg-card-hover: #161619;
    --accent-emerald: #00e599;
    --accent-cyan: #06b6d4;
    --text-primary: #f4f4f5;
    --text-muted: #a1a1aa;
    --border-color: rgba(0, 229, 153, 0.08);
    --border-hover: rgba(0, 229, 153, 0.25);
    --font-title: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

/* ============================================================
   2. GLOBAL BASE STYLES
   ============================================================ */
* {
    box-sizing: border-box;
}

body {
    background-color: var(--bg-primary) !important;
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
}

a {
    color: var(--accent-emerald);
    text-decoration: none;
    transition: color 0.3s ease;
}
a:hover {
    color: var(--accent-cyan);
}

/* ============================================================
   3. LANGUAGE VISIBILITY (Bilingüe ES/EN)
   ============================================================ */
body.lang-es .lang-en { display: none !important; }
body.lang-en .lang-es { display: none !important; }

/* ============================================================
   4. GENERATEPRESS OVERRIDES
   ============================================================ */
/* Ocultar header y footer de GP */
.site-header,
#site-navigation,
.main-navigation,
.site-footer,
.footer-widgets-container,
.site-info {
    display: none !important;
}

/* Contenido full-width sin sidebar */
.site, .site-content, #page, .grid-container,
.inside-article, .content-area {
    background-color: var(--bg-primary) !important;
    max-width: 100% !important;
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

.inside-article {
    border: none !important;
    box-shadow: none !important;
}

.site-main {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
}

.content-area {
    float: none !important;
}

#right-sidebar, #left-sidebar, .sidebar {
    display: none !important;
}

h1.entry-title, h2.entry-title, .page-header, .entry-header {
    display: none !important;
}

.wp-block-html {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

.entry-content {
    color: var(--text-primary) !important;
    margin-top: 0 !important;
}

/* ============================================================
   5. CUSTOM HEADER
   ============================================================ */
.are-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    background-color: rgba(9, 9, 11, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 16px 0;
}

.are-header__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo */
.are-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}
.are-logo:hover {
    text-decoration: none;
}
.are-logo__icon {
    width: 32px;
    height: 32px;
}
.are-logo__text {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 20px;
    letter-spacing: -0.01em;
    color: var(--text-primary);
}
.are-logo__text span {
    color: var(--accent-emerald);
}

/* Navigation */
.are-nav {
    display: flex;
    gap: 32px;
    align-items: center;
}

.are-nav__link {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.3s ease;
    text-decoration: none;
    font-family: var(--font-body);
}
.are-nav__link:hover,
.are-nav__link.active {
    color: var(--text-primary);
}

/* Language switch button */
.are-lang-switch {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-body);
    transition: all 0.3s ease;
}
.are-lang-switch:hover {
    border-color: var(--accent-emerald);
    background: rgba(0, 229, 153, 0.05);
}

/* Mobile hamburger */
.are-nav__toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
    padding: 4px 8px;
}

/* ============================================================
   6. CUSTOM FOOTER
   ============================================================ */
.are-footer {
    background-color: #050507;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    padding: 60px 0;
}

.are-footer__grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.are-footer__logos {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 32px;
    background-color: rgba(255, 255, 255, 0.01);
    padding: 24px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.03);
}

.are-footer__logo-img {
    max-height: 48px;
    width: auto;
    opacity: 0.85;
    transition: opacity 0.3s ease;
}
.are-footer__logo-img:hover {
    opacity: 1;
}

.are-footer__legal-text {
    color: var(--text-muted);
    font-size: 11.5px;
    text-align: center;
    max-width: 800px;
    line-height: 1.6;
}

.are-footer__copy {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.15);
}

/* ============================================================
   7. WP ADMIN BAR OFFSET (logged in users)
   ============================================================ */
.admin-bar .are-header {
    top: 32px;
}

@media screen and (max-width: 782px) {
    .admin-bar .are-header {
        top: 46px;
    }
}

/* ============================================================
   8. RESPONSIVE DESIGN
   ============================================================ */
@media (max-width: 768px) {
    .are-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background-color: rgba(9, 9, 11, 0.98);
        backdrop-filter: blur(12px);
        padding: 24px;
        gap: 20px;
        border-bottom: 1px solid var(--border-color);
    }

    .are-nav.open {
        display: flex;
    }

    .are-nav__toggle {
        display: block;
    }

    .are-header__container {
        position: relative;
    }
}
