:root {
  --sot-navy: #1f4a96;
  --sot-cyan: #0099ff;
  --sot-text: #333333;
  --sot-white: #ffffff;
  --sot-page-width: 1020px;
}

.main-content {
  padding: 10px 15px 40px;
  color: var(--sot-text);
}

.box-content img,
.wp-content img {
  max-width: 100%;
  height: auto;
}

/* Sidebar mini-slider must not inherit homepage 300px frame */
.box-left .flexslider.sidebar-slider,
.box-left .flexslider.sidebar-slider .flex-viewport,
.box-left .flexslider.sidebar-slider .slides > li {
  height: auto !important;
  max-height: none !important;
}

.box-left .flexslider.sidebar-slider .slides img {
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  object-fit: contain !important;
}

.box-left .flexslider.sidebar-slider .flex-direction-nav {
  display: none;
}

.box-8::after {
  content: '';
  display: table;
  clear: both;
}

/* Interior pages: slightly wider left rail (banner/ad fits closer to WP) */
@media (min-width: 992px) {
  .content-row > .box-left.col-md-3 {
    width: 30%;
    float: left;
  }

  .content-row > .box-content.col-md-9,
  .content-row > .box-content-news.col-md-9 {
    width: 70%;
    float: left;
  }

  /* Theme sets width:100% below 1200px — keep two columns on desktop */
  .content-row > .box-content-news.col-md-9 {
    width: 70% !important;
  }
}

.box-content .edi-lead {
  text-align: left;
}

/* EDI / GLN-ILN table: fit the right content column */
.edi-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
}

.box-content .edi-table {
  width: 100%;
  max-width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  margin: 0 0 20px;
  font-size: 13px;
  line-height: 1.35;
  text-align: left;
}

.box-content .edi-table th,
.box-content .edi-table td {
  padding: 6px 8px;
  vertical-align: top;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.box-content .edi-table th {
  background: var(--sot-navy);
  color: var(--sot-white);
  font-weight: 700;
  border-bottom: none;
}

.box-content .edi-table td {
  border-bottom: 1px dotted #ccc;
}

.box-content .edi-table tbody tr:nth-child(even) td {
  background: #f5f8fc;
}

.box-content .edi-table th:nth-child(1),
.box-content .edi-table td:nth-child(1) {
  width: 42%;
}

.box-content .edi-table th:nth-child(2),
.box-content .edi-table td:nth-child(2) {
  width: 16%;
  min-width: 8.2em;
  white-space: nowrap;
  overflow-wrap: normal;
  font-variant-numeric: tabular-nums;
}

.box-content .edi-table th:nth-child(3),
.box-content .edi-table td:nth-child(3) {
  width: 42%;
}

@media (max-width: 767px) {
  .box-content .edi-table {
    min-width: 640px;
    font-size: 12px;
    table-layout: auto;
  }
}

.pagefind-ui {
  max-width: 720px;
  margin: 20px 0;
}

/* Homepage full-bleed inside main — desktop only (WP 1020px layout) */
@media (min-width: 992px) {
  .main-content:has(.content-home) {
    padding-left: 0;
    padding-right: 0;
    overflow: visible;
  }

  .content-home.row,
  .content-home .row {
    margin-left: 0;
    margin-right: 0;
  }

  .content-home [class*="col-"] {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
}

.content-home {
  overflow: visible;
}

/* ---- Homepage slider: captions + hover arrows ---- */
.content-home .flexslider {
  overflow: visible !important;
  position: relative;
  z-index: 2;
}

.content-home .flexslider .slides > li {
  position: relative !important;
  height: 300px !important;
  max-height: 300px !important;
  overflow: hidden !important;
}

.content-home .flexslider .slides img {
  width: 100% !important;
  height: 300px !important;
  object-fit: cover !important;
  display: block !important;
}

.content-home .flex-viewport,
.content-home .slide-contain {
  max-height: 300px !important;
  height: 300px !important;
  overflow: hidden;
}

.content-home .flexslider .slide-title {
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: auto !important;
  max-width: 100%;
  box-sizing: border-box;
  z-index: 3;
  margin: 0;
  color: #fff !important;
  background: rgba(31, 74, 150, 0.9) !important;
}

/* Ensure direction arrows are visible on hover (font icons) */
.content-home .flex-direction-nav a {
  opacity: 0;
  color: rgba(0, 0, 0, 0.85) !important;
  text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.35);
  text-decoration: none !important;
  border: 0 !important;
  font-size: 0 !important;
  line-height: 0 !important;
}

.content-home .flexslider:hover .flex-direction-nav .flex-prev {
  opacity: 0.85;
  left: 10px;
}

.content-home .flexslider:hover .flex-direction-nav .flex-next {
  opacity: 0.85;
  right: 10px;
}

.content-home .flexslider:hover .flex-direction-nav .flex-prev:hover,
.content-home .flexslider:hover .flex-direction-nav .flex-next:hover {
  opacity: 1;
}

.content-home .flex-direction-nav a:before,
.content-home .flex-direction-nav a.flex-next:before {
  font-family: "flexslider-icon" !important;
  font-size: 40px !important;
  line-height: 45px !important;
  color: #000;
  speak: none;
}

/* ---- Homepage tiles: fill frame, caption flush on image ---- */
.content-home .box-1,
.content-home .box-2,
.content-home .box-3,
.content-home .box-4 {
  height: 150px;
  width: 225px;
  margin-left: 20px;
  overflow: hidden;
  position: relative;
  float: left;
}

.content-home .box-1 .box2,
.content-home .box-2 .box2,
.content-home .box-3 .box2,
.content-home .box-4 .box2 {
  position: relative;
  height: 140px;
  overflow: hidden;
  background: #09f;
}

.content-home .box-1 .box2 > a,
.content-home .box-2 .box2 > a,
.content-home .box-3 .box2 > a,
.content-home .box-4 .box2 > a {
  display: block;
  height: 140px;
  overflow: hidden;
}

.content-home .box-1 .box2 img,
.content-home .box-2 .box2 img,
.content-home .box-3 .box2 img,
.content-home .box-4 .box2 img {
  width: 100% !important;
  height: 140px !important;
  max-width: none !important;
  object-fit: cover !important;
  object-position: center center;
  display: block;
  margin: 0 !important;
}

.content-home .box-1 h3,
.content-home .box-1 #gstr,
.content-home .box-2 .box2 h3,
.content-home .box-3 h3,
.content-home .box-4 h3 {
  position: absolute !important;
  display: block !important;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0 !important;
  padding: 0 !important;
  height: 24pt;
  line-height: 24pt;
  font-size: 10pt;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  z-index: 2;
  color: #fff !important;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.content-home .box-1 h3,
.content-home .box-1 #gstr,
.content-home .box-2 .box2 h3,
.content-home .box-3 h3 {
  background: rgba(0, 153, 255, 0.9);
}

.content-home .box-4 h3 {
  background: rgba(31, 74, 150, 0.9);
}

.content-home .box-1 h3 a,
.content-home .box-2 .box2 h3 a,
.content-home .box-3 h3 a,
.content-home .box-4 h3 a {
  color: #fff !important;
  display: block;
  margin: 0;
  padding: 0;
  text-decoration: none;
  line-height: 24pt;
  white-space: nowrap;
}

.content-home .box-2 .boxb {
  height: 140px;
  overflow: hidden;
}

@media screen and (max-width: 991px) {
  .content-home .flexslider .slides > li,
  .content-home .flexslider .slides img,
  .content-home .flex-viewport,
  .content-home .slide-contain {
    height: auto !important;
    max-height: none !important;
  }

  .content-home .box-1,
  .content-home .box-2,
  .content-home .box-3,
  .content-home .box-4 {
    width: 50% !important;
    margin-left: 0;
    height: auto;
  }

  @media screen and (max-width: 600px) {
    .content-home .box-1,
    .content-home .box-2,
    .content-home .box-3,
    .content-home .box-4 {
      width: 100% !important;
    }
  }

  .content-home .box-1 .box2,
  .content-home .box-2 .box2,
  .content-home .box-3 .box2,
  .content-home .box-4 .box2,
  .content-home .box-1 .box2 > a,
  .content-home .box-2 .box2 > a,
  .content-home .box-3 .box2 > a,
  .content-home .box-4 .box2 > a,
  .content-home .box-1 .box2 img,
  .content-home .box-2 .box2 img,
  .content-home .box-3 .box2 img,
  .content-home .box-4 .box2 img {
    height: 150px !important;
  }
}

/* ---- Mobile / narrow layout ---- */
.submenu-toggle {
  display: none;
}

@media screen and (max-width: 991px) {
  .container.page-wrap {
    padding-left: 20px;
    padding-right: 20px;
    overflow-x: hidden;
  }

  .content-row,
  .content-home.row {
    margin-left: 0;
    margin-right: 0;
  }

  .site-header .row {
    display: flex;
    flex-wrap: wrap;
    margin-left: 0;
    margin-right: 0;
  }

  .site-header .logo {
    order: 1;
    flex: 1 1 100%;
  }

  .site-header .header-tools {
    order: 2;
    flex: 1 1 100%;
  }

  .site-header .main-menu {
    order: 3;
    flex: 1 1 100%;
  }

  .site-header .header-tools .row,
  .site-header .header-tools [class*="col-"] {
    display: block;
    margin-left: 0;
    margin-right: 0;
    padding-left: 0 !important;
    padding-right: 0 !important;
    width: 100%;
  }

  .site-header .search,
  .site-header .search form {
    width: 100%;
  }

  .site-header .search-box,
  .site-header .search input.search-box {
    width: 65%;
    box-sizing: border-box;
  }

  .site-header .search input.searching {
    width: 35%;
    box-sizing: border-box;
  }

  .main-content,
  .box-content,
  .box-content-news,
  .box-left,
  .content-row > [class*="col-"],
  .content-home [class*="col-"] {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .box-content,
  .box-content-news,
  .main-content,
  .box-5 h1,
  .box-5 p {
    overflow-wrap: break-word;
    word-wrap: break-word;
  }

  .box-5 p {
    padding-left: 0;
    padding-right: 0;
  }

  /* Logo stays in flow and clickable — WP absolute logo is covered by nav */
  .site-header .logo {
    position: relative !important;
    left: auto !important;
    float: none;
    width: 100%;
    margin: 0 auto 8px !important;
    padding: 0 !important;
    text-align: center;
    z-index: 5;
  }

  .site-header .logo a {
    display: inline-block;
    position: relative;
    z-index: 6;
  }

  .site-header .main-menu {
    margin-top: 0;
    width: 100%;
    padding: 0 !important;
    text-align: center;
  }

  .site-header #site-navigation {
    margin-left: 0 !important;
  }

  .site-header .menu-toggle {
    display: block !important;
    width: 100%;
    max-width: none;
    margin: 0 0 12px !important;
    box-sizing: border-box;
    font-size: 13px;
    letter-spacing: 0.06em;
  }

  .site-header .flags {
    float: none;
    top: auto !important;
    position: relative;
    width: auto;
    margin: 8px 0;
    text-align: right;
  }

  .site-header .header-tools {
    width: 100%;
    padding: 0 !important;
  }

  .site-header .search {
    margin: 0 0 12px;
  }

  /* Hamburger until Bootstrap `md`, not only <600px */
  .main-menu ul.menu {
    display: none !important;
  }

  .main-menu ul.menu.toggled-on {
    display: block !important;
  }

  #menu-sot-pl-menu {
    width: 100% !important;
    margin: 0 0 12px !important;
    line-height: 1.35 !important;
    text-align: left;
    background: #fff;
    border: 1px solid #e6e6e6;
    border-radius: 4px;
    overflow: hidden;
  }

  #menu-sot-pl-menu > li {
    display: flex !important;
    flex-wrap: wrap;
    float: none !important;
    width: 100% !important;
    position: relative;
    border-bottom: 1px solid #eee;
    text-transform: uppercase;
    text-align: left;
  }

  #menu-sot-pl-menu > li:last-child {
    border-bottom: none;
  }

  #menu-sot-pl-menu > li > a {
    flex: 1 1 auto;
    display: block;
    padding: 12px 14px !important;
    margin: 0 !important;
    text-align: left;
    font-weight: 700;
    font-size: 13px;
    color: #1f4a96;
    border-bottom: none !important;
  }

  #menu-sot-pl-menu li.current-menu-item > a,
  #menu-sot-pl-menu > li.current-menu-item > a {
    color: #1f4a96;
    background: #f4f8fd;
    border-bottom: none !important;
  }

  .submenu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: #1f4a96;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
  }

  .submenu-toggle:hover,
  .submenu-toggle:focus {
    background: #f4f8fd;
    outline: none;
  }

  nav ul li:hover > ul,
  nav ul li:hover ul {
    display: none;
  }

  #menu-sot-pl-menu .sub-menu {
    display: none !important;
    position: static !important;
    top: auto !important;
    left: auto !important;
    float: none;
    width: 100%;
    flex-basis: 100%;
    background: #f7f9fc;
    box-shadow: none !important;
    padding: 0;
  }

  #menu-sot-pl-menu .menu-item-has-children.is-open > .sub-menu {
    display: block !important;
  }

  #menu-sot-pl-menu .sub-menu li {
    display: block;
    min-width: 0;
    text-transform: none !important;
    line-height: 1.35;
    text-align: left;
    border-top: 1px solid #e8eef6;
  }

  #menu-sot-pl-menu .sub-menu a {
    display: block;
    padding: 10px 14px 10px 28px !important;
    text-align: left;
    font-size: 14px;
    font-weight: 400;
    color: #333;
    border-bottom: none !important;
  }

  #menu-sot-pl-menu .sub-menu a:hover,
  #menu-sot-pl-menu .sub-menu .current-menu-item > a {
    background: #eef4fb;
    color: #1f4a96;
    text-decoration: none;
  }

  .foot {
    padding-left: 20px;
    padding-right: 20px;
  }
}

/* ---- Sentos footer banner (wide) ---- */
.page-wrap--sentos-footer {
  margin-bottom: 0;
}

.page-wrap--sentos-footer:after {
  height: 0;
}

.site-footer--sentos-wide,
.site-footer--sentos-wide .foot {
  height: auto;
  min-height: 0;
}

.site-footer--sentos-wide .foot {
  padding-top: 24px;
  padding-bottom: 28px;
  overflow: hidden;
}

.site-footer--sentos-wide .foot::after {
  content: '';
  display: table;
  clear: both;
}

.site-footer--sentos-wide .foot-company {
  margin-top: 8px;
  overflow: hidden;
}

.site-footer--sentos-wide .foot-company img {
  float: left;
  margin-right: 10px;
  margin-top: 4px;
}

.site-footer--sentos-wide .foot-company p {
  margin: 0;
  overflow: hidden;
}

.foot-privacy {
  display: inline-block;
  margin-top: 10px;
  padding: 6px 12px;
  color: #fff !important;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 4px;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none !important;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.foot-privacy:hover,
.foot-privacy:focus {
  background: #0099ff;
  border-color: #0099ff;
  color: #fff !important;
  text-decoration: none !important;
}

/* Wide layout: company + privacy on top row, banner full width below */
.foot--sentos-wide {
  width: 1000px;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.foot--sentos-wide .foot-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px 24px;
  margin-bottom: 18px;
}

.foot--sentos-wide .foot-top .foot-privacy {
  margin-top: 8px;
  flex: 0 0 auto;
}

.foot--sentos-wide .foot-sentos--wide {
  width: 100%;
  clear: both;
}

.foot--sentos-wide .sentos-ad {
  width: 100%;
  box-sizing: border-box;
}

.sentos-ad {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 18px;
  padding: 14px 16px;
  background: #fff;
  color: #1a2b4a;
  border-radius: 6px;
  text-decoration: none !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.sentos-ad:hover,
.sentos-ad:focus {
  text-decoration: none !important;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.22);
  transform: translateY(-1px);
  outline: none;
}

.sentos-ad__brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  flex: 0 0 auto;
}

.sentos-ad__logo {
  display: block;
  float: none !important;
  margin: 0 !important;
  width: 140px;
  height: auto;
  max-width: 100%;
}

.sentos-ad__body {
  flex: 1 1 220px;
  min-width: 0;
}

.sentos-ad__lead {
  display: block;
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 700;
  color: #1f4a96;
  line-height: 1.25;
}

.sentos-ad__tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 12px;
}

.sentos-ad__tiles li {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  font-size: 12px;
  line-height: 1.25;
  color: #333;
}

.sentos-ad__icon {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  color: #1f4a96;
}

.sentos-ad__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  padding: 10px 16px;
  background: #1f4a96;
  color: #fff !important;
  font-size: 13px;
  font-weight: 700;
  border-radius: 4px;
  white-space: nowrap;
}

.sentos-ad:hover .sentos-ad__cta {
  background: #0099ff;
}

@media screen and (max-width: 991px) {
  .foot--sentos-wide {
    width: 100%;
    padding-left: 20px;
    padding-right: 20px;
  }

  .sentos-ad {
    padding: 12px;
  }

  .sentos-ad__cta {
    width: 100%;
  }
}

@media screen and (max-width: 600px) {
  .sentos-ad__tiles {
    grid-template-columns: 1fr;
  }

  .foot--sentos-wide .foot-top {
    flex-direction: column;
  }
}
