/* PRTMX V5.3 polish — additive stylesheet. V5.2 remains installed unchanged. */
/* The desktop and mobile hero use one complete composition. Never tile/crop
   a separate right-hand picture into the middle of the banner. */
body.prtmx-unified-ui#prtmxPortalHome .hero {
  position:relative!important;
  isolation:isolate!important;
  overflow:hidden!important;
  background:#eaf4fd!important;
  border:1px solid #d4e4f2!important;
}
body.prtmx-unified-ui#prtmxPortalHome .hero::before {
  content:""!important;
  display:block!important;
  position:absolute!important;
  inset:0!important;
  background-image:url('/static/prtmx-v53-hero-desktop.webp')!important;
  background-position:center center!important;
  background-size:100% 100%!important;
  background-repeat:no-repeat!important;
  opacity:1!important;
  transform:none!important;
  border-radius:inherit!important;
  pointer-events:none!important;
  z-index:-1!important;
}
body.prtmx-unified-ui#prtmxPortalHome .hero-inner {
  position:relative!important;
  z-index:1!important;
}
/* Keep the original, approved hero copy clear of the ship. */
@media (min-width:701px){
  body.prtmx-unified-ui#prtmxPortalHome .hero-inner {max-width:56%!important;}
}
@media (max-width:700px){
  body.prtmx-unified-ui#prtmxPortalHome .hero {
    min-height:266px!important;
    border-radius:20px!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .hero::before {
    background-image:url('/static/prtmx-v53-hero-mobile.webp')!important;
    background-position:center bottom!important;
    background-size:100% 100%!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .hero-inner {
    min-height:266px!important;
    max-width:none!important;
    width:100%!important;
    padding:20px 21px 116px!important;
    justify-content:flex-start!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .hero h1 {
    max-width:330px!important;
    font-size:clamp(23px,6vw,29px)!important;
    line-height:1.12!important;
    margin:0 0 8px!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .hero p {
    max-width:315px!important;
    font-size:11px!important;
    line-height:1.38!important;
  }
}
@media (max-width:365px){
  body.prtmx-unified-ui#prtmxPortalHome .hero-inner {padding-left:16px!important;padding-right:16px!important;}
  body.prtmx-unified-ui#prtmxPortalHome .hero h1 {font-size:22px!important;max-width:300px!important;}
}
/* The native board can place arrival/departure labels in adjacent inline
   elements without a gap. This class is added only to short time pairs. */
body.prtmx-unified-ui[data-prtmx-ui-route="board"] .prtmx-v53-time-pair {
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  flex-wrap:wrap!important;
  column-gap:12px!important;
  row-gap:4px!important;
  line-height:1.5!important;
  white-space:normal!important;
}
body.prtmx-unified-ui[data-prtmx-ui-route="board"] .prtmx-v53-time-pair > * {
  min-width:0;
  white-space:normal!important;
}
body.prtmx-unified-ui[data-prtmx-ui-route="board"] .prtmx-v53-time-separator {
  white-space:pre!important;
  color:#8da1b4;
}

/* V5.3 — one quiet voxel design system across ALL, including native pages. */
body.prtmx-unified-ui {
  --prtmx-ui-navy:#193956;
  --prtmx-ui-blue:#367da9;
  --prtmx-ui-bg:#f2f7fc;
  --prtmx-ui-border:#dce8f3;
  --prtmx-v53-step:#d6e4f1;
  --prtmx-v53-surface:#fbfdff;
  background-color:var(--prtmx-ui-bg);
  color:#233e5c;
}
/* Keep the unified header exactly the same height and position on all paths,
   even if an old page sets global header/nav styles. */
body.prtmx-unified-ui > .prtmx-ui-header,
body.prtmx-unified-ui header#prtmx-ui-v52-header {
  box-sizing:border-box!important;
  height:68px!important;
  min-height:68px!important;
  max-height:68px!important;
  padding:0!important;
  margin:0!important;
  display:block!important;
  background:rgba(250,253,255,.96)!important;
  border-radius:0!important;
  box-shadow:0 1px 0 #d8e5f0,0 3px 10px #244b6810!important;
}
body.prtmx-unified-ui .prtmx-ui-header-inner {
  box-sizing:border-box!important;
  height:68px!important;
  min-height:68px!important;
  padding:0!important;
  margin:0 auto!important;
  width:min(1340px,calc(100% - 36px))!important;
}
body.prtmx-unified-ui .prtmx-ui-logo,
body.prtmx-unified-ui .prtmx-ui-logo img {max-height:56px!important;}
body.prtmx-unified-ui .prtmx-ui-logo img {
  width:172px!important;
  height:54px!important;
  object-fit:contain!important;
  object-position:left center!important;
}
body.prtmx-unified-ui .prtmx-ui-brand-label {
  border-radius:9px!important;
  border:1px solid #e0eaf2!important;
  background:#f0f6fc!important;
  box-shadow:none!important;
}
body.prtmx-unified-ui .prtmx-ui-top-links a {
  min-height:35px!important;
  box-sizing:border-box!important;
  border-radius:10px!important;
  letter-spacing:0!important;
  line-height:1.15!important;
}
body.prtmx-unified-ui .prtmx-ui-top-menu {
  align-items:center!important;
  justify-items:center!important;
  line-height:0!important;
  border-radius:11px!important;
}
body.prtmx-unified-ui .prtmx-ui-top-menu svg {margin:0!important;transform:none!important;}
/* Unified bottom navigation on desktop too; flat, not videogame-like. */
body.prtmx-unified-ui > .prtmx-ui-dock {
  box-sizing:border-box!important;
  font-variant-numeric:tabular-nums;
  box-shadow:0 3px 0 #d7e5f2,0 10px 24px #2d506a18!important;
  border-radius:19px!important;
}
body.prtmx-unified-ui .prtmx-ui-dock a.active {
  color:#1969a7!important;
  background:#e4f0fa!important;
}
/* One consistent subtle cubic / stepped depth across ordinary cards only. */
body.prtmx-unified-ui :is(.ship-fleet-item,.ship-fleet-card,.schedule-card,.day-card,.stop-card,.stop-row,.board-row) {
  background-color:var(--prtmx-v53-surface);
  border:1px solid #d9e5ef;
  box-shadow:0 2px 0 #e0ebf4,0 8px 19px #234e7310;
  border-radius:15px;
}
body.prtmx-unified-ui :is(.ship-fleet-item,.ship-fleet-card,.schedule-card,.day-card,.stop-card,.stop-row,.board-row):is(:hover,:focus-within) {
  border-color:#bfd8ec;
}
/* Do not replace ship-specific thumbnails or set generic images on native cards. */
body.prtmx-unified-ui .ship-fleet-item img,
body.prtmx-unified-ui .schedule-card img {object-fit:contain;}

/* Homepage: 10 companies stay in a responsive grid, never sideways offset. */
body.prtmx-unified-ui#prtmxPortalHome .companies {
  display:grid!important;
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  gap:10px!important;
  align-items:stretch!important;
  overflow:visible!important;
  margin:0!important;
  padding:2px 0 5px!important;
  max-width:100%!important;
  scroll-snap-type:none!important;
}
body.prtmx-unified-ui#prtmxPortalHome .company-card {
  box-sizing:border-box!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:9px!important;
  min-width:0!important;
  width:100%!important;
  min-height:68px!important;
  padding:11px 12px!important;
  text-align:left!important;
  border-radius:13px!important;
  background:linear-gradient(155deg,#fff,#f7fafd)!important;
  border:1px solid #dce8f2!important;
  box-shadow:0 3px 0 #dbe8f3,0 7px 18px #2e577a10!important;
  transform:none!important;
  transition:background .16s,border-color .16s,box-shadow .16s!important;
}
body.prtmx-unified-ui#prtmxPortalHome .company-card:hover,
body.prtmx-unified-ui#prtmxPortalHome .company-card:focus-visible {
  background:#f5faff!important;
  border-color:#a8cce6!important;
  box-shadow:0 3px 0 #c6dfef,0 8px 19px #2e577a15!important;
}
body.prtmx-unified-ui#prtmxPortalHome .company-card > :not(.company-symbol),
body.prtmx-unified-ui#prtmxPortalHome .company-info {min-width:0!important;text-align:left!important;}
body.prtmx-unified-ui#prtmxPortalHome .company-symbol {
  flex:0 0 34px!important;
  display:grid!important;
  place-items:center!important;
  width:34px!important;
  height:34px!important;
  border-radius:9px!important;
  background:var(--company-color,#438bbd)!important;
  border:1px solid #ffffff50!important;
  box-shadow:inset 2px 2px 0 #ffffff40,inset -2px -3px 0 #103b5d23,0 2px 0 #c7d8e6!important;
  font-size:16px!important;
}
body.prtmx-unified-ui#prtmxPortalHome .company-name {
  font-size:12px!important;
  font-weight:780!important;
  line-height:1.2!important;
  color:#294765!important;
  text-align:left!important;
  overflow-wrap:anywhere!important;
}
body.prtmx-unified-ui#prtmxPortalHome .company-count {
  margin-top:3px!important;
  font-size:10px!important;
  color:#7a8da0!important;
  text-align:left!important;
}
/* Existing fleet catalog: styled company filter chips, but leave native JS click handlers. */
body.prtmx-unified-ui #prtmxCatalogTools {
  background:#f8fbff!important;
  border-radius:16px!important;
  box-shadow:0 2px 0 #e1ebf4!important;
}
body.prtmx-unified-ui #prtmxCatalogTools .prtmx-company-filters {
  display:flex!important;
  flex-wrap:wrap!important;
  justify-content:flex-start!important;
  gap:7px!important;
}
body.prtmx-unified-ui #prtmxCatalogTools [data-company] {
  border-radius:10px!important;
  background:linear-gradient(180deg,#fff,#f3f8fc)!important;
  border:1px solid #d6e3ef!important;
  box-shadow:0 2px 0 #e0eaf3!important;
  padding:8px 11px!important;
  color:#476781!important;
  min-height:36px!important;
  font-weight:650!important;
  line-height:1.15!important;
  white-space:normal!important;
  text-align:center!important;
  transition:background .15s,border-color .15s!important;
}
body.prtmx-unified-ui #prtmxCatalogTools [data-company]:is(.selected,[aria-pressed="true"]) {
  background:#e3f2ff!important;
  color:#145f9d!important;
  border-color:#83b8df!important;
  box-shadow:inset 0 2px 0 #c8e3f7!important;
}
body.prtmx-unified-ui #prtmxCatalogTools input {
  background:#fff!important;
  border:1px solid #d8e6f1!important;
  border-radius:11px!important;
  box-shadow:inset 0 1px 2px #21496707!important;
}
/* Existing board: keep its search/tab forms functional and give readable spacing. */
body.prtmx-unified-ui[data-prtmx-ui-route="board"] :is(input,select,button) {box-sizing:border-box;}
body.prtmx-unified-ui[data-prtmx-ui-route="board"] :is(input,select) {
  border-color:#d6e5f0;
  border-radius:11px;
}
body.prtmx-unified-ui[data-prtmx-ui-route="board"] :is(.board-card,.stop-card,.board-stop,.board-stop-card) {
  border:1px solid #dce8f3;
  border-radius:15px;
  box-shadow:0 2px 0 #e2ecf5;
  background-color:#fff;
}
/* Explicitly add spacing between arrivals and departures; the V53 script
   tags the *smallest* text container so the layout of a stop row is not changed. */
body.prtmx-unified-ui[data-prtmx-ui-route="board"] .prtmx-v53-time-pair {
  display:inline-flex!important;
  gap:9px!important;
  align-items:baseline!important;
  flex-wrap:wrap!important;
  line-height:1.45!important;
}
body.prtmx-unified-ui[data-prtmx-ui-route="board"] .prtmx-v53-time-pair > :is(span,b,strong,small) {margin-inline-end:4px!important;}
/* Calendar dates: gently squared voxel corners; native location buttons kept. */
body.prtmx-unified-ui :is(.schedule-card,.day-card,.calendar-day,.date-card) {
  border-radius:15px;
}
body.prtmx-unified-ui :is(.ship-fleet-item,.ship-fleet-card) :is(.ship-fleet-name,.ship-name,.ship-title) {
  color:#193958;
}
@media(max-width:1050px){
  body.prtmx-unified-ui#prtmxPortalHome .companies {grid-template-columns:repeat(3,minmax(0,1fr))!important;}
}
@media(max-width:700px){
  body.prtmx-unified-ui {--prtmx-ui-header-h:64px!important;}
  body.prtmx-unified-ui > .prtmx-ui-header,
  body.prtmx-unified-ui header#prtmx-ui-v52-header {
    height:64px!important;min-height:64px!important;max-height:64px!important;
  }
  body.prtmx-unified-ui .prtmx-ui-header-inner {
    height:64px!important;min-height:64px!important;
    width:calc(100% - 24px)!important;gap:8px!important;
  }
  body.prtmx-unified-ui .prtmx-ui-logo img {width:143px!important;height:52px!important;}
  body.prtmx-unified-ui .prtmx-ui-brand-label {max-width:calc(100vw - 240px)!important;}
  body.prtmx-unified-ui#prtmxPortalHome .companies {
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:9px!important;padding:2px 0 6px!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .company-card {
    padding:9px!important;gap:8px!important;min-height:62px!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .company-symbol {
    flex-basis:30px!important;width:30px!important;height:30px!important;font-size:14px!important;
  }
  body.prtmx-unified-ui#prtmxPortalHome .company-name{font-size:11.3px!important;}
  body.prtmx-unified-ui#prtmxPortalHome .company-count{font-size:9.7px!important;}
  body.prtmx-unified-ui #prtmxCatalogTools .prtmx-company-filters {gap:6px!important;}
  body.prtmx-unified-ui #prtmxCatalogTools [data-company] {min-height:36px!important;padding:7px 9px!important;font-size:12px!important;}
}
@media(max-width:360px){
  body.prtmx-unified-ui .prtmx-ui-brand-label {display:none!important;}
  body.prtmx-unified-ui#prtmxPortalHome .company-card {gap:6px!important;padding:8px!important;}
  body.prtmx-unified-ui#prtmxPortalHome .company-name {font-size:10.5px!important;}
}
/* Native shared-stay, route and map side panels: visual-only; the map itself
   and its controls retain their original event handlers and coordinates. */
body.prtmx-unified-ui :is(.shared-card,.shared-result,.shared-stay,.shared-match,.route-summary,.route-panel,.map-sidebar,.map-info-panel) {
  border:1px solid #dce7f1;
  background-color:#fbfdff;
  border-radius:15px;
  box-shadow:0 2px 0 #e4edf5,0 7px 18px #2a547610;
}
body.prtmx-unified-ui :is(input,select,textarea):focus-visible,
body.prtmx-unified-ui :is(button,a):focus-visible {
  outline:2px solid #4c9bd2;
  outline-offset:2px;
}
body.prtmx-unified-ui :is(h1,h2,h3) {text-wrap:pretty;}


/* TEPLOHODIKI_REMOVE_BOTTOM_NAV_FINAL */
html body .v2-bottom-nav,
html body .prtmx-bottom-nav,
html body .bottom-nav,
html body .board-bottom-nav {
    display: none !important;
    visibility: hidden !important;
}
