* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Segoe UI", sans-serif;
  color: #fff !important;
  background-color: #0f0f1a;
  background-image: radial-gradient(
      circle at 50% 100%,
      rgba(70, 85, 110, 0.5) 0%,
      transparent 60%
    ),
    radial-gradient(
      circle at 50% 100%,
      rgba(99, 102, 241, 0.4) 0%,
      transparent 70%
    ),
    radial-gradient(
      circle at 50% 100%,
      rgba(181, 184, 208, 0.3) 0%,
      transparent 80%
    ) !important;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  width: 100%;
  padding: 20px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo {
  font-size: 1.3rem;
  font-weight: bold;
  color: #a5b4fc;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 25px;
}

nav ul li a {
  text-decoration: none;
  color: #e5e7eb;
  font-weight: 500;
  transition: color 0.3s;
}
nav ul li a:hover {
  color: #818cf8;
}

.auth-buttons {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.btn {
  padding: 8px 16px;
  border-radius: 6px;
  border: 1px solid transparent;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s;
}
.btn-login {
  background: transparent;
  border: 1px solid #818cf8;
  color: #818cf8;
}
.btn-login:hover {
  background: #818cf8;
  color: #fff;
}
.btn-register {
  background: #6366f1;
  color: #fff;
}
.btn-register:hover {
  background: #4f46e5;
}

/* Hero Section */
.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  padding: 60px 20px 30px;
  gap: 20px;
}

#typing {
  font-size: 2.5rem;
  font-weight: bold;
  border-right: 3px solid #fff;
  white-space: nowrap;
  overflow: hidden;
  min-height: 3rem;
  margin-bottom: 10px;
}

.hero h3 {
  font-size: 1.2rem;
  font-weight: 400;
  color: #d1d5db;
  margin: 15px 0 30px;
}

.search-box {
  padding: 25px;
  border-radius: 16px;
  border: none;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.3);
  background: #1a1c2c;
  width: 500px;
  margin-bottom: 25px;
}

.input-group {
  display: flex;
  flex-direction: row;
  width: 100%;
  margin: 0 auto;
}

.input-group input {
  flex: 1;
  padding: 12px 16px;
  border: none;
  outline: none;
  background: #fff;
  color: #111;
  font-size: 1rem;
  border-top-left-radius: 10px;
  border-bottom-left-radius: 10px;
  min-width: 0;
}

.btn-apply {
  width: 60px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border: none;
  border-top-right-radius: 10px;
  border-bottom-right-radius: 10px;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
  flex-shrink: 0;
}
.btn-apply:hover {
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
}

.tab-container {
  position: relative;
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  overflow: hidden;
}

.tab-container::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border-radius: 10px;
  transition: transform 0.4s ease;
  z-index: 0;
  transform: translateX(0%);
}

.tab {
  flex: 1;
  text-align: center;
  padding: 12px 0;
  cursor: pointer;
  font-weight: 600;
  position: relative;
  z-index: 1;
  color: #9ca3af;
  transition: color 0.3s ease;
}

.tab.active {
  color: #fff;
}
.tab-container {
  --tab-index: 0;
}
.tab-container::before {
  transform: translateX(calc(var(--tab-index) * 100%));
}
.tab-container {
  --tab-index: 0;
}
.tab-container::before {
  transform: translateX(calc(var(--tab-index) * 100%));
}

.hero-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.btn-primary {
  background: #6366f1;
  color: #fff;
  padding: 12px 24px;
  border-radius: 6px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s;
}
.btn-primary:hover {
  background: #4f46e5;
}
.btn-secondary {
  background: transparent;
  border: 1px solid #818cf8;
  color: #818cf8;
  padding: 12px 24px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
}
.btn-secondary:hover {
  background: #818cf8;
  color: #fff;
}

/* Fade effect */
.fade {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s ease, transform 1s ease;
}
.fade.show {
  opacity: 1;
  transform: translateY(0);
}
.hero-title {
  font-size: 2.5rem;
  font-weight: bold;
  color: #fff;
  margin-bottom: 10px;
  animation: fadeZoomIn 1s ease forwards;
  opacity: 0;
  transform: scale(0.95);
}

@keyframes fadeZoomIn {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.character-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 320px;
  max-width: 100%;
  margin: 18px auto;
  overflow: hidden;
  border-radius: 16px;
  border: none;
  background: #1a1c2c;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.3);
  transition: transform 180ms ease, box-shadow 180ms ease;
  color: #ffffff;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial;
}

.character-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 50px rgba(2, 6, 23, 0.26);
}

.card-image {
  width: 100%;
  height: 240px;

  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.03),
    rgba(255, 255, 255, 0.02)
  );
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}

.card-image::after {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  pointer-events: none;
}

.card-image img {
  max-width: 92%;
  max-height: 92%;
  transform: scale(1.5);
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.45));
  background: transparent;
}

.card-body {
  padding: 14px 16px;
  flex-grow: 1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.02));
  gap: 16px;
}

.card-title {
  margin: 0 0 6px 0;
  font-size: 1.125rem;
  color: #ffffff;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
}
.card-meta {
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
  margin-bottom: 8px;
}
.card-meta .chip {
  background: rgba(255, 255, 255, 0.08);
  padding: 6px 8px;
  border-radius: 999px;
  color: #fff;
  font-weight: 600;
  font-size: 0.85rem;
}

.card-details {
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.95rem;
  line-height: 1.45;
}
.card-details p {
  margin: 6px 0;
}

.copy-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: #fff;
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
}
.copy-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn-primary {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  padding: 8px 12px;
  border-radius: 8px;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.btn-primary:hover {
  background: rgba(255, 255, 255, 0.18);
}

/* Responsive */
@media (max-width: 420px) {
  .character-card {
    width: calc(100% - 28px);
  }
  .card-image {
    height: 180px;
  }
}

/* Responsive */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    align-items: flex-start;
  }
  nav ul {
    flex-wrap: wrap;
    gap: 15px;
    margin: 10px 0;
  }
  #typing {
    font-size: 1.8rem;
    white-space: normal;
    word-break: break-word;
  }
  .hero h3 {
    font-size: 1rem;
  }
  .search-box {
    width: 100%;
  }
}
@media (max-width: 480px) {
  #typing {
    font-size: 1.4rem;
  }
  .btn-primary,
  .btn-secondary {
    padding: 10px 18px;
    font-size: 0.9rem;
  }
}
