/* StarVanguard — estilos de blog.html y tienda.html.
 * Se carga después de css/web.css (tokens, nav, botones y glass ya vienen de ahí).
 * Mantiene el mismo tema que la portada sin duplicar su CSS. */

/* ---------------------------------------------------------------- TIENDA */
.shop-toolbar{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:12px;
  margin-bottom:20px;
}
.currency-switch{
  display:inline-flex;
  padding:3px;
  gap:3px;
  border:1px solid var(--line);
  border-radius:999px;
  background:rgba(6,20,34,.6);
}
.currency-switch button{
  border:0;
  border-radius:999px;
  padding:7px 16px;
  background:transparent;
  color:var(--muted);
  font:inherit;
  font-size:.72rem;
  font-weight:800;
  letter-spacing:.1em;
  cursor:pointer;
}
.currency-switch button.is-active{
  background:rgba(63,208,255,.16);
  color:#dff6ff;
  box-shadow:inset 0 0 0 1px rgba(63,208,255,.35);
}
.shop-rate{font-size:.72rem;color:var(--muted)}
.session-info{font-size:.74rem;color:var(--muted)}
.shop-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(280px,1fr));
  gap:18px;
}
.shop-card{
  padding:20px;
  display:flex;
  flex-direction:column;
  gap:10px;
  overflow:hidden;
}
/* Tarjetas con arte: la imagen va de fondo y un degradado oscuro garantiza
 * la legibilidad del texto (kind, título, descripción, precio y botón). */
.shop-card.has-image{
  min-height:380px;
  justify-content:flex-end;
  isolation:isolate;
  background-color:#081624;
  background-position:center;
  background-repeat:no-repeat;
  background-size:cover;
  border-color:rgba(63,208,255,.2);
  transition:transform .18s ease,border-color .18s ease;
}
.shop-card.has-image::before{
  content:"";
  position:absolute;
  inset:0;
  z-index:0;
  pointer-events:none;
  background:linear-gradient(
    180deg,
    rgba(4,11,22,.08) 0%,
    rgba(4,11,22,.32) 38%,
    rgba(4,11,22,.78) 66%,
    rgba(4,11,22,.95) 100%
  );
}
.shop-card.has-image > *{position:relative;z-index:1}
.shop-card.has-image:hover{transform:translateY(-2px);border-color:rgba(63,208,255,.45)}
/* Panel de contenido: garantiza contraste sobre cualquier arte. */
.shop-card-body{
  display:flex;
  flex-direction:column;
  gap:10px;
  flex:1;
  min-width:0;
}
.shop-card.has-image .shop-card-body{
  flex:0 0 auto;
  padding:16px;
  border:1px solid rgba(63,208,255,.16);
  border-radius:14px;
  background:linear-gradient(165deg,rgba(7,21,37,.82) 0%,rgba(4,11,22,.94) 100%);
  box-shadow:0 18px 44px -26px rgba(0,0,0,.95),inset 0 1px 0 rgba(255,255,255,.05);
  backdrop-filter:blur(9px);
  -webkit-backdrop-filter:blur(9px);
}
.shop-card.has-image > .code-row{margin-top:8px}
.shop-card h3{margin:0;font-size:1rem;line-height:1.25}
.shop-kind{
  color:var(--cyan);
  font-size:.64rem;
  font-weight:800;
  letter-spacing:.16em;
  text-transform:uppercase;
  text-shadow:0 1px 3px rgba(0,0,0,.75);
}
.shop-card.has-image h3{color:#fff;text-shadow:0 1px 4px rgba(0,0,0,.8)}
.shop-desc{
  margin:0;
  color:#c6dfef;
  font-size:.78rem;
  line-height:1.5;
  overflow-wrap:anywhere;
  text-shadow:0 1px 3px rgba(0,0,0,.8);
}
.shop-gallery{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(62px,1fr));
  gap:7px;
  margin:2px 0 4px;
}
.shop-gallery.is-single{grid-template-columns:minmax(0,96px)}
.shop-shot{
  display:flex;
  flex-direction:column;
  gap:3px;
  min-width:0;
  margin:0;
}
.shop-shot img{
  width:100%;
  height:auto;
  aspect-ratio:1 / 1;
  object-fit:cover;
  border:1px solid rgba(63,208,255,.24);
  border-radius:8px;
  background:rgba(3,10,20,.55);
  transition:transform .18s ease,border-color .18s ease;
}
.shop-shot img:hover{transform:translateY(-2px);border-color:rgba(63,208,255,.6)}
.shop-shot figcaption{
  color:#a9c8da;
  font-size:.53rem;
  line-height:1.2;
  letter-spacing:.03em;
  text-align:center;
  overflow-wrap:anywhere;
  text-shadow:0 1px 2px rgba(0,0,0,.85);
}
.shop-price{
  font-size:1.35rem;
  font-weight:800;
  color:#fff;
  margin:2px 0 0;
  text-shadow:0 1px 4px rgba(0,0,0,.85);
}
.shop-card .mini-btn{margin-top:auto;width:100%}
.shop-card.has-image .mini-btn{margin-top:6px}
.code-row{display:flex;gap:8px}
.code-row input{flex:1;min-width:0}
.shop-note{
  margin:18px 0 0;
  color:var(--muted);
  font-size:.76rem;
  line-height:1.55;
}
.orders-wrap{margin-top:26px}
.orders-wrap h3{margin:0 0 10px;font-size:.94rem;letter-spacing:.08em;text-transform:uppercase}
.orders-list{display:flex;flex-direction:column;gap:8px}
.order-row{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  padding:11px 14px;
  border:1px solid var(--line);
  border-radius:12px;
  background:rgba(6,20,34,.45);
  font-size:.78rem;
}
/* En la lista de compras el estado es texto, no la píldora de cuenta.html. */
.order-row .order-state{
  display:inline;
  padding:0;
  border:0;
  border-radius:0;
  background:none;
  font-size:inherit;
  letter-spacing:normal;
  font-weight:800;
  color:#9fe7ff;
  white-space:normal;
}
.order-row .order-state.is-warn{color:#f6d98a}
.order-row .order-state.is-bad{color:#ffb4a8}

/* ---------------------------------------------------------------- BLOG */
.blog-grid{
  display:grid;
  grid-template-columns:minmax(280px,360px) minmax(0,1fr);
  gap:22px;
  align-items:start;
}
.compose{padding:22px;display:flex;flex-direction:column;gap:12px}
.compose h3{margin:0;font-size:1rem;letter-spacing:.08em;text-transform:uppercase}
.compose-session{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px}
.compose textarea,.reply-form textarea{
  width:100%;
  resize:vertical;
  min-height:110px;
  padding:11px 12px;
  border:1px solid var(--line);
  border-radius:12px;
  background:rgba(3,10,20,.65);
  color:var(--text);
  font:inherit;
  font-size:.86rem;
  line-height:1.5;
}
.compose textarea:focus,.reply-form textarea:focus{outline:2px solid rgba(63,208,255,.55);outline-offset:1px}
.compose-foot{display:flex;align-items:center;justify-content:space-between;gap:10px}
.compose-foot span{font-size:.7rem;color:var(--muted);font-variant-numeric:tabular-nums}
.posts{display:flex;flex-direction:column;gap:16px}
.post{padding:20px}
.post-head{display:flex;flex-wrap:wrap;align-items:baseline;gap:10px;margin-bottom:8px}
.post-head strong{font-size:.9rem;color:#dff6ff}
.post-head time{font-size:.7rem;color:var(--muted)}
.post-text{margin:0 0 10px;white-space:pre-wrap;overflow-wrap:anywhere;color:var(--text);font-size:.9rem;line-height:1.6}
.replies{display:flex;flex-direction:column;gap:8px;margin:10px 0 0;padding-left:12px;border-left:1px solid var(--line)}
.reply{padding:8px 10px;border-radius:10px;background:rgba(255,255,255,.03)}
.reply-head{display:flex;flex-wrap:wrap;gap:8px;align-items:baseline;font-size:.7rem;color:var(--muted)}
.reply-head strong{color:#bfeaff;font-size:.76rem}
.reply p{margin:3px 0 0;font-size:.82rem;line-height:1.5;white-space:pre-wrap;overflow-wrap:anywhere}
.post-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}
.reply-form{display:flex;flex-direction:column;gap:8px;margin-top:10px}
.reply-form textarea{min-height:70px}

/* Aviso de acceso restringido (blog y tienda sin sesión) */
.blog-guest,.access-guard{
  padding:clamp(24px,4vw,42px);
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:12px;
}
.blog-guest h3,.access-guard h3{
  margin:0;
  font-size:clamp(1.1rem,2.6vw,1.45rem);
  line-height:1.25;
  letter-spacing:.02em;
}
.blog-guest p,.access-guard p{margin:0;color:var(--muted);font-size:.92rem;line-height:1.6}
.blog-guest-actions,.access-guard-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:6px}

@media (max-width:820px){
  .blog-grid{grid-template-columns:1fr}
}
@media (max-width:520px){
  .shop-grid{grid-template-columns:1fr}
  .shop-toolbar{gap:8px}
}
