/* Contenedor general del blog */
.blog-index {
    display: block;
    margin: 0 auto;
    padding: 2em 2em 2em 2em;

}

.blog-post,
.blog-related {
    margin: 0 auto;
    padding: 2em 2em 2em 2em;
}


@media (min-width: 768px) {
    .blog-index {
        padding: 2em 4em 2em 4em;
    }

    .blog-post,
    .blog-related {
        padding: 2em 4em 2em 4em;
    }
}

.blog-index > header {
    margin-bottom: 2.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.25);
}

.blog-index > header h1 {
    font-size: clamp(1.85rem, 3vw, 2.5rem);
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 0.6rem;
}

.blog-index > header p {
    font-size: 1.05rem;
    line-height: 1.6;
    opacity: 0.85;
    margin: 0;
}

.blog-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-bottom: 2rem;
}

.blog-filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.95rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background-color: rgba(255, 255, 255, 0.85);
    color: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.3;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.blog-filter-btn:hover {
    border-color: rgba(180, 130, 50, 0.65);
    background-color: rgba(180, 130, 50, 0.1);
}

.blog-filter-btn:focus-visible {
    outline: 2px solid #b48232;
    outline-offset: 2px;
}

.blog-filter-btn.is-active {
    background-color: #b48232;
    border-color: #b48232;
    color: #ffffff;
}

.blog-filter-count {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.1rem 0.45rem;
    border-radius: 999px;
    background-color: rgba(148, 163, 184, 0.2);
}

.blog-filter-btn.is-active .blog-filter-count {
    background-color: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

.blog-filter-empty {
    margin-top: 1.5rem;
    font-size: 1rem;
    opacity: 0.8;
}

.blog-card[hidden],
.blog-filter-empty[hidden] {
    display: none !important;
}

.blog-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 5rem;
}

.blog-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.85rem;
    padding: 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(148, 163, 184, 0.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    background-color: rgba(255, 255, 255, 1);
}

.blog-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px -12px rgba(15, 23, 42, 0.18);
    border-color: rgba(180, 130, 50, 0.55);
}

.blog-category {
    display: inline-block;
    width: 100%;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    background-color: rgba(180, 130, 50, 0.12);
    color: #724c0c; /* Contraste accesible superior a 4.5:1 */
    border: 1px solid rgba(180, 130, 50, 0.3);
    margin-bottom: 10px;
}


.blog-category:hover {
  background-color: rgba(180, 130, 50, 0.22);
  border-color: rgba(180, 130, 50, 0.5);
}

.blog-card h2 {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.35;
    margin: 0;
    min-height: 160px;
}

.blog-card h2 a,
.blog-card > a {
    text-decoration: none;
}

.blog-card h2 a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.blog-card time {
    font-size: 0.55rem;
    opacity: 0.7;
    display: block;
    margin-top: 10px;
}

.blog-card p {
    font-size: 0.875rem;
    line-height: 1.6;
    opacity: 0.9;
    margin: 0;
    min-height: 115px;
    margin-bottom: 20px;
}

.blog-card > a {
    margin-top: auto;
    font-weight: 600;
    font-size: 0.95rem;
}

/* Vista de artículo individual */
.blog-breadcrumb {
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.blog-breadcrumb a {
    text-decoration: none;
    opacity: 0.8;
    color: black;
    font-weight: bold;
}

.blog-breadcrumb a:hover {
    opacity: 1;
    text-decoration: underline;
}

.blog-post-header {
    margin-bottom: 2rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.25);
}

.blog-post-header h1 {
    font-size: clamp(1.85rem, 3.4vw, 2.6rem);
    font-weight: 700;
    line-height: 1.2;
    margin: 0.65rem 0 0.75rem;
}

.blog-post-header time {
    display: block;
    font-size: 0.875rem;
    opacity: 0.7;
}

/* Cuerpo del artículo */
.blog-post-content {
    font-size: 1.0625rem;
    line-height: 1.8;
}

.blog-post-content h2 {
    font-size: 1.45rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 2rem 0 0.75rem;
}

.blog-post-content h3 {
    font-size: 1.2rem;
    font-weight: 600;
    line-height: 1.35;
    margin: 1.5rem 0 0.5rem;
}

.blog-post-content p {
    margin: 0 0 1.15rem;
}

.blog-post-content ul,
.blog-post-content ol {
    margin: 0 0 1.25rem 1.35rem;
}

.blog-post-content li {
    margin-bottom: 0.45rem;
}

/* Bloque CTA hacia el servicio */
.blog-cta {
    margin-top: 2.25rem;
    padding: 1.5rem;
    border-radius: 0.75rem;
    border-left: 4px solid #b48232;
    background-color: rgba(180, 130, 50, 0.08);
}

.blog-cta a {
    display: inline-block;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
}

.blog-cta a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Artículos relacionados */
.blog-related {
    padding-top: 0;
}

.blog-related h2 {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 1rem;
}

.blog-related ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 0.65rem;
}

.blog-related a {
    text-decoration: none;
    font-weight: 500;
}

.blog-related a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.law-blog-section {
    padding: 3rem 2rem;
    background: rgba(148, 163, 184, 0.06);
}

.law-blog-container {
    max-width: 1200px;
    margin: 0 auto;
}

.law-blog-container > h2 {
    margin: 0 0 1.5rem;
    font-size: clamp(1.5rem, 2.5vw, 2rem);
}

.law-blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
    gap: 1.25rem;
}

.law-blog-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1.25rem;
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 1);
}

.law-blog-card h3,
.law-blog-card p {
    margin: 0;
}

.law-blog-card h3 {
    font-size: 1.1rem;
    line-height: 1.4;
}

.law-blog-card h3 a,
.law-blog-card-link,
.law-blog-archive-link {
    text-decoration: none;
}

.law-blog-card h3 a:hover,
.law-blog-card-link:hover,
.law-blog-archive-link:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.law-blog-card time {
    font-size: 0.8rem;
    opacity: 0.75;
}

.law-blog-card p {
    line-height: 1.6;
}

.law-blog-card-link {
    margin-top: auto;
    font-weight: 600;
}

.law-blog-archive-link {
    display: inline-block;
    margin-top: 1.5rem;
    font-weight: 700;
}

.law-blog-card a:focus-visible,
.law-blog-archive-link:focus-visible {
    outline: 2px solid #b48232;
    outline-offset: 3px;
}



/* Cabecera y entradilla del artículo */
.blog-post-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.blog-post-lead {
    font-size: 1.125rem;
    line-height: 1.65;
    opacity: 0.88;
    margin: 0.5rem 0 0;
}

/* Imagen de portada */
.blog-post-cover {
    margin: 0 0 2rem;
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.25);
}

.blog-post-cover img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 440px;
    object-fit: cover;
}

/* Elementos tipográficos dentro de cualquier artículo */
.blog-post-content blockquote {
    margin: 1.5rem 0;
    padding: 1rem 1.25rem;
    border-left: 3px solid #b48232;
    background-color: rgba(148, 163, 184, 0.08);
    border-radius: 0 0.5rem 0.5rem 0;
}

.blog-post-content a {
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 500;
}

/* CTA genérico */
.blog-cta-title {
    margin: 0 0 0.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    opacity: 0.85;
}

.blog-cta-btn {
    display: inline-block;
    padding: 0.65rem 1.15rem;
    border-radius: 0.5rem;
    background-color: #b48232;
    color: #ffffff !important;
    font-weight: 600;
    text-decoration: none !important;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.blog-cta-btn:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

/* Artículos relacionados en tarjetas */
.blog-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
}

.blog-related-card {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding: 1.15rem;
    border-radius: 0.65rem;
    border: 1px solid rgba(148, 163, 184, 0.25);
    text-decoration: none;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.blog-related-card:hover {
    transform: translateY(-2px);
    border-color: rgba(180, 130, 50, 0.6);
}

.blog-related-card h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.35;
}

.blog-card a{
    display: inline-block;
  padding: 4px 10px;
  background-color: #000000;
  color: #ffffff;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: background-color 0.2s ease;
  font-size: large;
}

.blog-card a:hover{
    background-color: #9a6718;
}