/*
Theme Name: Books Library
Theme URI: https://example.com/books-library
Author: minoanDesign
Author URI: https://minoandesign.gr
Description: Ένα custom θέμα για δημοτική βιβλιοθήκη, φτιαγμένο για WordPress.
Version: 1.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: books-library
*/


@font-face {
  font-family: 'StoneSansSemiBold';
  src: url('assets/fonts/StoneSansITCHellenic-SemiBold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'StoneSansBook';
  src: url('assets/fonts/StoneSansITCHellenic-Book.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}


/* Για τίτλους και μενού */
h1, h2, h3, h4, h5, h6,
nav, .main-menu, .site-header {
  font-family: 'StoneSansSemiBold', sans-serif;
}

/* Για σώμα κειμένου και περιεχόμενο */
body, p, span, li {
  font-family: 'StoneSansBook', serif;
}


/* =Global Styles
-------------------------------------------------------------- */
html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: 'StoneSansBook', sans-serif;
  color: #333;
  background-color: #f8f8f8;
}

a {
  color: #1e73be;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.page-container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 2rem;
}

.post-container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 2rem;
}

/* =Header Styles
-------------------------------------------------------------- */
.site-header {
  background-color: #1b4445;
  color: white;
  padding: 10px 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 100;
  border-bottom: 10px solid #143536;
}

.header-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo img {
  max-height: 150px;
  width: auto;
}

.site-title {
  flex: 1;
  text-align: center;
  font-size: 2.5rem;
  font-weight: bold;
  color: white;
}


/* =Navigation Styles
-------------------------------------------------------------- */
.main-menu {
  display: flex;
  justify-content: center;
}

.main-menu .menu li {
  margin: 0 10px;
}

.main-menu .menu li a {
  color: white;
  font-weight: 500;
  padding: 6px 10px;
  transition: background 0.2s;
}

.main-menu .menu li a:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.main-menu .menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 20px;
  justify-content: center;
}

.main-menu .menu a {
  color: white;
  text-decoration: none;
  padding: 5px 10px;
  transition: all 0.3s ease;
  position: relative;
}

/* Hover effect */
.main-menu .menu a:hover {
  color: white;
}

/* Current menu item styles */
.main-menu .menu .current-menu-item > a,
.main-menu .menu .current_page_item > a,
.main-menu .menu .current-page-ancestor > a {
  color: white;
  font-weight: bold;
}

/* Underline indicator for current item */
.main-menu .menu .current-menu-item > a::after,
.main-menu .menu .current_page_item > a::after,
.main-menu .menu .current-page-ancestor > a::after {
  content: "";
  position: absolute;
  bottom: -3px;
  left: 10px;
  right: 10px;
  height: 2px;
  background-color: #a0d5b3;
}

/* Special case for home page */
.home .main-menu .menu li.menu-item-home.current-menu-item > a {
  color: white;
}

/* =Dropdown Submenu Styles
-------------------------------------------------------------- */
.main-menu .menu li {
  position: relative; /* Needed for absolute positioning of submenu */
}

/* Submenu styling */
.main-menu .menu .sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: #1b4445;
  min-width: 200px;
  padding: 10px 0;
  border-radius: 0 0 4px 4px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  z-index: 100;
}

/* Show submenu on hover */
.main-menu .menu li:hover > .sub-menu {
  display: block;
}

/* Submenu items */
.main-menu .menu .sub-menu li {
  margin: 0;
  padding: 0;
  list-style-type: none; /* Ensures no bullets appear */
}

.main-menu .menu .sub-menu a {
  padding: 8px 15px;
  display: block;
  white-space: nowrap;
}

/* Submenu indicator */
.main-menu .menu .menu-item-has-children > a::after {
  content: "▾";
  margin-left: 5px;
  font-size: 0.9em;
}

/* Current item in submenu */
.main-menu .menu .sub-menu .current-menu-item > a {
  background-color: rgba(255, 255, 255, 0.1);
}

/* Mobile dropdown styles */
@media (max-width: 768px) {
  .main-menu .menu .sub-menu {
    position: static;
    display: none;
    background-color: rgba(0, 0, 0, 0.1);
    box-shadow: none;
    padding-left: 20px;
  }

  .main-menu.active .menu .sub-menu {
    display: block;
  }

  .main-menu .menu li:hover > .sub-menu {
    display: none; /* Disable hover on mobile */
  }

  .main-menu .menu .menu-item-has-children > a::after {
    content: "+";
    float: right;
  }

  .main-menu .menu .menu-item-has-children.active > a::after {
    content: "-";
  }
}

/* =Auth Buttons Styles
-------------------------------------------------------------- */
.auth-buttons {
  display: flex;
  gap: 10px;
}

.auth-buttons .btn,
.auth-buttons .btn-outline {
  padding: 6px 12px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: bold;
  font-size: 14px;
}

.auth-buttons .btn {
  background-color: white;
  color: #1b4445;
}

.auth-buttons .btn-outline {
  background: transparent;
  border: 1px solid white;
  color: white;
}

.auth-buttons .btn:hover,
.auth-buttons .btn-outline:hover {
  background-color: white;
  color: #1b4445;
}

.auth-buttons .dropdown {
  position: relative;
  display: inline-block;
}

.auth-buttons .dropdown-menu {
  display: none;
  position: absolute;
  background-color: white;
  min-width: 180px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
  z-index: 999;
  border-radius: 8px;
  padding: 0.5rem 0;
}
.auth-buttons .dropdown-menu a {
  color: #333;
  padding: 10px 16px;
  display: block;
  text-decoration: none;
}

.auth-buttons .dropdown-menu a:hover {
  background-color: #f0f0f0;
}

.auth-buttons .dropdown:hover .dropdown-menu {
  display: block;
}
/* =Content Sections
-------------------------------------------------------------- */
.home-hero {
  background-color: #e6f0ff;
  padding: 60px 20px;
  text-align: center;
}

.two-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

/* =Books Grid Styles
-------------------------------------------------------------- */
.books-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
}

.book-item {
  background-color: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 12px;
  padding: 15px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

/* =Footer Styles
-------------------------------------------------------------- */
.site-footer {
  background-color: #1b4445;
  color: white;
  padding: 20px;
  margin-top: 60px;
}

.site-footer p {
  margin: 0;
  font-size: 14px;
}

.site-footer .footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0 0 10px 0;
  display: flex;
  gap: 20px; /* Αποστάσεις μεταξύ links */
  flex-wrap: wrap; /* Να σπάει σε επόμενη γραμμή αν δεν χωράει */
  font-size: 14px;
  text-decoration: underline;
}

.site-footer .footer-nav ul li {
  margin: 0;
}

.site-footer .footer-nav ul li a {
  color: #fff; /* χρώμα*/
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.site-footer .footer-nav ul li a:hover {
  color: #ddd;
}

/* =Responsive Styles
-------------------------------------------------------------- */
@media (max-width: 768px) {
  .two-columns {
    grid-template-columns: 1fr;
  }

  .header-flex {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    text-align: left;
}


  .site-title {
    order: -1;
    width: 100%;
    margin: 10px 0;
  }
}

@media (max-width: 768px) {
  #books-container {
    justify-content: center !important;
  }
}

@media (max-width: 768px) {
  .header-flex {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    text-align: center;
  }

  .logo {
    order: 1;
    flex: 0 0 auto;
  }

  .site-title {
    order: 2;
    flex: 1 1 auto;
    text-align: center;
    font-size: 1.4rem;
  }

  .menu-toggle {
    order: 3;
    flex: 0 0 auto;
  }
}



/* =news-ticker-wrapper
-------------------------------------------------------------- */
.news-ticker-wrapper {
  overflow: hidden;
  flex: 1;
}

.news-ticker {
  display: inline-flex;
  gap: 50px;
  white-space: nowrap;
  animation: ticker-scroll 40s linear infinite;
}

.news-title-link {
  color: #0073aa;
  text-decoration: none;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.news-title-link:hover {
  color: #005177;
  text-decoration: underline;
}

@keyframes ticker-scroll {
  0% {
    transform: translateX(100%);
  }
  100% {
    transform: translateX(-100%);
  }
}

.news-ticker-wrapper:hover .news-ticker {
  animation-play-state: paused;
}

/* Button Primary Search
-------------------------------------------------------------- */
.btn-primary {
  background-color: #1b4445;
  color: white;
  padding: 10px 20px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: bold;
}

.btn-primary:hover {
  background-color: #1b4446;
}

/* News
-------------------------------------------------------------- */
/* News Section Styles */
.news-column {
  padding: 1.5rem;
  border-radius: 10px;
}

.news-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.news-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.news-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.news-thumb {
  flex: 0 0 80px;
}

.news-thumb img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 4px;
}

.news-text {
  flex: 1;
}

.news-link {
  font-weight: bold;
  color: #1b4445;
  display: block;
  margin-bottom: 0.3rem;
  text-decoration: none;
}

.news-link:hover {
  text-decoration: underline;
  color: #143536;
}

.news-date {
  font-size: 0.85rem;
  color: #666;
  margin: 0;
}

.book-title a { color: inherit; text-decoration: none; }
.book-title a:hover { text-decoration: underline; }

/* Wrapper hero χωρίς crop (object-fit: contain) */
.featured-image--hero.no-crop{
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  background: #f3f6f6;            /* χρώμα “καμβά” πίσω από την εικόνα */
  display: flex;                   /* για κεντράρισμα του img αν δεν γεμίζει */
  align-items: center;
  justify-content: center;
  /* “Κόφτης” ύψους για να μην πιάνει πολύ χώρο */
  max-height: clamp(260px, 48vh, 520px);
}

/* Αναλογία ανάλογα με προσανατολισμό (λιγότερα κενά) */
.featured-image--hero.no-crop.is-landscape { aspect-ratio: 16/9; }
.featured-image--hero.no-crop.is-portrait  { aspect-ratio: 3/4;  }

/* Εικόνα: γεμίζει όσο γίνεται, ΧΩΡΙΣ crop */
.featured-image--hero.no-crop .featured-image__img{
  width: 100%;
  height: 100%;
  object-fit: contain;             /* <-- χωρίς crop */
  display: block;
}

/* Λίγο πιο “σφιχτά” σε tablet/mobile */
@media (max-width: 992px){
  .featured-image--hero.no-crop { max-height: clamp(240px, 42vh, 460px); }
}
@media (max-width: 600px){
  .featured-image--hero.no-crop { 
    aspect-ratio: 4/3;             /* πιο ήπια αναλογία σε κινητό */
    max-height: clamp(220px, 40vh, 420px);
  }
}


/* =Mobile Menu Styles
-------------------------------------------------------------- */
/* Mobile Menu Toggle - hidden on desktop */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1000;
}

.hamburger {
  display: block;
  width: 25px;
  height: 2px;
  background: white;
  position: relative;
}

.hamburger:before,
.hamburger:after {
  content: "";
  position: absolute;
  width: 25px;
  height: 2px;
  background: white;
  left: 0;
}

.hamburger:before {
  top: -8px;
}

.hamburger:after {
  bottom: -8px;
}

/* Mobile styles */
@media (max-width: 768px) {
  .menu-toggle {
    display: block;
    order: 1;
  }

  .main-menu {
    display: none;
    width: 100%;
    order: 4;
    background-color: #143536;
    padding: 20px 0;
  }

  .main-menu.active {
    display: block;
  }

  .main-menu .menu {
    flex-direction: column;
    gap: 10px;
  }

  .main-menu .menu li {
    margin: 0;
    padding: 0 15px;
  }

  .main-menu .menu li a {
    display: block;
    padding: 10px 0;
  }

  /* Adjust header layout for mobile */
  .header-flex {
    padding: 15px;
  }

  .logo {
    order: 0;
  }

  .site-title {
    order: 2;
    font-size: 1.8rem;
    margin: 15px 0;
    width: 100%;
  }

  .auth-buttons {
    order: 3;
    margin: 15px auto 0;
    justify-content: center;
    width: 100%;
  }
}

/* Single News Post Styles */
.single-news-container {
  max-width: 800px;
  margin: 2rem auto;
  padding: 0 1rem;
}

.featured-image {
  margin-bottom: 2rem;
}

.news-featured-img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.entry-header {
  margin-bottom: 2rem;
  text-align: center;
}

.entry-title {
  color: #1b4445;
  margin-bottom: 0.5rem;
}

.entry-meta {
  color: #666;
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.entry-content {
  line-height: 1.6;
  font-size: 1.1rem;
}

.entry-content p {
  margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
  .single-news-container {
    padding: 0 15px;
  }

  .entry-title {
    font-size: 1.8rem;
  }
}

/* Single News with Sidebar Layout */
.single-news-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 40px;
  justify-content: start;
  margin-left: 0;
  padding-left: 0;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.single-news-content {
  max-width: 100%;
}

.single-news-sidebar {
  padding: 20px;
  background: #f7f7f7;
  border-radius: 8px;
  align-self: start;
}

.widget {
  margin-bottom: 30px;
}

.widget:last-child {
  margin-bottom: 0;
}

.widget-title {
  color: #1b4445;
  font-size: 1.2rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #1b4445;
}

/* Responsive styles */
@media (max-width: 992px) {
  .single-news-grid {
    grid-template-columns: 1fr;
  }

  .single-news-sidebar {
    margin-top: 40px;
  }
}

/* Dashboard CSS */
.dashboard-container {
  text-align: center;
}
/* Tabs styles */
.tabs {
  max-width: 900px;
  margin: 20px auto;
  font-family: Arial, sans-serif;
}

.tab-buttons {
  display: flex;
  border-bottom: 2px solid #ccc;
}

.tab-buttons button {
  flex: 1;
  padding: 12px 15px;
  cursor: pointer;
  background: #f7f7f7;
  border: none;
  border-bottom: 3px solid transparent;
  font-size: 16px;
  transition: border-color 0.3s;
}

.tab-buttons button.active {
  border-bottom: 3px solid #1b4445; /* Green */
  background: #fff;
  font-weight: bold;
}

.tab-content {
  border: 1px solid #ccc;
  border-top: none;
  padding: 20px;
  background: #fff;
}

.table-responsive {
  overflow-x: auto;
}

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

th,
td {
  border: 1px solid #ddd;
  padding: 10px;
  text-align: left;
}

th {
  background: #f0f0f0;
}

.cancel-request-btn {
  background-color: #d9534f;
  border: none;
  color: white;
  padding: 6px 12px;
  cursor: pointer;
  border-radius: 3px;
  font-size: 14px;
  transition: background-color 0.2s ease;
}

.cancel-request-btn:hover {
  background-color: #c9302c;
}

html, body {
  height: 100%;
  margin: 0;
}

.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.dashboard-container {
  flex: 1;
}

/* Single Book CSS */
 .single-book {
        max-width: 1200px;
        margin: 40px auto;
        padding: 30px 40px;
        background: #fff;
        border-radius: 12px;
        border: 1px solid #ddd;
        box-shadow: 0 4px 10px rgb(0 0 0 / 0.05);
        font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
        color: #333;
    }
    .single-book h1 {
        color: #1b4445;
        margin-bottom: 25px;
        font-weight: 700;
        font-size: 2.4rem;
        border-bottom: 2px solid #1b4445;
        padding-bottom: 8px;
    }
    .single-book img {
        max-width: 300px;
        height: auto;
        float: left;
        margin-right: 35px;
        margin-bottom: 25px;
        border-radius: 10px;
        box-shadow: 0 4px 15px rgb(27 68 69 / 0.15);
    }
    .single-book .meta p {
        font-size: 16px;
        line-height: 1.5;
        margin: 6px 0;
    }
    .single-book .meta strong {
        display: inline-block;
        width: 110px;
        font-weight: 600;
        color: #1b4445;
    }
    .single-book .clear {
        clear: both;
    }
    .single-book .content {
        margin-top: 30px;
        line-height: 1.6;
        font-size: 17px;
    }
    .reservation-form {
        margin-top: 45px;
        padding-top: 25px;
        border-top: 1px solid #ccc;
    }
    .reservation-form label {
        font-weight: 600;
        font-size: 1rem;
        color: #1b4445;
    }
    .reservation-form input[type="date"] {
        padding: 8px 12px;
        margin: 10px 0 20px 0;
        border: 1px solid #ccc;
        border-radius: 6px;
        font-size: 1rem;
        width: 180px;
        transition: border-color 0.3s ease;
    }
    .reservation-form input[type="date"]:focus {
        border-color: #1b4445;
        outline: none;
        box-shadow: 0 0 8px rgb(27 68 69 / 0.4);
    }
    .reservation-form button {
        background-color: #1b4445;
        color: white;
        border: none;
        padding: 12px 26px;
        border-radius: 8px;
        font-size: 1rem;
        cursor: pointer;
        transition: background-color 0.3s ease;
    }
    .reservation-form button:hover {
        background-color: #15514e;
    }
    .reservation-message {
        margin-top: 15px;
        font-weight: 600;
        font-size: 1rem;
    }
    .reservation-message.success {
        color: #228B22;
    }
    .reservation-message.error {
        color: #d33;
    }
    .login-prompt {
        margin-top: 40px;
        font-size: 1rem;
    }
    .login-prompt a {
        color: #1b4445;
        font-weight: 600;
        text-decoration: underline;
    }
    
    .login-register-wrapper {
    display: flex;
    gap: 40px;
    max-width: 700px;
    margin: 40px auto;
}
.login-form, .register-form {
    flex: 1;
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
}
.login-form h2, .register-form h2 {
    margin-bottom: 20px;
}
.login-form input, .register-form input {
    width: 100%;
    padding: 8px;
    margin-top: 5px;
    margin-bottom: 15px;
}
    
    .reservation-message.success { color: green; }
    .reservation-message.error { color: red; }
    .reservation-info { margin-top: 20px; background: #f9f9f9; padding: 10px; border-radius: 6px; }
    
/* Page Book Search CSS */
 .book-search-wrapper {
        background: #f5f7f7;
        padding: 40px 20px;
    }

    .book-search-form {
        background: #fff;
        border: 2px solid #1b4445;
        padding: 30px;
        border-radius: 12px;
        margin: 0 auto 40px;
    }

    .book-search-form h2 {
        color: #1b4445;
        margin-bottom: 30px;
        text-align: center;
    }

    .book-form-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 20px;
    }

    .book-search-form label {
        font-weight: bold;
        margin-bottom: 5px;
        display: block;
    }

    .book-search-form input,
    .book-search-form select {
        width: 100%;
        padding: 8px;
        border: 1px solid #ccc;
        border-radius: 6px;
        margin-bottom: 10px;
    }

    .book-search-form button {
        margin-top: 20px;
        background: #1b4445;
        color: #fff;
        padding: 10px 20px;
        border: none;
        border-radius: 8px;
        cursor: pointer;
        display: block;
        width: 200px;
        margin-left: auto;
        margin-right: auto;
    }

    .book-grid {
        display: grid;
        gap: 20px;
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }

    .book-card {
        background: #fff;
        border: 1px solid #ddd;
        border-radius: 12px;
        padding: 15px;
        text-align: center;
    }

    .book-card img {
        max-width: 100%;
        border-radius: 8px;
        height: 200px;
        object-fit: cover;
    }

    .book-card h3 {
        margin: 15px 0 5px;
        color: #1b4445;
    }

    .book-meta {
        font-size: 14px;
        color: #444;
        margin-bottom: 15px;
    }

    .btn {
        display: inline-block;
        background: #1b4445;
        color: #fff;
        padding: 8px 15px;
        text-decoration: none;
        border-radius: 5px;
        margin-top: 10px;
    }

    .pagination {
        text-align: center;
        margin-top: 40px;
    }

    .pagination a,
    .pagination span {
        display: inline-block;
        padding: 8px 12px;
        margin: 0 5px;
        border: 1px solid #1b4445;
        border-radius: 5px;
        color: #1b4445;
        text-decoration: none;
    }

    .pagination .current {
        background-color: #1b4445;
        color: white;
    }
	
	@media (max-width: 768px) {
  .book-form-grid {
    grid-template-columns: 1fr !important;
    gap: 15px !important;
  }

  .book-search-form {
    padding: 20px !important;
  }

  .book-search-form button {
    width: 100% !important;
    max-width: 100% !important;
    margin: 20px 0 0 0 !important;
  }
}


/************ HEADER + NAV (FINAL) ************/

/* Πράσινη κορδέλα – ίδιο OpenData */
.site-header{
  background:#1b4445;
  color:#fff;
  padding:10px 0;
  box-shadow:0 2px 4px rgba(0,0,0,.1);
  border-bottom:10px solid #143536; /* η σκούρα πράσινη μπάρα */
  position:relative;
  z-index:100;
  margin:0;
}

/* Container του header – ΜΟΝΟ εδώ flex (όχι global .container) */
.site-header .container.library-topbar{
  position:relative;
  display:flex;
  justify-content:space-between;
  align-items:center;
  max-width:1200px;
  margin:0 auto;
  padding:0 20px;
}

/* Logo πάντα αριστερά και στην ίδια ευθεία με το burger */
.library-topbar .logo{display:flex;align-items:center;flex:0 0 auto;margin:0}
.library-topbar .logo img{display:block;max-height:90px;width:auto;margin:0}

/* Τίτλος απολύτως κεντραρισμένος στο desktop */
.site-header .site-title{
  position:absolute;left:50%;transform:translateX(-50%);
  margin:0;font-size:1.5rem;font-weight:700;color:#fff;white-space:nowrap;text-align:center;
}

/* Login δεξιά */
.auth-buttons{display:flex;gap:10px}
.auth-buttons .btn{
  background:#fff;color:#1b4445;padding:8px 14px;border-radius:6px;
  font-weight:700;text-decoration:none;line-height:1
}
.auth-buttons .btn:hover{filter:brightness(.95)}

/* Burger μέσα στο πράσινο, πάνω δεξιά (κρυφό σε desktop) */
.menu-toggle.header-toggle{
  display:none;position:absolute;top:14px;right:16px;background:none;border:0;
  font-size:1.6rem;color:#fff;cursor:pointer;z-index:999
}

/* Λευκή μπάρα μενού (desktop) – χωρίς extra γραμμές πάνω */
.main-nav{background:#fff;border:0;margin:0;padding:0}
.main-nav::before{display:none}
.main-nav .container.nav-container{
  display:flex;align-items:center;gap:16px;max-width:1200px;margin:0 auto;padding:0 20px;
}
.main-nav .menu{
  list-style:none;margin:0;padding:10px 0;display:flex;gap:20px;flex-wrap:wrap;
}
.main-nav .menu>li{margin:0;position:relative}
.main-nav .menu>li>a{
  color:#000;text-decoration:none;padding:10px 6px;font-weight:600;transition:background-color .3s
}
.main-nav .menu>li>a:hover{background:rgba(0,0,0,.04);border-radius:4px}
.main-nav .menu li.current-menu-item>a{text-decoration:underline}

/* Submenu (desktop) */
.main-nav .menu li ul{
  position:absolute;left:0;top:calc(100% + 8px);background:#fff;border:1px solid #e6e6e6;
  border-radius:8px;list-style:none;padding:8px 0;min-width:200px;display:none;z-index:50;
  box-shadow:0 10px 24px rgba(0,0,0,.08)
}
.main-nav .menu li:hover>ul{display:block}
.main-nav .menu li ul li a{padding:8px 12px;display:block;color:#123}
.main-nav .menu li ul li a:hover{background:#f5f7f7}

/* ========== MOBILE/TABLET (<=1024px) ========== */
@media (max-width:1024px){
  /* Πάνω σειρά: logo αριστερά, burger δεξιά */
  .menu-toggle.header-toggle{display:block}
  .site-header .container.library-topbar{
    display:flex !important;flex-wrap:wrap !important;flex-direction:row !important;
    justify-content:space-between !important;align-items:center !important;padding-top:10px !important;
  }
  .library-topbar .logo{order:1 !important}
  .menu-toggle.header-toggle{order:2 !important;margin-left:auto !important}
  /* Στο mobile να κρύβεται από την κορδέλα και να εμφανίζεται στο μενού */
@media (max-width:1024px){
  .auth-buttons{display:none !important}
  .main-nav .auth-buttons{
    display:flex !important;
    flex-direction:column;
    gap:10px;
    padding:10px 0;
  }
  .main-nav .auth-buttons .btn{
    background:#fff;color:#1b4445;padding:10px 14px;
    border-radius:6px;font-weight:700;text-align:center;
  }
}


  /* Τίτλος: κατεβαίνει σε δεύτερη γραμμή, αριστερά (όπως ζήτησες) */
  .site-header .site-title{
    order:3 !important;position:relative !important;left:auto !important;transform:none !important;
    width:100% !important;margin:8px 0 0 0 !important;text-align:left !important;white-space:normal !important;
  }

  /* Μενού ανοίγει κάτω από την πράσινη μπάρα, ΠΡΑΣΙΝΟ όπως OpenData */
  .main-nav{background:#1b4445;border:0;margin:0}
  .main-nav .menu{display:none;flex-direction:column;width:100%;padding:0;gap:0}
  .main-nav .menu.mobile-visible{display:flex}
  .main-nav .menu li{margin:0}
  .main-nav .menu li a{color:#fff;display:block;padding:12px 0;border-bottom:1px solid rgba(255,255,255,.2)}
  .main-nav .menu li.current-menu-item>a{text-decoration:underline}
}

/* Ασφάλεια: κανένα burger μέσα στο nav */
.main-nav .menu-toggle{display:none !important}


/* ===== Mobile: auth buttons δεξιά, με απόσταση από το μενού ===== */
@media (max-width: 1024px) {
  /* Κάνε τη στήλη του nav "καθαρή" στοίχιση */
  .main-nav .nav-container {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    padding: 0 20px; /* λίγο οριζόντιο padding */
  }

  /* Μενού πρώτο */
  .main-nav .menu {
    order: 1;
  }

  /* Auth block δεύτερο, δεξιά και με «αέρα» από το μενού */
  .main-nav .auth-buttons--nav {
    order: 2;
    display: none;              /* θα ανοίγει με την .is-open */
    margin-top: 12px;           /* απόσταση από τα items του μενού */
    align-self: flex-end;       /* σπρώξε όλο το block δεξιά */
    gap: 10px;
  }

  /* Όταν ανοίγει το burger */
  .main-nav.is-open .auth-buttons--nav {
    display: flex;
  }

  /* Κουμπιά όμορφα, σε σειρά δεξιά */
  .main-nav .auth-buttons--nav .btn {
    display: inline-block;
    background: #fff;
    color: #1b4445;
    padding: 10px 14px;
    border-radius: 6px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
  }
}

/* ===== ΜΟΝΟ Desktop ===== */
@media (max-width: 1024px) {
  .auth-buttons {
    display: none !important;
  }
}

/* ===== ΜΟΝΟ Mobile ===== */
@media (min-width: 1025px) {
  .auth-buttons--nav {
    display: none !important;
  }
}
