@import url("https://fonts.googleapis.com/css2?family=Google+Sans+Flex:opsz,wght@6..144,300..800&display=swap");

/* =====================================================
   VARIÁVEIS
===================================================== */

:root {
  --green-900: #174d24;
  --green-800: #21682d;
  --green-700: #2e7d32;
  --green-600: #3b9140;
  --green-500: #4cae50;
  --green-200: #cfe8d1;
  --green-100: #e8f5e9;
  --green-50: #f4faf4;

  --orange-600: #e76f00;
  --orange-100: #fff1e5;

  --text-primary: #263238;
  --text-secondary: #616b66;
  --text-light: #7c8781;

  --border-color: #dce5de;
  --background-page: #f7faf7;
  --white: #ffffff;

  --shadow-small: 0 3px 12px rgba(34, 72, 42, 0.08);
  --shadow-medium: 0 8px 26px rgba(34, 72, 42, 0.12);
}

/* =====================================================
   CONFIGURAÇÕES GERAIS
===================================================== */

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

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: "Google Sans Flex", sans-serif;
  color: var(--text-primary);
  background: var(--background-page);
}

button,
input,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: none;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* =====================================================
   CABEÇALHO
===================================================== */

.acervo-header {
  width: 100%;
  min-height: 360px;

  background-image: url("../img/matriz.jpg");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;

  position: relative;
}

.acervo-header-overlay {
  width: 100%;
  min-height: 360px;

  display: flex;
  align-items: flex-end;
  justify-content: center;

  padding: 34px 0 0;

  background: linear-gradient(
    90deg,
    rgba(12, 35, 18, 0.34),
    rgba(10, 28, 15, 0.12)
  );
}

/* =====================================================
   CAIXA DE PESQUISA
===================================================== */

.search-box {
  width: min(1220px, 92%);
  margin: 0 0 -48px;

  position: relative;
  z-index: 20;

  min-height: 165px;
  padding: 22px 28px;

  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(46, 125, 50, 0.14);
  border-radius: 18px;

  box-shadow: 0 12px 34px rgba(21, 52, 29, 0.18);
}

.search-tabs {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 18px;
}

.search-tab {
  flex-shrink: 0;
  position: relative;
  padding: 10px 14px;
  color: var(--text-secondary);
  background: transparent;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease;
}

.search-tab:hover {
  color: var(--green-800);
  background: var(--green-50);
}

.search-tab.active {
  color: var(--white);
  background: var(--green-600);
}

.search-tab.active::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -9px;
  width: 28px;
  height: 3px;
  border-radius: 3px;
  background: var(--green-600);
  transform: translateX(-50%);
}

.search-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px 48px;
  gap: 12px;
  align-items: center;
}

.search-input-wrapper {
  height: 48px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0 15px;
  background: var(--white);
  border: 1px solid #cbd6ce;
  border-radius: 10px;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.search-input-wrapper:focus-within {
  border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(59, 145, 64, 0.12);
}

.search-input-wrapper i {
  color: var(--green-600);
  font-size: 17px;
}

.search-input {
  width: 100%;
  height: 100%;
  color: var(--text-primary);
  background: transparent;
  border: none;
  outline: none;
  font-size: 15px;
}

.search-input::placeholder {
  color: #89918d;
}

.search-filter {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  color: var(--text-primary);
  background: var(--white);
  border: 1px solid #cbd6ce;
  border-radius: 10px;
  outline: none;
  cursor: pointer;
}

.search-filter:focus {
  border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(59, 145, 64, 0.12);
}

.search-button {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  color: var(--white);
  background: var(--green-600);
  border-radius: 10px;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    background-color 0.2s ease,
    box-shadow 0.2s ease;
}

.search-button i {
  font-size: 19px;
}

.search-button:hover {
  background: var(--green-700);
  box-shadow: 0 7px 15px rgba(46, 125, 50, 0.22);
  transform: translateY(-2px);
}

.search-history {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  color: var(--green-700);
  font-size: 14px;
  font-weight: 650;
  transition: color 0.2s ease;
}

.search-history:hover {
  color: var(--green-500);
}

.search-history span {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* =====================================================
   SEÇÃO DE RESULTADOS
===================================================== */

.results-section {
  width: 100%;
  padding: 96px 2% 60px;
  background: var(--background-page);
}

.results-toolbar {
  width: min(2000px, 100%);
  min-height: 72px;
  padding: 24px 26px;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  color: var(--white);
  background: linear-gradient(110deg, var(--green-600), var(--green-700));
  border-radius: 12px;
  box-shadow: var(--shadow-small);
}

.results-summary {
  display: flex;
  align-items: center;
  gap: 16px;
}

.results-summary > i {
  font-size: 25px;
}

.results-summary h1 {
  margin-bottom: 4px;
  font-size: 18px;
  font-weight: 650;
}

.results-summary h1 span {
  color: #d8f5b0;
  font-size: 15px;
}

.results-summary p {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.88);
}

.results-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.results-actions label {
  font-size: 13px;
}

.sort-select {
  min-width: 160px;
  height: 42px;
  padding: 0 13px;
  color: var(--text-primary);
  background: var(--white);
  border: none;
  border-radius: 8px;
  outline: none;
  cursor: pointer;
}

.view-buttons {
  display: flex;
  align-items: center;
  gap: 5px;
}

.view-button {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.72);
  background: transparent;
  border-radius: 7px;
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease;
}

.view-button:hover,
.view-button.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.16);
}

.toolbar-control {
  display: flex;
  align-items: center;
  gap: 9px;
}

.toolbar-control label {
  color: rgba(255, 255, 255, 0.95);
  font-size: 13px;
  font-weight: 550;
  white-space: nowrap;
}

.items-per-page-select {
  min-width: 72px;
  height: 42px;
  padding: 0 12px;
  color: var(--text-primary);
  background: var(--white);
  border: none;
  border-radius: 8px;
  outline: none;
  cursor: pointer;
  transition:
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

.items-per-page-select:hover {
  transform: translateY(-1px);
}

.items-per-page-select:focus {
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.24);
}

/* =====================================================
   LAYOUT: FILTROS + RESULTADOS
===================================================== */

.results-layout {
  width: min(2000px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 325px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

/* =====================================================
   FILTROS
===================================================== */

.filters-sidebar {
  padding: 22px;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: var(--shadow-small);
}

.filters-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 17px;
  border-bottom: 1px solid var(--border-color);
}

.filters-title h2 {
  font-size: 17px;
  font-weight: 700;
}

.filters-title i {
  color: var(--green-600);
}

.filter-box {
  padding: 20px 0;
  border-bottom: 1px solid var(--border-color);
}

.filter-box h3 {
  margin-bottom: 13px;
  color: var(--green-700);
  font-size: 14px;
  font-weight: 700;
}

.filter-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 11px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
}

.filter-option:last-child {
  margin-bottom: 0;
}

.filter-option span {
  display: flex;
  align-items: center;
  gap: 9px;
}

.filter-option input {
  width: 17px;
  height: 17px;
  accent-color: var(--green-600);
  cursor: pointer;
}

.filter-option small {
  color: var(--text-light);
  font-size: 12px;
}

.filter-search {
  height: 42px;
  display: flex;
  align-items: center;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 8px;
}

.filter-search:focus-within {
  border-color: var(--green-600);
  box-shadow: 0 0 0 3px rgba(59, 145, 64, 0.1);
}

.filter-search input {
  min-width: 0;
  flex: 1;
  height: 100%;
  padding: 0 12px;
  border: none;
  outline: none;
  background: transparent;
}

.filter-search button {
  width: 42px;
  height: 100%;
  color: var(--text-secondary);
  background: transparent;
  cursor: pointer;
}

.clear-filters {
  width: 100%;
  height: 42px;
  margin-top: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--green-700);
  background: var(--white);
  border: 1px solid var(--green-200);
  border-radius: 8px;
  font-weight: 650;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.clear-filters:hover {
  background: var(--green-50);
  border-color: var(--green-600);
}

/* =====================================================
   CARDS DOS LIVROS
===================================================== */

.results-content {
  min-width: 0;
}

.results-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.book-card {
  min-height: 180px;
  padding: 16px 18px;
  position: relative;
  display: grid;
  grid-template-columns: 34px 90px minmax(0, 1fr);
  gap: 18px;
  background: var(--white);
  border: 1px solid #e0e7e1;
  border-radius: 12px;
  box-shadow: var(--shadow-small);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    border-color 0.22s ease;
}

.book-card:hover {
  border-color: var(--green-200);
  box-shadow: var(--shadow-medium);
  transform: translateY(-2px);
}

.result-number {
  width: 25px;
  height: 25px;
  margin-top: 3px;
  display: grid;
  place-items: center;
  color: var(--white);
  background: var(--green-600);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
}

.book-cover {
  width: 86px;
  height: 128px;
  overflow: hidden;
  align-self: center;
  background: var(--green-50);
  border-radius: 7px;
  box-shadow: 0 5px 13px rgba(31, 47, 35, 0.18);
}

.book-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-information {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.book-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
}

.book-title {
  display: inline-block;
  color: #253036;
  font-size: 19px;
  font-weight: 750;
  line-height: 1.22;
  transition: color 0.2s ease;
}

.book-title:hover {
  color: var(--green-700);
}

.book-author {
  margin-top: 4px;
  color: var(--green-600);
  font-size: 13px;
  font-weight: 650;
}

.availability-wrapper {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 5px;
}

.availability-wrapper small {
  color: var(--text-secondary);
  font-size: 11px;
  white-space: nowrap;
}

.availability {
  flex-shrink: 0;
  min-height: 28px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 750;
  text-transform: uppercase;
}

.availability i {
  font-size: 9px;
}

.availability.available {
  color: var(--green-700);
  background: var(--green-100);
}

.availability.unavailable {
  color: var(--orange-600);
  background: var(--orange-100);
}

.book-metadata {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px 24px;
  margin-top: 12px;
}

.book-metadata span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text-secondary);
  font-size: 13px;
}

.book-metadata i {
  color: var(--green-600);
}

.book-description {
  max-width: 800px;
  margin-top: 11px;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.4;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
}

.book-footer {
  margin-top: auto;
  padding-top: 12px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.book-tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.book-tags span {
  padding: 4px 10px;
  color: var(--green-700);
  background: var(--green-50);
  border: 1px solid var(--green-200);
  border-radius: 15px;
  font-size: 11px;
  font-weight: 650;
}

.book-actions {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 9px;
}

.button-details,
.button-reserve,
.button-queue {
  min-height: 38px;
  padding: 0 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.button-details {
  color: var(--text-primary);
  background: var(--white);
  border: 1px solid var(--green-200);
}

.button-details i {
  color: var(--green-700);
}

.button-details:hover {
  background: var(--green-50);
  border-color: var(--green-600);
}

.button-reserve {
  color: var(--white);
  background: var(--green-600);
  border: 1px solid var(--green-600);
}

.button-reserve:hover {
  background: var(--green-700);
  border-color: var(--green-700);
  transform: translateY(-1px);
}

.button-queue {
  color: var(--green-700);
  background: var(--white);
  border: 1px solid var(--green-600);
}

.button-queue:hover {
  background: var(--green-50);
  transform: translateY(-1px);
}

/* =====================================================
   PAGINAÇÃO
===================================================== */

.pagination {
  min-height: 55px;
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
}

.pagination button {
  width: 35px;
  height: 35px;
  display: grid;
  place-items: center;
  color: var(--text-secondary);
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 7px;
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease;
}

.pagination button:hover {
  color: var(--green-700);
  border-color: var(--green-600);
}

.pagination button.active {
  color: var(--white);
  background: var(--green-600);
  border-color: var(--green-600);
}

.pagination span {
  position: absolute;
  right: 0;
  color: var(--text-secondary);
  font-size: 13px;
}

/* =====================================================
   SEM RESULTADOS
===================================================== */

.no-results {
  min-height: 230px;
  padding: 40px;
  display: grid;
  place-items: center;
  color: var(--text-secondary);
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  font-size: 17px;
  font-weight: 600;
}

/* =====================================================
   RESPONSIVIDADE
===================================================== */


/* Telas até 1150px */
@media (max-width: 1150px) {
  .results-layout {
    grid-template-columns: 245px minmax(0, 1fr);
  }

  .book-card {
    grid-template-columns: 30px 78px minmax(0, 1fr);
    gap: 14px;
  }

  .book-cover {
    width: 76px;
    height: 114px;
  }

  .book-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .book-actions {
    width: 100%;
    justify-content: flex-end;
  }
}

/* Telas até 900px */
@media (max-width: 900px) {
  .acervo-header,
  .acervo-header-overlay {
    min-height: 360px;
  }

  .search-form {
    grid-template-columns: 1fr 160px 48px;
  }

  .results-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .results-actions {
    width: 100%;
  }

  .results-layout {
    grid-template-columns: 1fr;
  }

  .filters-sidebar {
    width: 100%;
  }

  .filter-box {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 20px;
  }

  .filter-box h3 {
    grid-column: 1 / -1;
  }

}

/* Telas até 700px */
@media (max-width: 700px) {
  .search-tabs {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    width: 100%;
    margin-bottom: 18px;
    overflow: visible;
  }

  .search-tab:nth-child(1),
  .search-tab:nth-child(2) {
    grid-column: span 3;
  }

  .search-tab:nth-child(3),
  .search-tab:nth-child(4),
  .search-tab:nth-child(5) {
    grid-column: span 2;
  }

  .search-tab {
    flex: 0 0 auto;
    padding: 9px 14px;
    border: 1px solid var(--green-200);
    border-radius: 999px;
    background: var(--white);
    font-size: 13px;
  }

  .search-tab.active {
    color: var(--white);
    background: var(--green-600);
    border-color: var(--green-600);
  }

  .search-tab.active::after {
    display: none;
  }

  .acervo-logo-box {
    left: 20px;
    width: 135px;
  }

  .acervo-login {
    right: 20px;
    padding: 0 16px;
  }

  .search-box {
    width: 100%;
    padding: 18px;
  }

  .search-form {
    display: grid;

    grid-template-columns: minmax(0, 1fr) 52px;
    gap: 10px;

    width: 100%;
  }

  /* Campo de pesquisa ocupa a primeira linha inteira */
  .search-input-wrapper {
    grid-column: 1 / -1;
    width: 100%;
  }

  /* Select ocupa o espaço disponível */
  .search-filter {
    grid-column: 1;
    width: 100%;
    height: 48px;
  }

  /* Botão fica ao lado do select */
  .search-button {
    grid-column: 2;

    width: 52px;
    height: 48px;

    display: grid;
    place-items: center;

    padding: 0;

    color: var(--white);
    background: var(--green-600);

    border: none;
    border-radius: 10px;
  }

  .results-section {
    padding-inline: 16px;
  }

  .results-actions {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .book-card {
    grid-template-columns: 27px 72px minmax(0, 1fr);
    padding: 14px;
  }

  .book-cover {
    width: 70px;
    height: 105px;
  }

  .book-heading {
    flex-direction: column;
    gap: 8px;
  }

  .availability-wrapper {
    align-items: flex-start;
  }

  .availability {
    align-self: flex-start;
  }

  .book-metadata {
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }

  .book-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .button-details,
  .button-reserve,
  .button-queue {
    width: 100%;
  }

  .pagination span {
    position: static;
    margin-left: 10px;
  }
}

/* Telas até 520px */
@media (max-width: 520px) {
  .acervo-logo-box {
    width: 115px;
  }

  .acervo-login span {
    display: none;
  }

  .acervo-login {
    width: 44px;
    padding: 0;
  }

  .results-toolbar {
    padding: 18px;
  }

  .results-actions {
    flex-direction: column;
  }

  .sort-select {
    width: 100%;
  }

  .view-buttons {
    display: none;
  }

  .filter-box {
    grid-template-columns: 1fr;
  }

  .filter-box h3 {
    grid-column: auto;
  }

  .book-card {
    grid-template-columns: 1fr;
  }

  .result-number {
    position: absolute;
    top: 16px;
    left: 16px;
  }

  .book-cover {
    grid-column: 1;
    width: 110px;
    height: 165px;
    margin: 0 auto 10px;
    justify-self: center;
  }

  .book-information {
    grid-column: 1;
    width: 100%;
  }

  .book-title {
    font-size: 18px;
  }

  .book-footer {
    align-items: stretch;
  }

  .pagination {
    flex-wrap: wrap;
  }

  .pagination span {
    width: 100%;
    margin: 5px 0 0;
    text-align: center;
  }
}

/* =====================================================
   RESPONSIVIDADE — NOTEBOOKS
   Preserva a navegação desktop e compacta a área útil.
===================================================== */
@media (min-width: 1151px) and (max-width: 1440px) {

  .acervo-header,
  .acervo-header-overlay {
    min-height: 340px;
  }

  .search-box {
    width: min(1120px, 94%);
    min-height: 150px;
    padding: 20px 24px;
  }

  .search-form {
    grid-template-columns: minmax(0, 1fr) 165px 48px;
  }

  .results-section {
    padding: 62px 1.5% 50px;
  }

  .results-layout {
    grid-template-columns: 270px minmax(0, 1fr);
  }

  .filters-sidebar {
    padding: 18px;
  }

  .results-toolbar {
    padding: 20px 22px;
  }

  .book-card {
    min-height: 164px;
    padding: 14px 16px;
    grid-template-columns: 30px 80px minmax(0, 1fr);
    gap: 14px;
  }

  .book-cover {
    width: 78px;
    height: 116px;
  }
}

@media (min-width: 901px) and (max-width: 1150px) {

  .acervo-header,
  .acervo-header-overlay {
    min-height: 340px;
  }

  .search-box {
    width: 94%;
    padding: 20px 22px;
  }

  .search-form {
    grid-template-columns: minmax(0, 1fr) 150px 48px;
  }

  .results-section {
    padding: 58px 1.5% 45px;
  }

  .results-layout {
    grid-template-columns: 225px minmax(0, 1fr);
  }

  .filters-sidebar {
    padding: 16px;
  }

  .filter-box {
    padding: 16px 0;
  }

  .results-toolbar {
    padding: 18px;
    gap: 16px;
  }

  .results-actions {
    gap: 8px;
  }

  .sort-select {
    min-width: 140px;
  }

  .book-card {
    min-height: 154px;
    padding: 13px 14px;
    grid-template-columns: 28px 72px minmax(0, 1fr);
    gap: 12px;
  }

  .book-cover {
    width: 70px;
    height: 105px;
  }
}

@media (min-width: 901px) and (max-height: 850px) {
  .acervo-header,
  .acervo-header-overlay {
    min-height: 340px;
  }
}


/* =====================================================
   AJUSTE FINAL — ALINHAMENTO DOS BOTÕES DOS CARDS
   Mantém Detalhes + Reservar/Entrar na fila alinhados.
===================================================== */

@media (min-width: 701px) {
  .book-actions {
    margin-left: auto;
    display: grid;
    grid-template-columns: 118px 150px;
    align-items: center;
    justify-content: end;
    gap: 9px;
  }

  .button-details,
  .button-reserve,
  .button-queue {
    width: 100%;
    min-width: 0;
    min-height: 38px;
    padding-inline: 12px;
    white-space: nowrap;
  }
}

/* Em telas intermediárias, preserva as duas colunas sem
   deixar o bloco de ações variar conforme o texto. */
@media (min-width: 701px) and (max-width: 1150px) {
  .book-actions {
    width: auto;
    align-self: flex-end;
    grid-template-columns: 118px 150px;
  }
}

/* Mobile: dois botões proporcionais e alinhados lado a lado. */
@media (max-width: 700px) {
  .book-actions {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 8px;
    align-items: stretch;
  }

  .button-details,
  .button-reserve,
  .button-queue {
    width: 100%;
    min-width: 0;
    min-height: 40px;
    padding-inline: 8px;
    white-space: nowrap;
  }
}

/* Celulares muito estreitos: evita compressão excessiva. */
@media (max-width: 420px) {
  .book-actions {
    grid-template-columns: 1fr;
  }
}
