/* =========================
   cavvia.css  (static footer menu)
   Mobile-first
   ========================= */

/* --- Base / Global --- */
html { overflow-y: scroll; }
body { background-color: #fff; font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Open Sans", sans-serif; }

/* Cards & Buttons */
.card {
  border: 2px solid #000;
  border-radius: 10px;
  background-color: #fff;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 0;
}
.card-body {
  flex-grow: 1;
  padding: 0;
  border-top: 5px;
  border-color: black;
}
.card-body-no-border {
  flex-grow: 1;
  padding: 0;
  border: 0;
}
.btn-custom {
  background-color: #D9D9D9;
  color: #000;
  border: 2px solid #000;
  border-radius: 10px;
  font-size: clamp(12px, 2vw, 18px);
  padding: clamp(2px, 1.5vw, 6px) clamp(2px, 4vw,16px);
}
.card-title {
  height: clamp(20px, 2.5vw, 50px);
  overflow: hidden;
}
.card-text {
  word-wrap: break-word;
  overflow-wrap: break-word;
}
.image-container {
  height: 220px;
  display: flex;
  align-items: center;
  overflow: hidden;
  justify-content: center;
  background-color: #f8f9fa;
}
.form-control-custom {
  border: 2px solid #000;
  border-radius: 10px;
}
.support-data {
  background-color: #e9ecef;
  padding: 10px;
  border-left: 5px solid #007bff;
  margin: 20px 0;
}

/* Header */
.header {
  padding: 10px;
  text-align: left;
  border-bottom: 1px solid black;
  margin-bottom: 20px;
  position: relative;            /* keep if you rely on it elsewhere */
  display: flex;                 /* NEW: flex header */
  align-items: flex-end;         /* sit on baseline-ish */
  justify-content: space-between;
}
.header-title {
  /* removed: position:absolute; right:10px; bottom:5px; */
  position: static;
  font-size: clamp(10px, 2vw, 24px);
  font-family: 'Open Sans', sans-serif;
  color: black;
  white-space: nowrap;
}
.header-right {
  display: inline-flex;
  align-items: flex-end;
  gap: 0.5rem;                   /* small space between strapline and hamburger */
}
.logo { height: 40px; }
.hamburger {
  line-height: 1;
  border: none;
  background: transparent;
  color: #000;
  /* Match/track the strapline’s clamp, slightly larger for touch target */
  font-size: clamp(12px, 2.2vw, 26px);
  cursor: pointer;
}
.hamburger-icon {
  width: 1.25em;
  height: 1.25em;
  display: block;
  fill: currentColor;
}
/* Hero + Inner content shell */
.hero {
  width: 100%;
  display: block;
  border-radius: 8px;
}
.inner {
  width: 95%;
  min-width: 280px;
  max-width: 100%;
  margin: -40px auto 0;
  background: white;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  position: relative;
}


/* IMAGE */
/* match the height of normal images */
.fixed-img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);  /* center both axes */
  height: 100%;          /* lock height to container */
  width: auto !important;/* prevent Bootstrap's .card-img-top width:100% */
  max-width: none;       /* allow overflow for equal side cropping */
  display: block;
  border-radius: 0; 
}
.no-image {
  background-color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none; /* no underline */
}
.image-block {
  position: relative;
  height: 250px;
  background: #000;
  overflow: hidden;
  display: block;
  border-bottom: 10px solid #000;
}
/* Absolutely centered image whose width can be narrower (pillarbox) or wider (cropped) */
.image-block .card-img-top.fixed-img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);

  height: 100% !important;          /* scale by height */
  width: auto !important;            /* never force to container width */
  max-width: none !important;        /* defeat any img { max-width:100% } */

  display: block;
  border-radius: 0;
}
.image-block img {
  float: none !important;
  margin: 0 !important;
}
.no-image-block {
  background: #fff !important;                  /* white background restored */
  height: 250px;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.no-image-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.no-image-inner img {
  display: block;
}

.no-image-inner .text-muted {
  text-decoration: none; /* make sure text isn't underlined */
}

/* Equal gap, always 2 columns */
.compact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* 2 equal cols */
  gap: 0.5rem;  /* same horizontal + vertical spacing */
}

/* Equal spacing horizontally & vertically in compact rows */
.row.compact {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;   /* set equal horizontal + vertical gap */
  margin: 0;     /* reset Bootstrap row margins */
}

.row.compact > [class*="col-"] {
  padding: 0;    /* kill Bootstrap's column padding */
  margin: 0;
}

/* Square input fields */
.form-control-custom {
  border: 2px solid #000;
  border-radius: 0;         /* no rounded corners */
  font-size: 0.9rem;
  padding: .25rem .5rem;
}


/* Text scales */
.results-text { font-size: clamp(15px, 3vw, 32px); font-family: 'Open Sans', sans-serif; }
.results-text-small { font-size: clamp(8px, 2vw, 16px); font-family: 'Open Sans', sans-serif; }
.results-sub { display: block; font-size: 75%; }

/* Pagination */
.pagination .page-link {
  color: black;
  background-color: white;
  border: 1px solid black;
}
.pagination .page-link:hover {
  color: white;
  background-color: black;
}
.pagination .active .page-link {
  color: white;
  background-color: black;
  border-color: black;
}
.pagination-top {
  padding-bottom: 1rem;
}

/* Make the select look like a pagination link */
.pagination .pagination-select {
  appearance: none;           /* remove native arrows */
  -webkit-appearance: none;
  -moz-appearance: none;
  background: transparent;
  border: 1px solid #dee2e6;
  padding: .375rem .75rem;
  line-height: 1.25;
  height: calc(1.5em + .75rem + 2px);
  border-radius: .25rem;
}
/* Remove left radius to visually connect to previous page item */
.pagination .pagination-select {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-color: #fff;
  border: 1px solid #000;
  padding: .375rem 1.75rem .375rem .75rem; /* extra right padding for arrow */
  line-height: 1.25;
  height: calc(1.5em + .75rem + 2px);
  border-radius: 0; /* matches pagination link edges */
  margin-left: -1px; /* overlap like other pagination items */
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath fill='black' d='M0 0l5 6 5-6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .5rem center;
  background-size: .65rem;
}
/* Keep the whole card visually rounded and clip inner square corners */
.card {
  border-radius: .75rem;
  overflow: hidden; /* clip inner corners/images */
}


/* Utility title box */
.custom-title {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  font-size: 0.9rem;
  font-weight: bold;
  color: black;
  text-align: center;
  background-color: #f0f0f0;
  border: 1px solid #ccc;
  border-radius: 0.375rem;
}

/* Modals above everything */
.modal { z-index: 2000 !important; }
.modal-backdrop { z-index: 1999 !important; }

/* Legacy top menu (kept in case you re‑enable it) */
.menu-bar {
  padding: 3px 10px;
  border-bottom: 1px solid #000;
  margin-bottom: 20px;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.9rem;
  color: #000;
}
.menu-link { margin-right: 15px; text-decoration: none; color: #000; }
.menu-link:hover { text-decoration: underline; color: #000; }

/* Images inside cards */
.card img { 
  float: none !important;
  margin: 0 !important; 
}

/* ---------------------------------------
   Static Bottom Menu (footer-style)
   --------------------------------------- */

/* Base footer menu block */
.bottom-menu {
  background: #fff;
  border-top: 1px solid #000;
  width: 100%;
}

/* Layout */
.bm-content {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 1rem;
  padding: .75rem 1rem 1.25rem;
}

/* Brand area: centered logo + strapline underneath */
.bm-left .bm-brand {
  display: flex;
  flex-direction: column;
  align-items: center;   /* horizontal center */
  justify-content: center;
  text-decoration: none;
  text-align: center;
}
.bm-left .bm-logo { height: 40px; width: auto; }
.bm-strapline {
  display: block;
  margin-top: .25rem;
  font-size: 0.9rem;
  line-height: 1.2;
  color: #000;
}

/* Menu columns (no borders; use gaps) */
.bm-right .menu-columns {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: .75rem 1rem; /* row gap / column gap */
}
.menu-col { padding: 0 .5rem; }

/* Links (tighter spacing) */
.bm-link {
  display: block;
  padding: .35rem 0;
  line-height: 1.2;
  text-decoration: none;
  color: #000;
}
.bm-link:hover,
.bm-link:focus { text-decoration: underline; }
.site-footer {
  text-align: center;
  font-size: 0.9rem;       /* ~50% smaller than old footer text */
  padding: 0.75rem 0;      /* smaller vertical spacing */
  background: none;        /* no background color */
  border-top: none;        /* remove the line above */
  color: #000;
}

.site-footer p {
  margin: 0;
}
/* Force no-image variant to be white instead of black */
a.image-block.no-image {
  background-color: #fff !important;  /* override .image-block black */
}
/* Responsive number plate SVG */
.plate-svg {
  display: block;
  margin: 0 auto;      /* center horizontally */
  width: 50%;          /* default for desktop */
  height: auto;
}
/* ---------------------------------------
   Responsive
   --------------------------------------- */

@media (min-width: 576px) {
  .bm-right .menu-columns { grid-template-columns: 1fr; }
}

@media (min-width: 768px) {
  .logo { height: 90px; }
  .header { padding: 10px 20px; }
  .plate-svg {
    width: 25%;
  }
}

@media (min-width: 992px) {
  .bm-content { grid-template-columns: 1fr; }
  .bm-right .menu-columns { grid-template-columns: repeat(2, minmax(140px, 1fr)); }
  .bm-strapline { display: none !important; }
}

