/* Enmarkalia Frame Comparator — only EPU products and this plugin's markup. */
.epu-photo-product .efc-launch{box-sizing:border-box;display:flex;align-items:center;text-align:left;gap:12px;width:100%;border:1px solid #d9e0e8;background:#f7f9fc;border-radius:9px;padding:10px 12px;margin:3px 0 12px;color:#15283e;cursor:pointer;font:inherit;min-height:53px;transition:border-color .15s,background .15s}
.epu-photo-product .efc-launch:hover,.epu-photo-product .efc-launch:focus-visible{background:#f0f5fb;border-color:#7088a3;outline:none}
.epu-photo-product .efc-launch-icon{display:grid;place-items:center;width:31px;height:31px;background:#e7edf4;border-radius:6px;font-size:23px;line-height:1;flex:none}
.epu-photo-product .efc-launch-copy{display:flex;flex-direction:column;flex:1;min-width:0;gap:1px}
.epu-photo-product .efc-launch-copy strong{font-size:12px;line-height:1.3;font-weight:750;color:#17293d}
.epu-photo-product .efc-launch-copy small{font-size:10px;line-height:1.3;color:#677689}
.epu-photo-product .efc-launch-tail{font-size:11px;font-weight:750;white-space:nowrap}
body.efc-modal-open{overflow:hidden!important}
.efc-modal[hidden],.efc-recent[hidden]{display:none!important}
.efc-modal{position:fixed;inset:0;z-index:999999;display:grid;place-items:center;padding:20px;font-family:inherit;color:#17283d}
.efc-backdrop{position:absolute;inset:0;background:rgba(11,22,36,.66);backdrop-filter:blur(3px)}
.efc-dialog{box-sizing:border-box;position:relative;width:min(1480px,94vw);max-height:min(960px,92dvh);overflow:hidden;background:#fff;border-radius:17px;box-shadow:0 24px 90px rgba(0,0,0,.28);display:flex;flex-direction:column}
.efc-dialog *{box-sizing:border-box}
.efc-dialog button{font-family:inherit;cursor:pointer}
.efc-dialog button:focus-visible{outline:3px solid #568fbe;outline-offset:2px}
.efc-dialog-head{flex:none;display:flex;gap:14px;justify-content:space-between;align-items:flex-start;padding:19px 23px 15px;border-bottom:1px solid #eef0f4}
.efc-dialog-head h2{font-size:24px!important;line-height:1.18!important;margin:4px 0 5px!important;font-weight:760!important;color:#17293d!important}
.efc-dialog-head p{margin:0;font-size:12px;color:#718094}
.efc-dialog-eyebrow{font-size:10px;font-weight:800;letter-spacing:.13em;color:#8290a1}
.efc-close{border:1px solid #e1e5eb;background:#fff;border-radius:9px;font-size:28px;line-height:1;width:35px;height:35px;color:#596b7c;flex:none}
.efc-dialog-body{display:grid;grid-template-columns:minmax(0,45fr) minmax(0,55fr);gap:0;min-height:0;flex:1;overflow:hidden}
.efc-left{display:flex;flex-direction:column;gap:8px;min-width:0;min-height:0;padding:14px 18px 14px 20px}
.efc-stage{flex:1;min-height:240px;background:#f6f7f8;border:1px solid #eff0f4;border-radius:12px;display:grid;place-items:center;padding:8px;overflow:hidden}
.efc-stage img,.efc-preview-canvas{display:block;width:auto!important;height:auto!important;max-width:100%!important;max-height:100%!important;object-fit:contain!important;box-shadow:none!important;border-radius:2px}
.efc-stage img{max-height:720px!important}
.efc-preview-canvas{max-height:min(70vh,720px)!important}
.efc-loading{color:#647487;font-size:13px;text-align:center}
.efc-picked{display:flex;justify-content:space-between;align-items:center;gap:14px;min-height:55px;padding:5px 6px}
.efc-picked>div{display:flex;flex-direction:column;gap:4px;min-width:0}
.efc-picked strong{font-size:13px;color:#152a3e}
.efc-picked span{font-size:11px;line-height:1.3;color:#758295}
.efc-picked>strong{font-size:16px;flex:none}
.efc-right{min-height:0;display:flex;flex-direction:column;border-left:1px solid #e9edf3;padding:17px 19px 15px}
.efc-list-title{display:flex;flex-direction:column;gap:3px;margin:0 0 12px}
.efc-list-title strong{font-size:14px;color:#15283b}
.efc-list-title span{font-size:11px;color:#788797}
.efc-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-rows:max-content;gap:12px;overflow:auto;align-content:start;padding:2px;flex:1;min-height:0}
.efc-model-card{min-width:0;align-self:start;border:1px solid #e2e7ed;background:#fff;border-radius:10px;padding:6px;display:flex;flex-direction:column;gap:5px;align-items:stretch;text-align:left;transition:border-color .15s,background .15s}
.efc-model-card:hover{border-color:#a5b6c8;background:#f9fbfd}
.efc-model-card.is-selected{border:2px solid #17283d;background:#f4f7fa;padding:5px}
.efc-model-card img{width:100%;height:clamp(125px,17vh,176px);object-fit:contain;background:#f9fafc;border-radius:6px}
.efc-model-card strong{font-size:12px;line-height:1.3;color:#25374b;overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}
.efc-model-card span{font-size:12px;font-weight:750;color:#21354b;margin-top:auto}
.efc-pagination{flex:none;display:flex;justify-content:space-between;align-items:center;gap:6px;padding:13px 0 2px;color:#657487;font-size:11px}
.efc-pagination button{font-size:11px;padding:8px 10px;background:#f8fafc;border:1px solid #dfe5ec;border-radius:7px;color:#25394f}
.efc-pagination button:disabled{opacity:.35;cursor:default}
.efc-dialog-actions{padding:15px 22px;display:flex;align-items:center;gap:14px;border-top:1px solid #eaedf2;flex:none}
.efc-dialog-actions button{font-size:12px;font-weight:700;border-radius:8px;min-height:40px;padding:10px 20px}
.efc-cancel{border:1px solid #dce2e9;background:#fff;color:#40536a}
.efc-choose{background:#17283d;color:#fff;border:1px solid #17283d;white-space:nowrap}
.efc-choose:hover{background:#2b4058}
.efc-choose:disabled{opacity:.55;cursor:wait}
.efc-message{font-size:11px;line-height:1.3;flex:1;color:#536b81;margin:0}
.efc-recent{clear:both;max-width:1240px;margin:35px auto 60px;padding:22px 2px 8px;border-top:1px solid #e5e9ee;font-family:inherit}
.efc-recent-head{display:flex;justify-content:space-between;align-items:end;margin:0 0 19px}
.efc-recent-head h2{font-size:23px!important;margin:0 0 5px!important;color:#17283d!important}
.efc-recent-head p{font-size:13px;color:#708093;margin:0}
.efc-recent-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:13px}
.efc-recent-card{min-width:0;display:flex;flex-direction:column;text-decoration:none!important;color:inherit!important;border:1px solid #e3e8ef;background:#fff;border-radius:11px;padding:9px;gap:10px;transition:transform .12s,border-color .12s}
.efc-recent-card:hover{transform:translateY(-2px);border-color:#aebfd1}
.efc-recent-card img{width:100%;height:152px;object-fit:contain;background:#f9fafc;border-radius:6px}
.efc-recent-copy{display:flex;flex-direction:column;gap:5px}
.efc-recent-copy strong{font-size:12px;line-height:1.35;color:#26394e}
.efc-recent-copy span{font-size:12px;color:#17293d;font-weight:700}
@media(max-width:980px){.efc-dialog{max-height:95dvh;width:96vw}.efc-dialog-body{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.efc-right{padding:13px}.efc-grid{grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:max-content}.efc-model-card img{height:clamp(108px,14vh,152px)}.efc-recent-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:640px){.efc-modal{padding:0;place-items:stretch}.efc-dialog{width:100vw;max-height:100dvh;height:100dvh;border-radius:0}.efc-dialog-head{padding:13px 15px}.efc-dialog-head h2{font-size:19px!important}.efc-dialog-head p{font-size:11px}.efc-dialog-body{display:flex;flex-direction:column;overflow-y:auto}.efc-left{padding:10px 12px 6px;flex:none}.efc-stage{min-height:0;height:27dvh;flex:none}.efc-stage img,.efc-preview-canvas{max-height:25dvh!important}.efc-picked{min-height:43px;padding:2px 0}.efc-picked strong{font-size:12px}.efc-picked>strong{font-size:14px}.efc-right{border:0;border-top:1px solid #edf0f4;overflow:visible;flex:none;padding:11px 12px}.efc-list-title{margin-bottom:8px}.efc-grid{grid-template-columns:repeat(3,minmax(0,1fr));overflow:visible;grid-auto-rows:max-content;gap:7px}.efc-model-card img{height:75px}.efc-grid{grid-auto-rows:max-content}.efc-dialog-actions{padding:9px 12px;gap:8px}.efc-dialog-actions button{padding:9px 12px}.efc-message{font-size:10px}.efc-recent{margin:25px 0 45px;padding:15px}.efc-recent-head h2{font-size:19px!important}.efc-recent-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.efc-recent-card img{height:145px}}

/* v1.0.4 — foco comercial en la ficha, sin modificar el motor de Photo Upload */
.epu-photo-product .efc-launch{
  position:relative;display:flex!important;min-height:64px!important;width:100%!important;
  padding:11px 12px!important;margin:5px 0 13px!important;
  background:linear-gradient(110deg,#1c3047,#293f5a)!important;border:1px solid #1a2e44!important;
  border-radius:11px!important;color:#fff!important;box-shadow:0 3px 12px rgba(24,41,61,.12);
  transition:transform .16s ease,box-shadow .16s ease!important;
}
.epu-photo-product .efc-launch:hover,.epu-photo-product .efc-launch:focus-visible{
  background:linear-gradient(110deg,#253b55,#354f70)!important;box-shadow:0 6px 18px rgba(24,41,61,.22);transform:translateY(-1px);
}
.epu-photo-product .efc-launch-icon{background:#eaf1f8!important;color:#182b40!important;width:37px;height:37px;font-size:24px;border-radius:8px}
.epu-photo-product .efc-launch-copy strong{font-size:13px!important;color:#fff!important;font-weight:800;line-height:1.2}
.epu-photo-product .efc-launch-copy small{font-size:10px!important;color:#e5edf5!important;line-height:1.3}
.epu-photo-product .efc-launch-tail{font-size:10px!important;font-weight:800!important;color:#fff!important;white-space:nowrap;opacity:.95}
.epu-photo-product .efc-launch:focus-visible{outline:3px solid #83b3e6!important;outline-offset:3px!important}

/* Vista de comparación sin parpadeo de lienzo al elegir otra moldura */
.efc-stage{position:relative}
.efc-stage.efc-is-updating::after{content:'Actualizando vista…';position:absolute;right:12px;bottom:12px;
  background:rgba(23,40,61,.88);color:#fff;font-size:11px;font-weight:700;padding:7px 11px;
  border-radius:16px;pointer-events:none;box-shadow:0 2px 8px rgba(0,0,0,.16)}

/* Vistos recientemente: tarjetas con tamaño real en ordenador. */
body.efc-photo-page .efc-recent{
  box-sizing:border-box!important;width:100%!important;max-width:1280px!important;min-width:0!important;
  grid-column:1/-1!important;flex-basis:100%;margin:35px auto 60px!important;
  padding:27px 10px 8px!important;border-top:1px solid #e4e9ef!important;
}
body.efc-photo-page .efc-recent-grid{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:17px!important;align-items:stretch}
body.efc-photo-page .efc-recent-card{display:flex!important;min-width:0;max-width:none!important;padding:12px!important;border-radius:13px!important;gap:10px!important}
body.efc-photo-page .efc-recent-card img{width:100%!important;height:220px!important;object-fit:contain!important;background:#f6f8fb!important;border-radius:9px}
body.efc-photo-page .efc-recent-copy strong{font-size:14px!important;line-height:1.38!important;min-height:38px}
body.efc-photo-page .efc-recent-copy .efc-recent-price{font-size:15px!important;color:#17293d!important}
body.efc-photo-page .efc-recent-copy .efc-recent-cta{font-size:12px!important;color:#2c5475!important;font-weight:750!important;margin-top:5px}

/* Relacionados: el cliente personaliza en la ficha, no compra sin configurar. */
body.efc-photo-page .related.products li.product.efc-related-enhanced,
body.efc-photo-page section.related li.product.efc-related-enhanced{box-sizing:border-box;min-width:0}
body.efc-photo-page .related li.product.efc-related-enhanced .add_to_cart_button,
body.efc-photo-page .related li.product.efc-related-enhanced .ajax_add_to_cart,
body.efc-photo-page .related li.product.efc-related-enhanced .added_to_cart,
body.efc-photo-page .related li.product.efc-related-enhanced .ct-woo-card-actions,
body.efc-photo-page .related li.product.efc-related-enhanced .ct-cart-actions{display:none!important}
body.efc-photo-page .related li.product .efc-related-action{
  display:flex!important;align-items:center;justify-content:center;box-sizing:border-box!important;
  width:100%!important;min-height:39px;margin:12px 0 3px!important;padding:9px 12px!important;
  border-radius:8px!important;border:1px solid #223850!important;background:#fff!important;
  color:#172a41!important;font-family:inherit!important;font-size:12px!important;font-weight:700!important;line-height:1.3!important;text-decoration:none!important;
  transition:background .15s,color .15s;
}
body.efc-photo-page .related li.product .efc-related-action:hover,
body.efc-photo-page .related li.product .efc-related-action:focus-visible{background:#172a41!important;color:#fff!important}
@media(max-width:1199px){
  body.efc-photo-page .efc-recent-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  body.efc-photo-page .efc-recent-card img{height:185px!important}
}
@media(max-width:700px){
  .epu-photo-product .efc-launch{min-height:59px!important;padding:9px 10px!important}
  .epu-photo-product .efc-launch-copy strong{font-size:12px!important}
  .epu-photo-product .efc-launch-tail{font-size:10px!important}
  body.efc-photo-page .efc-recent{padding:19px 3px 0!important;margin:23px auto 40px!important}
  body.efc-photo-page .efc-recent-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important}
  body.efc-photo-page .efc-recent-card{padding:9px!important}
  body.efc-photo-page .efc-recent-card img{height:155px!important}
  body.efc-photo-page .efc-recent-copy strong{font-size:12px!important;min-height:0}
}
@media(max-width:380px){.epu-photo-product .efc-launch-tail{display:none!important}}


/* 1.0.6 — Comparador como segunda acción, visual neutra, sin azul royal.
   No afecta a la ventana modal ni a los vistos recientemente. */
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch{
  min-height:43px!important;margin:0 0 8px!important;padding:7px 10px!important;
  border:1px solid #e3e4e4!important;border-left:3px solid #bca06b!important;
  border-radius:9px!important;background:#f7f8f8!important;
  box-shadow:none!important;color:#1d2937!important;transform:none!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch:hover,
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch:focus-visible{
  border-color:#c8b994!important;background:#f3f1ec!important;
  box-shadow:none!important;transform:none!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-icon{
  width:29px!important;height:29px!important;font-size:20px!important;
  background:#eeeae1!important;color:#69583d!important;border-radius:7px!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-copy strong{
  color:#1d2937!important;font-size:11.5px!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-copy small{
  color:#65717e!important;font-size:9.5px!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-tail{
  color:#233344!important;font-size:10px!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch:focus-visible{
  outline:2px solid #ad956c!important;outline-offset:2px!important;
}
@media(max-width:767px){
  body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch{
    min-height:42px!important;padding:7px 8px!important;
  }
  body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-copy small{
    font-size:9px!important;
  }
}

/* 1.0.7 — Icono vectorial y texto de prueba visual, conservando tarjeta compacta. */
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch{
  min-height:48px!important;padding:7px 10px!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-icon{
  flex:0 0 33px!important;width:33px!important;height:33px!important;
  display:grid!important;place-items:center!important;background:#eeece7!important;color:#77613e!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-icon svg{
  display:block!important;width:27px!important;height:27px!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-copy{
  gap:1px!important;min-width:0!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-copy strong{
  font-size:11px!important;line-height:1.2!important;
}
body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-copy small{
  font-size:9px!important;line-height:1.2!important;
}
@media(max-width:400px){
  body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-icon{width:29px!important;height:29px!important;flex-basis:29px!important;}
  body.epu-photo-product.epu-studio-ready .epu-photo-box .efc-launch-icon svg{width:24px!important;height:24px!important;}
}


/* 1.0.10 · Comparador móvil: 4 modelos por página en una cuadrícula 2×2.
   El área de vista previa se conserva arriba; la navegación funciona con
   botones grandes y desplazamiento lateral (swipe), sin ocultar el CTA. */
@media(max-width:640px){
  .efc-dialog-body .efc-grid{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    grid-auto-rows:max-content!important;
    gap:10px!important;
    overflow:visible!important;
    align-content:start!important;
    touch-action:pan-y!important;
  }
  .efc-dialog-body .efc-model-card{
    min-height:0!important;
    padding:8px!important;
    gap:5px!important;
  }
  .efc-dialog-body .efc-model-card.is-selected{padding:7px!important;}
  .efc-dialog-body .efc-model-card img{
    height:clamp(106px,15dvh,144px)!important;
    width:100%!important;object-fit:contain!important;
  }
  .efc-dialog-body .efc-model-card strong{font-size:12px!important;line-height:1.25!important;}
  .efc-dialog-body .efc-model-card span{font-size:12px!important;}
  .efc-dialog-body .efc-pagination{
    position:sticky!important;bottom:0!important;z-index:3!important;
    background:#fff!important;padding:10px 2px 7px!important;
    box-shadow:0 -6px 12px rgba(255,255,255,.96)!important;
    gap:6px!important;
  }
  .efc-dialog-body .efc-pagination button{
    min-height:40px!important;padding:9px 12px!important;
    font-size:12px!important;font-weight:700!important;
  }
  .efc-dialog-body .efc-pagination span{white-space:nowrap;font-size:10px!important;}
}
@media(max-width:640px) and (max-height:720px){
  .efc-dialog-body .efc-stage{height:22dvh!important;}
  .efc-dialog-body .efc-model-card img{height:105px!important;}
}
