/* Banner de consent — modal centrado en sintonía con la landing editorial.
   Paleta: crema/papel + tinta verde oscuro + acentos mate/terracotta.
   Tipografías: Playfair Display (titular) + Instrument Sans (body). */

#ia-consent-banner {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(30, 42, 35, 0.55);
    backdrop-filter: blur(8px) saturate(120%);
    -webkit-backdrop-filter: blur(8px) saturate(120%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    font-family: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, sans-serif;
    animation: ia-consent-fadein 0.28s ease-out;
}

@keyframes ia-consent-fadein {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.ia-consent-inner {
    position: relative;
    width: 100%;
    max-width: 540px;
    background: #FBF7EE;
    color: #1E2A23;
    border: 1px solid #D9CFB8;
    border-radius: 28px;
    box-shadow:
        0 1px 0 rgba(30, 42, 35, 0.04),
        0 24px 60px -20px rgba(30, 42, 35, 0.45),
        0 4px 14px rgba(30, 42, 35, 0.18);
    padding: 36px 36px 32px;
    text-align: left;
    animation: ia-consent-pop 0.36s cubic-bezier(0.2, 0.9, 0.3, 1.15);
    overflow: hidden;
}

/* Grain sutil en el panel para el feel "papel" */
.ia-consent-inner::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.25;
    mix-blend-mode: multiply;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .12  0 0 0 0 .16  0 0 0 0 .14  0 0 0 .06 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

/* Línea decorativa en el borde superior (acento mate) */
.ia-consent-inner::after {
    content: "";
    position: absolute;
    top: 0; left: 36px;
    width: 56px;
    height: 4px;
    background: #6B7B3F;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
}

@keyframes ia-consent-pop {
    from { opacity: 0; transform: translateY(14px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.ia-consent-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #4D5A2B;
    margin-bottom: 14px;
    position: relative;
}

.ia-consent-eyebrow::before {
    content: "";
    width: 28px;
    height: 1px;
    background: #4D5A2B;
    opacity: 0.7;
}

.ia-consent-title {
    font-family: "Playfair Display", "Times New Roman", Georgia, serif;
    font-size: 30px;
    font-weight: 500;
    line-height: 1.05;
    letter-spacing: -0.015em;
    margin: 0 0 14px;
    color: #1E2A23;
    position: relative;
}

.ia-consent-title em {
    font-style: italic;
    color: #6B7B3F;
}

.ia-consent-text {
    font-family: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
    font-size: 15.5px;
    line-height: 1.6;
    color: #3E4A42;
    margin: 0 0 24px;
    position: relative;
}

.ia-consent-text a {
    color: #1E2A23;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-color: #6B7B3F;
    text-decoration-thickness: 1.5px;
    transition: color 0.15s ease;
}

.ia-consent-text a:hover {
    color: #6B7B3F;
}

.ia-consent-actions {
    display: flex;
    gap: 12px;
    flex-direction: row-reverse;
    flex-wrap: wrap;
    position: relative;
}

.ia-consent-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 24px;
    border-radius: 999px;
    border: 1px solid transparent;
    font-family: "Instrument Sans", ui-sans-serif, system-ui, sans-serif;
    font-weight: 600;
    font-size: 15px;
    letter-spacing: -0.005em;
    cursor: pointer;
    transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
    flex: 1 1 auto;
    min-width: 140px;
}

.ia-consent-btn:hover {
    transform: translateY(-1px);
}

.ia-consent-btn:focus-visible {
    outline: 2px solid #6B7B3F;
    outline-offset: 3px;
}

.ia-consent-accept {
    background: #1E2A23;
    color: #FBF7EE;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.18), 0 10px 24px -12px rgba(30, 42, 35, 0.6);
}

.ia-consent-accept:hover {
    background: #4D5A2B;
}

.ia-consent-accept .arrow {
    display: inline-block;
    transition: transform 0.18s ease;
}

.ia-consent-accept:hover .arrow {
    transform: translateX(3px);
}

.ia-consent-deny {
    background: transparent;
    color: #1E2A23;
    border-color: #1E2A23;
}

.ia-consent-deny:hover {
    background: #1E2A23;
    color: #FBF7EE;
}

@media (max-width: 480px) {
    .ia-consent-inner { padding: 28px 24px 24px; border-radius: 22px; }
    .ia-consent-inner::after { left: 24px; }
    .ia-consent-title { font-size: 24px; }
    .ia-consent-text  { font-size: 14.5px; }
    .ia-consent-actions { flex-direction: column-reverse; }
    .ia-consent-btn { width: 100%; min-width: 0; }
}

/* Bloquea el scroll del body mientras el modal está visible */
body.ia-consent-locked { overflow: hidden; }
