html, body {
  width: 100%;
  min-height: 100%;
  overflow-x: hidden;
  margin: 0;
  padding: 0;
  background-color: #fff;
  /*background-image: url('../images/notebook-page.png');
  background-size: cover;
  background-attachment: fixed;
  */
  font-family: 'Poppins', sans-serif;
  color: #222;
  position: relative;
  z-index:0;
}

/* RESET */
* {
  box-sizing: border-box;
}

*[v-cloak] {
  display: none;
}

body {
  scroll-behavior: smooth;
}

/* NAVBAR */
.navbar {
      background-color: #6ef863;
  border-bottom: 3px solid #000;
  box-shadow: 0 2px 0 #000;
}

.navbar-brand {
  font-weight: 700;
  font-size: 1.6rem;
  color: #000 !important;
}

.nav-link {
  color: #333 !important;
  font-weight: 600;
  font-size: 1rem;
  transition: color 0.3s;
}

.nav-link:hover {
  color: #ff8fab !important;
}

.navbar-toggler{
    border-width: 3px;
    border-color: #056500;
}

@media (max-width: 990px) {
  .nav-link {
    font-size: 1.4rem;
    margin-left: 1.5rem;
  }
}


/* HERO SECTION */
.hero {
  background-color: #fdfdfd;
  color: #000;
  padding: 100px 0 70px;
  text-align: center;
  border-bottom: 3px solid #000;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: #444;
}

.hero p {
  font-size: 1.2rem;
  color: #555;
}

/* SECTION GENERICA */
section {
  padding: 70px 0;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 50px;
  color: #333;
  border-bottom: 2px dashed #000;
  display: inline-block;
  padding-bottom: 5px;
}

/* BOOKS SCROLL */
.books-scroll-container {
  overflow-x: auto;
  padding: 20px 0;
  scrollbar-width: thin;
  scrollbar-color: #bbb #f1f1f1;
}

.books-scroll {
  display: flex;
  gap: 20px;
  padding: 10px;
}

.book-card-item {
  background: #fff;
  border: 2px solid #000;
  border-radius: 12px;
  transition: transform 0.2s, box-shadow 0.2s;
  width: 180px;
  min-width: 180px;
  cursor: pointer;
  
}

.book-card-item:hover {
  transform: translateY(-5px);
  box-shadow: 4px 4px 0 #000;
}

.book-card-item img {
  border-bottom: 2px solid #000;
  border-radius: 10px 10px 0 0;
  width: 100%;
  height: 225px;
  object-fit: cover;
}

.book-title {
  text-align: center;
  font-weight: 600;
  font-size: 0.95rem;
  color: #333;
  padding: 8px;
}

/* PASTEL BADGE */
.book-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #ffd6a5;
  color: #000;
  border: 2px solid #000;
  padding: 5px 10px;
  border-radius: 10px;
  font-weight: 600;
}

.input-group-text{
  border: 2px solid #000;
  background-color: #d877ff;
  color: #000;
  font-weight: 600;
}

/* DOWNLOADS SECTION */
.downloads-section {
  background: #fff;
}

.download-card {
  border: 2px solid #000;
  border-radius: 12px;
  padding: 30px;
  box-shadow: 4px 4px 0 #000;
  margin-bottom: 30px;
  background: #fefefe;
}

.downloads-container{
  overflow-x: hidden;
  overflow-y: auto;
  max-height: 100vh;
}

/* ABOUT SECTION */
.about-section {
  background-color: #e2f0ff;
  border-top: 3px solid #000;
  border-bottom: 3px solid #000;
  color: #000;
}

.about-section .section-title {
  color: #000;
}

/* FOOTER */
footer {
  background-color: #fff;
  border-top: 3px solid #000;
  text-align: center;
  padding: 30px 0;
  color: #333;
}

/* BUTTONS */
.btn-primary {
  background-color: #a7f3d0;
  color: #000;
  border: 2px solid #000;
  font-weight: 600;
  padding: 10px 25px;
  border-radius: 8px;
  transition: all 0.2s;
}

.btn-primary:hover {
  background-color: #fbc4ab;
  transform: translateY(-2px);
}

/* FORM */
.form-control {
  border: 2px solid #000;
  border-radius: 8px;
}

.form-control:focus {
  outline: none;
  border-color: #ffafcc;
  box-shadow: 3px 3px 0 #000;
}

/* COOKIE BANNER */
.cookie-banner {
    background: #b2ff9e;
    border-top: 3px solid #000;
    color: #000;
    box-shadow: 0 -3px 0 #000;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100vw;
    padding: 2rem;
    background-color: #b2ff9e;
}

/* MODAL */
.modal-content {
  border: 3px solid #000;
  border-radius: 15px;
  background: #fff;
  overflow: hidden;
}

.modal-header {
  background-color: #cde8ff;
  border-bottom: 2px solid #000;
  overflow: hidden;
}

.modal-body img {
  border: 2px solid #000;
  border-radius: 10px;
  overflow: auto;
}

/* LOADING */
.loading-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  background: rgba(255, 255, 255, 0.8);
}

.loading-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px;
  border: 2px solid #000;
  background: #fff;
  border-radius: 12px;
}

.spinner {
  width: 60px;
  height: 60px;
  border: 5px solid #ddd;
  border-top-color: #a2d2ff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.loading-text {
  font-size: 14px;
  color: #000;
  margin-top: 10px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn-amazon{
  background-color: #ff9900;
  color: #fff;
  border: solid 2px #000000;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-amazon:hover{
  background-color: #ff9900;
  color: #351a00;
  border: solid 2px #271500;
  box-shadow: 5px 5px 0px 0px rgb(77, 46, 0);
  transform: translateY(-5px);
}

.btn-amazon:active{
background-color: #a86500!important;
}

.alert {
  border-width: 3px;
}

.btn {
  border-width: 2px;
  border-color: #00000091!important;
}

.book-download-card{
    border: solid 2px #000;
    border-radius: 5px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    z-index: 1;
}
.book-download-card.active{

border: solid 2px #00491c;
}

.disabled{
  opacity: 0.5;
}

.book-download-card.disabled{
  border: solid 2px #444444;
  opacity: 0.5;
}

.book-download-card img{
    width: 100%;
    height: auto;
}

.book-download-card:hover{
  box-shadow: 5px 5px 0px 0px rgb(49, 49, 49);
  transform: translateY(-5px);
}

.book-download-card.active:hover{
  box-shadow: 5px 5px 0px 0px rgb(0, 95, 24);
  transform: translateY(-5px);
}

.book-download-card-title{
  position: absolute;
  z-index: 5;
  padding: 0.5rem 1rem;
  font-weight: bold;
  font-size: 1rem;
  background-color: #bce5ff;
  border-bottom: solid 2px #000;
  top: 0;
  left: 0;
  width: 100%;
}

.locked-overlay{
  position: absolute;
  z-index: 10;
  bottom: 0.5rem;
  left: 1rem;
  font-size: 2rem;
}

.bi-lock-fill{
  color: #bb0000;
}
.bi-cloud-download-fill{
  color: #00741a;
}

        /* START LOADING */
        .loading-overlay{
      position: absolute;
      inset: 0;               /* top:0; right:0; bottom:0; left:0 */
      display: flex;
      align-items: center;
      justify-content: center;
      z-index: 100;          /* richiesto */
      background: rgba(255,255,255,0.0); /* trasparente, cambiare se serve oscurare */
      pointer-events: none;  /* permette click sotto; togliere se vuoi bloccare interazioni */
    }

    /* Contenitore centrale per spinner + testo */
    .loading-box{
      pointer-events: auto;  /* permette di interagire con contenuto interno se serve */
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 12px;
      padding: 16px;
      border-radius: 12px;
      /* box shadow visibile attorno al cerchio */
      box-shadow: 0 8px 24px rgba(0,0,0,0.18), 0 2px 6px rgba(0,0,0,0.12);
      background: rgba(255,255,255,0.9);
      backdrop-filter: blur(4px);
    }

    /* Spinner */
    .spinner{
      width: 64px;
      height: 64px;
      border-radius: 50%;
      border: 6px solid rgba(0,0,0,0.08);
      border-top-color: #2b6cb0; /* colore del segmento attivo */
      animation: spin 1s linear infinite;
      box-shadow: 0 6px 18px rgba(43,108,176,0.18), inset 0 -4px 8px rgba(0,0,0,0.04);
    }

    @keyframes spin{
      to { transform: rotate(360deg); }
    }

    /* Testo sotto lo spinner */
    .loading-text{
      font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
      font-size: 14px;
      letter-spacing: 0.2px;
      color: #222;
      user-select: none;
      -webkit-user-select: none;
    }

    /* Utility: centro nel contenitore se vuoi che l'overlay non sia fullscreen */
    .centered {
      position: relative;
      height: 100vh;
    }

    
    /* END LOADING */

    .bg-gradient{
      background: linear-gradient(135deg, #f0e6ff 0%, #ffe6f7 100%)!important;
    }

    .brand{
      text-decoration: none;
      margin-bottom: 1rem;
      font-weight: 600;
      color: #0094ff;
      background: linear-gradient(135deg, #beebff 0%, #f3cff8 100%);
      font-family: system-ui;
      text-transform: uppercase;
      /*box-shadow: 3px 3px 0px #7ec9ff;*/
      transition: transform 0.2s, box-shadow 0.2s;
      border: solid 3px #0094ff;
      border-radius: 0.5rem;
      padding: 1rem;
    }

    .brand:hover{
      transform: translateY(-5px);
      box-shadow: 4px 4px 0 #3fafff;
    }