:root {
  --orange: #ff7a00;
  --orange-dark: #e56600;
  --black: #111111;
  --text: #1d1d1f;
  --muted: #667085;
  --muted-strong: #475467;
  --border: #e6e8ec;
  --soft: #f6f7fb;
  --white: #ffffff;
  --shadow: 0 16px 40px rgba(17, 17, 17, .08);
  --shadow-soft: 0 10px 26px rgba(17,17,17,.05);
  --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: Arial, Helvetica, sans-serif; color: var(--text); background: var(--soft); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; }

.public-body { min-height: 100vh; }
.public-header {
  position: sticky; top: 0; z-index: 20;
  padding: 14px 16px;
  background: rgba(255,255,255,.92); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.header-inner,
.catalog-hero,
.category-block,
.footer-inner,
.hero { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand-link { display: flex; align-items: center; gap: 12px; font-weight: 800; }
.brand-logo { width: 104px; height: auto; border-radius: 10px; }
.public-nav { display: flex; gap: 8px; flex-wrap: wrap; }
.public-nav a {
  padding: 10px 14px; border-radius: 999px; color: var(--muted-strong); font-weight: 800;
  transition: background .2s ease, color .2s ease;
}
.public-nav a:hover { background: var(--black); color: var(--white); }

.hero, .catalog-hero { padding: clamp(26px, 6vw, 54px) 0; }
.hero-card {
  border: 1px solid var(--border);
  border-radius: 34px;
  background: radial-gradient(circle at top right, rgba(255,122,0,.16), transparent 42%), var(--white);
  box-shadow: var(--shadow);
}
.hero-card-home { padding: clamp(26px, 5vw, 58px); }
.hero-copy { max-width: 760px; }
.eyebrow {
  margin: 0 0 12px;
  color: var(--orange);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-size: 12px;
  font-weight: 900;
}
h1 { margin: 0; font-size: clamp(32px, 5vw, 56px); line-height: 1.03; }
.hero-text, .catalog-subtext { color: var(--muted); font-size: clamp(15px, 2vw, 18px); line-height: 1.6; }
.home-cards {
  margin-top: 32px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.home-card {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  text-align: left;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.home-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-soft); border-color: rgba(255,122,0,.35); }
.home-icon { font-size: 38px; display: block; margin-bottom: 18px; }
.home-card strong { display: block; font-size: 26px; margin-bottom: 8px; }
.home-card small { color: var(--muted); font-size: 15px; line-height: 1.5; }
.home-link { display: inline-flex; margin-top: 18px; font-weight: 900; color: var(--orange-dark); }

.catalog-hero { padding-bottom: 14px; }
.back-link { display: inline-flex; margin-bottom: 16px; color: var(--muted-strong); font-weight: 800; }
.catalog-hero-card {
  padding: clamp(22px, 4vw, 34px);
  background: linear-gradient(135deg, rgba(255,255,255,1), rgba(255,248,241,1));
  border: 1px solid var(--border);
  border-radius: 28px;
  box-shadow: var(--shadow-soft);
}
.category-block { padding: 4px 0 34px; }
.category-title {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}
.category-title h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.1;
}
.category-title::after {
  content: '';
  flex: 1;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--orange), rgba(255,122,0,0));
}
.product-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}
.phone-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.accessory-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.product-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  min-height: 100%;
}
.product-image-wrap {
  min-height: 250px;
  padding: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #ffffff 0%, #f7f7fa 100%);
}
.product-image-wrap img {
  width: 100%;
  height: 210px;
  object-fit: contain;
}
.image-placeholder {
  width: 100%;
  min-height: 170px;
  border: 2px dashed var(--border);
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 800;
}
.product-info {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.product-info h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
}
.spec-list { display: grid; gap: 8px; }
.spec {
  margin: 0;
  color: #344054;
  font-size: 14px;
  line-height: 1.45;
}
.spec span { color: var(--muted-strong); font-weight: 800; }
.payjoy-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 11px;
  background: #f8fafc;
  border: 1px solid #e7edf3;
  border-radius: 14px;
  flex-wrap: wrap;
  align-self: flex-start;
}
.payjoy-label { color: var(--muted-strong); font-size: 13px; font-weight: 800; }
.payjoy-box img { width: 72px; height: auto; }
.payjoy-yes {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #ecfdf3;
  color: #027a48;
  font-weight: 900;
  font-size: 13px;
}
.price-pill {
  margin-top: auto;
  align-self: flex-start;
  padding: 10px 17px;
  border: 2px solid var(--orange);
  border-radius: 999px;
  font-weight: 900;
  font-size: 18px;
  color: var(--orange-dark);
  background: #fff8f1;
}
.promo-text {
  display: inline-flex;
  align-self: flex-start;
  margin: 0;
  padding: 6px 10px;
  background: var(--black);
  color: var(--white);
  border-radius: 999px;
  font-weight: 800;
  font-size: 13px;
}
.empty-state, .placeholder-box {
  width: min(920px, calc(100% - 32px));
  margin: 24px auto;
  padding: 28px;
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.public-footer { padding: 12px 16px 28px; }
.public-footer p { margin: 0; color: var(--muted); text-align: center; font-size: 13px; line-height: 1.5; }

.auth-body { min-height: 100vh; display: grid; place-items: center; padding: 18px; background: radial-gradient(circle at 30% 20%, rgba(255,122,0,.20), transparent 35%), #101010; }
.login-card { width: min(430px, 100%); background: var(--white); border-radius: 28px; padding: 30px; box-shadow: var(--shadow); }
.login-logo { width: 150px; margin-bottom: 20px; }
.login-card h1 { font-size: 30px; }
.login-card p { color: var(--muted); }
.form-stack, .form-grid { display: grid; gap: 16px; }
label { display: grid; gap: 7px; color: #343842; font-weight: 800; font-size: 14px; }
input, select, textarea { width: 100%; border: 1px solid var(--border); border-radius: 14px; padding: 12px 13px; background: #fff; color: var(--text); outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--orange); box-shadow: 0 0 0 4px rgba(255,122,0,.12); }
.btn { display: inline-flex; justify-content: center; align-items: center; gap: 8px; border: 1px solid var(--border); border-radius: 14px; padding: 11px 16px; background: #fff; font-weight: 900; cursor: pointer; }
.btn.primary { background: var(--orange); border-color: var(--orange); color: #fff; }
.btn.small { padding: 8px 11px; font-size: 13px; }
.alert { padding: 13px 15px; border-radius: 14px; font-weight: 800; margin: 12px 0; }
.alert.error { background: #fff0f0; color: #b51d1d; }
.alert.success { background: #ecfff4; color: #15763a; }

.admin-body { min-height: 100vh; background: var(--soft); }
.admin-sidebar { position: fixed; inset: 0 auto 0 0; width: 270px; background: var(--black); color: var(--white); padding: 18px; z-index: 40; transform: translateX(-100%); transition: transform .22s ease; }
.sidebar-open .admin-sidebar { transform: translateX(0); }
.admin-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.admin-brand img { width: 96px; border-radius: 10px; }
.admin-menu { display: grid; gap: 7px; }
.admin-menu a { padding: 12px 14px; border-radius: 14px; color: rgba(255,255,255,.82); font-weight: 800; }
.admin-menu a:hover { background: rgba(255,255,255,.08); color: #fff; }
.admin-main { min-height: 100vh; }
.admin-topbar { position: sticky; top: 0; z-index: 25; height: 68px; display: flex; align-items: center; gap: 14px; padding: 0 18px; background: rgba(255,255,255,.94); border-bottom: 1px solid var(--border); backdrop-filter: blur(12px); }
.admin-topbar span { display: block; color: var(--muted); font-size: 13px; }
.menu-toggle { width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 12px; background: #fff; font-size: 22px; }
.admin-content { padding: 22px clamp(14px, 3vw, 36px) 70px; }
.page-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.page-head h1 { font-size: clamp(28px, 4vw, 42px); }
.stat-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.stat-card, .quick-actions a, .form-card, .table-card, .quick-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 10px 26px rgba(17,17,17,.04); }
.stat-card { padding: 20px; }
.stat-card span { color: var(--muted); font-weight: 800; }
.stat-card strong { display: block; font-size: 36px; margin-top: 8px; }
.quick-actions { margin-top: 20px; display: grid; grid-template-columns: 1fr; gap: 12px; }
.quick-actions a { padding: 18px; font-weight: 900; }
.filters { display: grid; grid-template-columns: 1fr; gap: 10px; margin-bottom: 16px; }
.table-card { overflow: auto; }
.admin-table { width: 100%; border-collapse: collapse; min-width: 860px; }
.admin-table th, .admin-table td { padding: 13px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
.admin-table th { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.thumb { width: 54px; height: 54px; object-fit: contain; background: #f5f5f7; border-radius: 12px; }
.mini-placeholder { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 12px; background: #f5f5f7; color: var(--muted); font-weight: 900; }
.status-badge { display: inline-flex; padding: 6px 10px; border-radius: 999px; font-size: 12px; font-weight: 900; background: #eef2ff; color: #23307d; }
.status-badge.available { background: #ecfff4; color: #15763a; }
.status-badge.out_of_stock { background: #fff0f0; color: #b51d1d; }
.status-badge.hidden { background: #f0f0f0; color: #555; }
.form-card { padding: clamp(16px, 3vw, 28px); }
.form-grid { grid-template-columns: 1fr; }
.span-2 { grid-column: auto; }
.checkbox-line { display: flex; align-items: center; gap: 10px; min-height: 44px; }
.checkbox-line input { width: auto; }
.form-actions { display: flex; justify-content: flex-end; margin-top: 20px; }
.quick-grid { display: grid; grid-template-columns: 1fr; gap: 13px; }
.quick-card { padding: 16px; display: grid; gap: 10px; }
.quick-card small { color: var(--muted); }
.sticky-save { position: sticky; bottom: 0; display: flex; justify-content: flex-end; padding: 15px 0; background: linear-gradient(transparent, var(--soft) 35%); }

@media (min-width: 620px) {
  .home-cards, .stat-grid, .quick-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .span-2 { grid-column: span 2; }
  .quick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 980px) {
  .admin-sidebar { transform: none; }
  .admin-main { margin-left: 270px; }
  .menu-toggle { display: none; }
  .filters { grid-template-columns: 2fr 1fr 1fr 1fr auto; }
  .quick-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 1280px) {
  .stat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .brand-link span { display: none; }
  .public-nav a { padding: 9px 10px; font-size: 13px; }
  .product-image-wrap { min-height: 220px; }
  .product-image-wrap img { height: 180px; }
  .price-pill { font-size: 20px; }
}

/* Ajuste visual 2: PayJoy en una sola línea, más parecido al catálogo */
.payjoy-line {
  display: flex !important;
  align-items: center !important;
  gap: 7px !important;
  flex-wrap: nowrap !important;
  width: 100% !important;
  margin: 0 !important;
  color: #344054 !important;
  font-size: 13px !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
}
.payjoy-line span {
  color: var(--muted-strong) !important;
  font-weight: 800 !important;
  flex: 0 0 auto !important;
}
.payjoy-line img {
  display: inline-block !important;
  width: 64px !important;
  max-width: 64px !important;
  height: auto !important;
  object-fit: contain !important;
  flex: 0 0 auto !important;
}
.payjoy-line strong {
  display: inline-block !important;
  color: var(--black) !important;
  font-weight: 900 !important;
  flex: 0 0 auto !important;
}
.product-info { gap: 10px; }
.spec-list { gap: 6px; }
.phone-card .product-info h3 { margin-bottom: 2px; }

@media (max-width: 360px) {
  .payjoy-line { flex-wrap: wrap !important; white-space: normal !important; }
}


/* GP_AJUSTE_VISUAL_3_START */
/* Ajuste de tarjetas públicas: evita que una sola tarjeta se estire a todo el ancho */
.product-grid.phone-grid,
.product-grid.accessory-grid {
  grid-template-columns: repeat(auto-fill, minmax(280px, 350px)) !important;
  justify-content: start !important;
  align-items: stretch !important;
}

.product-card {
  width: 100% !important;
  max-width: 350px !important;
}

.product-image-wrap {
  min-height: 230px !important;
}

.product-image-wrap img {
  height: 200px !important;
  object-fit: contain !important;
}

.payjoy-line,
.payjoy-box {
  display: flex !important;
  align-items: center !important;
  gap: 7px !important;
  flex-wrap: nowrap !important;
  width: 100% !important;
  font-size: 13px !important;
  line-height: 1.2 !important;
}

.payjoy-line img,
.payjoy-box img {
  width: 68px !important;
  height: auto !important;
  flex: 0 0 auto !important;
}

@media (max-width: 640px) {
  .product-grid.phone-grid,
  .product-grid.accessory-grid {
    grid-template-columns: 1fr !important;
  }

  .product-card {
    max-width: none !important;
  }

  .product-image-wrap {
    min-height: 220px !important;
  }

  .product-image-wrap img {
    height: 180px !important;
  }
}
/* GP_AJUSTE_VISUAL_3_END */


/* AJUSTE VISUAL 5 - TARJETA CATALOGO COMPACTA */
/* Forzar tarjetas tipo catálogo: no se estiran aunque haya pocos productos */
.product-grid.phone-grid,
.product-grid.accessory-grid,
.phone-grid,
.accessory-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(290px, 350px)) !important;
  justify-content: start !important;
  align-items: stretch !important;
  gap: 20px !important;
}

.product-card.phone-card,
.product-card.accessory-card,
.product-card {
  width: 100% !important;
  max-width: 350px !important;
  display: flex !important;
  flex-direction: column !important;
  border-radius: 18px !important;
  overflow: hidden !important;
}

/* Imagen más parecida al catálogo: bloque superior limpio */
.product-card .product-image-wrap {
  min-height: 230px !important;
  height: 230px !important;
  padding: 16px !important;
  background: #ffffff !important;
  border-bottom: 0 !important;
}

.product-card .product-image-wrap img {
  width: 100% !important;
  height: 195px !important;
  object-fit: contain !important;
}

/* Información compacta */
.product-card .product-info {
  padding: 16px 18px 18px !important;
  gap: 7px !important;
  background: #ffffff !important;
}

.product-card .product-info h3 {
  font-size: 19px !important;
  line-height: 1.15 !important;
  margin: 0 0 5px !important;
}

.product-card .spec-list {
  gap: 5px !important;
}

.product-card .spec {
  font-size: 13px !important;
  line-height: 1.25 !important;
}

/* PayJoy en una línea */
.product-card .payjoy-line {
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
  flex-wrap: nowrap !important;
  width: 100% !important;
  margin: 0 0 4px !important;
  font-size: 12px !important;
  line-height: 1.2 !important;
  color: #344054 !important;
}

.product-card .payjoy-line span {
  color: #475467 !important;
  font-weight: 800 !important;
  white-space: nowrap !important;
}

.product-card .payjoy-line img {
  width: 62px !important;
  height: auto !important;
  display: inline-block !important;
  flex: 0 0 auto !important;
}

.product-card .payjoy-line strong {
  color: #111111 !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
}

/* Precio estilo catálogo PDF: rectángulo completo con borde naranja */
.product-card .price-pill {
  width: 100% !important;
  display: block !important;
  align-self: stretch !important;
  text-align: center !important;
  margin: 12px 0 0 !important;
  padding: 6px 10px !important;
  border: 2px solid var(--orange) !important;
  border-radius: 6px !important;
  background: #ffffff !important;
  color: #1d1d1f !important;
  font-size: 23px !important;
  line-height: 1.1 !important;
  font-weight: 500 !important;
  letter-spacing: -0.02em !important;
  box-shadow: none !important;
}

/* En celular sí ocupar todo el ancho disponible */
@media (max-width: 640px) {
  .product-grid.phone-grid,
  .product-grid.accessory-grid,
  .phone-grid,
  .accessory-grid {
    grid-template-columns: 1fr !important;
  }

  .product-card.phone-card,
  .product-card.accessory-card,
  .product-card {
    max-width: none !important;
  }

  .product-card .product-image-wrap {
    min-height: 210px !important;
    height: 210px !important;
  }

  .product-card .product-image-wrap img {
    height: 175px !important;
  }

  .product-card .price-pill {
    font-size: 22px !important;
  }
}
/* FIN AJUSTE VISUAL 5 */

/* MEJORA ADMIN 1 - EDICION RAPIDA ORDEN */
.admin-help-text {
  margin: 8px 0 0;
  color: var(--muted);
  max-width: 760px;
  line-height: 1.5;
}

.quick-grid.quick-grid-order {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.quick-card.quick-card-order {
  padding: 16px;
  display: grid;
  gap: 14px;
}

.quick-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.quick-card-head strong {
  display: block;
  font-size: 16px;
  line-height: 1.25;
}

.quick-card-head small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.35;
}

.order-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 76px;
  padding: 7px 10px;
  border-radius: 999px;
  background: #fff8f1;
  color: var(--orange-dark);
  border: 1px solid rgba(255,122,0,.35);
  font-weight: 900;
  font-size: 12px;
  white-space: nowrap;
}

.quick-fields {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.quick-visible {
  align-self: end;
}

@media (min-width: 760px) {
  .quick-grid.quick-grid-order {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-fields {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1180px) {
  .quick-grid.quick-grid-order {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .quick-fields {
    grid-template-columns: 1fr 1fr 110px;
  }

  .quick-visible {
    grid-column: 1 / -1;
  }
}
/* FIN MEJORA ADMIN 1 */

/* MEJORA ADMIN 3 - TABLA EDICION RAPIDA */
.admin-help-text {
  margin: 8px 0 0;
  color: var(--muted);
  max-width: 760px;
  line-height: 1.5;
}

.quick-table-filters {
  grid-template-columns: 2fr 1fr 1fr auto;
}

.quick-table-card {
  overflow-x: auto;
}

.quick-edit-table {
  min-width: 920px;
}

.quick-edit-table th {
  background: #111111;
  color: #ffffff;
  border-bottom: 0;
}

.quick-edit-table td {
  background: #ffffff;
}

.quick-edit-table tbody tr:nth-child(even) td {
  background: #fafafa;
}

.quick-edit-table strong {
  display: block;
  font-size: 15px;
  line-height: 1.25;
}

.quick-product-meta {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.quick-edit-table input,
.quick-edit-table select {
  height: 42px;
  padding: 9px 11px;
  border-radius: 11px;
  margin: 0;
}

.quick-price-input {
  max-width: 140px;
  font-weight: 800;
}

.quick-order-input {
  max-width: 76px;
  text-align: center;
  font-weight: 900;
}

.quick-status-select {
  min-width: 150px;
}

.quick-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  font-weight: 900;
}

.quick-check input {
  width: 18px;
  height: 18px;
}

@media (max-width: 980px) {
  .quick-table-filters {
    grid-template-columns: 1fr 1fr;
  }

  .quick-table-card {
    background: transparent;
    border: 0;
    box-shadow: none;
    overflow: visible;
  }

  .quick-edit-table,
  .quick-edit-table thead,
  .quick-edit-table tbody,
  .quick-edit-table th,
  .quick-edit-table td,
  .quick-edit-table tr {
    display: block;
    min-width: 0;
    width: 100%;
  }

  .quick-edit-table thead {
    display: none;
  }

  .quick-edit-table tr {
    margin-bottom: 14px;
    padding: 16px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 10px 26px rgba(17,17,17,.04);
  }

  .quick-edit-table td {
    border: 0;
    padding: 9px 0;
    background: transparent !important;
  }

  .quick-edit-table td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 7px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .04em;
  }

  .quick-price-input,
  .quick-order-input,
  .quick-status-select {
    max-width: none;
    width: 100%;
  }
}

@media (max-width: 560px) {
  .quick-table-filters {
    grid-template-columns: 1fr;
  }
}
/* FIN MEJORA ADMIN 3 */
/* AJUSTE VISUAL 6 - ALINEACION PRECIOS */
/* Mantiene la altura visual de las tarjetas de celulares para que el precio quede al mismo nivel,
   aunque un equipo no muestre PayJoy. */
.phone-grid {
  align-items: stretch !important;
}

.phone-card {
  min-height: 445px !important;
}

.phone-card .product-info {
  min-height: 205px !important;
  display: flex !important;
  flex-direction: column !important;
}

.phone-card .spec-list {
  min-height: 58px !important;
}

.phone-card .price-pill {
  margin-top: auto !important;
}

@media (max-width: 640px) {
  .phone-card {
    min-height: 430px !important;
  }

  .phone-card .product-info {
    min-height: 195px !important;
  }
}
/* FIN AJUSTE VISUAL 6 */
/* AJUSTE VISUAL 7 - SIN MENU PUBLICO */
.public-header .header-inner {
  justify-content: center;
}

.public-header .brand-link {
  margin: 0 auto;
}

.public-nav {
  display: none !important;
}

.catalog-hero .back-link {
  display: inline-flex !important;
  align-items: center;
  font-weight: 900;
  color: #344054;
}

.catalog-hero .back-link:hover {
  color: var(--orange-dark);
}
/* FIN AJUSTE VISUAL 7 */
/* AJUSTE VISUAL 8 - SIN CABECERA PUBLICA */
.public-header {
  display: none !important;
}

body.public-body main {
  padding-top: 0 !important;
}

.hero,
.catalog-hero {
  padding-top: 22px !important;
}

@media (max-width: 640px) {
  .hero,
  .catalog-hero {
    padding-top: 16px !important;
  }
}
/* FIN AJUSTE VISUAL 8 */
/* MEJORA EXCEL IMPORT 1 */
.import-card {
  margin-bottom: 18px;
}

.import-card h2 {
  margin-top: 0;
  font-size: 22px;
}

.import-rules,
.import-result-list,
.import-error-list {
  margin: 10px 0 0;
  padding-left: 20px;
  line-height: 1.6;
}

.import-error-list {
  max-height: 260px;
  overflow: auto;
  background: rgba(255,255,255,.65);
  border-radius: 12px;
  padding-top: 10px;
  padding-bottom: 10px;
}
/* FIN MEJORA EXCEL IMPORT 1 */
/* MEJORA EXCEL IMPORT 3 */
.import-card {
  margin-bottom: 18px;
}

.import-card h2 {
  margin-top: 0;
  font-size: 22px;
}

.import-rules,
.import-result-list,
.import-error-list {
  margin: 10px 0 0;
  padding-left: 22px;
  line-height: 1.65;
}

.import-error-list {
  max-height: 260px;
  overflow: auto;
  background: rgba(255,255,255,.65);
  border-radius: 12px;
  padding-top: 10px;
  padding-bottom: 10px;
}
/* FIN MEJORA EXCEL IMPORT 3 */
/* AJUSTE ACCESORIOS 1 - PROMO COMO PRECIO */
.accessory-card .price-pill {
  font-weight: 500 !important;
  letter-spacing: -0.02em !important;
  text-transform: none !important;
}

.accessory-card .promo-text {
  display: none !important;
}
/* FIN AJUSTE ACCESORIOS 1 */
/* PRODUCTOS 1 - ELIMINAR SELECCIONADOS */
.bulk-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 12px 0 14px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 10px 26px rgba(17,17,17,.04);
}

.select-all-line {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 900;
  color: #344054;
}

.select-all-line input,
.product-check {
  width: 18px;
  height: 18px;
}

.btn.danger {
  background: #b42318;
  border-color: #b42318;
  color: #fff;
}

.btn.danger:hover {
  filter: brightness(.95);
}

.products-select-table .check-col {
  width: 52px;
  text-align: center;
}

@media (max-width: 760px) {
  .bulk-actions-bar {
    align-items: stretch;
    flex-direction: column;
  }

  .bulk-actions-bar .btn {
    width: 100%;
  }

  .products-select-table .check-col {
    width: auto;
    text-align: left;
  }
}
/* FIN PRODUCTOS 1 */
/* PRODUCTOS 2 - BARRA ELIMINAR MEJORADA */
.bulk-actions-bar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
  margin: 18px 0 18px !important;
  padding: 16px 18px !important;
  background: #ffffff !important;
  border: 1px solid #e6e8ec !important;
  border-radius: 18px !important;
  box-shadow: 0 10px 28px rgba(17, 17, 17, .045) !important;
}

.select-all-line {
  display: inline-flex !important;
  align-items: center !important;
  gap: 12px !important;
  margin: 0 !important;
  padding: 11px 14px !important;
  background: #f8fafc !important;
  border: 1px solid #e6e8ec !important;
  border-radius: 14px !important;
  color: #344054 !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  cursor: pointer !important;
  user-select: none !important;
}

.select-all-line:hover {
  background: #fff8f1 !important;
  border-color: rgba(255, 122, 0, .35) !important;
}

.select-all-line input {
  appearance: none !important;
  -webkit-appearance: none !important;
  width: 21px !important;
  height: 21px !important;
  margin: 0 !important;
  border: 2px solid #cfd6df !important;
  border-radius: 7px !important;
  background: #ffffff !important;
  display: inline-grid !important;
  place-content: center !important;
  cursor: pointer !important;
}

.select-all-line input:checked {
  background: var(--orange) !important;
  border-color: var(--orange) !important;
}

.select-all-line input:checked::after {
  content: "✓" !important;
  color: #ffffff !important;
  font-size: 15px !important;
  line-height: 1 !important;
  font-weight: 900 !important;
}

.product-check {
  appearance: none !important;
  -webkit-appearance: none !important;
  width: 19px !important;
  height: 19px !important;
  margin: 0 !important;
  border: 2px solid #cfd6df !important;
  border-radius: 6px !important;
  background: #ffffff !important;
  display: inline-grid !important;
  place-content: center !important;
  cursor: pointer !important;
}

.product-check:checked {
  background: var(--orange) !important;
  border-color: var(--orange) !important;
}

.product-check:checked::after {
  content: "✓" !important;
  color: #ffffff !important;
  font-size: 13px !important;
  line-height: 1 !important;
  font-weight: 900 !important;
}

.btn.danger,
.bulk-actions-bar .btn.danger {
  min-height: 46px !important;
  padding: 0 20px !important;
  border-radius: 14px !important;
  background: #b42318 !important;
  border: 1px solid #b42318 !important;
  color: #ffffff !important;
  font-weight: 950 !important;
  letter-spacing: -0.01em !important;
  box-shadow: 0 10px 22px rgba(180, 35, 24, .18) !important;
}

.btn.danger:hover,
.bulk-actions-bar .btn.danger:hover {
  background: #9f1f15 !important;
  border-color: #9f1f15 !important;
  transform: translateY(-1px) !important;
}

.products-select-table .check-col {
  width: 64px !important;
  text-align: center !important;
}

.products-select-table tbody tr:has(.product-check:checked) td {
  background: #fff8f1 !important;
}

@media (max-width: 760px) {
  .bulk-actions-bar {
    align-items: stretch !important;
    flex-direction: column !important;
    gap: 12px !important;
  }

  .select-all-line {
    justify-content: center !important;
    width: 100% !important;
  }

  .bulk-actions-bar .btn.danger {
    width: 100% !important;
  }

  .products-select-table .check-col {
    width: auto !important;
    text-align: left !important;
  }
}
/* FIN PRODUCTOS 2 */
/* LOGO GAMA PLUS REAL 1 */
.login-logo.real-gama-logo,
.login-card .login-logo {
  width: 260px !important;
  max-width: 88% !important;
  height: auto !important;
  object-fit: contain !important;
  margin: 0 auto 18px !important;
  display: block !important;
  border-radius: 0 !important;
  background: transparent !important;
}

.admin-brand {
  align-items: center !important;
  justify-content: center !important;
  padding: 18px 14px !important;
}

.admin-brand img,
.admin-brand .admin-real-logo {
  width: 165px !important;
  max-width: 100% !important;
  height: auto !important;
  object-fit: contain !important;
  border-radius: 0 !important;
  background: transparent !important;
}

.admin-brand strong {
  display: none !important;
}

@media (max-width: 760px) {
  .admin-brand img,
  .admin-brand .admin-real-logo {
    width: 140px !important;
  }

  .login-logo.real-gama-logo,
  .login-card .login-logo {
    width: 230px !important;
  }
}
/* FIN LOGO GAMA PLUS REAL 1 */


/* DISEÑO TARJETAS ACCESORIOS 4 */
/*
  Este ajuste aplica SOLO a accesorios.
  Los celulares conservan su diseño anterior.
*/
body:has(.catalog-hero h1) .catalog-hero h1 {
  /* sin cambios visuales; solo mantiene compatibilidad */
}

/* Compatibilidad para página /accesorios:
   Se usa el título visible "Accesorios" como contexto cuando el navegador soporta :has().
*/
body:has(.catalog-hero h1:is(:contains("Accesorios"))) {
  --gp-card-accessory-mode: 1;
}

/* Como :contains no es estándar, aplicamos por estructura y anulamos celulares abajo usando encabezado de celulares. */
.catalog-page .catalog-card,
.catalog-page .product-card,
.catalog-card,
.product-card {
  transition: none;
}

/* SOLO accesorios: las tarjetas de accesorios suelen no traer specs técnicas.
   Este bloque se activa cuando el body o contenedor tenga clase de accesorios si existe. */
body.accessories .catalog-card,
body.accessories .product-card,
.catalog-accessories .catalog-card,
.catalog-accessories .product-card,
.accessories-catalog .catalog-card,
.accessories-catalog .product-card,
#accessories .catalog-card,
#accessories .product-card {
  min-height: 355px !important;
  height: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
}

/* Fallback seguro: si no hay clase de accesorios, aplica SOLO cuando la URL sea /accesorios mediante clase inyectada por JS abajo */
body.gp-accessories-page .catalog-card,
body.gp-accessories-page .product-card {
  min-height: 355px !important;
  height: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
}

body.gp-accessories-page .catalog-products,
body.gp-accessories-page .catalog-grid,
body.gp-accessories-page .products-grid,
body.gp-accessories-page .product-grid {
  align-items: stretch !important;
}

body.gp-accessories-page .catalog-card .product-image-box,
body.gp-accessories-page .catalog-card .image-box,
body.gp-accessories-page .catalog-card .image-area,
body.gp-accessories-page .catalog-card .product-image,
body.gp-accessories-page .catalog-card .card-image,
body.gp-accessories-page .product-card .product-image-box,
body.gp-accessories-page .product-card .image-box,
body.gp-accessories-page .product-card .image-area,
body.gp-accessories-page .product-card .product-image,
body.gp-accessories-page .product-card .card-image,
body.accessories .catalog-card .product-image-box,
body.accessories .product-card .product-image-box,
.catalog-accessories .catalog-card .product-image-box,
.catalog-accessories .product-card .product-image-box {
  height: 165px !important;
  min-height: 165px !important;
  max-height: 165px !important;
  flex: 0 0 165px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 18px 18px 6px !important;
  box-sizing: border-box !important;
}

body.gp-accessories-page .catalog-card img,
body.gp-accessories-page .product-card img,
body.accessories .catalog-card img,
body.accessories .product-card img,
.catalog-accessories .catalog-card img,
.catalog-accessories .product-card img {
  max-height: 145px !important;
  max-width: 82% !important;
  width: auto !important;
  object-fit: contain !important;
  display: block !important;
  margin: 0 auto !important;
}

body.gp-accessories-page .catalog-card .product-content,
body.gp-accessories-page .catalog-card .card-content,
body.gp-accessories-page .catalog-card .product-info,
body.gp-accessories-page .catalog-card .card-body,
body.gp-accessories-page .catalog-card .content,
body.gp-accessories-page .product-card .product-content,
body.gp-accessories-page .product-card .card-content,
body.gp-accessories-page .product-card .product-info,
body.gp-accessories-page .product-card .card-body,
body.gp-accessories-page .product-card .content,
body.accessories .catalog-card .product-content,
body.accessories .product-card .product-content,
.catalog-accessories .catalog-card .product-content,
.catalog-accessories .product-card .product-content {
  flex: 1 1 auto !important;
  display: flex !important;
  flex-direction: column !important;
  padding: 18px 22px 20px !important;
  box-sizing: border-box !important;
}

body.gp-accessories-page .catalog-card h2,
body.gp-accessories-page .catalog-card h3,
body.gp-accessories-page .catalog-card .product-name,
body.gp-accessories-page .catalog-card .product-title,
body.gp-accessories-page .catalog-card .card-title,
body.gp-accessories-page .product-card h2,
body.gp-accessories-page .product-card h3,
body.gp-accessories-page .product-card .product-name,
body.gp-accessories-page .product-card .product-title,
body.gp-accessories-page .product-card .card-title,
body.accessories .catalog-card h2,
body.accessories .catalog-card h3,
body.accessories .product-card h2,
body.accessories .product-card h3,
.catalog-accessories .catalog-card h2,
.catalog-accessories .catalog-card h3,
.catalog-accessories .product-card h2,
.catalog-accessories .product-card h3 {
  min-height: 52px !important;
  max-height: 52px !important;
  line-height: 1.15 !important;
  margin: 0 0 12px !important;
  overflow: hidden !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
}

body.gp-accessories-page .catalog-card .price-pill,
body.gp-accessories-page .catalog-card .price,
body.gp-accessories-page .catalog-card .product-price,
body.gp-accessories-page .product-card .price-pill,
body.gp-accessories-page .product-card .price,
body.gp-accessories-page .product-card .product-price,
body.accessories .catalog-card .price-pill,
body.accessories .product-card .price-pill,
.catalog-accessories .catalog-card .price-pill,
.catalog-accessories .product-card .price-pill {
  margin-top: auto !important;
  width: 100% !important;
  box-sizing: border-box !important;
  flex: 0 0 auto !important;
  min-height: 48px !important;
}

/* Celulares: forzamos a NO heredar este ajuste */
body.gp-phones-page .catalog-card,
body.gp-phones-page .product-card {
  min-height: unset !important;
}

@media (max-width: 760px) {
  body.gp-accessories-page .catalog-card,
  body.gp-accessories-page .product-card {
    min-height: 340px !important;
  }

  body.gp-accessories-page .catalog-card .product-image-box,
  body.gp-accessories-page .catalog-card .image-box,
  body.gp-accessories-page .catalog-card .image-area,
  body.gp-accessories-page .catalog-card .product-image,
  body.gp-accessories-page .catalog-card .card-image,
  body.gp-accessories-page .product-card .product-image-box,
  body.gp-accessories-page .product-card .image-box,
  body.gp-accessories-page .product-card .image-area,
  body.gp-accessories-page .product-card .product-image,
  body.gp-accessories-page .product-card .card-image {
    height: 150px !important;
    min-height: 150px !important;
    max-height: 150px !important;
    flex-basis: 150px !important;
  }
}
/* FIN DISEÑO TARJETAS ACCESORIOS 4 */








/* MODELOS DISPONIBLES DEFINITIVO 11 */
.gp11-compat-btn,button.gp11-compat-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:100%!important;min-height:44px!important;border:1.5px solid #ff6b00!important;border-radius:999px!important;background:#fff8f1!important;background-image:none!important;color:#b45309!important;font-family:Arial,Helvetica,sans-serif!important;font-size:15px!important;font-weight:950!important;line-height:1!important;cursor:pointer!important;padding:0 14px!important;margin:0 0 10px!important;box-shadow:none!important;text-decoration:none!important;text-align:center!important;-webkit-appearance:none!important;appearance:none!important;-webkit-tap-highlight-color:transparent!important;}
.gp11-compat-btn:hover,button.gp11-compat-btn:hover{background:#ff6b00!important;color:#fff!important;}
/* FIN MODELOS DISPONIBLES DEFINITIVO 11 */
