/* ========================================
   Importar Google Fonts
   ======================================== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700;800&family=Inter:wght@400;500;600&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colores mejorados con mayor contraste */
    --primary-dark: #0d1f2d;
    --primary-color: #1a3a52;
    --primary-light: #2c5f7f;
    --gold: #c9a36a;
    --gold-light: #d4b183;
    --gold-dark: #b8925a;
    
    /* Colores de texto */
    --text-color: #2c3e50;
    --text-light: #6c757d;
    --text-white: #ffffff;
    
    /* Fondos */
    --light-bg: #fafbfc;
    --white: #ffffff;
    --dark-bg: #0d1f2d;
    
    /* Utilidades */
    --border-color: #e8ecef;
    --error-color: #e74c3c;
    --success-color: #27ae60;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    
    /* LEGACY - Mantener para compatibilidad */
    --secondary-color: #c9a36a;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-color);
    line-height: 1.7;
    background-color: var(--white);
    font-size: 16px;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    line-height: 1.3;
    color: var(--primary-dark);
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Animaciones base */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.fade-in {
    animation: fadeIn 0.6s ease-out forwards;
}

.header {
    background-color: var(--primary-dark);
    color: var(--text-white);
    padding: 1.2rem 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

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

.logo-link {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.3s ease;
}

.logo-link:hover {
    opacity: 0.85;
}

.logo {
    font-size: 1.75rem;
    font-weight: 700;
    font-family: 'Poppins', sans-serif;
    letter-spacing: -0.5px;
    color: var(--white);
    margin: 0;
}

.nav {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-link {
    color: var(--text-white);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    padding-bottom: 4px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--gold);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover,
.nav-link.active {
    color: var(--gold);
}

.hero {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 50%, var(--primary-light) 100%);
    color: var(--text-white);
    padding: 8rem 0 6rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 85vh;
    display: flex;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(201, 163, 106, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(44, 95, 127, 0.15) 0%, transparent 50%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    animation: fadeInUp 1s ease-out;
}

.hero-content h2 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1.2;
    color: var(--white);
}

.hero-content p {
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    margin-bottom: 3rem;
    opacity: 0.95;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 400;
    line-height: 1.6;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 1rem 2.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    letter-spacing: 0.3px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(201, 163, 106, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(201, 163, 106, 0.4);
    background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold) 100%);
}

.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--white);
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.1);
}

.btn-secondary:hover {
    background-color: var(--white);
    color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
}

.section-title {
    text-align: center;
    font-size: clamp(2rem, 4vw, 2.75rem);
    margin-bottom: 4rem;
    color: var(--primary-dark);
    font-weight: 700;
    letter-spacing: -0.5px;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--gold) 0%, var(--gold-light) 100%);
    border-radius: 2px;
}

.services {
    padding: 6rem 0;
    background-color: var(--white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
}

.service-card {
    background-color: var(--white);
    padding: 3rem 2rem;
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border-color);
    text-align: center;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--gold) 0%, var(--gold-light) 100%);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-lg);
    border-color: var(--gold-light);
}

.service-icon {
    width: 90px;
    height: 90px;
    margin: 0 auto 2rem;
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s ease;
    box-shadow: 0 8px 20px rgba(201, 163, 106, 0.25);
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 12px 30px rgba(201, 163, 106, 0.35);
}

.service-icon i {
    font-size: 2.5rem;
    color: var(--white);
}

.service-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
    font-weight: 600;
}

.service-card p {
    color: var(--text-light);
    line-height: 1.7;
    font-size: 0.98rem;
}

/* Estilos duplicados eliminados - se usan los nuevos arriba */

.service-card:hover .service-icon i {
    transform: scale(1.1);
}

.service-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.3rem;
    font-weight: 700;
}

.service-card p {
    color: #666;
    line-height: 1.7;
}

.about {
    padding: 6rem 0;
    background-color: var(--light-bg);
}

.about-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3.5rem;
}

.about-item {
    text-align: center;
    padding: 2rem;
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.about-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.about-item h4 {
    color: var(--primary-dark);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.testimonials {
    padding: 5rem 0;
    background-color: var(--light-bg);
}

.testimonial-card {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    height: 100%;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 25px rgba(0,0,0,0.2);
}

.testimonial-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.testimonial-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 3px solid var(--secondary-color);
}

.testimonial-info h4 {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-bottom: 0.3rem;
}

.testimonial-stars {
    color: #ffc107;
    font-size: 0.9rem;
}

.testimonial-text {
    color: var(--text-color);
    line-height: 1.6;
    font-style: italic;
    margin: 0;
}

.carousel-control-prev,
.carousel-control-next {
    width: 5%;
    opacity: 0.8;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    opacity: 1;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: var(--primary-color);
    border-radius: 50%;
    padding: 1.5rem;
}

.carousel-indicators {
    margin-bottom: -2rem;
}

.carousel-indicators button {
    background-color: var(--secondary-color);
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.modal-header-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.modal-avatar {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: 3px solid var(--secondary-color);
}

.modal-title {
    color: var(--primary-color);
    font-weight: 600;
    margin: 0;
}

.modal-body p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
    font-style: italic;
}

.modal-header {
    border-bottom: 2px solid var(--light-bg);
}

.modal-footer {
    border-top: 2px solid var(--light-bg);
}

.footer {
    background-color: var(--primary-dark);
    color: var(--text-white);
    padding: 4rem 0 1.5rem;
    margin-top: 5rem;
    border-top: 3px solid var(--gold);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 10% 20%, rgba(201, 163, 106, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(44, 95, 127, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
    position: relative;
    z-index: 1;
}

.footer-section h4 {
    color: var(--gold);
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
}

.footer-section p,
.footer-section a {
    margin-bottom: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.3s ease;
    text-decoration: none;
    display: block;
}

.footer-section a:hover {
    color: var(--gold);
    padding-left: 5px;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.15);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    position: relative;
    z-index: 1;
}

.login-container {
    display: flex;
    min-height: 100vh;
    background-color: var(--light-bg);
}

/* Panel Izquierdo - Branding */
.login-panel-left {
    flex: 1;
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c5f7f 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.login-panel-left::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    top: -150px;
    right: -150px;
}

.login-panel-left::after {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 50%;
    bottom: -100px;
    left: -100px;
}

.login-branding {
    position: relative;
    z-index: 1;
    text-align: center;
    color: var(--white);
}

.login-logo {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.login-logo i {
    font-size: 3rem;
    color: var(--secondary-color);
}

.login-branding h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--white);
}

.login-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 3rem;
}

.login-features {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 300px;
    margin: 0 auto;
}

.login-feature {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.login-feature i {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

.login-feature span {
    font-size: 0.95rem;
    font-weight: 500;
}

/* Panel Derecho - Formulario */
.login-panel-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    background-color: var(--white);
}

.login-box {
    width: 100%;
    max-width: 450px;
}

.login-header {
    margin-bottom: 2.5rem;
}

.login-header h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.login-header p {
    color: #666;
    font-size: 0.95rem;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.login-form .form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper input {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.3s;
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(26, 58, 82, 0.1);
}

.toggle-password {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.3s;
}

.toggle-password:hover {
    color: var(--primary-color);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: -0.5rem;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: #666;
}

.checkbox-wrapper input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.btn-login {
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c5f7f 100%);
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s;
    margin-top: 0.5rem;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(26, 58, 82, 0.2);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login.loading {
    pointer-events: none;
    opacity: 0.7;
}

.login-form .error-message {
    display: none;
    padding: 1rem;
    background-color: #fee;
    border-left: 4px solid var(--error-color);
    border-radius: 5px;
    color: var(--error-color);
    font-size: 0.9rem;
    gap: 0.5rem;
    align-items: center;
}

.login-form .error-message.show {
    display: flex;
}

.login-footer {
    margin-top: 2rem;
    text-align: center;
}

.login-footer .back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s;
}

.login-footer .back-link:hover {
    color: var(--secondary-color);
    gap: 0.7rem;
}

/* Responsive */
@media (max-width: 968px) {
    .login-container {
        flex-direction: column;
    }

    .login-panel-left {
        min-height: 300px;
    }

    .login-branding h1 {
        font-size: 2rem;
    }

    .login-features {
        flex-direction: row;
        flex-wrap: wrap;
        max-width: 100%;
    }

    .login-feature {
        flex: 1;
        min-width: 150px;
    }

    .login-panel-right {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 576px) {
    .login-panel-left {
        padding: 2rem 1.5rem;
    }

    .login-branding h1 {
        font-size: 1.8rem;
    }

    .login-subtitle {
        font-size: 1rem;
    }

    .login-features {
        flex-direction: column;
    }

    .login-header h2 {
        font-size: 1.6rem;
    }
}

.login-form,
.contact-form,
.admin-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--primary-color);
}

.form-group input,
.form-group textarea,
.form-group select {
    padding: 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1rem;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.error-message {
    color: var(--error-color);
    font-size: 0.9rem;
    display: none;
    margin-top: 1rem;
}

.success-message {
    color: var(--success-color);
    font-size: 0.9rem;
    display: none;
    margin-top: 1rem;
    padding: 1rem;
    background-color: #d4edda;
    border-radius: 5px;
}

.back-link {
    display: block;
    text-align: center;
    margin-top: 1.5rem;
    color: var(--primary-color);
    text-decoration: none;
}

.back-link:hover {
    color: var(--secondary-color);
}

.admin-container {
    padding: 3rem 0;
    min-height: calc(100vh - 200px);
}

.admin-form {
    max-width: 800px;
    margin: 0 auto 3rem;
    background-color: var(--light-bg);
    padding: 2rem;
    border-radius: 8px;
}

.posts-list-title {
    margin: 3rem 0 2rem;
    text-align: center;
}

.posts-admin-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.post-admin-item {
    background-color: var(--white);
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.post-admin-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}

.post-admin-title {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.post-admin-category {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-size: 0.85rem;
}

.post-admin-content {
    color: var(--text-color);
    margin-bottom: 1rem;
}

.post-admin-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: #666;
}

.btn-delete {
    background-color: var(--error-color);
    color: var(--white);
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
}

.btn-delete:hover {
    background-color: #a93226;
}

.blog-hero,
.contact-hero {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 3rem 0;
    text-align: center;
}

.blog-hero h2,
.contact-hero h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: var(--white);
}

.blog-container,
.contact-container {
    padding: 3rem 0;
    min-height: calc(100vh - 400px);
}

/* ========================================
   BÚSQUEDA AVANZADA
   ======================================== */
.search-container {
    margin-bottom: 3rem;
}

.search-bar {
    position: relative;
    display: flex;
    gap: 0.5rem;
    align-items: center;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    padding: 0.5rem 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.3s;
}

.search-bar:focus-within {
    border-color: var(--primary-color);
    box-shadow: 0 4px 20px rgba(26, 58, 82, 0.15);
}

.search-icon {
    color: var(--text-light);
    font-size: 1.1rem;
}

#searchInput {
    flex: 1;
    border: none;
    outline: none;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    background: transparent;
}

.search-btn,
.advanced-filters-btn {
    border: none;
    background: var(--primary-color);
    color: white;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.search-btn:hover,
.advanced-filters-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

.advanced-filters-btn {
    background: var(--text-light);
}

.advanced-filters-btn:hover {
    background: var(--primary-color);
}

/* Sugerencias de autocompletado */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-top: 0.5rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    z-index: 100;
    max-height: 400px;
    overflow-y: auto;
}

.suggestion-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    cursor: pointer;
    transition: background 0.2s;
    border-bottom: 1px solid var(--border-color);
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item:hover {
    background: var(--light-bg);
}

.suggestion-item i {
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-top: 0.2rem;
}

.suggestion-content {
    flex: 1;
}

.suggestion-title {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.25rem;
}

.suggestion-category {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Filtros avanzados */
.advanced-filters {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-top: 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.filters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.filter-group label {
    display: block;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.filter-group label i {
    margin-right: 0.5rem;
    color: var(--primary-color);
}

.filter-group select,
.filter-group input[type="date"] {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
}

.filter-group select:focus,
.filter-group input[type="date"]:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(26, 58, 82, 0.1);
}

.filter-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* Información de resultados */
.search-results-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--light-bg);
    border-radius: 8px;
    margin-top: 1rem;
    margin-bottom: 2rem;
    font-size: 0.95rem;
    color: var(--text-color);
}

.search-results-info i {
    color: var(--primary-color);
}

.clear-search-btn {
    margin-left: auto;
    padding: 0.5rem 1rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.clear-search-btn:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Resaltado de términos en resultados */
mark {
    background-color: #fff3cd;
    padding: 0.1rem 0.3rem;
    border-radius: 3px;
    font-weight: 600;
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.pagination-btn {
    padding: 0.75rem 1.25rem;
    border: 1px solid var(--border-color);
    background: white;
    color: var(--text-color);
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pagination-btn:hover {
    background: var(--light-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.pagination-ellipsis {
    padding: 0.75rem;
    color: var(--text-light);
}

.blog-filters {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.6rem 1.5rem;
    border: 2px solid var(--primary-color);
    background-color: var(--white);
    color: var(--primary-color);
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.filter-btn:hover,
.filter-btn.active {
    background-color: var(--primary-color);
    color: var(--white);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
}

.blog-post {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.blog-post:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.blog-post-header {
    background-color: var(--light-bg);
    padding: 1.5rem;
}

.blog-post-title {
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.blog-post-category {
    display: inline-block;
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-size: 0.85rem;
}

.blog-post-content {
    padding: 1.5rem;
}

.blog-post-excerpt {
    color: var(--text-color);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.blog-post-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.blog-post-date {
    color: #666;
    font-size: 0.9rem;
}

.read-more {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 0.9rem;
}

.empty-state {
    text-align: center;
    padding: 3rem;
    color: #999;
    display: none;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 3rem;
}

.contact-info {
    background-color: var(--light-bg);
    padding: 2rem;
    border-radius: 8px;
}

.contact-info h3 {
    color: var(--primary-color);
    margin-bottom: 2rem;
}

.info-item {
    margin-bottom: 2rem;
}

.info-item h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.info-item p {
    color: var(--text-color);
}

.contact-form-container {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.contact-form-container h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.post-detail-container {
    padding: 3rem 0;
    min-height: calc(100vh - 400px);
}

.back-to-blog {
    display: inline-block;
    color: var(--primary-color);
    text-decoration: none;
    margin-bottom: 2rem;
    font-weight: 600;
    transition: color 0.3s;
}

.back-to-blog:hover {
    color: var(--secondary-color);
}

.post-detail {
    background-color: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 3rem;
    max-width: 900px;
    margin: 0 auto;
}

.post-detail-header {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--light-bg);
}

.post-detail-category {
    display: inline-block;
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 0.4rem 1rem;
    border-radius: 4px;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.post-detail-title {
    color: var(--primary-color);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.post-detail-meta {
    display: flex;
    gap: 1rem;
    color: #666;
    font-size: 0.95rem;
}

.post-detail-date {
    font-style: italic;
}

.post-detail-body {
    color: var(--text-color);
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Imagen destacada del post */
.post-detail-image {
    width: 100%;
    height: 400px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 2rem;
}

.post-detail-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Tiempo de lectura */
.post-detail-reading-time {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
    font-size: 0.95rem;
}

/* Botones de compartir */
.post-share-buttons {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.5rem 0;
    margin-bottom: 2rem;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.share-label {
    font-weight: 600;
    color: var(--text-color);
    margin-right: 0.5rem;
}

.share-btn {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.share-btn:active {
    transform: translateY(0);
}

.share-whatsapp {
    background-color: #25D366;
}

.share-whatsapp:hover {
    background-color: #1fbb5a;
}

.share-facebook {
    background-color: #1877F2;
}

.share-facebook:hover {
    background-color: #0d65d9;
}

.share-twitter {
    background-color: #1DA1F2;
}

.share-twitter:hover {
    background-color: #0d8bd9;
}

.share-linkedin {
    background-color: #0A66C2;
}

.share-linkedin:hover {
    background-color: #004b99;
}

.share-copy {
    background-color: #6c757d;
}

.share-copy:hover {
    background-color: #5a6268;
}

/* Artículos relacionados */
.related-posts {
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 2px solid var(--border-color);
}

.related-posts-title {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 2rem;
    font-weight: 700;
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.related-post-card {
    display: block;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.related-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

.related-post-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
}

.related-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-post-card:hover .related-post-image img {
    transform: scale(1.05);
}

.related-post-content {
    padding: 1.5rem;
}

.related-post-title {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 0.75rem;
    font-weight: 600;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-post-date {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.post-not-found {
    text-align: center;
    padding: 5rem 2rem;
    display: none;
}

.post-not-found h2 {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.post-not-found p {
    color: #666;
    margin-bottom: 2rem;
}

@media (max-width: 768px) {
    .header {
        padding: 1rem 0;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .logo {
        font-size: 1.5rem;
    }
    
    .nav {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1.5rem;
    }
    
    .hero {
        padding: 5rem 0 4rem;
        min-height: 70vh;
    }
    
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .hero-content p {
        font-size: 1.1rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 3rem;
    }
    
    .services,
    .about {
        padding: 4rem 0;
    }
    
    /* Estilos responsivos para post detail */
    .post-detail {
        padding: 1.5rem;
    }
    
    .post-detail-image {
        height: 250px;
        margin-bottom: 1.5rem;
    }
    
    .post-detail-title {
        font-size: 1.8rem;
    }
    
    .post-detail-body {
        font-size: 1rem;
    }
    
    .post-share-buttons {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .share-btn {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
    
    .share-label {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    .related-posts {
        margin-top: 2rem;
        padding-top: 2rem;
    }
    
    .related-posts-title {
        font-size: 1.5rem;
    }
    
    .related-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .services-grid,
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .service-icon {
        width: 80px;
        height: 80px;
    }
    
    .service-icon i {
        font-size: 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .testimonials .col-md-6 {
        margin-bottom: 1rem;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        display: none;
    }
    
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .blog-filters {
        gap: 0.5rem;
    }
    
    .filter-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .post-detail {
        padding: 2rem 1.5rem;
    }
    
    .post-detail-title {
        font-size: 1.8rem;
    }
    
    .post-detail-body {
        font-size: 1rem;
    }
    
    .admin-stats {
        grid-template-columns: 1fr;
    }
    
    .admin-table-container {
        overflow-x: auto;
    }
}

/* ========================================
   ADMIN PANEL - NUEVO DISEÑO CRUD
   ======================================== */

.admin-header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.admin-header-left i {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-size: 0.9rem;
}

.admin-user i {
    font-size: 1.2rem;
}

/* Admin Page Header */
.admin-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--border-color);
}

.admin-page-header h2 {
    color: var(--primary-color);
    font-size: 2rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-page-header h2 i {
    color: var(--secondary-color);
}

.admin-subtitle {
    color: #666;
    margin: 0.5rem 0 0 0;
    font-size: 0.95rem;
}

/* Estadísticas */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c5f7f 100%);
    color: var(--white);
    padding: 1.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

.stat-info h3 {
    font-size: 2rem;
    margin: 0;
    font-weight: 700;
}

.stat-info p {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Filtros y búsqueda */
.admin-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.search-box {
    flex: 1;
    position: relative;
}

.search-box i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
}

.search-box input {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 3rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.95rem;
    transition: border-color 0.3s;
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.admin-filters select {
    padding: 0.8rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.95rem;
    background-color: var(--white);
    cursor: pointer;
    min-width: 200px;
}

.admin-filters select:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Tabla Admin */
.admin-table-container {
    background-color: var(--white);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c5f7f 100%);
    color: var(--white);
}

.admin-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.admin-table tbody tr {
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.2s;
}

.admin-table tbody tr:hover {
    background-color: var(--light-bg);
}

.admin-table td {
    padding: 1rem;
    vertical-align: middle;
}

.post-id {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    color: #666;
}

.post-title-cell {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.post-title-cell strong {
    color: var(--primary-color);
    font-size: 1rem;
}

.post-title-cell small {
    color: #666;
    font-size: 0.85rem;
}

/* Badges de categorías */
.badge {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--white);
    white-space: nowrap;
}

.badge-laboral {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

.badge-contencioso {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

.badge-disciplinario {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.badge-civil {
    background: linear-gradient(135deg, #1abc9c 0%, #16a085 100%);
}

.badge-general {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
}

/* Botones de acción */
.action-buttons {
    display: flex;
    gap: 0.5rem;
}

.btn-icon {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.btn-edit {
    background-color: #3498db;
    color: var(--white);
}

.btn-edit:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(52, 152, 219, 0.3);
}

.btn-delete {
    background-color: #e74c3c;
    color: var(--white);
}

.btn-delete:hover {
    background-color: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(231, 76, 60, 0.3);
}

/* Empty State */
.empty-state {
    padding: 4rem 2rem;
    text-align: center;
    color: #999;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.empty-state p {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.modal-content {
    background-color: var(--white);
    border-radius: 12px;
    width: 90%;
    max-width: 700px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s;
}

.modal.show .modal-content {
    transform: scale(1);
}

.modal-header {
    padding: 1.5rem 2rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c5f7f 100%);
    color: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.modal-close {
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background-color 0.3s;
}

.modal-close:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.modal-body {
    padding: 2rem;
    max-height: calc(90vh - 140px);
    overflow-y: auto;
}

.admin-form .form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--primary-color);
}

.admin-form .form-group label i {
    color: var(--secondary-color);
}

.form-help {
    display: block;
    margin-top: 0.5rem;
    color: #666;
    font-size: 0.85rem;
}

.form-help i {
    color: var(--secondary-color);
}

.modal-footer {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

/* Notificaciones */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    z-index: 10001;
    transform: translateX(400px);
    transition: transform 0.3s ease;
}

.notification.show {
    transform: translateX(0);
}

.notification-success {
    background-color: #27ae60;
    color: var(--white);
}

.notification-error {
    background-color: #e74c3c;
    color: var(--white);
}

.notification-info {
    background-color: #3498db;
    color: var(--white);
}

.notification i {
    font-size: 1.2rem;
}

/* Responsive Admin */
@media (max-width: 968px) {
    .admin-page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .admin-filters {
        flex-direction: column;
    }
    
    .admin-filters select {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .modal-content {
        width: 95%;
        margin: 1rem;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
    
    .admin-table th,
    .admin-table td {
        padding: 0.75rem 0.5rem;
        font-size: 0.85rem;
    }
    
    .post-title-cell small {
        display: none;
    }
}

/* ========================================
   TABS DE NAVEGACIÓN
   ======================================== */

.admin-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.tab-btn {
    background: none;
    border: none;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    transition: all 0.3s;
    border-bottom: 3px solid transparent;
}

.tab-btn:hover {
    color: var(--primary-color);
    background-color: rgba(26, 58, 82, 0.05);
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab-btn i {
    font-size: 1.1rem;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   ESTILOS ESPECÍFICOS DE CATEGORÍAS
   ======================================== */

.category-name-cell {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.category-name-cell strong {
    color: var(--primary-color);
    font-size: 1rem;
}

.category-name-cell small {
    color: #666;
    font-size: 0.85rem;
}

.color-preview {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.color-box {
    width: 30px;
    height: 30px;
    border-radius: 6px;
    border: 2px solid var(--border-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.color-preview span:last-child {
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    color: #666;
}

.post-count {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color) 0%, #2c5f7f 100%);
    color: var(--white);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

code {
    background-color: var(--light-bg);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    color: #e74c3c;
    border: 1px solid var(--border-color);
}

/* Modal pequeño para categorías */
.modal-small {
    max-width: 550px;
}

/* Color Picker Group */
.color-picker-group {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.color-picker-group input[type="color"] {
    width: 80px;
    height: 45px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    padding: 0.2rem;
}

.color-picker-group input[type="text"] {
    flex: 1;
    padding: 0.8rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    font-size: 0.95rem;
}

.color-picker-group input[type="text"]:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Botón disabled */
.btn-icon:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.btn-icon:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Responsive Tabs */
@media (max-width: 576px) {
    .admin-tabs {
        flex-direction: column;
        gap: 0;
    }
    
    .tab-btn {
        width: 100%;
        justify-content: center;
        border-bottom: 1px solid var(--border-color);
    }
    
    .tab-btn.active {
        border-bottom: 1px solid var(--primary-color);
        border-left: 3px solid var(--primary-color);
    }
    
    .color-picker-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .color-picker-group input[type="color"] {
        width: 100%;
    }
}

/* ========================================
   NUEVO LAYOUT ADMIN CON SIDEBAR
   ======================================== */

.admin-body {
    background-color: #f5f7fa;
    margin: 0;
    padding: 0;
}

/* Topbar Superior */
.admin-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: var(--white);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.sidebar-toggle {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s;
}

.sidebar-toggle:hover {
    background-color: var(--light-bg);
}

.topbar-logo {
    font-size: 1.3rem;
    color: var(--primary-color);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.btn-logout {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: var(--white);
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-logout:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.3);
}

/* Layout Principal */
.admin-layout {
    display: flex;
    margin-top: 60px;
    min-height: calc(100vh - 60px);
}

/* Sidebar */
.admin-sidebar {
    position: fixed;
    left: 0;
    top: 60px;
    width: 260px;
    height: calc(100vh - 60px);
    background: var(--white);
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
    transition: all 0.3s;
    z-index: 999;
}

.admin-sidebar.collapsed {
    margin-left: -260px;
}

.sidebar-nav {
    padding: 1rem 0;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem 1.5rem;
    color: #555;
    text-decoration: none;
    transition: all 0.3s;
    border-left: 3px solid transparent;
    font-weight: 500;
}

.sidebar-link:hover {
    background-color: var(--light-bg);
    color: var(--primary-color);
    border-left-color: var(--primary-color);
}

.sidebar-link.active {
    background: linear-gradient(90deg, rgba(26, 58, 82, 0.1) 0%, transparent 100%);
    color: var(--primary-color);
    border-left-color: var(--primary-color);
}

.sidebar-link i {
    font-size: 1.2rem;
    width: 24px;
    text-align: center;
}

.sidebar-divider {
    height: 1px;
    background-color: var(--border-color);
    margin: 1rem 0;
}

/* Contenido Principal */
.admin-main {
    flex: 1;
    margin-left: 260px;
    padding: 2rem;
    transition: all 0.3s;
    background-color: #f5f7fa;
}

.admin-sidebar.collapsed ~ .admin-main {
    margin-left: 0;
}

/* Secciones */
.admin-section {
    display: none;
}

.admin-section.active {
    display: block;
    animation: fadeInUp 0.4s;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2rem;
}

.section-header h2 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-subtitle {
    color: #666;
    margin: 0.5rem 0 0 0;
}

/* ========================================
   DASHBOARD
   ======================================== */

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.dashboard-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 1.5rem;
    transition: all 0.3s;
    border-left: 4px solid;
}

.dashboard-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.dashboard-card.card-primary {
    border-left-color: #3498db;
}

.dashboard-card.card-success {
    border-left-color: #2ecc71;
}

.dashboard-card.card-warning {
    border-left-color: #f39c12;
}

.dashboard-card.card-info {
    border-left-color: #9b59b6;
}

.card-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

.card-primary .card-icon {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: var(--white);
}

.card-success .card-icon {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: var(--white);
}

.card-warning .card-icon {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: var(--white);
}

.card-info .card-icon {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
    color: var(--white);
}

.card-content {
    flex: 1;
}

.card-content h3 {
    font-size: 2rem;
    margin: 0 0 0.3rem 0;
    color: var(--primary-color);
}

.card-content p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

.card-trend {
    display: inline-block;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    font-weight: 600;
}

.card-trend.positive {
    color: #2ecc71;
}

.card-trend.negative {
    color: #e74c3c;
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 1.5rem;
}

.dashboard-widget {
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.widget-header {
    padding: 1.2rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

.widget-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.widget-link {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s;
}

.widget-link:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.widget-body {
    padding: 1.5rem;
}

/* Widget Table */
.widget-table {
    width: 100%;
    border-collapse: collapse;
}

.widget-table thead {
    background-color: var(--light-bg);
}

.widget-table th {
    padding: 0.8rem;
    text-align: left;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.widget-table td {
    padding: 0.8rem;
    border-top: 1px solid var(--border-color);
    color: #333;
    font-size: 0.9rem;
}

.widget-table tbody tr:hover {
    background-color: var(--light-bg);
}

/* Category Chart */
.category-chart {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.category-bar-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.category-bar-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.category-bar-bg {
    height: 10px;
    background-color: var(--light-bg);
    border-radius: 5px;
    overflow: hidden;
}

.category-bar-fill {
    height: 100%;
    border-radius: 5px;
    transition: width 0.6s ease;
}

/* Activity Feed */
.activity-feed {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 0.8rem;
    border-radius: 8px;
    transition: all 0.3s;
}

.activity-item:hover {
    background-color: var(--light-bg);
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1rem;
    flex-shrink: 0;
}

.activity-icon.bg-primary {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

.activity-icon.bg-success {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
}

.activity-icon.bg-warning {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
}

.activity-icon.bg-info {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

.activity-content {
    flex: 1;
}

.activity-content p {
    margin: 0 0 0.3rem 0;
    color: #333;
    font-size: 0.9rem;
}

.activity-time {
    font-size: 0.8rem;
    color: #999;
}

/* Reviews List */
.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.review-item {
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: all 0.3s;
}

.review-item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.review-rating {
    color: #f39c12;
    font-size: 0.9rem;
}

.review-date {
    font-size: 0.8rem;
    color: #999;
}

.review-text {
    margin: 0.5rem 0;
    color: #555;
    font-size: 0.9rem;
    font-style: italic;
}

.review-author {
    margin: 0;
    font-size: 0.85rem;
    color: #333;
}

/* Placeholder Content */
.placeholder-content {
    text-align: center;
    padding: 4rem 2rem;
    color: #999;
}

.placeholder-content i {
    color: #ddd;
    margin-bottom: 1rem;
}

.placeholder-content h3 {
    color: #666;
    margin: 1rem 0 0.5rem 0;
}

.placeholder-content p {
    color: #999;
}

/* Hidden utility */
.hidden {
    display: none !important;
}

/* Responsive Dashboard */
@media (max-width: 968px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .admin-topbar {
        padding: 0 1rem;
    }
    
    .topbar-logo {
        font-size: 1.1rem;
    }
    
    .admin-sidebar {
        margin-left: -260px;
    }
    
    .admin-sidebar.collapsed {
        margin-left: 0;
    }
    
    .admin-main {
        margin-left: 0;
        padding: 1rem;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        gap: 1rem;
    }
    
    /* Búsqueda avanzada responsiva */
    .search-bar {
        flex-wrap: wrap;
        border-radius: 12px;
        padding: 0.75rem;
    }
    
    #searchInput {
        width: 100%;
        min-width: 0;
        padding: 0.5rem;
    }
    
    .search-btn,
    .advanced-filters-btn {
        width: 38px;
        height: 38px;
    }
    
    .filters-grid {
        grid-template-columns: 1fr;
    }
    
    .filter-actions {
        flex-direction: column;
    }
    
    .filter-actions button {
        width: 100%;
    }
    
    .pagination {
        gap: 0.25rem;
        padding: 0 1rem;
    }
    
    .pagination-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }
    
    .search-results-info {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .clear-search-btn {
        margin-left: 0;
        width: 100%;
        justify-content: center;
    }
}
