.intro-block {
    break-inside: avoid;
    margin-bottom: 1.5em;
}
/* Two-column layout for intro text */
.intro-text {
    column-count: 2;
    column-gap: 2em;
    margin-bottom: 2em;
}
/* Side-by-side carousels for Characters section */
.carousels-row {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 30px;
    margin-bottom: 30px;
}
.carousel-col {
    flex: 1 1 0;
    min-width: 320px;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
}


#Characters .carousel-inner img {
        display: block;
        width: 100%;
        max-width: 100%;
        height: auto;
        margin-left: auto;
        margin-right: auto;
        border-radius: 12px;
}

/* Mobile-first: stack carousel columns vertically */
.carousels-row {
    flex-direction: column;
    gap: 24px;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.carousel-col {
    margin: 0 auto;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
header{
    padding: 40px;
    background-color: #070922;
}
body{
    background-color: #1E2347;
}
#Titles{
    background-image: url('../img/batgif.gif');
    background-size: cover;
     background-position: center -250px;
}

nav>ul {
    font-size: 0.85rem;
    justify-content: space-between;
}

nav ul{
    display: flex;
    justify-content: flex-end;
    align-items: center;
    list-style: none;
    gap: 30px;
}

a{
    color:#ffff;
    font-family:Arial, Helvetica, sans-serif;
    font-size: 1.5rem;
    font-weight: bolder;
    transition: color 0.3s ease-in;
}

a:hover {
    text-decoration: none;
    color:rgb(251, 226, 83)
}

p{
color: #ffff;
font-size: 2rem;
font-family:arial, Helvetica, sans-serif;   
padding: 20px;
}

h1{
    color: #ffff;
    font-weight: bold;
    font-size: 7rem;
    font-family: 'Andes', sans-serif;
    text-align: center;
    padding-top: 45px;
    padding-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

h2{
    color: #ffff;
    font-size: 3rem;
    font-family: 'Andes', sans-serif;
    text-align: center;
  padding-bottom: 15px;
  font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);

}

h3{
    color: #ffff;
    font-size: 4.5rem;
    font-weight: bold;
    font-family: 'Andes', sans-serif;
    text-align: center;
    background-color: #070922;
    padding: 15px;
}

h4{
    color: #ffff;
    font-size: 3rem;
    font-family: 'Andes', sans-serif;
    text-align: center;
    padding: 12px;
}

.header-img {
    max-width: 100px;
    padding-right: 20px;
    padding-bottom: 30px;
    height: auto;
    float: left;
    margin-right: 16px;
    display: block;
}

figcaption{
    color: #ffff;
    font-size: 1.5rem;
    font-family: arial, Helvetica, sans-serif;
    text-align: center;
    padding-top: 10px;
}
#Intro img{
    border-radius: 12px;
    width: 25%;
    padding: 10px;
display: grid;
grid-template-columns: 1fr 1fr;
}
.info {
    display: block;
    width: 100%;
    height: auto;
}
.overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    overflow: hidden;
    width: 100;
    height: 100%;
    -webkit-transform: scale(0);
    -ms-transform: scale(0);
    transform: scale(0);
    -webkit-transition: .3s ease;
    transition: .3s ease;
}
#Episodes{
    padding: 15px;
}

.carousel{
    scale: 150%;
    margin: 100px auto;
    width: 50%;
    border: 5px solid #070922;
    display: flex;
    overflow-x: auto;
    gap: 1em;
}
.group img{
    scale: 170%;
     border-radius: 12px    ;
}
.carousel::-webkit-scrollbar {
    display: none;
}
.group{
display: flex;
align-items: center;
justify-content: center;
gap: 1em;
animation: 5s spin linear infinite;
padding-right: 1em;
}
#Legacy .card {
    flex: 0 0 5em;
height: 5em;
padding: 1em;
background-color:#282c6f;
font-size: 3rem;
border-radius: .2em;
text-align: center;
align-content: center;
}
.media {
  display: flex;
  justify-content: center;
}
.card{
    background-color: #070922;
    padding: 20px;
    border-radius: 12px;
    border: 3px solid #282c6f;
}
.card img {
    border-radius: 12px;
    width: 80%;
    padding: 10px;
    display: block;
  margin: auto;
}
.card:hover {
  transition: 0.3s;
  box-shadow: 0 8px 16px 0 rgba(124, 161, 255, 0.2);
}
.cards{
    display:grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
}
.card p{
    padding: 10px;
}
.carousel-container {
  width: 100%;
  max-width: 400px; /* or 100vw for full width */
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}

.carousel-slide {
  width: 100%;
  display: flex;
  transition: transform 0.3s ease;
}

.carousel-item {
  min-width: 100%;
  box-sizing: border-box;
}
footer{
    background-color: #070922;
    text-align: center;
    padding: 12px;
}

@media (min-width: 700px) {
    .carousels-row {
        flex-direction: row;
        gap: 40px;
        align-items: flex-start;
    }
    
.media {
  display: flex;
  justify-content: center;
}
}

@media (max-width: 700px) {
    a {
     font-size: 0.75rem;
     } 
header{
    padding: 20px;
}
.intro-text {
    column-count: 1;
    column-gap: 1em;
    margin-bottom: 1em;
}
     .header-img {
        max-width: 75px;

     }
        #Titles{
        background-image: url('../img/batgif.gif');
        background-size: cover;
        background-position: center -0px;
 }
.cards{
    display:grid;
    grid-template-columns: 1fr;
    gap: 20px;
}
.cards img{
    width: 100%;
}
#Intro img{
    width: 60%;
}
.carousel{
    margin: 100px auto;
    width: 65%;
    border: 5px solid #070922;
    display: flex;
    overflow-x: auto;
    gap: 1em;
}
};
@keyframes spin {
    from { translate: 0; }
    to { translate: -100%; }
}