/**
 * Maribilis Lexus — modern look.
 * Same structure and blue palette as the D7 Lexus site, with modern type,
 * spacing, cards and a responsive grid. Replaces style.css + media.css.
 */

:root {
  --lx-blue: #0094ca;
  --lx-blue-light: #01aff0;
  --lx-blue-mid: #21a8da;
  --lx-blue-dark: #00729c;
  --lx-ink: #0f2233;
  --lx-text: #334155;
  --lx-muted: #64748b;
  --lx-line: #e2e8f0;
  --lx-surface: #f6f9fc;
  --lx-table-head: #2e3d4a;
  --lx-wrap: 1200px;
  --lx-radius: 10px;
  --lx-shadow: 0 1px 2px rgba(15, 34, 51, .06), 0 4px 16px rgba(15, 34, 51, .06);
  --lx-font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #fff;
  color: var(--lx-text);
  font-family: var(--lx-font);
  font-size: 16px;
  line-height: 1.7;
  text-align: left;
  -webkit-font-smoothing: antialiased;
}
p { margin: 0 0 1em; text-align: left; }
a { color: var(--lx-blue); text-decoration: none; transition: color .15s; }
a:hover, a:focus { color: var(--lx-blue-dark); text-decoration: underline; text-underline-offset: 3px; }
img { max-width: 100%; height: auto; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--lx-font);
  color: var(--lx-ink);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -.01em;
  text-transform: none;
  margin: 0 0 .6em;
}
h1 { font-size: clamp(26px, 3vw, 34px); }
h2 { font-size: clamp(20px, 2.2vw, 24px); }
h3 { font-size: 18px; }
h4 { font-size: 16px; }

/* Content pasted from D7 often carries inline font styles — normalise them. */
#post-content [style*="font-family"],
#footer [style*="font-family"],
#top-area [style*="font-family"] { font-family: var(--lx-font) !important; }

.visually-hidden, .element-invisible {
  position: absolute !important; clip: rect(1px, 1px, 1px, 1px); overflow: hidden;
  height: 1px; width: 1px; word-wrap: normal;
}
.clearfix::after { content: ""; display: table; clear: both; }
/* Bootstrap's clearfix pseudo-elements become empty cells in grid/flex rows. */
#top-area .page-wrap::before, #top-area .page-wrap::after,
#footer-area::before, #footer-area::after,
#copyright::before, #copyright::after,
#header::before, #header::after,
#bottom-area::before, #bottom-area::after { display: none !important; content: none; }

#header,
.container-wrap,
.full-wrap {
  max-width: var(--lx-wrap);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* ---------- Header ---------- */
#header_wrapper { background: #fff; }
#header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 18px;
  padding-bottom: 18px;
}
.logo_wrap { flex: 1 1 auto; min-width: 0; }
#logo a { display: inline-block; }
#logo img { display: block; max-height: 96px; width: auto; max-width: 100%; }
#site-title { font-size: 22px; font-weight: 700; margin: 0; }
#site-title a { color: var(--lx-ink); }
#site-description { color: var(--lx-muted); font-size: 13px; }
#header .region { flex: 0 1 auto; max-width: 40%; font-size: 14px; color: var(--lx-muted); }
#header .region .block > h2 { display: none; }
#header .region p { margin: 0; }

/* ---------- Main menu (sticky) ---------- */
.menu-wrap {
  position: sticky;
  top: var(--drupal-displace-offset-top, 0px);
  z-index: 500;
  background: var(--lx-blue);
  box-shadow: 0 2px 10px rgba(0, 60, 90, .18);
}
#main-menu { position: relative; }
#main-menu ul { list-style: none; margin: 0; padding: 0; }
#main-menu > .menu-navigation-container > ul.menu {
  display: flex;
  flex-wrap: wrap;
  margin-left: -16px;
}
#main-menu li { position: relative; }
#main-menu a {
  display: block;
  padding: 16px 16px;
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  position: relative;
}
#main-menu > .menu-navigation-container > ul > li > a::after {
  content: "";
  position: absolute;
  left: 16px; right: 16px; bottom: 9px;
  height: 2px;
  background: #fff;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .2s ease;
}
#main-menu > .menu-navigation-container > ul > li > a:hover::after,
#main-menu > .menu-navigation-container > ul > li > a.is-active::after,
#main-menu > .menu-navigation-container > ul > li.active-trail > a::after { transform: scaleX(1); }
#main-menu a:hover { color: #fff; text-decoration: none; }

/* Dropdowns */
#main-menu li ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 230px;
  padding: 8px 0;
  background: #fff;
  border-radius: 0 0 var(--lx-radius) var(--lx-radius);
  box-shadow: var(--lx-shadow);
}
#main-menu li ul a {
  color: var(--lx-ink);
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
  font-size: 14px;
  padding: 9px 18px;
}
#main-menu li ul a:hover { background: var(--lx-surface); color: var(--lx-blue); }
#main-menu li ul ul { top: 0; left: 100%; border-radius: var(--lx-radius); }
#main-menu li:hover > ul,
#main-menu li:focus-within > ul { display: block; }
#main-menu .nav-toggle { display: none; }

/* ---------- Hero ---------- */
.slideshow,
.region-slideshow,
.region-slideshow .block { margin: 0; padding: 0; }
.region-slideshow .block > h2 { display: none; }
.region-slideshow img { display: block; width: 100%; }

/* ---------- Top feature boxes ---------- */
#top-area .page-wrap {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}
#top-area .column {
  background: var(--lx-blue-light);
  color: #fff;
  text-align: center;
  padding: 44px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
#top-area .column.two { background: var(--lx-blue); }
#top-area .column.three { background: var(--lx-blue-mid); }
#top-area .column.four { background: #49c9f9; }
#top-area .column.five { background: #36bff2; }
#top-area .column.six { background: #4fc8f5; }
#top-area .block { margin: 0; max-width: 460px; }
#top-area h2,
#top-area h3 {
  color: #fff;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: .02em;
  text-transform: uppercase;
  margin: 6px 0 12px;
}
#top-area p { text-align: center; color: rgba(255, 255, 255, .92); font-size: 15px; line-height: 1.65; margin-bottom: 14px; }
#top-area p:empty { display: none; }
#top-area .fa {
  display: inline-grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .16);
  font-size: 30px;
  color: #fff;
}
#top-area a {
  display: inline-block;
  margin-top: 4px;
  padding: 9px 22px;
  border: 1.5px solid rgba(255, 255, 255, .85);
  border-radius: 999px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: background .2s, color .2s;
}
#top-area a:hover { background: #fff; color: var(--lx-blue-dark); }

/* ---------- Content + sidebars ---------- */
#page-wrap { background: #fff; }
#container { padding: 48px 0 56px; }
.content-sidebar-wrap { display: block; }
body.sidebar-first .content-sidebar-wrap,
body.two-sidebars .content-sidebar-wrap {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
}
body.sidebar-first #sidebar-first,
body.two-sidebars #sidebar-first { grid-column: 1; grid-row: 1; }
body.sidebar-first #content,
body.two-sidebars #content { grid-column: 2; grid-row: 1; }
body.sidebar-second .container-wrap,
body.two-sidebars .container-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 48px;
  align-items: start;
}

.block { margin: 0 0 40px; }
.block:last-child { margin-bottom: 0; }
.block > h2 {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--lx-ink);
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--lx-line);
  position: relative;
}
.block > h2::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 44px; height: 2px;
  background: var(--lx-blue);
}
#post-content .content h2 { font-size: 22px; }
#post-content h1:not(.page-title) { color: var(--lx-blue-dark) !important; }
#post-content img { border-radius: 8px; }
#post-content .block::after { content: ""; display: table; clear: both; }

/* Breadcrumb, title, tabs, messages */
#breadcrumbs { margin-bottom: 18px; }
.breadcrumb {
  background: none; padding: 0; margin: 0; border: 0;
  font-size: 13px; color: var(--lx-muted);
}
.breadcrumb a { color: var(--lx-muted); }
.breadcrumb a:hover { color: var(--lx-blue); }
.page-title { font-size: clamp(26px, 3vw, 34px); margin: 0 0 24px; }
.tabs-wrapper { margin-bottom: 24px; }
ul.tabs.primary {
  display: flex; flex-wrap: wrap; gap: 4px;
  list-style: none; margin: 0; padding: 0;
  border-bottom: 1px solid var(--lx-line);
}
ul.tabs.primary li a {
  display: block; padding: 8px 16px; font-size: 14px; font-weight: 600;
  color: var(--lx-muted); border-bottom: 2px solid transparent; margin-bottom: -1px;
}
ul.tabs.primary li a:hover { color: var(--lx-ink); text-decoration: none; }
ul.tabs.primary li a.is-active,
ul.tabs.primary li.active a { color: var(--lx-blue); border-bottom-color: var(--lx-blue); }
.messages {
  padding: 14px 18px; margin: 0 0 24px; border-radius: var(--lx-radius);
  border: 1px solid; border-left-width: 4px; font-size: 15px;
}
.messages--status { background: #f0fdf4; border-color: #22c55e; color: #14532d; }
.messages--warning { background: #fffbeb; border-color: #f59e0b; color: #78350f; }
.messages--error { background: #fef2f2; border-color: #ef4444; color: #7f1d1d; }

/* Nodes / teasers */
.node { margin: 0 0 32px; }
.node--view-mode-teaser,
.node-teaser {
  padding-bottom: 28px;
  border-bottom: 1px solid var(--lx-line);
}
.submitted, .node__submitted { font-size: 13px; color: var(--lx-muted); margin-bottom: 10px; }
ul.links, .links.inline { list-style: none; padding: 0; margin: 10px 0 0; }
.field--label-inline .field__label { font-weight: 600; color: var(--lx-ink); }

/* ---------- Tables (activities block, contacts view) ---------- */
table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  border: 1px solid var(--lx-line);
  border-radius: var(--lx-radius);
  overflow: hidden;
  font-size: 14px;
  margin: 0 0 24px;
  box-shadow: var(--lx-shadow);
}
th,
table caption,
.views-view-table caption {
  background: var(--lx-table-head);
  color: #fff;
  font-weight: 600;
  text-align: left;
  padding: 12px 14px;
}
table caption,
.views-view-table caption {
  caption-side: top;
  border-radius: var(--lx-radius) var(--lx-radius) 0 0;
  font-size: 13px;
  letter-spacing: .06em;
  text-transform: uppercase;
}
th a, th a:hover { color: #fff; }
td {
  padding: 12px 14px;
  color: var(--lx-text);
  vertical-align: top;
  border-top: 1px solid var(--lx-line);
  background: #fff;
}
tbody tr:nth-child(even) td { background: var(--lx-surface); }
tbody tr:hover td { background: #eaf6fc; }
#sidebar-first td:first-child { white-space: nowrap; color: var(--lx-blue-dark); font-weight: 600; font-size: 13px; }

/* ---------- Bottom widgets ---------- */
.bottom_widget { background: var(--lx-surface); padding: 48px 0; }
.bottom_widget #bottom-area { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }

/* ---------- Footer ---------- */
#footer { background: var(--lx-surface); color: var(--lx-text); border-top: 1px solid var(--lx-line); }
#footer-area {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 40px;
  padding-top: 56px;
  padding-bottom: 48px;
}
#footer-area .column { min-width: 0; }
#footer-area .column:empty { display: none; }
#footer-area .column.two { grid-column: span 1; }
#footer p { font-size: 14.5px; line-height: 1.7; color: var(--lx-text); }
#footer .block > h2 { border-bottom-color: #d8e2ec; }

/* Photo gallery thumbs (views table or grid) */
.region-footer-second table,
.region-footer-second .views-view-grid {
  width: auto;
  border: 0;
  box-shadow: none;
  background: transparent;
  border-radius: 0;
  overflow: visible;
}
.region-footer-second td,
.region-footer-second .views-col {
  padding: 3px;
  border: 0;
  background: transparent !important;
}
.region-footer-second .views-view-grid .views-row { display: flex; }
.region-footer-second img {
  display: block;
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  transition: transform .2s, box-shadow .2s;
}
.region-footer-second a:hover img { transform: scale(1.06); box-shadow: var(--lx-shadow); }
.region-footer-second .more-link,
.region-footer-second .view-footer { margin-top: 12px; font-weight: 600; font-size: 14px; }

/* Search form */
#footer .search-block-form form,
#footer .search-block-form { display: flex; gap: 0; }
#footer .search-block-form .form-item,
#footer .search-block-form .form-actions { margin: 0; }
#footer .search-block-form .form-item { flex: 1 1 auto; }
#footer .search-block-form input[type="search"] {
  width: 100%;
  height: 42px;
  padding: 0 14px;
  border: 1px solid #cbd5e1;
  border-right: 0;
  border-radius: 8px 0 0 8px;
  background: #fff;
  font: inherit;
  font-size: 14px;
}
#footer .search-block-form input[type="search"]:focus { outline: 2px solid var(--lx-blue); outline-offset: -1px; }
#footer .search-block-form .form-submit {
  height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 0 8px 8px 0;
  background: var(--lx-blue);
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
#footer .search-block-form .form-submit:hover { background: var(--lx-blue-dark); }

/* Copyright + social */
.footer_credit { border-top: 1px solid var(--lx-line); padding: 18px 0; }
#copyright { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.footer_credit .copyright { font-size: 14px; color: var(--lx-muted); }
.social-icons ul { display: flex; gap: 8px; list-style: none; margin: 0; padding: 0; }
.social-icons a {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--lx-line);
  color: var(--lx-muted);
  font-size: 15px;
  transition: background .2s, color .2s, border-color .2s;
}
.social-icons a:hover { background: var(--lx-blue); border-color: var(--lx-blue); color: #fff; text-decoration: none; }
.credits {
  background: var(--lx-ink);
  color: #94a3b8;
  font-size: 12.5px;
  text-align: center;
  padding: 12px 0;
}
.credits a { color: #fff; }

/* Forms (generic) */
input[type="text"], input[type="email"], input[type="password"], input[type="search"], textarea, select {
  font: inherit;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 8px 12px;
}
input[type="submit"], .button {
  font: inherit;
  font-weight: 600;
  background: var(--lx-blue);
  color: #fff;
  border: 0;
  border-radius: 8px;
  padding: 9px 18px;
  cursor: pointer;
}
input[type="submit"]:hover, .button:hover { background: var(--lx-blue-dark); }
.pager__items { display: flex; justify-content: center; gap: 6px; list-style: none; padding: 0; margin: 24px 0; }
.pager__item a { display: block; padding: 6px 12px; border: 1px solid var(--lx-line); border-radius: 8px; }
.pager__item.is-active a { background: var(--lx-blue); color: #fff; border-color: var(--lx-blue); }

/* Focus visibility */
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--lx-blue); outline-offset: 2px; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  #footer-area { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.sidebar-first .content-sidebar-wrap,
  body.two-sidebars .content-sidebar-wrap { grid-template-columns: 260px minmax(0, 1fr); gap: 32px; }
}
@media (max-width: 860px) {
  #top-area .page-wrap { grid-template-columns: 1fr; }
  #top-area .column { padding: 36px 24px; }
  body.sidebar-first .content-sidebar-wrap,
  body.two-sidebars .content-sidebar-wrap,
  body.sidebar-second .container-wrap,
  body.two-sidebars .container-wrap { display: block; }
  #sidebar-first, #sidebar-second { margin-top: 40px; }
  .bottom_widget #bottom-area { grid-template-columns: 1fr; }
  #header { flex-wrap: wrap; }
  #header .region { max-width: 100%; }
}
@media (max-width: 760px) {
  body { font-size: 15.5px; }
  #header, .container-wrap, .full-wrap { padding-left: 16px; padding-right: 16px; }
  #logo img { max-height: 64px; }
  #container { padding: 32px 0 40px; }
  #footer-area { grid-template-columns: 1fr; gap: 32px; padding-top: 40px; }
  #copyright { flex-direction: column; text-align: center; }

  /* Mobile menu */
  #main-menu .nav-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 0;
    color: #fff;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: .06em;
    text-transform: uppercase;
    text-decoration: none;
  }
  #main-menu .nav-toggle::before {
    content: "\f0c9";
    font-family: FontAwesome;
    font-size: 18px;
  }
  #main-menu > .menu-navigation-container > ul.menu { display: none; flex-direction: column; margin: 0 -16px; }
  #main-menu > .menu-navigation-container > ul.menu.is-open { display: flex; }
  #main-menu a { padding: 13px 16px; border-top: 1px solid rgba(255, 255, 255, .18); }
  #main-menu > .menu-navigation-container > ul > li > a::after { display: none; }
  #main-menu li ul,
  #main-menu li:hover > ul { display: block; position: static; box-shadow: none; background: var(--lx-blue-dark); border-radius: 0; padding: 0; }
  #main-menu li ul a { color: #fff; padding-left: 32px; }
  #main-menu li ul a:hover { background: rgba(255, 255, 255, .1); color: #fff; }
}
