/* Modern Kid-Friendly Character Page Styles */

/* ===== GLOBAL STYLES ===== */
:root {
  --primary: #ff6b6b;
  --secondary: #4ecdc4;
  --accent: #ffd166;
  --purple: #a06cd5;
  --blue: #6a9bff;
  --green: #7ed957;
  --red: #ff7e79;
  --dark: #2a2d34;
  --light: #f7f9fc;
  --box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
  --border-radius: 20px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Vazirmatn', 'Comic Sans MS', sans-serif;
  background-color: #f0f7ff;
  background-image: url('data:image/svg+xml;utf8,<svg width="100" height="100" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"><path d="M10 10L90 10L90 90L10 90" stroke="%23a06cd5" stroke-width="1" fill="none" stroke-dasharray="5,5" opacity="0.1"/></svg>');
  color: var(--dark);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

/* ===== CHARACTER CONTAINER ===== */
.character-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* ===== CHARACTER SHOWCASE ===== */
.character-showcase {
  position: relative;
  padding: 40px 0;
  margin-bottom: 60px;
  overflow: hidden;
}

.floating-clouds {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
}

.cloud {
  position: absolute;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
}

.cloud-1 {
  width: 150px;
  height: 80px;
  top: 20%;
  left: 10%;
  animation: float 15s infinite ease-in-out;
}

.cloud-2 {
  width: 100px;
  height: 60px;
  top: 60%;
  right: 15%;
  animation: float 12s infinite ease-in-out 2s;
}

.cloud-3 {
  width: 120px;
  height: 70px;
  bottom: 20%;
  left: 20%;
  animation: float 18s infinite ease-in-out 1s;
}

.cloud-4 {
  width: 80px;
  height: 50px;
  top: 30%;
  right: 25%;
  animation: float 10s infinite ease-in-out 3s;
}

@keyframes float {
  0%, 100% { transform: translateY(0) translateX(0); }
  25% { transform: translateY(-15px) translateX(15px); }
  50% { transform: translateY(0) translateX(30px); }
  75% { transform: translateY(15px) translateX(15px); }
}

.character-card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  background: linear-gradient(135deg, #fff6e5, #ffe8e8);
  border-radius: var(--border-radius);
  padding: 40px;
  box-shadow: var(--box-shadow);
  border: 5px solid white;
}

@media (min-width: 768px) {
  .character-card {
    flex-direction: row;
    align-items: flex-start;
  }
}

.character-image-container {
  position: relative;
  flex-shrink: 0;
  width: 280px;
  height: 280px;
  margin: 0 auto;
}

.character-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 8px solid white;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  transition: transform 0.5s ease;
}

.character-image.animated {
  animation: bounce 2s infinite alternate;
}

@keyframes bounce {
  0% { transform: translateY(0); }
  100% { transform: translateY(-15px); }
}

.sparkles {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.sparkle {
  position: absolute;
  width: 20px;
  height: 20px;
  background-image: url('data:image/svg+xml;utf8,<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 0L14 9L23 12L14 15L12 24L10 15L1 12L10 9L12 0Z" fill="%23ffd166"/></svg>');
  background-size: contain;
}

.sparkle-1 {
  top: 0;
  right: 30px;
  animation: twinkle 3s infinite;
}

.sparkle-2 {
  bottom: 30px;
  left: 0;
  animation: twinkle 3s infinite 1s;
}

.sparkle-3 {
  top: 50%;
  right: 0;
  animation: twinkle 3s infinite 2s;
}

@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(0.5); }
  50% { opacity: 1; transform: scale(1); }
}

.character-info {
  flex: 1;
}

.character-name {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 20px;
  text-shadow: 2px 2px 0 rgba(255, 255, 255, 0.8);
  position: relative;
  display: inline-block;
}

.character-name::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 10px;
}

.character-description {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--dark);
  margin-bottom: 30px;
  background-color: rgba(255, 255, 255, 0.7);
  padding: 15px;
  border-radius: 15px;
  border-left: 5px solid var(--accent);
}

.character-actions {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.action-button {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border: none;
  border-radius: 50px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  color: white;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.vr-button {
  background-color: var(--purple);
}

.ar-button {
  background-color: var(--blue);
}

.action-button:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.action-button.pulse {
  animation: pulse 0.5s;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

/* ===== CHARACTER STORIES ===== */
.character-stories {
  margin-bottom: 60px;
}

.section-title {
  font-size: 2rem;
  color: var(--purple);
  text-align: center;
  margin-right: 25%;
  margin-bottom: 30px;
  position: relative;
  display: inline-block;
  left: 50%;
  transform: translateX(-50%);
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, var(--purple), var(--blue));
  border-radius: 10px;
}

.story-swiper {
  padding: 20px 0 50px;
}

.story-card {
  background-color: white;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  height: 100%;
  border: 5px solid transparent;
}

.story-card:hover {
  transform: translateY(-10px) scale(1.03);
  border-color: var(--accent);
}

.story-image-container {
  height: 200px;
  overflow: hidden;
}

.story-image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.story-card:hover .story-image-container img {
  transform: scale(1.1);
}

.story-title {
  padding: 15px;
  font-size: 1.2rem;
  color: var(--dark);
  text-align: center;
  background-color: white;
  transition: var(--transition);
}

.story-card:hover .story-title {
  color: var(--primary);
}

/* Swiper Navigation Customization */
.swiper-button-next,
.swiper-button-prev {
  color: var(--primary) !important;
  background-color: white;
  width: 40px !important;
  height: 40px !important;
  border-radius: 50%;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.swiper-button-next:after,
.swiper-button-prev:after {
  font-size: 18px !important;
}

.swiper-pagination-bullet {
  background-color: var(--primary) !important;
  width: 10px;
  height: 10px;
}

.swiper-pagination-bullet-active {
  background-color: var(--accent) !important;
}

/* ===== FUN FACTS SECTION ===== */
.fun-facts {
  margin-bottom: 60px;
}

.facts-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.fact-card {
  background-color: white;
  border-radius: var(--border-radius);
  padding: 25px;
  text-align: center;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  border-top: 5px solid var(--accent);
}

.fact-card:hover {
  transform: translateY(-10px);
}

.fact-icon {
  width: 60px;
  height: 60px;
  background-color: var(--light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 1.5rem;
  color: var(--accent);
  transition: var(--transition);
}

.fact-card:hover .fact-icon {
  background-color: var(--accent);
  color: white;
  transform: rotate(10deg);
}

.fact-card p {
  font-size: 1.1rem;
  color: var(--dark);
}

/* ===== RESPONSIVE STYLES ===== */
@media (max-width: 768px) {
  .character-name {
    font-size: 2rem;
  }

  .character-image-container {
    width: 220px;
    height: 220px;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .fact-card {
    padding: 20px;
  }
}

@media (max-width: 576px) {
  .character-card {
    padding: 25px;
  }

  .character-name {
    font-size: 1.8rem;
  }

  .character-description {
    font-size: 1rem;
  }

  .character-image-container {
    width: 180px;
    height: 180px;
  }

  .section-title {
    font-size: 1.5rem;
  }

  .story-image-container {
    height: 150px;
  }

  .story-title {
    font-size: 1rem;
  }
}