/* ===================================
   BLOG TEMPLATE STYLES
   ================================== */

/* Blog Layout */
.blog-container {
    background-color: var(--color-fondo);
    color: var(--color-texto);
    min-height: 100vh;
}

/* ===================================
   HERO SECTION (Blog & Single)
   ================================== */
.blog-hero {
    position: relative;
    width: 100%;
    height: 450px;
    background-color: var(--color-fondo-secundario);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.blog-hero-header {
    height: 500px; /* Mas alto para posts individuales */
}

.blog-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.blog-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, 
                rgba(0,0,0,0.3) 0%, 
                rgba(53,53,53,0.7) 70%, 
                var(--color-fondo) 100%);
    z-index: 2;
}

.blog-hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    padding: 0 20px;
    max-width: 900px;
}

.blog-hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 1rem;
    line-height: 1.2;
    text-shadow: 0 2px 15px rgba(0,0,0,0.3);
}

.blog-hero-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    color: var(--color-titulo);
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===================================
   TEAM INFO CARD
   ================================== */
.team-info-card {
    background: var(--color-fondo-secundario);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 20px;
    padding: 30px;
    display: flex;
    align-items: center;
    gap: 30px;
    margin-bottom: 50px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.team-card-image {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
}

.team-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid var(--color-titulo);
}

.team-card-content {
    flex-grow: 1;
}

.team-card-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--color-titulo);
    margin-bottom: 10px;
}

.team-card-description {
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.8);
    margin-bottom: 20px;
}

.team-card-social {
    display: flex;
    gap: 15px;
}

.team-card-social a {
    color: var(--color-titulo);
    background: rgba(137, 196, 255, 0.1);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.team-card-social a:hover {
    background: var(--color-titulo);
    color: var(--color-fondo);
    transform: translateY(-3px);
}

@media (max-width: 640px) {
    .team-info-card {
        flex-direction: column;
        text-align: center;
        padding: 25px;
    }
    .team-card-social {
        justify-content: center;
    }
}

/* ===================================
   POST GRID
   ================================== */
.blog-grid-section {
    padding: 80px 0;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

@media (max-width: 1100px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr;
        padding: 0 20px;
    }
    .blog-hero-title {
        font-size: 2.5rem;
    }
}

/* Blog Card */
.blog-card {
    background: var(--color-fondo-secundario);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(255,255,255,0.05);
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
    border-color: rgba(137, 196, 255, 0.2);
}

.blog-card-image-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.blog-card-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.blog-card:hover .blog-card-image-wrap img {
    transform: scale(1.1);
}

.blog-card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.blog-card-tag {
    color: var(--color-titulo);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.blog-card-title {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 15px;
    line-height: 1.4;
}

.blog-card-title a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s;
}

.blog-card-title a:hover {
    color: var(--color-titulo);
}

.blog-card-excerpt {
    color: rgba(255,255,255,0.7);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.blog-card-footer {
    margin-top: auto;
    padding-top: 15px;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
}

/* ===================================
   SINGLE POST CONTENT
   ================================== */
.single-post-body {
    padding: 60px 0;
}

.post-content-wrap {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.post-main-content {
    font-size: 1.15rem;
    line-height: 1.8;
    color: rgba(255,255,255,0.9);
}

.post-main-content p {
    margin-bottom: 2rem;
}

.post-main-content h2, 
.post-main-content h3 {
    color: var(--color-titulo);
    margin: 3rem 0 1.5rem 0;
    line-height: 1.2;
}

.post-main-content h2 { font-size: 2rem; }
.post-main-content h3 { font-size: 1.6rem; }

.post-main-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 2rem 0;
}

.post-main-content figure {
    max-width: 100%;
    margin: 2rem 0;
}

.post-main-content figure img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Post Navigation */
.post-navigation {
    margin-top: 80px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 640px) {
    .post-navigation {
        grid-template-columns: 1fr;
    }
}

.nav-link-card {
    background: var(--color-fondo-secundario);
    padding: 30px;
    border-radius: 16px;
    text-decoration: none;
    transition: background 0.3s;
}

.nav-link-card:hover {
    background: rgba(255,255,255,0.05);
}

.nav-label {
    display: block;
    color: var(--color-titulo);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.nav-title {
    color: #fff;
    font-weight: 600;
    font-size: 1.1rem;
}

.blog-hero-meta .meta-sep {
    opacity: 0.5;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.tags-list a {
    background: rgba(255,255,255,0.05);
    color: var(--color-texto);
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.3s;
}

.tags-list a:hover {
    background: var(--color-accent);
    color: var(--color-fondo);
}

.post-comments {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

/* ===================================
   COMMENTS SYSTEM STYLES
   ================================== */
.comments-area {
    margin-top: 50px;
}

.comments-title, .comment-reply-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--color-titulo);
    margin-bottom: 30px;
}

/* Form Styles */
#commentform {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 100%;
}

.comment-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    max-width: 100%;
}

@media (max-width: 640px) {
    .comment-form-row { grid-template-columns: 1fr; }
}

.comment-form-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 100%;
}

.comment-form-field label {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255,255,255,0.8);
}

.comment-form-field input, 
.comment-form-field textarea {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 15px;
    color: #fff;
    font-family: inherit;
    transition: all 0.3s;
    width: 100%;
    box-sizing: border-box;
}

/* Evitar desbordamiento en la casilla de guardar datos (cookies consent) */
.comment-form-cookies-consent {
    display: flex !important;
    align-items: flex-start !important;
    gap: 10px;
    margin: 15px 0 !important;
    max-width: 100%;
}

.comment-form-cookies-consent input {
    margin-top: 5px !important;
    flex-shrink: 0;
}

.comment-form-cookies-consent label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
    cursor: pointer;
}

.comment-form-field input:focus, 
.comment-form-field textarea:focus {
    outline: none;
    border-color: var(--color-titulo);
    background: rgba(255,255,255,0.08);
}

.submit-button-premium {
    background: var(--color-titulo);
    color: var(--color-fondo);
    padding: 15px 35px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    align-self: flex-start;
    margin-top: 10px;
}

.submit-button-premium:hover {
    background: var(--color-accent);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(137, 196, 255, 0.3);
}

/* Comment List Styles */
.comment-list {
    list-style: none;
    padding: 0;
    margin: 40px 0;
}

.comment-list .comment {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.comment-body {
    display: grid;
    grid-template-columns: 70px 1fr;
    gap: 20px;
}

.comment-author img {
    border-radius: 50%;
    border: 2px solid var(--color-titulo);
}

.comment-meta {
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.comment-meta b {
    color: #fff;
    font-size: 1.1rem;
}

.comment-metadata {
    color: rgba(255,255,255,0.4);
    font-size: 0.8rem;
    margin-top: 2px;
}

.comment-content {
    line-height: 1.6;
    color: rgba(255,255,255,0.8);
}

.reply {
    margin-top: 10px;
}

.comment-reply-link {
    color: var(--color-titulo);
    font-size: 0.85rem;
    text-decoration: none;
    font-weight: 600;
}

.comment-reply-link:hover {
    text-decoration: underline;
}

/* ===================================
   PAGINATION
   ================================== */
.blog-pagination {
    margin-top: 60px;
    display: flex;
    justify-content: center;
}

.pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    margin: 0 5px;
    border-radius: 50%;
    background: var(--color-fondo-secundario);
    color: #fff;
    text-decoration: none;
    transition: all 0.3s;
    border: 1px solid rgba(255,255,255,0.05);
}

.pagination .page-numbers.current,
.pagination .page-numbers:hover {
    background: var(--color-accent);
    color: var(--color-fondo);
}

.pagination .page-numbers.prev,
.pagination .page-numbers.next {
    width: auto;
    padding: 0 20px;
    border-radius: 30px;
}
