/* ═══════════════════════════════════════════════
   Bookinest Form — Estilos
   Prefijo: bk- para evitar conflictos con el theme
   ═══════════════════════════════════════════════ */

#bookinest-app {
  font-family: 'Nunito', sans-serif;
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#bookinest-app * { box-sizing: border-box; }

/* Fullscreen overlay para el formulario */
.bk-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
}
.bk-overlay.bk-overlay--open {
  display: flex;
}
.bk-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.6);
}
.bk-overlay-inner {
  position: relative;
  background: #ffffff;
  border-radius: 16px;
  max-width: 800px;
  width: 80vw;
  max-height: 90vh;
  padding: 24px 16px;
  display: flex;
  justify-content: center;
  align-items: stretch;
  overflow: hidden;
}
.bk-overlay-close {
  position: fixed;
  top: 20px;
  right: 20px;
  background: transparent;
  border: none;
  color: #ffffff;
  font-size: 1.8rem;
  cursor: pointer;
  z-index: 1;
}

/* Steps */
.bk-step { display: none; }
.bk-step.active {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 16px;
  flex: 1;
  overflow: auto;
}

/* Card */
.bk-card {
  background: white;
  border-radius: 16px;
  box-shadow: none;
  padding: 28px 24px;
  width: 100%;
  max-width: 460px;
}
.bk-card-title { font-family: 'Dongle', sans-serif; font-size: 2.4rem; color: #1a56a0; text-align: center; line-height: 1; margin-bottom: 4px; }
.bk-card-sub { text-align: center; color: #90a8c8; font-size: .9rem; margin-bottom: 24px; }

/* Labels e inputs */
.bk-label { display: block; font-weight: 700; font-size: .85rem; color: #2b4a7a; margin: 16px 0 6px; }
.bk-optional { font-weight: 400; color: #aac0da; }
.bk-input,
.bk-textarea {
  width: 100%; padding: 11px 14px; border: 1.5px solid #c5d8f0;
  border-radius: 10px; font-family: 'Nunito', sans-serif; font-size: 1rem;
  background: #f7faff; outline: none; transition: border .2s;
}
.bk-input:focus, .bk-textarea:focus { border-color: #1a56a0; }
.bk-textarea { height: 80px; resize: vertical; }

/* Age grid */
.bk-age-grid { display: grid; grid-template-columns: repeat(6,1fr); gap: 8px; margin-top: 4px; }
.bk-age-btn {
  padding: 10px 0; border-radius: 8px; cursor: pointer; text-align: center;
  font-family: 'Nunito', sans-serif; font-weight: 700; font-size: 1rem;
  border: 2px solid #c5d8f0; background: white; color: #5580b0;
  transition: all .15s; user-select: none;
}
.bk-age-btn.sel { background: #1a56a0; color: white; border-color: #1a56a0; }

/* Botones */
.bk-btn-main {
  width: 100%; margin-top: 24px; padding: 13px; background: #1a56a0;
  color: white; border: none; border-radius: 100px;
  font-family: 'Nunito', sans-serif; font-size: 1.05rem; font-weight: 700; cursor: pointer;
}
.bk-btn-main:hover, .bk-ghost-small:hover { background: #80c0d8!important; color: #ffffff!important; }
.bk-btn-main:disabled { opacity: .4; cursor: not-allowed; }
.bk-ghost {
  background: none; border: none; cursor: pointer; color: #1a56a0;
  font-family: 'Nunito', sans-serif; font-weight: 700; font-size: .95rem; margin-bottom: 12px;
  border-radius: 100px;
  padding: 6px 16px;
}
.bk-ghost-small {
  background: none; border: none; color: #90a8c8;
  font-family: 'Nunito', sans-serif; font-size: .85rem; cursor: pointer;
  border-radius: 100px;
  padding: 4px 12px;
}
.bk-ghost-small:hover {
  background-color: #80c0d8;
  color: #ffffff;
}

/* Botón ancla para descripción corta (short description) */
.bk-shortdesc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 26px !important;
  margin-top: 8px;
  border-radius: 100px !important;
  border: none !important;
  font-family: 'Roboto', sans-serif !important;
  font-weight: 700;
  font-size: .95rem;
  text-transform: uppercase;
  color: #ffffff !important;
  background: #000000 !important;
  text-decoration: none !important;
  cursor: pointer;
  transition: all 0.3s ease;
}
.bk-shortdesc-btn:hover {
  background-color: #80c0d8 !important; /* celeste */
  color: #ffffff !important;
  text-decoration: none !important;
}

/* Hover global para mantener consistencia con botones del theme */
.completar-formulario-btn:hover,
.wp-block-button__link:hover,
.uagb-button__wrapper .uagb-button__link:hover,
.wp-block-uagb-buttons .uagb-buttons-repeater .uagb-button__link:hover,
a.button:hover,
button:hover,
input[type="submit"]:hover {
  background-color: #80c0d8 !important;
  color: #ffffff !important;
}

/* Botones de navegación también redondos */
.bk-nav-btn {
  border-radius: 100px;
}

/* Cover selection */
.bk-pick-title { font-family: 'Dongle', sans-serif; font-size: 2.2rem; color: #1a56a0; text-align: center; }
.bk-pick-sub { color: #90a8c8; font-size: .9rem; text-align: center; margin: 4px 0 28px; }
.bk-cover-row { display: flex; gap: 24px; justify-content: center; flex-wrap: wrap; width: 100%; max-width: 580px; }
.bk-cover-card { width: calc(50% - 12px); max-width: 250px; display: flex; flex-direction: column; gap: 12px; align-items: center; }
.bk-cover-wrap {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: none;
  cursor: pointer;
  transition: transform .2s;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 260px;
  width: 100%;
}
.bk-cover-wrap:hover { transform: scale(1.03); }
.bk-cover-wrap canvas {
  height: 100%;
  width: auto;
  max-width: 100%;
  display: block;
}

/* Format selection */
.bk-format-row { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; width: 100%; max-width: 780px; }
.bk-format-card {
  flex: 1; min-width: 180px; max-width: 230px; background: white;
  border-radius: 14px; border: 2.5px solid #c5d8f0; padding: 24px 18px;
  text-align: center; cursor: pointer; transition: all .2s;
}
.bk-format-card:hover { border-color: #1a56a0; transform: translateY(-2px); box-shadow: none; }
.bk-format-card.sel { border-color: #1a56a0; background: #f0f6ff; box-shadow: none; }
.bk-format-icon { font-size: 2.4rem; margin-bottom: 8px; }
.bk-format-name { font-family: 'Dongle', sans-serif; font-size: 1.8rem; color: #1a56a0; line-height: 1.1; }
.bk-format-desc { font-size: .82rem; color: #90a8c8; margin: 6px 0 12px; line-height: 1.4; }
.bk-format-price { font-family: 'Dongle', sans-serif; font-size: 2rem; color: #2b4a7a; line-height: 1; }
.bk-format-price-note { font-size: .75rem; color: #aac0da; margin-top: 2px; }

/* Book preview */
.bk-book-wrap { width: 100%; max-width: 720px; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.bk-book-header { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.bk-pg-count { color: #90a8c8; font-size: .85rem; }
.bk-page-box {
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: none;
  transition: transform .28s, opacity .28s;
  max-height: 300px;
  height: auto;
}
.bk-page-box.sl { transform: translateX(-40px); opacity: 0; }
.bk-page-box.sr { transform: translateX(40px); opacity: 0; }

.bk-price-bar {
  background: white; border-radius: 10px; padding: 10px 18px;
  box-shadow: none; display: flex;
  align-items: center; justify-content: center; gap: 8px;
  font-family: 'Nunito', sans-serif; font-size: .9rem; color: #2b4a7a;
  margin-bottom: 10px; width: 100%; max-width: 720px;
}
.bk-price-bar strong { font-family: 'Dongle', sans-serif; font-size: 1.6rem; color: #1a56a0; line-height: 1; }

/* Page layouts */
.bk-sq {
  width: 100%;
  height: auto;
  overflow: hidden;
}
.bk-sq img,
.bk-sq canvas {
  position: static;
  display: block;
  max-height: 300px;
  width: auto;
  height: auto;
  max-width: 100%;
  margin: 0 auto;
}

/* Canvas principal del libro: sin crop, máximo 300px de alto */
#bk-cv-book {
  position: static !important;
  width: auto !important;
  height: auto !important;
  max-height: 300px !important;
  max-width: 100% !important;
  margin: 0 auto;
}
.bk-ls {
  width: 100%;
  height: auto;
  overflow: hidden;
}
.bk-ls img {
  position: static;
  display: block;
  max-height: 300px;
  width: auto;
  height: auto;
  max-width: 100%;
  margin: 0 auto;
}

/* Lock page */
.bk-lock-page {
  width: 100%;
  min-height: 200px;
  max-height: 300px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f6ff 0%, #e8f0fe 100%);
}
.bk-lock-content {
  position: absolute; top:0; left:0; width:100%; height:100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
}
.bk-lock-icon { font-size: 3rem; opacity: 0.7; }
.bk-lock-title { font-family: 'Dongle', sans-serif; font-size: 2.2rem; color: #1a56a0; line-height: 1; }
.bk-lock-sub { font-family: 'Nunito', sans-serif; font-size: .85rem; color: #90a8c8; text-align: center; max-width: 80%; line-height: 1.5; }

/* Navigation */
.bk-nav-row { display: flex; align-items: center; gap: 16px; }
.bk-nav-btn {
  background: #1a56a0; color: white; border: none; border-radius: 50%;
  width: 46px; height: 46px; font-size: 1.6rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.bk-nav-btn:disabled { opacity: .3; cursor: not-allowed; }
.bk-dots { display: flex; gap: 7px; flex-wrap: wrap; justify-content: center; max-width: 320px; }
.bk-dot { width: 10px; height: 10px; border-radius: 50%; cursor: pointer; background: #c5d8f0; transition: all .2s; }
.bk-dot.active { background: #1a56a0; transform: scale(1.35); }

/* Confirm box */
.bk-confirm-box {
  width: 100%; background: white; border-radius: 14px;
  box-shadow: none; padding: 20px 24px;
  display: flex; flex-direction: column; align-items: center; gap: 10px; margin-top: 4px;
}
.bk-confirm-summary {
  font-family: 'Nunito', sans-serif; font-size: .95rem; color: #2b4a7a; text-align: center;
}
