/* ====================== RESET & BASE ====================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ====================== CSS VARIABLES ====================== */
:root {
  --primary: #ff9edb;
  --primary-hover: #ffb5e8;
  --gradient-primary: linear-gradient(180deg, #f4e5ff 0%, #ffe4f5 100%);
  --accent: #e0bbff;
  --highlight: #ff9edb;
  --sakura: #ff9edb;
  --text-light: #ffffff;
  --text-dark: #6b4e9e;
  --bg-body: linear-gradient(135deg, #f8f1eb 0%, #f0e6ff 50%, #fdf4f8 100%);
  --bg-navbar: rgba(0, 0, 0, 0.2);
  --bg-overlay: rgba(0, 0, 0, 0.38);
  --bg-badge: rgba(0, 0, 0, 0.42);
  --border-light: rgba(224, 187, 255, 0.35);
  --border-btn: #ffffff;
  --preloader-bg: linear-gradient(
    135deg,
    #1a0f2e 0%,
    #2d1b4a 50%,
    #1f1438 100%
  );
}

/* ====================== DARK MODE ====================== */
[data-theme="dark"] {
  --bg-body: linear-gradient(135deg, #1a0f2e 0%, #2d1b4a 50%, #1f1438 100%);
  --text-light: #f0e6ff;
  --text-dark: #d4b8ff;
  --bg-navbar: rgba(20, 10, 40, 0.85);
  --bg-overlay: rgba(10, 5, 25, 0.65);
  --bg-badge: rgba(255, 158, 219, 0.15);
  --border-light: rgba(224, 187, 255, 0.25);
  --accent: #e0bbff;
  --highlight: #ff9edb;

  /* Override cho các section sáng */
  .about-section,
  .gallery-section,
  .fan-gallery {
    background: linear-gradient(135deg, #2a1b45 0%, #1f1438 100%);
  }

  .gallery-subtitle,
  .fan-subtitle {
    color: #d4b8ff;
  }

  /* Gaming section giữ tối sẵn nên ít thay đổi */
  .footer {
    background: linear-gradient(135deg, #0f0820 0%, #1a0f2e 100%);
  }

  /* Lightbox tối hơn */
  .lightbox {
    background: rgba(10, 5, 25, 0.98);
  }

  /* Settings modal tối */
  .settings-content {
    background: #1f1438;
    color: #f0e6ff;
  }

  .settings-header {
    background: linear-gradient(90deg, #ff9edb, #c084fc);
  }

  .setting-item label {
    color: #d4b8ff;
  }
}

/* Smooth transition khi chuyển mode */
* {
  transition:
    background-color 0.4s ease,
    color 0.4s ease,
    border-color 0.4s ease;
}

/* ====================== BASE ====================== */
body {
  font-family:
    "Inter",
    system-ui,
    -apple-system,
    sans-serif;
  background: var(--bg-body);
  color: var(--text-light);
  overflow-x: hidden;
  line-height: 1.6;
}

html {
  scroll-behavior: smooth !important;
}

/* ====================== NAVBAR + STATUS BAR ====================== */

/* Container chính của Navbar + Status */
.navbar-with-status {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--bg-navbar);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-light);
}

/* ====================== STATUS BAR ====================== */
.status-bar {
  font-size: 0.85rem;
  padding: 8px 0;
}

[data-theme="dark"] .status-bar {
  background: rgba(42, 26, 46, 0.95);
}

.status-content {
  width: 100%;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-light);
}

.status-left {
  display: flex;
  align-items: center;
  gap: 18px;
  font-weight: 500;
}

.status-left i {
  color: #ff9edb;
  font-size: 1.05rem;
}

.status-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.visit-count {
  display: flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  padding: 4px 10px;
  border-radius: 9999px;
  transition: all 0.3s ease;
}

.visit-count:hover {
  background: rgba(255, 158, 219, 0.15);
  color: #ff9edb;
}

.visit-text {
  font-size: 0.78rem;
  opacity: 0.8;
}

.online-status {
  display: flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 158, 219, 0.18);
  padding: 5px 14px;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #e05a9e;
}

[data-theme="dark"] .online-status {
  background: rgba(192, 132, 252, 0.25);
  color: #c084fc;
}

/* ====================== MAIN NAVIGATION ====================== */
.main-nav .nav-container {
  width: 100%;
  margin: 0 auto;
  padding: 14px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo img {
  height: 34px;
  width: auto;
}

.nav-menu {
  display: flex;
  gap: 48px;
}

.nav-link {
  color: var(--text-light);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  transition: color 0.3s ease;
}

.nav-link:hover {
  color: var(--primary);
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.contact-btn {
  padding: 10px 28px;
  background: transparent;
  color: var(--text-light);
  border: 2px solid var(--border-btn);
  border-radius: 50px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.contact-btn:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.mobile-btn {
  display: none;
  font-size: 28px;
  background: none;
  border: none;
  color: var(--text-light);
  cursor: pointer;
}

@media (max-width: 1024px) {
  .status-content,
  .main-nav .nav-container {
    padding-left: 24px;
    padding-right: 24px;
  }
}

@media (max-width: 768px) {
  .status-content {
    font-size: 0.78rem;
  }

  .nav-menu {
    display: none;
  }
}

/* ====================== MOBILE MENU ====================== */
.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 20px;
  padding: 20px 30px;
  background: var(--bg-navbar);
  border-top: 1px solid rgba(255, 158, 219, 0.3);
}

[data-theme="dark"] .mobile-menu {
  background: rgba(42, 26, 46, 0.98);
}

.mobile-menu .nav-link {
  font-size: 1.25rem;
  padding: 10px 0;
  color: var(--text-light);
}

.mobile-menu.active {
  display: flex;
}

/* Hiển thị nút mobile và ẩn desktop menu trên mobile */
@media (max-width: 768px) {
  .nav-menu {
    display: none;
  }
  .mobile-btn {
    display: block;
  }
}

/* ====================== SMOOTH SCROLL ====================== */
html {
  scroll-behavior: auto;
  scroll-padding-top: 0;
}

#home,
#about,
#gaming,
#fan-gallery,
#gallery,
#contact {
  scroll-margin-top: 0;
}

/* ====================== HERO SECTION ====================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-background {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.hero-background iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100vw;
  height: 100vh;
  transform: translate(-50%, -50%);
  pointer-events: none;
  border: none;
  filter: contrast(1.05) saturate(1.1);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--bg-overlay);
  z-index: 2;
}

.hero-container {
  position: relative;
  z-index: 3;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  padding-top: 100px;
}

.hero-content {
  padding-top: 40px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-badge);
  padding: 12px 28px;
  border-radius: 50px;
  border: 1px solid var(--accent);
  margin-bottom: 30px;
  box-shadow: 0 4px 15px rgba(255, 181, 232, 0.2);
}

.hero-title {
  font-size: 5.5rem;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -4px;
  margin-bottom: 24px;
  color: var(--text-light);
}

.highlight {
  color: var(--highlight);
}

.hero-subtitle {
  font-size: 1.35rem;
  max-width: 460px;
  margin-bottom: 40px;
  opacity: 0.92;
  line-height: 1.5;
}

.hero-buttons {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.btn-primary,
.btn-secondary {
  padding: 18px 42px;
  border-radius: 50px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.4s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 10px 25px rgba(255, 158, 219, 0.4);
}

.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(255, 158, 219, 0.5);
}

.btn-secondary {
  border: 2px solid var(--accent);
  color: var(--text-light);
}

.btn-secondary:hover {
  background: var(--accent);
  color: var(--text-dark);
}

/* Floating Sakura */
.floating-sakura {
  position: absolute;
  font-size: 48px;
  animation: floatSakura 6s ease-in-out infinite;
  pointer-events: none;
  z-index: 4;
  color: var(--sakura);
  opacity: 0.95;
}

.sakura-1 {
  top: 15%;
  right: 8%;
  animation-delay: 0s;
}
.sakura-2 {
  top: 30%;
  left: 4%;
  animation-delay: 2s;
  font-size: 38px;
}
.sakura-3 {
  bottom: 18%;
  right: 15%;
  animation-delay: 4s;
  font-size: 42px;
}

@keyframes floatSakura {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-45px) rotate(25deg);
  }
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 50px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-light);
  font-size: 0.9rem;
  letter-spacing: 3px;
  font-weight: 500;
}

.scroll-indicator i {
  animation: bounce 1.8s infinite;
}

/* Hero Image */
.hero-image-wrapper {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: center;
}

.hero-image {
  width: 100%;
  max-width: 520px;
  border-radius: 30px;
  box-shadow: 30px 30px 60px rgba(0, 0, 0, 0.45);
  transform: rotate(2deg);
  transition: transform 0.7s ease;
}

.hero-image:hover {
  transform: rotate(0deg);
}

/* ====================== RESPONSIVE HERO ====================== */
@media (max-width: 1024px) {
  .hero-container {
    gap: 60px;
  }
  .hero-title {
    font-size: 4.8rem;
  }
  .hero-image {
    max-width: 460px;
  }
}

@media (max-width: 968px) {
  .hero-container {
    grid-template-columns: 1fr; /* Chỉ 1 cột */
    gap: 50px;
    text-align: center;
    padding-top: 120px;
  }

  /* === QUAN TRỌNG: Giữ nguyên thứ tự HTML === */
  .hero-content {
    order: 0; /* Content vẫn ở trên */
    padding-top: 20px;
  }

  .hero-image-wrapper {
    order: 0; /* Image vẫn ở dưới */
    justify-content: center;
  }

  .hero-title {
    font-size: 4.2rem;
    letter-spacing: -3px;
  }

  .hero-subtitle {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-buttons {
    justify-content: center;
  }

  /* Giảm kích thước ảnh trên mobile */
  .hero-image {
    max-width: 7.5rem;
    transform: rotate(0deg); /* bỏ rotate trên mobile để đẹp hơn */
  }

  .hero-image:hover {
    transform: rotate(0deg);
  }

  /* Sakura nhỏ hơn trên mobile */
  .floating-sakura {
    font-size: 36px;
  }
  .sakura-2 {
    font-size: 30px;
  }
  .sakura-3 {
    font-size: 34px;
  }
}

@media (max-width: 640px) {
  .hero {
    min-height: 100vh;
  }

  .hero-container {
    padding: 0 24px;
    padding-top: 130px;
  }

  .hero-title {
    font-size: 3.4rem;
    letter-spacing: -2px;
  }

  .hero-subtitle {
    font-size: 1.2rem;
  }

  .btn-primary,
  .btn-secondary {
    padding: 16px 32px;
    font-size: 1rem;
  }

  .hero-image {
    max-width: 9.5rem;
    border-radius: 24px;
    box-shadow: 20px 20px 40px rgba(0, 0, 0, 0.35);
  }

  .scroll-indicator {
    bottom: 30px;
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .hero-image {
    max-width: 0rem;
  }
}

/* Xử lý chiều cao màn hình nhỏ (điện thoại dọc) */
@media (max-height: 680px) {
  .hero-title {
    font-size: 3.8rem;
  }

  .hero-container {
    padding-top: 80px;
  }

  .scroll-indicator {
    display: none; /* Ẩn scroll indicator khi màn hình quá ngắn */
  }
}

/* Video background responsive */
@media (max-aspect-ratio: 16/9) {
  .hero-background iframe {
    width: 177.78vh;
    height: 100vh;
  }
}

@media (min-aspect-ratio: 16/9) {
  .hero-background iframe {
    width: 100vw;
    height: 56.25vw;
  }
}

/* ====================== ABOUT SECTION ====================== */
.about-section {
  padding: 100px 0 120px;
  background: linear-gradient(135deg, #fff0f8 0%, #f8e1f0 100%);
  transition: background 0.5s ease;
}

[data-theme="dark"] .about-section {
  background: linear-gradient(135deg, #2a1b45 0%, #1f1438 100%);
}

.about-container {
  padding: 0 5%;
  max-width: 1400px;
  margin: 0 auto;
}

/* ====================== ABOUT ME CARD ====================== */
.about-me-card {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 70px;
  background: white;
  border-radius: 32px;
  padding: 65px 55px;
  box-shadow: 0 25px 70px rgba(255, 158, 219, 0.28);
  max-width: 1280px;
  margin: 0 auto 80px;
  transition: all 0.4s ease;
}

[data-theme="dark"] .about-me-card {
  background: #2d1b4a;
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.65);
}

.about-left {
  text-align: center;
}

.profile-circle {
  width: 310px;
  height: 310px;
  border-radius: 50%;
  overflow: hidden;
  border: 16px solid #ff9edb;
  margin: 0 auto 25px;
  box-shadow: 0 20px 45px rgba(255, 158, 219, 0.35);
  position: relative;
}

[data-theme="dark"] .profile-circle {
  border-color: #ff6ec4;
  box-shadow: 0 20px 45px rgba(255, 105, 180, 0.4);
}

.profile-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.name {
  font-size: 2.45rem;
  font-weight: 700;
  color: #6b4e9e;
  margin-bottom: 8px;
}

[data-theme="dark"] .name {
  color: #f0d6ff;
}

.title {
  color: #c084fc;
  font-size: 1.2rem;
  font-weight: 600;
}

[data-theme="dark"] .title {
  color: #c8a2ff;
}

/* About Right Content */
.about-right .section-title {
  font-size: 3.3rem;
  color: #ff69b4;
  margin-bottom: 22px;
}

[data-theme="dark"] .about-right .section-title {
  color: #ff9edb;
}

.greeting,
.bio,
.invite,
.thanks {
  line-height: 1.78;
  font-size: 1.17rem;
}

.greeting {
  color: #ff69b4;
  font-weight: 600;
  margin-bottom: 18px;
}

[data-theme="dark"] .greeting {
  color: #ffb3e6;
}

.bio {
  color: #555;
  margin: 22px 0 32px;
}

[data-theme="dark"] .bio {
  color: #d4b8ff;
}

.invite {
  color: #6b4e9e;
  font-style: italic;
  margin-bottom: 20px;
}

[data-theme="dark"] .invite {
  color: #c8a2ff;
}

.thanks {
  color: #ff69b4;
  font-weight: 600;
}

[data-theme="dark"] .thanks {
  color: #ff9edb;
}

/* ====================== HOBBY SECTION ====================== */
.hobby-main-title {
  text-align: center;
  font-size: 3.3rem;
  color: #ff69b4;
  margin-bottom: 12px;
}

[data-theme="dark"] .hobby-main-title {
  color: #ff9edb;
}

.hobby-subtitle {
  text-align: center;
  font-size: 1.22rem;
  color: #777;
  margin-bottom: 55px;
}

[data-theme="dark"] .hobby-subtitle {
  color: #b8a2d9;
}

.hobby-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
  gap: 26px;
}

.hobby-card {
  background: white;
  border-radius: 26px;
  padding: 34px 26px;
  text-align: center;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.07);
  transition: all 0.4s ease;
  border: 3px solid #fdf0f7;
}

[data-theme="dark"] .hobby-card {
  background: #3a2559;
  border-color: #6b4e9e;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5);
}

.hobby-card:hover {
  transform: translateY(-12px);
  box-shadow: 0 22px 50px rgba(255, 158, 219, 0.3);
  border-color: #ff9edb;
}

[data-theme="dark"] .hobby-card:hover {
  box-shadow: 0 22px 50px rgba(255, 105, 180, 0.35);
  border-color: #ff6ec4;
}

.hobby-icon {
  font-size: 3.4rem;
  margin-bottom: 18px;
}

.hobby-card h4 {
  font-size: 1.48rem;
  color: #6b4e9e;
  margin-bottom: 14px;
}

[data-theme="dark"] .hobby-card h4 {
  color: #f0d6ff;
}

.hobby-card p {
  color: #666;
  font-size: 1.03rem;
  line-height: 1.65;
}

[data-theme="dark"] .hobby-card p {
  color: #d4b8ff;
}

/* Responsive */
@media (max-width: 1100px) {
  .about-me-card {
    grid-template-columns: 1fr;
    padding: 50px 40px;
    gap: 50px;
  }
  .profile-circle {
    width: 260px;
    height: 260px;
  }
}

@media (max-width: 768px) {
  .about-container {
    padding: 0 5%;
  }
  .about-me-card {
    padding: 45px 30px;
  }
  .hobby-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
}

/* ====================== GAMING SECTION ====================== */
.gaming-section {
  padding: 140px 40px 160px;
  background: linear-gradient(135deg, #1a0033 0%, #2d004d 100%);
  position: relative;
  overflow: hidden;
}

.gaming-container {
  max-width: 1280px;
  margin: 0 auto;
}

.gaming-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(620px, 1fr));
  gap: 40px;
}

/* ====================== GAMING CARD ====================== */
.gaming-card {
  background: var(--card-color);
  backdrop-filter: blur(22px);
  border: 2px solid var(--accent-color);
  border-radius: 32px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 300px 1fr;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
  transition: all 0.5s ease;
  margin-bottom: 40px;
}

.gaming-card:hover {
  transform: translateY(-12px);
  box-shadow: 0 35px 80px var(--card-color);
}

/* Card Left */
.card-left {
  position: relative;
  height: 100%;
  min-height: 380px;
  background: #0f0a1f;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.character-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}

.gaming-card:hover .character-image {
  transform: scale(1.08);
}

.card-left::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(255, 252, 70, 0.2) 0%,
    rgba(0, 0, 0, 0) 50%,
    rgba(75, 174, 255, 0.2) 100%
  );
  z-index: 2;
  pointer-events: none;
}

.gaming-card:hover .card-left::after {
  opacity: 0.85;
}

/* Card Right */
.card-right {
  padding: 34px 38px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.summoner-info h3 {
  font-size: 1.65rem;
  font-weight: 700;
}

.summoner-info .tag {
  color: var(--accent-color);
  font-weight: 600;
  opacity: 0.9;
}

.rank,
.lp {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.25rem;
  font-weight: 600;
}

.favorite-champs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.champ {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  padding: 8px 18px;
  border-radius: 50px;
  font-size: 0.97rem;
  border: 1px solid color-mix(in srgb, var(--accent-color) 30%, transparent);
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 26px;
}

.stat-item .label {
  font-size: 0.87rem;
  color: rgba(255, 255, 255, 0.65);
  margin-right: 3%;
}

.stat-item .value {
  font-size: 1.15rem;
  color: #fff;
  font-weight: 600;
}

.playstyle {
  color: var(--accent-color);
  font-style: italic;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid color-mix(in srgb, var(--accent-color) 25%, transparent);
}

.game-title {
  color: var(--accent-color);
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 4px;
}

.game-name {
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--accent-color);
  margin-bottom: 12px;
  letter-spacing: -0.8px;
  line-height: 1.1;
}

/* ====================== RESPONSIVE GAMING SECTION ====================== */
@media (max-width: 1200px) {
  .gaming-grid {
    grid-template-columns: repeat(auto-fit, minmax(580px, 1fr));
    gap: 32px;
  }
}

@media (max-width: 968px) {
  .gaming-section {
    padding: 100px 24px 120px;
  }

  .gaming-grid {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .gaming-card {
    grid-template-columns: 1fr; /* Stack vertically */
    margin-bottom: 0;
  }

  .card-left {
    min-height: 320px;
    height: 320px; /* Fixed height cho mobile */
  }

  .card-right {
    padding: 32px 28px;
  }

  .game-name {
    font-size: 1.85rem;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 640px) {
  .gaming-section {
    padding: 80px 20px 100px;
  }

  .gaming-card {
    border-radius: 24px;
  }

  .card-left {
    min-height: 280px;
    height: 280px;
  }

  .card-right {
    padding: 28px 24px;
  }

  .summoner-info h3 {
    font-size: 1.45rem;
  }

  .game-name {
    font-size: 1.65rem;
  }

  .champ {
    padding: 6px 14px;
    font-size: 0.9rem;
  }
}

/* ====================== GALLERY SECTION ====================== */
.gallery-section {
  padding: 0 40px 160px;
  background: var(--gradient-primary);
  position: relative;
  overflow: hidden;
}

.gallery-container {
  max-width: 1280px;
  margin: 0 auto;
}

.gallery-header {
  text-align: center;
  margin-bottom: 80px;
}

.gallery-title {
  font-size: 3.8rem;
  font-weight: 700;
  letter-spacing: -2.5px;
  color: var(--highlight);
  margin-bottom: 16px;
}

.gallery-subtitle {
  font-size: 1.25rem;
  color: var(--text-dark);
  max-width: 520px;
  margin: 0 auto;
  opacity: 0.9;
}

/* Masonry Grid */
.gallery-grid {
  column-count: 4;
  column-gap: 24px;
  width: 100%;
}

.gallery-item {
  break-inside: avoid;
  margin-bottom: 24px;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.18);
  transition: all 0.5s ease;
  position: relative;
  display: block;
}

.gallery-item:hover {
  transform: scale(1.03);
  box-shadow: 0 25px 60px rgba(255, 158, 219, 0.35);
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.7s ease;
}

.gallery-item:hover img {
  transform: scale(1.08);
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 60%, rgba(0, 0, 0, 0.75));
  opacity: 0;
  transition: opacity 0.4s ease;
  display: flex;
  align-items: flex-end;
  padding: 28px;
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-info h3 {
  color: white;
  font-size: 1.4rem;
  margin-bottom: 4px;
}

.gallery-info p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.95rem;
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.95);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 92%;
  max-height: 92vh;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.7);
}

.lightbox-content img {
  width: 100%;
  height: auto;
  max-height: 88vh;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: -18px;
  right: -18px;
  background: #fff;
  color: var(--text-dark);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  font-size: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.lightbox-close:hover {
  background: var(--primary);
  color: white;
}

/* Responsive Masonry */
@media (max-width: 1200px) {
  .gallery-grid {
    column-count: 3;
  }
}

@media (max-width: 768px) {
  .gallery-grid {
    column-count: 2;
  }
  .gallery-section {
    padding: 100px 24px 120px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    column-count: 1;
  }
}

/* ====================== FOOTER ====================== */
.footer {
  background: linear-gradient(135deg, #1a0033 0%, #2d004d 100%);
  color: #fff;
  padding: 90px 40px 50px;
  position: relative;
  overflow: hidden;
}

.footer-container {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr;
  gap: 50px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.footer-logo {
  font-size: 38px;
  font-weight: 700;
  letter-spacing: -1.5px;
  background: linear-gradient(90deg, #ff9edb, #e0bbff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-description {
  font-size: 1.05rem;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.72);
  max-width: 300px;
}

/* Footer Columns */
.footer-column h3 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 24px;
  letter-spacing: 0.5px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.footer-link {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 1.02rem;
}

.footer-link:hover {
  color: var(--primary);
  padding-left: 4px;
}

/* Social Icons */
.footer-social {
  display: flex;
  gap: 14px;
  margin-top: 12px;
}

.social-icon {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 158, 219, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.35rem;
  text-decoration: none;
  transition: all 0.4s ease;
}

.social-icon:hover {
  background: var(--primary);
  border-color: var(--primary);
  transform: translateY(-3px);
}

/* Newsletter */
.newsletter-box {
  margin-top: 10px;
}

.newsletter-box input {
  width: 100%;
  padding: 14px 22px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 158, 219, 0.25);
  border-radius: 50px;
  color: white;
  font-size: 1rem;
  margin-bottom: 12px;
}

.newsletter-box input::placeholder {
  color: rgba(255, 255, 255, 0.45);
}

.newsletter-box button {
  width: 100%;
  padding: 14px;
  background: linear-gradient(90deg, var(--primary), #ff6ec4);
  color: white;
  border: none;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.newsletter-box button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(255, 158, 219, 0.4);
}

/* Footer Bottom */
.footer-bottom {
  margin-top: 80px;
  padding-top: 25px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.55);
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
}

.footer-bottom a:hover {
  color: var(--primary);
}

/* Responsive */
@media (max-width: 1024px) {
  .footer-container {
    grid-template-columns: 1.8fr 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .footer {
    padding: 70px 24px 40px;
  }
  .footer-container {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 576px) {
  .footer-container {
    grid-template-columns: 1fr;
    gap: 45px;
  }
}

/* ====================== MULTI FAN GALLERY - GRID 3 CỘT ====================== */
.fan-gallery {
  padding: 140px 40px 160px;
  background: var(--gradient-primary);
}

.fan-container {
  max-width: 1280px;
  margin: 0 auto;
}

.fan-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 110px 60px;
}

/* Mỗi bộ bài */
.fan-section {
  text-align: center;
}

.fan-header {
  margin-bottom: 75px;
}

.fan-title {
  font-size: 2.85rem;
  font-weight: 700;
  letter-spacing: -2px;
  color: var(--highlight);
  margin-bottom: 12px;
}

.fan-subtitle {
  font-size: 1.18rem;
  color: var(--text-dark);
  opacity: 0.88;
}

/* Deck */
.fan-deck {
  position: relative;
  height: 520px;
  max-width: 460px;
  margin: 0 auto;
  perspective: 1800px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Card - To hơn */
.fan-card {
  position: absolute;
  width: 290px;
  height: 400px;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
  transition: all 0.85s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
  background: #fff;
}

.fan-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s ease;
}

.fan-card:hover img {
  transform: scale(1.07);
}

/* Trạng thái gom lại - Hở góc tinh tế */
.fan-card:nth-child(1) {
  transform: rotate(-8deg) translateX(-18px) scale(0.92);
  z-index: 1;
}
.fan-card:nth-child(2) {
  transform: rotate(-4deg) translateX(-8px) scale(0.95);
  z-index: 2;
}
.fan-card:nth-child(3) {
  transform: rotate(4deg) translateX(8px) scale(0.95);
  z-index: 3;
}
.fan-card:nth-child(4) {
  transform: rotate(8deg) translateX(18px) scale(0.92);
  z-index: 4;
}

/* Khi hover → Xòe đẹp, rộng hơn */
.fan-deck:hover .fan-card:nth-child(1) {
  transform: rotate(-27deg) translateX(-145px) scale(1);
}
.fan-deck:hover .fan-card:nth-child(2) {
  transform: rotate(-13deg) translateX(-60px) scale(1);
}
.fan-deck:hover .fan-card:nth-child(3) {
  transform: rotate(8deg) translateX(45px) scale(1);
}
.fan-deck:hover .fan-card:nth-child(4) {
  transform: rotate(25deg) translateX(135px) scale(1);
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.94);
  z-index: 3000;
  align-items: center;
  justify-content: center;
  padding: 30px;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 92%;
  max-height: 92vh;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 40px 110px rgba(0, 0, 0, 0.75);
}

.lightbox-content img {
  width: 100%;
  height: auto;
  max-height: 88vh;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: -22px;
  right: -22px;
  width: 56px;
  height: 56px;
  background: #fff;
  color: var(--text-dark);
  border-radius: 50%;
  font-size: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
}

.lightbox-close:hover {
  background: var(--primary);
  color: white;
}

/* Responsive */
@media (max-width: 1100px) {
  .fan-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 90px 50px;
  }
}

@media (max-width: 768px) {
  .fan-grid {
    grid-template-columns: 1fr;
    gap: 80px;
  }
  .fan-deck {
    height: 460px;
  }
  .fan-card {
    width: 260px;
    height: 360px;
  }
}

/* ====================== BACK TO TOP ====================== */
.back-to-top {
  position: fixed;
  bottom: 40px;
  right: 40px;
  z-index: 9999;
  width: 58px;
  height: 58px;
  background: var(--primary);
  color: var(--text-light);
  border: 3px solid var(--border-btn);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.65rem;
  box-shadow: 0 0px 30px rgba(255, 158, 219, 0.45);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.back-to-top:hover {
  background: var(--primary-hover);
  transform: translateY(-5px) scale(1.12);
  box-shadow: 0 0px 35px rgba(255, 158, 219, 0.6);
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

/* Responsive */
@media (max-width: 640px) {
  .back-to-top {
    bottom: 25px;
    right: 25px;
    width: 52px;
    height: 52px;
    font-size: 1.45rem;
  }
}

/* ====================== SETTINGS MODAL ====================== */
.settings-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(12px);
}

.settings-modal.active {
  display: flex;
}

.settings-content {
  background: rgba(255, 255, 255, 0.95);
  color: #333;
  width: 100%;
  max-width: 420px;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
}

.settings-header {
  padding: 20px 28px;
  background: linear-gradient(90deg, #ff9edb, #e0bbff);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.settings-header h2 {
  margin: 0;
  font-size: 1.45rem;
}

.close-btn {
  background: none;
  border: none;
  font-size: 28px;
  color: white;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: 0.3s;
}

.close-btn:hover {
  background: rgba(255, 255, 255, 0.3);
}

.settings-body {
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.setting-item {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.setting-item label {
  font-weight: 600;
  color: #555;
  font-size: 1.05rem;
}

.toggle-switch {
  position: relative;
  width: 62px;
  height: 32px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #ccc;
  border-radius: 50px;
  transition: 0.4s;
}

.slider:before {
  content: "";
  position: absolute;
  height: 24px;
  width: 24px;
  left: 4px;
  bottom: 4px;
  background: white;
  border-radius: 50%;
  transition: 0.4s;
}

input:checked + .slider {
  background: #ff9edb;
}

input:checked + .slider:before {
  transform: translateX(30px);
}

#volume-slider {
  width: 100%;
  accent-color: #ff9edb;
}

#volume-value {
  font-weight: 600;
  color: #ff9edb;
  font-size: 1.1rem;
}

#video-volume-slider {
  width: 100%;
  accent-color: #c084fc;
}

.settings-btn {
  padding: 16px 24px;
  border: none;
  border-radius: 50px;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.settings-btn.full {
  width: 100%;
}

.settings-btn.secondary {
  background: #f0e6ff;
  color: #6b4e9e;
}

.settings-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(255, 158, 219, 0.4);
}

/* ====================== MINI MUSIC PLAYER ====================== */
.mini-music-player {
  position: fixed;
  bottom: 80px;
  left: 30px;
  background: rgba(255, 158, 219, 0.15);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 158, 219, 0.3);
  border-radius: 50px;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 100;
  box-shadow: 0 8px 25px rgba(255, 158, 219, 0.2);
}

.music-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.1rem;
  transition: all 0.3s;
}

.music-btn:hover {
  background: var(--primary-hover);
  transform: scale(1.1);
}

.music-info {
  color: var(--text-light);
  font-size: 0.95rem;
  white-space: nowrap;
}

.change-music-btn {
  background: none;
  border: none;
  color: var(--text-light);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 6px;
  opacity: 0.7;
}

.change-music-btn:hover {
  opacity: 1;
  color: var(--primary);
}

/* Responsive */
@media (max-width: 768px) {
  .mini-music-player {
    left: 15px;
    bottom: 70px;
    padding: 8px 14px;
  }
}

/* ====================== MUSIC LINK MODAL ====================== */
.music-link-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
}

.music-link-modal.active {
  display: flex;
}

.music-link-content {
  background: rgba(255, 255, 255, 0.95);
  color: #333;
  width: 100%;
  max-width: 420px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.music-link-header {
  padding: 20px 24px;
  background: linear-gradient(90deg, #ff9edb, #e0bbff);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.music-link-header h3 {
  margin: 0;
  font-size: 1.35rem;
}

.music-link-body {
  padding: 24px;
}

.music-link-body p {
  margin-bottom: 12px;
  font-weight: 500;
}

.music-url-input {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #ff9edb;
  border-radius: 12px;
  font-size: 1rem;
  outline: none;
  transition: all 0.3s;
}

.music-url-input:focus {
  border-color: #ff6ec4;
  box-shadow: 0 0 0 3px rgba(255, 158, 219, 0.2);
}

.music-link-body small {
  display: block;
  margin-top: 8px;
  color: #888;
  font-size: 0.85rem;
}

.music-link-footer {
  padding: 16px 24px;
  display: flex;
  gap: 12px;
  background: #f8f8f8;
}

.music-btn {
  flex: 1;
  padding: 14px;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}

.music-btn.primary {
  background: linear-gradient(90deg, #ff9edb, #ff6ec4);
  color: white;
}

.music-btn.secondary {
  background: #e0e0e0;
  color: #555;
}

.music-btn:hover {
  transform: translateY(-2px);
}
/* ====================== PRELOADER ====================== */
.preloader {
  position: fixed;
  inset: 0;
  background: var(--preloader-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  transition: opacity 1.2s ease;
}

.preloader-content {
  text-align: center;
  color: var(--text-light);
  max-width: 460px;
  padding: 40px 30px;
}

.sakura-loader {
  font-size: 6.2rem;
  animation: sakuraSpin 3.2s linear infinite;
  margin-bottom: 28px;
  display: inline-block;
}

@keyframes sakuraSpin {
  0% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(180deg) scale(1.22);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

.preloader h2 {
  font-size: 2.35rem;
  font-weight: 700;
  letter-spacing: -1.2px;
  margin-bottom: 10%;
}

/* Nút bắt đầu */
.preloader-start-btn {
  padding: 18px 64px;
  font-size: 1.28rem;
  font-weight: 700;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  box-shadow: 0 0px 40px rgba(255, 158, 219, 0.45);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.preloader-start-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-6px) scale(1.06);
}

/* Progress Container */
.progress-container {
  width: 100%;
  max-width: 360px;
  margin-top: 30px;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.progress-container:not(.hidden) {
  opacity: 1;
}

.progress-bar {
  height: 10px;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 50px;
  overflow: hidden;
  margin-bottom: 14px;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), #ffb5e8, var(--accent));
  border-radius: 50px;
  transition: width 0.1s linear;
  box-shadow: 0 0 12px rgba(255, 158, 219, 0.6);
}

.progress-text {
  display: block;
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 1px;
  opacity: 0.9;
}

.preloader.hidden {
  opacity: 0;
  pointer-events: none;
}

/* ====================== VIEWER COUNT ====================== */
.viewer-count {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  padding: 12px 24px;
  border-radius: 50px;
  border: 1px solid rgba(255, 158, 219, 0.3);
  margin: 30px 0 40px 0;
  font-size: 1.05rem;
  color: var(--text-light);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

.viewer-icon {
  font-size: 1.4rem;
  animation: viewerPulse 2s infinite;
}

#visit-count {
  font-weight: 700;
  color: var(--primary);
  font-size: 1.25rem;
  min-width: 50px;
  text-align: center;
}

.viewer-text {
  opacity: 0.85;
  font-weight: 500;
}

/* Animation nhấp nháy nhẹ */
@keyframes viewerPulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.15);
  }
}

/* Dark mode */
[data-theme="dark"] .viewer-count {
  background: rgba(30, 15, 60, 0.6);
  border-color: rgba(255, 158, 219, 0.25);
}

/* ====================== RESPONSIVE ====================== */
@media (max-width: 968px) {
  .nav-menu {
    display: none;
  }
  .mobile-btn {
    display: block;
  }
  .contact-btn {
    display: none;
  }

  .section-title {
    font-size: 2.8rem;
  }
}

@media (max-width: 640px) {
  .nav-container {
    padding: 10px 24px;
  }
}

@keyframes bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(8px);
  }
}
