
body {
    margin: 0;
    font-family: Arial, sans-serif;
    color: #000000;
    background-color: #f9f9f9;
}

header {
    background-color: #4CAF50;
    padding: 0; 
    position: relative;
}
.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between; 
  background-color: #FFD700; 
  padding: 10px 20px;
  border-bottom: 2px solid #ccc; 
}

.logo {
  width: 50px;
  height: 50px;
  object-fit: contain;
}

.store-title {
  font-size: 1.8em;
  font-weight: bold;
  margin: 0 auto; 
  text-align: center;
  flex-grow: 1;
}

.horizontal-menu {
    list-style: none;
    display: flex;
    justify-content: center;
    padding: 10px;
    margin: 0;
}

.horizontal-menu li {
    margin: 0 20px;
}

.horizontal-menu a {
    text-decoration: none;
    color: white;
    font-size: 18px;
    transition: color 0.3s;
}

.horizontal-menu a:hover {
    color: #FFD700;
}
.menu-btn.open div:nth-child(1) {
  transform: rotate(45deg);
  position: relative;
  top: 8px;
  background-color: #FFD700; 
}

.menu-btn.open div:nth-child(2) {
  opacity: 0; 
}

.menu-btn.open div:nth-child(3) {
  transform: rotate(-45deg);
  position: relative;
  top: -10px;
  background-color: #FFD700; 
}
.menu-container {
  display: none;
  align-items: center;
  justify-content: flex-start; 
  padding: 0 10px;
  box-sizing: border-box; 
  position: relative; 
  z-index: 10;
}
.menu-label {
  color: white;
  font-size: 18px;
  margin-left: 15px; 
  white-space: nowrap;
  position: relative;
  top: 0px; 
}

.mobile-menu {
  display: none;
  background-color: #4CAF50;
  position: relative;
  top: -35px;
  left: 0;
  right: 0;
  width: 100%; 
  padding: -11px;
  z-index: 5;
  box-sizing: border-box; 
  transition: max-height 0.3s ease-in-out;
  max-height: 0;
  overflow: hidden;
}
.mobile-menu.show {
  display: block;
  max-height: 500px;
}
.mobile-menu li {
    margin: 10px 0;
    text-align: center;
}

.mobile-menu a {
    color: white;
    font-size: 18px;
    text-decoration: none;
}

.mobile-menu a:hover {
    color: #00ff73;
}

.menu-btn {
  display: flex;
  flex-direction: column; 
  justify-content: space-between; 
  align-items: center; 
  background: none;
  border: none;
  cursor: pointer;
  z-index: 10;
  padding: 10px;
  margin-right: 10px; 
}

.menu-btn div {
  width: 25px;
  height: 3px;
  background-color: white;
  margin: 3px 0; 
  transition: all 0.3s ease;
}

@media screen and (max-width: 768px) {
  .menu-container {
      display: flex; 
      align-items: center;
  }

  .horizontal-menu {
      display: none;
  }
}

@media screen and (min-width: 769px) {
  .horizontal-menu {
      display: flex;
  }
} 
  .hero {
    font-size: 24px; 
    text-align: center;
  }
  
  .hero h1 {
    font-size: 32px; 
    color: #2c3e50;
    text-align: center;
    margin-bottom: 20px; 
    text-transform: uppercase; 
    letter-spacing: 2px; 
    font-weight: 700; 
  }
  
  .hero button {
    background-color: #e3c100b4;
    border: none;
    padding: 10px 20px;
    font-size: 18px;
    cursor: pointer;
    transition: background-color 0.3s;
  }
  
  .hero button a {
    text-decoration: none;
    color: black;
  }
  
  .hero button:hover {
    background-color: #FFA500;
  }

  .carousel {
    position: relative;
    max-width: 800px;
    height: 400px;
    margin: 50px auto;
    overflow: hidden;
    border: 2px solid #4CAF50; 
    border-radius: 10px;
  }
  
  .carousel-container {
    display: flex;
    transition: transform 0.5s ease-in-out;
  }
  
  .carousel-slide {
    min-width: 100%;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
  }
  
  .carousel-slide img {
    width: 100%; 
    max-width: 800px; 
    max-height: 400px; 
    object-fit: cover; 
    border-radius: 10px; 
  }

  .carousel-text {
    position: absolute;
    bottom: 0; 
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.6); 
    text-align: center;
    padding: 10px;
    z-index: 2; 
  }
  
  .carousel-text h1 {
    font-size: 24px;
    margin-bottom: 5px;
    color: white;
  }
  
  .carousel-text p {
    font-size: 16px;
    color: white;
  }

  .carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    border-radius: 50%;
    font-size: 20px;
    z-index: 10;
  }
  
  .carousel-btn.prev {
    left: 10px;
  }
  
  .carousel-btn.next {
    right: 10px;
  }
  
  .carousel-btn:hover {
    background-color: rgba(0, 0, 0, 0.8);
  }
  
  footer {
    background-color: #333; 
    color: white;
    text-align: center;
    padding: 20px;
    font-size: 14px;
  }

  .social-media {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px; 
    margin-top: 10px;
  }

  .social-icon {
    width: 30px;
    height: 30px;
    margin: 0 10px;
    transition: transform 0.3s ease;
  }

  .social-icon:hover {
    transform: scale(1.2); 
  }
  .social-media a {
    text-decoration: none;
  }
  footer .social-links a {
    color: #FFD700;
    text-decoration: none;
  }
  
  footer .social-links a:hover {
    color: #FFA500;
  }
  .map {
    margin-top: 20px;
    text-align: center;
  }
  
  .map-container {
    max-width: 800px;
    margin: 0 auto;
    border: 2px solid #ccc;
    border-radius: 8px;
    overflow: hidden;
  }
  .book-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 18px;
    text-align: left;
  }
  
  .book-table th, .book-table td {
    padding: 12px;
    border: 1px solid #ddd;
  }
  
  .book-table th {
    background-color: #f4f4f4;
  }
  
  .book-table tr:nth-child(even) {
    background-color: #f9f9f9;
  }
  
  .book-table tr:hover {
    background-color: #f1f1f1;
  }

  .book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
    padding: 20px;
  }
  
  .book-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Рівномірний розподіл */
    align-items: center; /* Центрування */
    background-color: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    height: auto; /* Динамічна висота */
    min-height: 350px; /* Мінімальна висота для стабільності */
  }
  
  .book-image {
    max-width: 100%;
    height: 200px;
    object-fit: contain;
    margin-bottom: 12px;
    background-color: #fff;
  }
  
  .book-card h3 {
    font-size: 18px;
    margin: 8px 0;
    color: #333;
  }
  
  .book-card p {
    font-size: 14px;
    margin: 4px 0;
  }
  
  .add-to-cart {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    margin-top: 12px; /* Відступ зверху */
    width: 100%; /* Займає всю ширину картки */
    max-width: 200px; /* Обмеження ширини кнопки */
    transition: background-color 0.3s, transform 0.3s;
  }
  
  .add-to-cart:hover {
    background-color: #218838;
    transform: scale(1.05); /* Легка анімація при наведенні */
  }
  
  .add-to-cart:active {
    background-color: #1e7e34;
    transform: scale(0.95);
  }
    .info-button {
    background-color: #2196f3;
    color: white;
    border: none;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    margin-top: 12px; /* Відступ зверху */
    width: 100%; /* Займає всю ширину картки */
    max-width: 200px; /* Обмеження ширини кнопки */
    transition: background-color 0.3s, transform 0.3s;
  }
  
  .info-button:hover {
    background-color:  #1e88e5;
    transform: scale(1.05); /* Легка анімація при наведенні */
  }
  
  .info-button:active {
    background-color:  #1e88e560;
    transform: scale(0.95);
  }
  
  .new-books-table {
    width: 100%;
    border-collapse: collapse; 
    margin: 20px 0;
    font-size: 16px;
    text-align: left;
  }
  
  .new-books-table th, 
  .new-books-table td {
    border: 1px solid #ddd; 
    padding: 8px;
  }
  
  .new-books-table th {
    background-color: #f4f4f4; 
    font-weight: bold;
  }
  
  .new-books-table tr:nth-child(even) {
    background-color: #f9f9f9; 
  }
  
  .new-books-table tr:hover {
    background-color: #f1f1f1; 
  }

  #cart-container {
    display: flex;
    flex-direction: column;
    gap: 15px; 
  }
  
  .cart-item {
    position: relative;
    padding: 10px 40px 10px 10px; 
    border: 1px solid #ddd; 
    border-radius: 5px;
    background-color: #f9f9f9; 
  }

  .remove-btn {
    position: absolute;
    top: 50%;
    right: 10px; 
    transform: translateY(-50%); 
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
  }
  
  .remove-icon {
    width: 40px;
    height: 40px;
    transition: transform 0.2s ease;
  }
  
  .remove-btn:hover .remove-icon {
    transform: scale(1.2);
  }
   
#checkout-btn {
  display: block;
  margin: 20px auto; 
  padding: 10px 20px;
  font-size: 17px;
  background-color:green;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s, transform 0.3s;
}

#checkout-btn:disabled {
  background-color: grey;
  cursor: not-allowed;
}
#checkout-btn:hover {
  background-color: #218838;
  transform: scale(1.1); 
}

#checkout-btn:active {
  background-color: #1e7e34; 
  transform: scale(0.9);
}

.checkout-content {
  max-width: 800px;
  margin: auto;
  padding: 20px;
  background: white;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
}

form {
  display: flex;
  flex-direction: column;
}

form div {
  margin-bottom: 15px;
}

form label {
  font-weight: bold;
}

form input, form select {
  width: 100%;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
  margin-top: 5px;
}

.order-button {
  background-color: #4CAF50; 
  color: white; 
  border: none;
  padding: 12px 20px;
  text-align: center;
  font-size: 16px;
  cursor: pointer;
  border-radius: 5px;
  transition: background-color 0.3s ease;
  margin-top: 20px; 
}

.order-button:hover {
  background-color: #45a049; 
}

.order-button:active {
  background-color: #3e8e41; 
}
.audio-books {
  margin: 20px auto;
  padding: 0 10px;
  max-width: 800px;
}

.audio-book {
  margin-bottom: 40px;
  padding: 20px;
  border: 1px solid #ddd;
  border-radius: 8px;
  background-color: #f9f9f9;
}

.book-title {
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 15px;
  color: #333;
}

.video-container {
  position: relative;
  padding-bottom: 56.25%; 
  height: 0;
  overflow: hidden;
  margin-bottom: 15px;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.book-description {
  font-size: 16px;
  line-height: 1.6;
  color: #555;
}

section.content p {
  text-indent: 30px; 
  line-height: 1.6;  
}

.about-heading {
  font-size: 36px; 
  font-weight: bold;
  text-align: center; 
  margin-top: 40px;
  margin-bottom: 20px;
}


section.content h2 {
  font-size: 28px; 
  font-weight: bold;
  margin-top: 30px; 
  margin-bottom: 10px; 
  text-align: left; 
  text-indent: 30px; 
}

section.content ul {
  margin-left: 50px; 
  line-height: 1.8;  
}

section.content li {
  margin-bottom: 10px;
}
.contacts-content {
  text-align: center; 
  margin-top: 20px; 
}
.social-media-section {
  text-align: center;
  margin-top: 30px;
}
.popular-books h2 {
  font-size: 32px; 
  color: #2c3e50;
  text-align: center;
  margin-bottom: 20px; 
  text-transform: uppercase; 
  letter-spacing: 2px; 
  font-weight: 700; 
}
.subscription {
  background-color: #f5f5f5;
  padding: 30px;
  text-align: center;
  border-radius: 8px;
  margin: 40px auto;
  max-width: 500px;
}

.subscription h2 {
  font-size: 1.8rem;
  color: #2c3e50;
  margin-bottom: 10px;
}

.subscription p {
  font-size: 1rem;
  color: #7f8c8d;
  margin-bottom: 20px;
}

.subscription-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.subscription-form input {
  padding: 10px 15px;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  width: 100%;
  max-width: 300px;
  text-align: center;
}

.subscription-form input:focus {
  outline: none;
  border-color: #3498db;
  box-shadow: 0 0 5px rgba(52, 152, 219, 0.5);
}

.subscription-form button {
  padding: 10px 20px;
  font-size: 1rem;
  color: #fff;
  background-color: #3498db;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s;
  max-width: 150px;
}

.subscription-form button:hover {
  background-color: #2980b9;
}

.hidden {
  display: none;
}

#subscription-message {
  margin-top: 20px;
  color: #27ae60;
  font-weight: bold;
  font-size: 1rem;
}
.search-container {
  text-align: center;
  margin: 20px 0;
}

#search-input {
  padding: 10px;
  font-size: 1rem;
  width: 80%;
  max-width: 400px;
  border: 1px solid #ccc;
  border-radius: 5px;
}
/* Загальні стилі тільки для сторінки info-page */
/* Основна сторінка */
.info-page .book-detail-page {
  display: flex;
  justify-content: center;
  align-items: flex-start; /* Вирівнювання зверху */
  min-height: calc(75vh - 120px); /* Висота сторінки мінус header і footer */
  padding: 20px 10px; /* Зменшені внутрішні відступи */
  background-color: #f8f9fa;
  
}

/* Контейнер книги */
.info-page .book-detail-container {
  display: flex;
  background: #ffffff;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  align-items: center;
}

.book-detail-page .book-image-container {
  margin-bottom: 20px;
  padding: 10px; 
  box-sizing: border-box; 
  justify-content: space-between;
  height: auto;
  width: 450px;
}


.book-detail-page img {
  border-radius: 8px;
  width: 100%; 
  height: 100%; 
  object-position: center;
}

.info-page .book-info {
  flex: 2;
  padding: 10px 20px;
  text-align: left;
}

.info-page .book-title {
  font-size: 20px;
  font-weight: bold;
  margin-bottom: 10px;
}

.info-page .book-info p {
  font-size: 14px;
  margin: 6px 0;
}

.info-page .book-description {
  margin-top: 10px;
  line-height: 1.4;
  font-size: 14px;
  color: #555;
}

.info-page .button-group {
  margin-top: 16px;
  display: flex;
  gap: 8px;
}
.info-page .back-to-catalog-button {
  background-color:  #e3c100b4;
  color: white;
  border: none;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: bold;
  border-radius: 50px;
  cursor: pointer;
  margin-top: 12px;
  width: 100%; 
  max-width: 200px; 
  transition: background-color 0.3s, transform 0.3s;
}

.info-page .back-to-catalog-button:hover {
  background-color:  #FFA300;
  transform: scale(1.05);
}

.info-page .back-to-catalog-button:active {
  background-color:  #FFA300;
  transform: scale(0.95);
}

.search-bar {
  margin: 20px 0; 
  text-align: center;
}


.search-bar input[type="text"] {
  width: 80%;
  max-width: 500px; 
  padding: 12px 15px;
  font-size: 16px;
  border: 2px solid #ccc;
  border-radius: 25px;
  background-color: #f9f9f9; 
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); 
  outline: none; 
  transition: all 0.3s ease;
  font-style: italic;
}

.search-bar input[type="text"]:focus {
  border-color: #4CAF50; 
  box-shadow: 0 2px 8px rgba(72, 154, 72, 0.4);
}

.images {
  text-align: center;
  margin-top: 5px;
}

.image-gallery {
  display: flex;
  justify-content: center;
  gap: 250px;
}

.image {
  width: 300px; 
  height: 300px; 
  border-radius: 35%; 
  object-fit: cover;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2); 
}








