/* =========================================
   Variables y Reset
   ========================================= */
:root {
    /* Color principal (Naranja de la marca) */
    --primary-color: #ff6600; 
    --primary-light: #fff0e6;
    
    /* Fondo solicitado (Naranja claro) */
    --bg-body: #fff7ed; 
    
    /* Textos */
    --text-dark: #1f2937;
    --text-gray: #6b7280;
    --text-light: #9ca3af;
    
    /* Componentes */
    --card-bg: #ffffff;
    --border-radius: 12px;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --transition: all 0.3s ease;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--bg-body); /* Fondo naranja claro */
    color: var(--text-dark);
    line-height: 1.6;
    padding-bottom: 40px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

/* =========================================
   Layout & Container
   ========================================= */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px;
}

/* =========================================
   Botón Volver
   ========================================= */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.95rem;
}

.back-link:hover {
    transform: translateX(-5px);
    color: #cc5200;
}

/* =========================================
   Tarjetas Generales (Estilo Base)
   ========================================= */
.empresa-header,
.content-section {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 30px;
    margin-bottom: 24px;
    border-top: 4px solid var(--primary-color); /* Borde superior naranja como en la foto */
    position: relative;
}

/* =========================================
   Header de la Empresa
   ========================================= */
.empresa-header {
    display: flex;
    gap: 25px;
    align-items: flex-start;
}

/* Logo */
.empresa-logo {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    border: 1px solid #e5e7eb;
    border-radius: var(--border-radius);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
}

.empresa-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 5px;
}

.empresa-logo-placeholder {
    width: 100%;
    height: 100%;
    background-color: var(--primary-light);
    color: var(--primary-color);
    font-size: 3rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Info Header */
.empresa-info-header {
    flex-grow: 1;
}

.empresa-nombre h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 5px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.verificado {
    color: #3b82f6; /* Azul verificación */
    font-size: 1.2rem;
}

.empresa-categorias {
    margin-bottom: 15px;
}

.categoria {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Tags (Aunque se llamen tag-azul en PHP, los estilamos naranja/beige según la foto) */
.tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
}

.tag-azul {
    background-color: #fff3e0; /* Beige/Naranja muy claro */
    color: #d97706; /* Naranja oscuro/Ocre */
}

.tag i {
    font-size: 0.8rem;
}

/* Botón Favorito */
.favorito-btn {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 50%;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-gray);
    font-size: 1.2rem;
    transition: var(--transition);
}

.favorito-btn:hover {
    background-color: #fef2f2;
    color: #ef4444;
    border-color: #fecaca;
}

.favorito-btn.activo {
    color: #ef4444;
    border-color: #ef4444;
}

/* =========================================
   Grid de Contenido (Dos columnas)
   ========================================= */
.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr; /* Izquierda ancha, Derecha estrecha */
    gap: 24px;
}

/* Títulos de Sección */
.section-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

/* Subrayado naranja pequeño */
.section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

/* Descripción */
.empresa-descripcion {
    color: var(--text-gray);
    margin-bottom: 30px;
    white-space: pre-line; /* Respetar saltos de línea */
}

/* Sección Vacantes */
.vacantes-section {
    border-top: 1px dashed #e5e7eb;
    padding-top: 25px;
}

#vacantes-container a {
    color: var(--primary-color);
    font-weight: 600;
}

#vacantes-container a:hover {
    text-decoration: underline;
}

/* =========================================
   Barra Lateral (Contacto y Redes)
   ========================================= */
.action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    font-weight: 500;
    transition: var(--transition);
    margin-bottom: 20px;
}

.web-btn {
    background-color: white;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

.web-btn:hover {
    background-color: var(--primary-light);
}

/* Lista de Contacto */
.content-section ul li {
    font-size: 0.9rem;
    color: var(--text-gray);
    display: flex;
    align-items: flex-start;
}

.content-section ul li i {
    margin-top: 4px;
    color: var(--primary-color) !important; /* Forzar color naranja en iconos */
}

/* Redes Sociales */
.social-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.social-link-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px;
    border-radius: 8px;
    transition: background-color 0.2s;
}

.social-link-container:hover {
    background-color: #f9fafb;
}

.social-link {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.social-name {
    font-weight: 500;
    font-size: 0.9rem;
}

/* Gradiente TikTok */
.tiktok-gradient {
    background: linear-gradient(45deg, #00f2ea, #ff0050);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
}

/* =========================================
   Animaciones
   ========================================= */
.fade-in {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes pulsate {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.pulsate {
    animation: pulsate 0.3s ease-in-out;
}

/* =========================================
   Responsive
   ========================================= */
@media (max-width: 768px) {
    .content-grid {
        grid-template-columns: 1fr;
    }

    .empresa-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .empresa-logo {
        margin-bottom: 15px;
    }
    
    .empresa-nombre h1 {
        justify-content: center;
        font-size: 1.5rem;
    }

    .favorito-btn {
        position: absolute;
        top: 20px;
        right: 20px;
    }
    
    .section-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .empresa-header .section-title::after { 
        /* Si hubiera titulos centrados en movil */
    }
    
    /* Centrar alineación de items en header móvil */
    .empresa-info-header div[style*="display: flex"] {
        justify-content: center;
    }
}