/*  JavaScript 7th Edition
    Chapter 3
    Hands-on Project 3-2

    Filename: styles.css

    Purpose: Page-specific slideshow layout for Hands-on Project 3-2.
    The main retro terminal theme comes from ../../css/style.css.
*/

/* =============================
   Project 3-2 Slideshow Layout
   ============================= */

article {
   max-width: 960px;
   margin: 0 auto;
   padding: 2rem 1rem;
}

article h2 {
   margin-bottom: 1.5rem;
   text-align: center;
}

/* =============================
   Slide Display
   ============================= */

#gallery {
   display: flex;
   flex-direction: column;
   align-items: center;
   max-width: 760px;
   margin: 0 auto;
}

#gallery figure {
   width: 100%;
   margin: 0;
   border: 2px solid currentColor;
}

#gallery img {
   display: block;
   width: 100%;
   height: auto;
}

#gallery figcaption {
   padding: 0.5rem;
   text-align: center;
}

/* =============================
   Slideshow Controls
   ============================= */

.slideshow-controls {
   display: flex;
   justify-content: center;
   gap: 1rem;
   margin-top: 1rem;
}

.slideshow-controls button {
   cursor: pointer;
   padding: 0.45rem 1rem;
   font: inherit;
}

/* =============================
   Small Screen Adjustments
   ============================= */

@media (max-width: 700px) {
   article {
      padding: 1rem;
   }

   #gallery {
      max-width: 100%;
   }

   .slideshow-controls {
      flex-direction: column;
      align-items: center;
   }
}