﻿/* =====================================================
   BSS HOMEPAGE v2 — Hero, chips, cards
   ===================================================== */

.hp-root { min-height: 100vh; }

/* ── HERO ──────────────────────────────────────────── */
.hp-hero { padding: 160px 64px 100px; min-height: 560px; text-align: center; }

/* Animated gradient orbs */
.hero-gradient-orb {
  position: absolute; border-radius: 50%;
  filter: blur(80px); opacity: 0.3; pointer-events: none;
}
.orb-1 {
  width: 500px; height: 500px; top: -120px; right: -100px;
  background: radial-gradient(circle, #E08B30 0%, transparent 70%);
  animation: orbPulse 8s ease-in-out infinite;
}
.orb-2 {
  width: 400px; height: 400px; bottom: -100px; left: 10%;
  background: radial-gradient(circle, #D4736A 0%, transparent 70%);
  animation: orbPulse 10s ease-in-out infinite 3s;
}
@keyframes orbPulse {
  0%, 100% { transform: scale(1) translate(0,0); opacity: 0.25; }
  50%       { transform: scale(1.2) translate(20px,-15px); opacity: 0.4; }
}

/* Wireframe geometric shapes */
.hero-shape {
  position: absolute; pointer-events: none; opacity: 0.08;
  border: 2px solid rgba(255,255,255,0.5);
}
.shape-1 { width:160px; height:160px; border-radius:50%;  top:15%; right:18%; animation: shapeOrbit 20s linear infinite; }
.shape-2 { width:80px;  height:80px;  border-radius:12px; top:60%; right:28%; animation: shapeFloat 12s ease-in-out infinite 1s; }
.shape-3 { width:120px; height:120px; border-radius:50%;  bottom:10%; left:5%; animation: shapeFloat 15s ease-in-out infinite 2s; }
.shape-4 { width:60px;  height:60px;  border-radius:8px;  top:25%; left:8%;   animation: shapeSpin 18s linear infinite; }
.shape-5 { width:100px; height:100px; border-radius:50%;  top:50%; right:8%;  animation: shapeFloat 14s ease-in-out infinite 4s; }

@keyframes shapeOrbit {
  0%   { transform: rotate(0deg) translateX(20px) rotate(0deg); }
  100% { transform: rotate(360deg) translateX(20px) rotate(-360deg); }
}
@keyframes shapeFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  33%       { transform: translateY(-25px) rotate(8deg); }
  66%       { transform: translateY(10px) rotate(-5deg); }
}
@keyframes shapeSpin {
  0%   { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Particles */
.hero-particle {
  position: absolute; pointer-events: none; opacity: 0.12;
  animation: particleDrift ease-in-out infinite;
}
@keyframes particleDrift {
  0%, 100% { transform: translate(0,0) scale(1); }
  25%       { transform: translate(12px,-18px) scale(1.15); }
  50%       { transform: translate(-8px,-28px) scale(0.9); }
  75%       { transform: translate(15px,-10px) scale(1.1); }
}

/* ── HERO CONTENT ──────────────────────────────────── */
.hp-hero-content {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1200px; margin: 0 auto; gap: 60px;
}
.hp-hero-centered {
  flex-direction: column; align-items: center; justify-content: center;
  gap: 36px; text-align: center;
}

/* ── TEXT CLOUD ────────────────────────────────────── */
.hero-text-cloud {
  position: relative; width: 740px; height: 400px; flex-shrink: 0;
  animation: cloudEntrance 1.2s ease-out 0.3s both;
}
@keyframes cloudEntrance {
  from { opacity: 0; transform: scale(0.85) translateY(24px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.cloud-title {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  text-align: center; z-index: 2;
  display: flex; flex-direction: column; align-items: center; gap: 0;
  pointer-events: none;
}
.cloud-title-the {
  font-family: 'DM Sans', sans-serif; font-size: 17px;
  text-transform: uppercase; letter-spacing: 10px;
  color: rgba(224,139,48,0.75); font-weight: 600;
}
.cloud-title-main {
  font-family: 'DM Serif Display', serif; font-size: 88px;
  color: #fff; line-height: 1.04;
  text-shadow: 0 4px 32px rgba(0,0,0,0.3), 0 0 120px rgba(255,255,255,0.1);
  animation: mainGlow 9s ease-in-out infinite;
}
@keyframes mainGlow {
  0%, 100% { text-shadow: 0 4px 32px rgba(0,0,0,0.3), 0 0 80px rgba(255,255,255,0.06); }
  50%       { text-shadow: 0 4px 32px rgba(0,0,0,0.3), 0 0 160px rgba(255,255,255,0.16); }
}
.cloud-title-main::after {
  content: '';
  display: block;
  width: 90px; height: 2px; margin: 10px auto 12px;
  background: linear-gradient(90deg, transparent, rgba(224,139,48,0.65), transparent);
  border-radius: 2px;
}
.cloud-title-book {
  font-family: 'DM Serif Display', serif; font-size: 48px;
  color: #E08B30; letter-spacing: 10px;
  text-shadow: 0 0 40px rgba(224,139,48,0.45), 0 2px 20px rgba(224,139,48,0.2);
  animation: bookGlow 4s ease-in-out infinite alternate;
}
@keyframes bookGlow {
  0%   { color: rgba(224,139,48,0.82); text-shadow: 0 0 30px rgba(224,139,48,0.3), 0 0 60px rgba(224,139,48,0.1); }
  100% { color: #F0A050;               text-shadow: 0 0 70px rgba(224,139,48,0.75), 0 0 120px rgba(224,139,48,0.3); }
}

.floating-name {
  position: absolute; white-space: nowrap;
  font-family: 'DM Sans', sans-serif; font-weight: 600;
  letter-spacing: 0.5px; pointer-events: none;
  text-shadow: 0 1px 10px rgba(0,0,0,0.2);
  animation: nameDrift ease-in-out infinite both, nameGlow 6s ease-in-out infinite alternate;
}
@keyframes nameDrift {
  0%   { transform: translate(0,0) rotate(var(--r,0deg)); }
  15%  { transform: translate(10px,-14px) rotate(calc(var(--r,0deg) + 2deg)); }
  30%  { transform: translate(-8px,-22px) rotate(calc(var(--r,0deg) - 1deg)); }
  50%  { transform: translate(14px,-10px) rotate(calc(var(--r,0deg) + 3deg)); }
  65%  { transform: translate(-6px,8px)  rotate(calc(var(--r,0deg) - 2deg)); }
  80%  { transform: translate(8px,4px)   rotate(calc(var(--r,0deg) + 1deg)); }
  100% { transform: translate(0,0) rotate(var(--r,0deg)); }
}
@keyframes nameGlow {
  0%   { filter: brightness(1); }
  100% { filter: brightness(1.3); }
}

.cloud-lines {
  position: absolute; inset: 0; width: 100%; height: 100%;
  pointer-events: none; opacity: 0.6;
  animation: linesFloat 20s ease-in-out infinite;
}
@keyframes linesFloat {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-6px); }
}

/* ── SEARCH ────────────────────────────────────────── */
.hp-search-wrap {
  position: relative; max-width: 440px;
  animation: fadeInUp 0.7s ease-out 0.36s both;
}
.hp-search-centered {
  max-width: 520px; width: 100%;
  animation: fadeInUp 0.8s ease-out 0.8s both;
}
.hp-search-icon {
  position: absolute; left: 20px; top: 50%;
  transform: translateY(-50%); z-index: 2;
}
.hp-search {
  width: 100%; padding: 17px 24px 17px 56px;
  border-radius: 16px; border: 2px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.07); font-size: 16px;
  color: #fff; outline: none; font-family: 'DM Sans', sans-serif;
  backdrop-filter: blur(8px); transition: all 0.3s;
}
.hp-search:focus {
  border-color: rgba(224,139,48,0.4);
  background: rgba(255,255,255,0.12);
  box-shadow: 0 0 0 4px rgba(224,139,48,0.1);
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-wave {
  position: absolute; bottom: -1px; left: 0;
  width: 100%; height: 80px; display: block;
}

/* ── FILTER CHIPS ──────────────────────────────────── */
.hp-chips {
  display: flex; gap: 10px; justify-content: center;
  flex-wrap: wrap; padding: 44px 48px 8px;
}
.hp-chip {
  padding: 10px 24px; border-radius: 30px; border: none;
  font-size: 13px; font-weight: 600;
  background: #fff; color: #2C2215;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  transition: all 0.3s; letter-spacing: 0.3px;
}
.hp-chip.active {
  background: #1B3A5C; color: #fff;
  box-shadow: 0 4px 16px rgba(27,58,92,0.35);
}
.hp-chip:not(.active):hover { background: #f0e8df; transform: translateY(-2px); }

/* ── REGION CARDS ──────────────────────────────────── */
.hp-cards-section { padding: 36px 48px 80px; }
.hp-cards-grid {
  display: grid; grid-template-columns: repeat(4,1fr);
  gap: 20px; max-width: 1200px; margin: 0 auto;
}

.hp-card {
  border-radius: 20px; padding: 34px 26px;
  cursor: pointer; position: relative; overflow: hidden;
  min-height: 180px; display: flex; flex-direction: column;
  justify-content: flex-end; text-decoration: none;
  animation: cardEntry 0.5s ease-out both;
  transition: all 0.4s cubic-bezier(0.175,0.885,0.32,1.275);
}
@keyframes cardEntry {
  from { opacity: 0; transform: scale(0.88) translateY(20px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
.hp-card:hover {
  transform: scale(1.05) translateY(-4px);
  box-shadow: 0 24px 48px rgba(0,0,0,0.2);
}
.hp-card.hidden { display: none; }

.hp-card-deco-circle {
  position: absolute; top: -22px; right: -22px;
  width: 80px; height: 80px; border-radius: 50%;
  background: rgba(255,255,255,0.08); transition: transform 0.5s;
}
.hp-card:hover .hp-card-deco-circle { transform: scale(1.4); }
.hp-card-deco-square {
  position: absolute; top: 18px; right: 18px;
  width: 36px; height: 36px; border-radius: 8px;
  background: rgba(255,255,255,0.06);
  transform: rotate(45deg); transition: transform 0.5s;
}
.hp-card:hover .hp-card-deco-square { transform: rotate(135deg) scale(1.2); }

.hp-card-group {
  font-size: 11px; text-transform: uppercase; letter-spacing: 1.5px;
  color: rgba(255,255,255,0.5); font-weight: 700; margin-bottom: 10px;
}
.hp-card-name {
  font-family: 'DM Serif Display', serif; font-size: 19px;
  color: #fff; line-height: 1.3;
}
.hp-card-arrow {
  position: absolute; top: 18px; left: 20px;
  opacity: 0; transform: translateX(-8px);
  transition: all 0.35s ease;
}
.hp-card:hover .hp-card-arrow { opacity: 1; transform: translateX(0); }

.hp-no-results {
  text-align: center; color: #7A6B5A; padding: 48px; font-size: 15px;
}

/* AJAX loading transition */
#bss-cards-grid { transition: opacity 0.15s ease; }

/* ── RESPONSIVE ────────────────────────────────────── */
@media (max-width: 1024px) {
  .hp-cards-grid { grid-template-columns: repeat(3,1fr); }
  .hero-text-cloud { width: 100%; height: 320px; }
  .cloud-title-main { font-size: 72px; }
  .cloud-title-book { font-size: 38px; letter-spacing: 7px; }
}
@media (max-width: 768px) {
  .hp-hero { padding: 130px 32px 80px; }
  .hero-text-cloud { width: 100%; height: 260px; }
  .cloud-title-main { font-size: 42px; }
  .cloud-title-main::after { width: 60px; margin: 6px auto 8px; }
  .cloud-title-book { font-size: 24px; letter-spacing: 6px; }
  .floating-name    { font-size: 9px !important; }
  .hp-cards-grid    { grid-template-columns: repeat(2,1fr); gap: 14px; }
  .hp-cards-section { padding: 28px 24px 60px; }
  .hp-chips         { padding: 32px 24px 4px; }
  .hp-card          { min-height: 150px; padding: 26px 20px; }
}
@media (max-width: 480px) {
  .hp-cards-grid { grid-template-columns: 1fr; }
}
