/* css/style.css */

/* Reset minim */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Body */
body {
  font-family: Arial, sans-serif;
  background-color: #f4f4f4;
  color: #333;
}

/* Header */
.header {
  background-color: #004080;
  color: white;
  display: flex;
  align-items: center;
  padding: 10px 20px;
}

.header .home-icon img {
  width: 40px;
  height: 40px;
  margin-right: 15px;
}

.header .site-title {
  font-size: 1.5rem;
}

/* Meniu de navigație */
.menu {
  background-color: #0066cc;
  padding: 10px;
  text-align: center;
}

.menu-button {
  color: white;
  text-decoration: none;
  margin: 0 8px;
  padding: 8px 12px;
  border-radius: 4px;
  background-color: #0080ff;
  font-weight: bold;
}

.menu-button:hover {
  background-color: #0059b3;
}

/* Secțiune Copertă */
.cover-section {
  text-align: center;
  margin: 20px 0;
}

.cover-image {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

/* Secțiune Despre */
.about {
  background: white;
  margin: 20px auto;
  padding: 20px;
  max-width: 800px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.about h2 {
  margin-bottom: 10px;
  color: #004080;
}

.about p {
  line-height: 1.6;
}

/* Main (conține tot conținutul) */
main {
  padding-bottom: 30px;
}
/* Stiluri pentru pagina Noutăți */
.section-content {
  background: white;
  margin: 20px auto;
  padding: 20px;
  max-width: 800px;
  border-radius: 8px;
  box-shadow: 0 0 8px rgba(0,0,0,0.1);
}

.section-content h2 {
  margin-bottom: 15px;
  color: #004080;
}

.lista-documente {
  list-style-type: none;
  padding-left: 0;
}

.document-item {
  margin-bottom: 10px;
}

.document-item a {
  text-decoration: none;
  color: #0066cc;
  font-weight: bold;
}

.document-item a:hover {
  text-decoration: underline;
}

.data-item {
  color: #666;
  font-size: 0.9rem;
}
/* profesori.php styles */

.section-content {
  background: white;
  margin: 20px auto;
  padding: 20px;
  max-width: 900px;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.section-content h2 {
  margin-bottom: 15px;
  color: #004080;
}

.box {
  background: #fdfdfd;
  border: 1px solid #ddd;
  border-radius: 6px;
  margin-bottom: 20px;
  padding: 15px;
}

.box h3 {
  margin-bottom: 10px;
  color: #004080;
}

.form-simple input,
.form-simple textarea,
.form-simple button {
  width: 100%;
  margin-bottom: 8px;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.form-simple button {
  background: #0066cc;
  color: white;
  font-weight: bold;
  cursor: pointer;
}

.form-simple button:hover {
  background: #0052a3;
}

/* Teacher grid */
.teacher-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

.teacher-card {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 6px;
  width: calc(33.333% - 10px);
  text-align: center;
  padding: 10px;
}

.prof-image {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 4px;
  margin-bottom: 8px;
}

.prof-placeholder {
  width: 100%;
  height: 150px;
  background: #ddd;
  color: #666;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  margin-bottom: 8px;
}

.success-msg {
  color: green;
  margin-bottom: 10px;
}

.error-msg {
  color: red;
  margin-bottom: 10px;
}

.link-button {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 12px;
  background: #cc0000;
  color: white;
  text-decoration: none;
  border-radius: 4px;
}

.link-button:hover {
  background: #a30000;
}

/* Submenu under Catalog */
.submenu {
  margin-top: 5px;
  background: #f0f8ff;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 8px;
}

.submenu a {
  text-decoration: none;
  color: #004080;
  font-weight: bold;
}

.submenu a:hover {
  text-decoration: underline;
}
/* catalog.php styles */

.table-grades {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.table-grades th,
.table-grades td {
  border: 1px solid #ccc;
  padding: 8px;
  text-align: left;
}

.table-grades th {
  background: #004080;
  color: white;
}

.table-grades tr:nth-child(even) {
  background: #f9f9f9;
}

.form-inline {
  display: flex;
  gap: 8px;
  align-items: center;
}

.form-inline input[type="number"] {
  width: 60px;
}

.section-content h2 {
  margin-bottom: 15px;
  color: #004080;
}

/* Styles for success/error messages are inherited from previous CSS */
/* elevi.php styles */

.button-clase {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 10px;
}

.class-button {
  display: inline-block;
  padding: 10px 16px;
  background: #0066cc;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-weight: bold;
}

.class-button:hover {
  background: #0055a3;
}

.auth-box {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.half-box {
  flex: 1 1 300px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 15px;
  max-width: 400px;
}

.half-box h3 {
  margin-bottom: 10px;
  color: #004080;
}

.section-content h2 {
  margin-bottom: 15px;
  color: #004080;
}

.form-simple input,
.form-simple select,
.form-simple button {
  width: 100%;
  margin-bottom: 8px;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.form-simple button {
  background: #0066cc;
  color: white;
  font-weight: bold;
  cursor: pointer;
}

.form-simple button:hover {
  background: #0052a3;
}

.table-grades {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.table-grades th,
.table-grades td {
  border: 1px solid #ccc;
  padding: 8px;
  text-align: left;
}

.table-grades th {
  background: #004080;
  color: white;
}

.table-grades tr:nth-child(even) {
  background: #f9f9f9;
}

.success-msg {
  color: green;
  margin-bottom: 10px;
  text-align: center;
}

.error-msg {
  color: red;
  margin-bottom: 10px;
  text-align: center;
}

.link-button {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 12px;
  background: #cc0000;
  color: white;
  text-decoration: none;
  border-radius: 4px;
}

.link-button:hover {
  background: #a30000;
}
/* activitati.php styles */

.section-content h2 {
  margin-bottom: 15px;
  color: #004080;
}

.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.thumb {
  width: 200px;
  height: 150px;
  overflow: hidden;
  border-radius: 6px;
  border: 1px solid #ddd;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.thumb img:hover {
  transform: scale(1.1);
}
/* biblioteca.php styles */

.table-library {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.table-library th,
.table-library td {
  border: 1px solid #ccc;
  padding: 8px;
}

.table-library th {
  background: #004080;
  color: white;
  text-align: left;
}

.genre-row td {
  background: #e6f0ff;
  font-weight: bold;
  text-transform: uppercase;
  text-align: center;
}

.table-library a {
  color: #0066cc;
  text-decoration: none;
}

.table-library a:hover {
  text-decoration: underline;
}

/* imprumut.php styles (inherits many from form-simple, etc.) */

.section-content h2 {
  margin-bottom: 15px;
  color: #004080;
}

.box {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  margin-bottom: 20px;
  padding: 15px;
}

.form-simple button {
  background: #0066cc;
  color: white;
  font-weight: bold;
  cursor: pointer;
}

.form-simple button:hover {
  background: #0052a3;
}

.success-msg {
  color: green;
  margin-bottom: 10px;
}

.error-msg {
  color: red;
  margin-bottom: 10px;
}

.link-button {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 12px;
  background: #cc0000;
  color: white;
  text-decoration: none;
  border-radius: 4px;
}

.link-button:hover {
  background: #a30000;
}
/* biblioteca.php – Add Book form */
.box h3 {
  margin-bottom: 10px;
  color: #004080;
}

.form-simple input,
.form-simple button {
  width: 100%;
  margin-bottom: 8px;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.form-simple button {
  background: #0066cc;
  color: white;
  font-weight: bold;
  cursor: pointer;
}

.form-simple button:hover {
  background: #0052a3;
}

/* table-library (if not already present) */
.table-library {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.table-library th,
.table-library td {
  border: 1px solid #ccc;
  padding: 8px;
}

.table-library th {
  background: #004080;
  color: white;
  text-align: left;
}

.genre-row td {
  background: #e6f0ff;
  font-weight: bold;
  text-transform: uppercase;
  text-align: center;
}

.table-library a {
  color: #0066cc;
  text-decoration: none;
}

.table-library a:hover {
  text-decoration: underline;
}

/* Success and error messages */
.success-msg {
  color: green;
  margin: 10px 0;
}

.error-msg {
  color: red;
  margin: 10px 0;
}
/* istoric.php styles */

.section-content h2,
.section-content h3 {
  margin-bottom: 15px;
  color: #004080;
}

/* Text history */
.istoric-text {
  background: white;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 15px;
  max-width: 800px;
  margin: 0 auto 20px auto;
  line-height: 1.6;
}

.istoric-text p {
  margin-bottom: 12px;
  text-align: justify;
}

/* Gallery below text */
.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 20px;
}

.thumb {
  width: 180px;
  height: 120px;
  overflow: hidden;
  border-radius: 6px;
  border: 1px solid #ddd;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.thumb img:hover {
  transform: scale(1.1);
}

/* Error message */
.error-msg {
  color: red;
  margin: 10px 0;
  text-align: center;
}
/* Ensure cover-container and cover-image are set up for fading */
.cover-container {
  position: relative;
  overflow: hidden;
}

.cover-image {
  width: 100%;
  height: auto;
  display: block;
  transition: opacity 1.0s ease-in-out; /* fade duration = 0.5s */
  opacity: 5;
}
/* istoric.php – updated for <pre> */
.istoric-text {
  background: white;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 15px;
  max-width: 800px;
  margin: 20px auto;
  overflow-x: auto;       /* allow horizontal scrolling if needed */
  font-family: Consolas, Courier, monospace; /* monospaced for tabs */
  font-size: 0.95rem;
  line-height: 1.4;
}

.istoric-text pre {
  white-space: pre-wrap;   /* wrap lines but preserve tabs/spaces */
}


/* Carusel de imagini */
.carousel {
  position: relative;
  width: 100%;
  max-width: 1000px;
  margin: 40px auto;
  overflow: hidden;
  border-radius: 10px;
}

.carousel-container {
  width: 100%;
  overflow: hidden;
}

.carousel-slide {
  display: flex;
  transition: transform 0.5s ease-in-out;
}

.carousel-slide img {
  width: 100%;
  flex-shrink: 0;
  object-fit: cover;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: rgba(255,255,255,0.7);
  border: none;
  padding: 10px 15px;
  font-size: 24px;
  cursor: pointer;
  z-index: 1;
  border-radius: 50%;
}

.carousel-btn.prev {
  left: 10px;
}

.carousel-btn.next {
  right: 10px;
}
/* activitati.php caption */
.thumb {
  position: relative;
}
.caption {
  background: rgba(0, 0, 0, 0.6);
  color: white;
  padding: 4px 6px;
  font-size: 0.9rem;
  position: absolute;
  bottom: 0;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
}