/*
Theme Name: Juanjo Geometry Blocks
Theme URI: https://example.com/
Author: Juanjo
Description: Tema oscuro ultraconfigurable tipo Block Theme/FSE, con patrones geométricos, carruseles visuales y estilos alternativos de entradas.
Version: 2.0.0
Requires at least: 6.3
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: juanjo-geometry-blocks
*/

:root {
  --jj-black: #111111;
  --jj-black-soft: #1a1a1a;
  --jj-yellow: #ffcc22;
  --jj-text: #f7f7f7;
  --jj-muted: #b8b8b8;
  --jj-line: rgba(255, 255, 255, 0.12);
}

html { scroll-behavior: smooth; }
body { overflow-x: hidden; }
.wp-site-blocks { position: relative; isolation: isolate; }

.wp-site-blocks::before,
.wp-site-blocks::after {
  content: "";
  position: fixed;
  pointer-events: none;
  z-index: -1;
}

.wp-site-blocks::before {
  width: 420px;
  height: 420px;
  right: -190px;
  top: 130px;
  border: 2px solid rgba(255, 204, 34, .35);
  transform: rotate(24deg);
  box-shadow: 0 0 70px rgba(255, 204, 34, .16);
}

.wp-site-blocks::after {
  width: 280px;
  height: 280px;
  left: -120px;
  bottom: 90px;
  border: 2px solid rgba(255, 204, 34, .24);
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255,204,34,.16), transparent 62%);
}

a { transition: color .2s ease, background .2s ease, border-color .2s ease, transform .2s ease; }
a:hover { color: var(--wp--preset--color--accent); }

.jj-header {
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.jj-logo-mark {
  width: 44px;
  height: 44px;
  position: relative;
  border: 1px solid rgba(255, 204, 34, .42);
  background: rgba(255, 204, 34, .14);
  border-radius: 14px;
  box-shadow: 0 0 48px rgba(255, 204, 34, .18);
}
.jj-logo-mark::before,
.jj-logo-mark::after {
  content: "";
  position: absolute;
  inset: 50%;
  transform: translate(-50%, -50%);
}
.jj-logo-mark::before {
  width: 18px;
  height: 18px;
  border: 2px solid var(--jj-yellow);
  transform: translate(-50%, -50%) rotate(45deg);
}
.jj-logo-mark::after {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--jj-yellow);
}

.jj-hero-card,
.jj-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.1);
  box-shadow: 0 24px 80px rgba(0,0,0,.48);
}
.jj-hero-card::after,
.jj-card::after {
  content: "";
  position: absolute;
  width: 92px;
  height: 92px;
  right: -28px;
  top: -28px;
  border: 2px solid rgba(255,204,34,.42);
  transform: rotate(35deg);
}

.jj-geometry-stage {
  position: relative;
  min-height: 440px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 32px;
  background: linear-gradient(145deg, rgba(255,255,255,.08), rgba(255,255,255,.025));
  box-shadow: 0 24px 80px rgba(0,0,0,.55), 0 0 54px rgba(255,204,34,.14);
  overflow: hidden;
}
.jj-geometry-stage::before {
  content: "";
  position: absolute;
  inset: 20px;
  border: 1px solid rgba(255,204,34,.26);
  border-radius: 24px;
}
.jj-shape { position: absolute; display: block; }
.jj-shape-square { width: 160px; height: 160px; right: 54px; top: 54px; border: 3px solid var(--jj-yellow); transform: rotate(14deg); }
.jj-shape-circle { width: 178px; height: 178px; left: 48px; bottom: 58px; border-radius: 999px; border: 3px solid rgba(255,204,34,.72); background: radial-gradient(circle, rgba(255,204,34,.22), transparent 60%); }
.jj-shape-triangle { width: 0; height: 0; left: 76px; top: 70px; border-left: 70px solid transparent; border-right: 70px solid transparent; border-bottom: 124px solid rgba(255,204,34,.9); filter: drop-shadow(0 20px 36px rgba(255,204,34,.14)); }
.jj-shape-diamond { width: 92px; height: 92px; right: 124px; bottom: 110px; background: var(--jj-yellow); transform: rotate(45deg); }
.jj-shape-line { width: 72%; height: 2px; left: 14%; top: 50%; background: linear-gradient(90deg, transparent, var(--jj-yellow), transparent); transform: rotate(-24deg); }

.jj-scroll-carousel {
  display: grid !important;
  grid-auto-flow: column;
  grid-auto-columns: minmax(280px, 36%);
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: inline mandatory;
  padding-bottom: 16px;
}
.jj-scroll-carousel > * { scroll-snap-align: start; }
.jj-scroll-carousel::-webkit-scrollbar { height: 10px; }
.jj-scroll-carousel::-webkit-scrollbar-track { background: rgba(255,255,255,.08); border-radius: 999px; }
.jj-scroll-carousel::-webkit-scrollbar-thumb { background: var(--jj-yellow); border-radius: 999px; }

.wp-block-post-template.is-style-jj-card-grid,
.is-style-jj-card-grid.wp-block-query .wp-block-post-template {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.wp-block-post-template.is-style-jj-card-grid .wp-block-post,
.is-style-jj-card-grid.wp-block-query .wp-block-post {
  padding: 24px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255,255,255,.07), rgba(255,255,255,.025));
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}

.wp-block-post-template.is-style-jj-minimal-list,
.is-style-jj-minimal-list.wp-block-query .wp-block-post-template {
  display: grid;
  gap: 0;
}
.wp-block-post-template.is-style-jj-minimal-list .wp-block-post,
.is-style-jj-minimal-list.wp-block-query .wp-block-post {
  padding: 22px 0;
  border-bottom: 1px solid rgba(255,255,255,.12);
}

.wp-block-post-template.is-style-jj-featured-cards,
.is-style-jj-featured-cards.wp-block-query .wp-block-post-template {
  display: grid;
  gap: 24px;
}
.wp-block-post-template.is-style-jj-featured-cards .wp-block-post,
.is-style-jj-featured-cards.wp-block-query .wp-block-post {
  position: relative;
  padding: clamp(26px, 4vw, 44px);
  border: 1px solid rgba(255,204,34,.28);
  border-radius: 28px;
  background: radial-gradient(circle at top right, rgba(255,204,34,.13), transparent 34%), rgba(255,255,255,.04);
}

.is-style-jj-outline-card { border: 1px solid rgba(255,204,34,.38); border-radius: 24px; background: rgba(255,204,34,.06); }
.is-style-jj-glow-card { border-radius: 26px; box-shadow: 0 0 50px rgba(255,204,34,.16), 0 24px 70px rgba(0,0,0,.45); }
.is-style-jj-pill-button .wp-block-button__link { border-radius: 999px; font-weight: 900; }
.is-style-jj-outline-button .wp-block-button__link { background: transparent !important; color: var(--jj-yellow) !important; border: 1px solid rgba(255,204,34,.55); border-radius: 999px; }

@media (max-width: 900px) {
  .jj-scroll-carousel { grid-auto-columns: minmax(260px, 82%); }
  .jj-geometry-stage { min-height: 340px; }
}
