/*
Theme Name: Blog Posgrados UP
Author: Tu Nombre
Description: Tema personalizado para la Universidad Panamericana
Version: 1.0
Text Domain: posgrados-up
*/

/* --- INICIO: VARIABLES --- */
:root {
    --primary-green: #005b4f;
    --primary-green-hover: #00453c;
    --gold: #b38e5d;
    --gold-hover: #9c7b4f;
    --accent-cyan: #00a4b4;
    --text-gray: #7a7a7a;
    --text-dark: #333333;
    --bg-navbar: #fdfdfd;
    --bg-light: #ffffff;
    --bg-widget: #f4f5f4;
    --border-color: #e0e0e0;
}
/* --- FIN: VARIABLES --- */

/* --- INICIO: ESTILOS BASE Y TIPOGRAFIA --- */
body {
    margin: 0;
    background-color: var(--bg-light);
    color: var(--text-dark);
    font-family: "Nunito Sans", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

h3 {
    font-family: "Lora", ui-serif, Georgia, "Times New Roman", serif;
    font-weight: 500;
}

p, a {
    font-family: "Nunito Sans", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}
/* --- FIN: ESTILOS BASE Y TIPOGRAFIA --- */

/* --- INICIO: NAVBAR --- */
.navbar {
    background-color: var(--bg-navbar);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 0 2rem;
    box-sizing: border-box;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 75px;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    color: #333;
}

.logo-img {
    height: 40px;
    object-fit: contain;
}

.logo-text {
    font-family: Georgia, 'Times New Roman', Times, serif;
    font-size: 1.25rem;
    color: #4a4a4a;
}

.navbar-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 24px;
}

.navbar-menu li a {
    text-decoration: none;
    color: var(--text-gray);
    font-size: 0.95rem;
    transition: color 0.2s ease-in-out;
}

.navbar-menu li a:hover {
    color: var(--primary-green);
}
.navbar-action{
    display: flex;
    justify-content: flex-end;
    width: 55%;
    gap: 15px;
}
.navbar-action .btn-cta {
    width: 30% !important;
    padding: 5px;
}
/* --- FIN: NAVBAR --- */

/* --- INICIO: LAYOUT PRINCIPAL --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.main-layout {
    display: grid;
    grid-template-columns: 2.5fr 1fr;
    gap: 3rem;
}
/* --- FIN: LAYOUT PRINCIPAL --- */

/* --- INICIO: ARTICULO DESTACADO --- */
.featured-post {
    position: relative;
    background-size: cover;
    background-position: center;
    color: white;
    border-radius: 4px;
    overflow: hidden;
    min-height: 450px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.image-filter {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(to left, rgb(0 39 33 / 72%) 30%, rgb(0 39 33 / 15%) 100%);
    z-index: 1;
}

.glass-effect {
    position: relative;
    z-index: 2;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 2.5rem;
    width: 55%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid rgba(255,255,255,0.1);
}
.glass-effect .post-category{
    left: 2rem;
}
.tag-container {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 1rem;
}

.tag {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.tag-line {
    flex-grow: 1;
    height: 1px;
    border: none;
    margin: 0;
}

.accent-cyan {
    background-color: var(--accent-cyan);
}

.accent-gold {
    background-color: var(--gold);
}

.featured-title {
    font-family: "Lora", ui-serif, Georgia, "Times New Roman", serif;
    font-weight: 500;
    font-size: 1.7rem;
    margin: 0 0 1rem 0;
    line-height: 1.2;
}

.post-meta {
    font-size: 0.85rem;
    color: #cccccc;
    margin-bottom: 1rem;
}

.excerpt {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    color: #e0e0e0;
}

.excerpt p {
    font-size: 14px;
}
/* --- FIN: ARTICULO DESTACADO --- */

/* --- INICIO: GRID DE ARTICULOS SECUNDARIOS --- */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.post-card {
    background-color: #f1f3ef;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.post-card:hover {
    border-color: #2DD4BF !important;
    transform: translateY(-5px);
    box-shadow: 0 0 15px rgba(45, 212, 191, 0.4);
}

.post-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.post-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.post-category {
    background-color: transparent;
    border: 1px solid white;
    color: white;
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    position: absolute;
    top: 1rem;
    left: 1rem;
    backdrop-filter: blur(8px);
}

.post-image-container {
    position: relative;
}

.btn-read-more {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: bold;
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #b38e5d;
    padding-top: 1rem;
}

.pagination {
    margin-top: 3rem;
    display: flex;
    gap: 8px;
    align-items: center;
}

.pagination .page-numbers {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    font-size: 1.1rem;
    transition: all 0.2s ease-in-out;
}

.pagination .current {
    background-color: var(--primary-green);
    color: white;
}

.pagination a.page-numbers:hover {
    background-color: #f0f0f0;
    color: var(--primary-green);
}

.pagination .next,
.pagination .prev {
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    color: var(--text-gray);
    font-size: 1.5rem;
    line-height: 1;
}

.pagination .next:hover,
.pagination .prev:hover {
    border-color: var(--primary-green);
    color: var(--primary-green);
    background-color: #ffffff;
}

.pagination .dots {
    width: auto;
    background: transparent;
    padding: 0 5px;
}
/* --- FIN: GRID DE ARTICULOS SECUNDARIOS --- */

/* --- INICIO: BOTONES UNIFICADOS --- */
.btn-cta {
    width: 30%;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    text-align: center;
    transition: background-color 0.2s ease-in-out;
    border: none;
    cursor: pointer;
    height: 40px;
    background: #00685e;
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
}

.btn-green {
    background-color: var(--gold);
    color: #ffffff;
}

.btn-green:hover {
    background-color: var(--primary-green-hover);
}

.btn-gold {
    background-color: var(--gold);
    color: #ffffff;
}

.btn-gold:hover {
    background-color: var(--gold-hover);
}
/* --- FIN: BOTONES UNIFICADOS --- */

/* --- INICIO: SIDEBAR Y WIDGETS --- */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.widget {
    background-color: transparent;
}

.widget-header {
    border-bottom: 2px solid var(--gold);
    margin-bottom: 0;
    display: flex;
}

.widget-title {
    background-color: var(--gold);
    color: white;
    padding: 0.6rem 1.5rem;
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    border-radius: 6px 6px 0 0;
    display: inline-block;
}
.widget-content{
    border-top: 1px solid var(--border-color) !important;
}
.widget-content,
.widget-list {
    background-color: var(--bg-widget);
    padding: 1.5rem;
    margin: 0;
    border: 1px solid var(--border-color);
    border-top: none;
}

.search-box {
    display: flex;
}

.search-box input {
    flex-grow: 1;
    border: 1px solid #ccc;
    padding: 0.6rem 1rem;
    border-radius: 4px 0 0 4px;
    outline: none;
    font-family: inherit;
}

.search-box button {
    border-radius: 4px;
    border-color: transparent;
    font-family: "Nunito Sans", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

.widget-list {
    list-style: none;
}

.widget-list li {
    display: flex;
    align-items: center;
    padding: 0.8rem 0;
    border-bottom: 1px solid #e2e2e2;
    gap: 10px;
}

.widget-list li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.widget-list a {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
    width: 100%;
}

.widget-list a:hover {
    color: var(--primary-green);
}

.category-list li::before {
    content: '›';
    color: var(--primary-green);
    font-weight: bold;
    font-size: 1.2rem;
    margin-right: 5px;
}

.social-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.custom-social-widget {
    font-family: inherit;
    background: transparent;
    margin-bottom: 24px;
    width: 100%;
}

.custom-social-header-container {
    border-bottom: 1px solid #B48D4F;
    margin-bottom: 0;
}

.custom-social-header {
    background-color: #C09A5B;
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: bold;
    padding: 10px 24px;
    display: inline-block;
    border-radius: 8px 8px 0 0;
    font-family: "Nunito Sans", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, sans-serif !important;
    font-weight: 500 !important;
    margin-bottom: -1px;
    letter-spacing: 0.5px;
}

.custom-social-list {
    background-color: var(--bg-widget);
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.custom-social-list li {
    border-bottom: 1px solid #eaeaea;
    margin: 0 !important;
    padding: 0 !important;
}

.custom-social-list li::before {
    content: none !important;
    display: none !important;
}

.custom-social-list li:last-child {
    border-bottom: none;
}

.custom-social-list a {
    display: flex;
    align-items: center;
    padding: 14px 20px;
    color: #333333;
    text-decoration: none;
    font-size: 1rem;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.custom-social-list a:hover {
    background-color: #fcfcfc;
}

.custom-social-arrow {
    width: 16px;
    height: 16px;
    fill: #055C50;
    margin-right: 10px;
    flex-shrink: 0;
}

.custom-social-icon {
    width: 20px;
    height: 20px;
    margin-right: 14px;
    fill: #055C50;
    flex-shrink: 0;
}
/* --- FIN: SIDEBAR Y WIDGETS --- */

/* --- INICIO: FOOTER --- */
.site-footer {
    background-color: var(--primary-green);
    color: white;
    padding: 3rem 0;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.footer-links li::before, .footer-contact li::before {
    content: '';
    display: block;
    width: 4px;
    height: 16px;
    background-color: white;
    margin-right: 12px;
}

.footer-links a, .footer-contact a {
    color: white;
    text-decoration: none;
    font-size: 0.95rem;
}

.footer-links a:hover, .footer-contact a:hover {
    text-decoration: underline;
}

.footer-links h3, .footer-contact h3 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.3);
    padding-bottom: 0.5rem;
    width: 80%;
}

.footer-links li, .footer-contact li {
    display: flex;
    align-items: center;
    margin-bottom: 0.8rem;
}

.footer-links ul, .footer-contact ul {
    list-style: none;
    padding: 0;
}
/* --- FIN: FOOTER --- */

/* --- INICIO: RESPONSIVE / MOBILE --- */
@media (max-width: 992px) {

    .logo-text {
        font-size: 1.1rem;
    }
    
    .main-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 1rem;
    }

    .navbar-container {
        flex-direction: column;
        height: auto;
        gap: 1rem;
        justify-content: center;
    }

    .navbar-brand {
        flex-direction: column;
        text-align: center;
        gap: 5px;
    }

    .navbar-action {
        width: 100%;
        flex-direction: column;
        align-items: center;
    }
    .navbar-action .btn-cta {
        width: 70% !important;}
    .btn-cta {
        width: 100% !important;
        max-width: 100%;
    }

    .container {
        padding: 1.5rem;
    }

    .featured-post {
        min-height: auto;
        justify-content: center;
    }

    .glass-effect {
        width: 100%;
        border-right: none;
        padding: 1.5rem;
    }

    .image-filter {
        background: rgba(0, 39, 33, 0.7); 
    }

    .featured-title {
        font-size: 1.4rem;
        margin-top: 2rem;
    }

    .posts-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .footer-links h3, .footer-contact h3 {
        width: 100%;
        text-align: center;
    }

    .footer-links li, .footer-contact li {
        justify-content: center;
    }
    
    .footer-logo {
        display: flex;
        justify-content: center;
    }
    
    .pagination {
        flex-wrap: wrap;
        justify-content: center;
    }
}
/* --- FIN: RESPONSIVE / MOBILE --- */


/* Estilos básicos para el contenido dinámico de WordPress en single.php */
