:root {
  --grid-card-bg: rgba(15,20,30,0.4);
  --card-hover-bg: rgba(20,25,35,0.6);
  --card-active-bg: rgba(25,30,40,0.8);
  --card-border: rgba(255,255,255,0.1);
  --card-hover-border: rgba(255,255,255,0.2);
  --card-shadow: 0 8px 32px rgba(0,0,0,0.3);
  --card-hover-shadow: 0 16px 48px rgba(0,0,0,0.4);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.roleplay-section {
  position: relative;
  width: 100%;
  min-height: 90vh;
  background: url('/images/background/interactivebg.webp') no-repeat center center;
  background-size: cover;
  background-attachment: fixed;
  padding: 4rem 0;
  overflow: hidden;
  z-index: 1;
}

.roleplay-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1;
}

.roleplay-section .container {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.roleplay-section .section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.roleplay-section .section-header .section-number {
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(91,155,213,0.9);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: 0.75rem;
  display: block;
  text-shadow: 0 0 20px rgba(91,155,213,0.5);
}

.roleplay-section .section-header .section-title {
  font-size: 3.5rem;
  font-weight: 800;
  color: #fff;
  line-height: 1;
  margin-bottom: 0.75rem;
  text-shadow: 0 4px 30px rgba(0,0,0,0.5);
  background: linear-gradient(to right, #fff, rgba(255,255,255,0.8));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.roleplay-section .section-header .section-title span {
  display: block;
  font-size: 0.4em;
  font-weight: 400;
  opacity: 0.8;
  margin-top: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: none;
  -webkit-text-fill-color: rgba(255,255,255,0.7);
}

.roleplay-section .section-header .section-subtitle {
  font-size: 1.2rem;
  color: rgba(255,255,255,0.7);
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.6;
  text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.roleplay-section .roleplay-cards {
  margin-top: 1rem;
  display: flex;
  min-height: 500px;
  gap: 1.5rem;
  align-items: stretch;
  perspective: 1000px;
}

.roleplay-section .roleplay-card {
  position: relative;
  flex: 1;
  overflow: hidden;
  border-radius: 1.5rem;
  background: var(--grid-card-bg);
  border: 1px solid var(--card-border);
  box-shadow: var(--card-shadow);
  cursor: pointer;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.roleplay-section .roleplay-card:hover:not(.active) {
  transform: translateY(-5px);
}

.roleplay-section .roleplay-card.active {
  flex: 2.5;
  background: var(--card-active-bg);
  box-shadow: var(--card-hover-shadow);
  transform: translateZ(10px);
}

.roleplay-section .roleplay-card .card-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.roleplay-section .roleplay-card:hover .card-bg,
.roleplay-section .roleplay-card.active .card-bg {
  transform: scale(1.05);
  filter: brightness(0.85);
}

.roleplay-section .roleplay-card .card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem;
  background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.7) 50%, transparent 100%);
  color: #fff;
  transform: translateY(30%);
  opacity: 0;
  transition: all 0.4s ease;
}

.roleplay-section .roleplay-card .card-overlay h3 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.roleplay-section .roleplay-card .card-overlay p {
  font-size: 1rem;
  opacity: 0.9;
  margin: 0;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.roleplay-section .roleplay-card:hover .card-overlay,
.roleplay-section .roleplay-card.active .card-overlay {
  transform: translateY(0);
  opacity: 1;
}

.roleplay-section .roleplay-card .card-details {
  position: absolute;
  right: 2rem;
  top: 50%;
  width: 45%;
  opacity: 0;
  color: #fff;
  transform: translateX(30px);
  transition: all 0.4s ease;
  pointer-events: none;
}

.roleplay-section .roleplay-card .card-details p {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.roleplay-section .roleplay-card .card-details .btn-details {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: rgba(91,155,213,0.9);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 2rem;
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
}

.roleplay-section .roleplay-card .card-details .btn-details:hover {
  background: rgba(91,155,213,1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(91,155,213,0.3);
}

.roleplay-section .roleplay-card.active .card-details {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}