/* ==========================================================================
   BLUE OCEAN GROUP - EXACT REFERENCE STYLESHEET
   ========================================================================== */

@font-face {
  font-family: 'Theory of Signature';
  src: url('../fonts/Theory Of Signature.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'Aptos';
  src: local('Aptos'), local('Aptos Bold'), url('../fonts/Aptos-Bold.ttf') format('truetype');
  font-weight: bold;
  font-style: normal;
}

:root {
  --color-primary-navy: #0B2545;
  --color-accent-blue: #1E40AF;
  --color-red-group: #D90429;
  --color-border-frame: #334155;
  --color-border-pill: #64748B;
  --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-script: 'Dancing Script', cursive;
}

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

body {
  font-family: var(--font-main);
  color: #1E293B;
  background-color: #F1F5F9;
  line-height: 1.4;
  overflow-x: clip;
}

/* Page Outer Frame (Exact border box from reference) */
@media (max-width: 991px) {

  .page-outer-frame p,
  .page-outer-frame li,
  .page-outer-frame td,
  .page-outer-frame th,
  .page-outer-frame .text-dark {
    font-size: clamp(0.72rem, 1.5vh, 0.9rem) !important;
    line-height: clamp(1.3, 2.2vh, 1.8) !important;
  }

  .page-outer-frame h3,
  .page-outer-frame h4,
  .page-outer-frame h5,
  .section-title,
  .page-banner-title {
    font-size: clamp(0.95rem, 2.2vh, 1.15rem) !important;
    line-height: 1.2 !important;
  }
}

.page-outer-frame {
  width: 100%;
  max-width: 100%;
  margin: 0;
  background-color: #FFFFFF;
  box-shadow: none;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: clip;
}

/* Header Bar */
.header-main-bar {
  padding: 9px 24px 6px 14px;
  background-color: #FFFFFF;
  position: sticky;
  top: 0;
  z-index: 1050;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Script Logo */
.brand-logo-script {
  display: inline-flex;
  flex-direction: column;
  line-height: 1;
  text-decoration: none;
}

.brand-logo-script .logo-title {
  font-family: 'Theory of Signature', cursive;
  font-size: 2.8rem;
  font-weight: bold;
  color: var(--color-primary-navy);
  letter-spacing: -0.5px;
}

.logo-subtitle {
  font-family: 'Aptos', sans-serif;
  font-size: 1rem;
  font-weight: bold;
  font-stretch: expanded;
  color: var(--color-red-group);
  text-transform: lowercase;
  letter-spacing: 10px;
  display: block;
  margin-top: -14px;
  align-self: flex-start;
  margin-left: 80px;
}

/* Phone Hunting Link */
.phone-hunting-link {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--color-primary-navy);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.phone-hunting-link i {
  color: var(--color-accent-blue);
}

/* Pill Navigation Wrapper */
.nav-pill-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.nav-pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 14px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #1E293B;
  background-color: #FFFFFF;
  border: 1px solid var(--color-border-pill);
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s ease;
  white-space: nowrap;
}

/* Force single line for inland grid titles to prevent wrapping in EN translation */
.inland-grid p {
  white-space: nowrap !important;
  font-size: clamp(0.6rem, 1vw, 0.75rem) !important;
}

.nav-pill-btn:hover {
  border-color: var(--color-accent-blue);
  color: var(--color-accent-blue);
  background-color: #F8FAFC;
}

.nav-pill-btn.active {
  border: 2px solid var(--color-accent-blue);
  color: var(--color-accent-blue);
  font-weight: 800;
}

/* Footer Slim Bar */
.footer-exact-bar {
  background-color: #FFFFFF;
  padding: 12px 20px;
  border-top: 1px solid #E2E8F0;
  text-align: center;
  font-size: 0.95rem;
  color: #1E293B;
}

/* Responsive - Desktop Nav */
@media (min-width: 992px) {
  .nav-pill-wrapper {
    flex-wrap: wrap;
    gap: 4px;
  }

  .nav-pill-btn {
    padding: 6px 10px;
    font-size: 0.72rem;
  }
}

/* Responsive - Mobile */
@media (max-width: 991px) {
  .page-outer-frame {
    margin: 0;
    border: none;
  }

  .header-main-bar {
    padding: 3px 10px;
  }

  .brand-logo-script .logo-title {
    font-size: 2.2rem;
  }

  .brand-logo-script .logo-subtitle {
    font-size: 0.7rem;
    letter-spacing: 7px;
    margin-top: -12px;
    align-self: flex-start;
    margin-left: 65px;
  }

  .phone-hunting-link {
    font-size: 0.8rem;
  }

  .nav-pill-wrapper {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    margin-top: 15px;
    gap: 8px;
    overflow: visible;
  }

  .nav-pill-btn {
    padding: 10px 15px;
    font-size: 0.85rem;
    text-align: center;
    border-radius: 8px;
  }

  .services-submenu {
    width: 100%;
    position: relative;
    top: auto;
    right: auto;
  }

  .nav-pill-wrapper-sub {
    display: flex;
    flex-direction: column;
    padding-left: 15px;
    padding-right: 15px;
    gap: 6px;
  }

  .nav-pill-wrapper-sub .nav-pill-btn {
    font-size: 0.75rem;
    background-color: #F8FAFC;
    padding: 8px 10px;
  }

  .services-submenu.show {
    max-height: 400px;
  }
}

/* Services Submenu Base Animation */
.services-submenu {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.2s ease-in-out, opacity 0.2s ease-in-out, margin-top 0.2s ease-in-out;
  margin-top: 0;
}

.services-submenu.show {
  opacity: 1;
  margin-top: 5px;
}

/* Text alignment fix for paragraphs globally */
p {
  text-align: justify;
}

.contact-text-block p {
  text-align: left !important;
}

.contact-text-block table,
.contact-text-block td,
.contact-text-block th {
  color: inherit !important;
  font-family: inherit !important;
}

.why-us-right-content,
.why-us-right-content>[data-i18n],
.why-us-right-content h6,
.why-us-right-content p,
.why-us-trust-statement,
.why-us-trust-statement p {
  text-align: center !important;
}

.page-banner-title {
  text-align: center;
}

/* Services Submenu Desktop Absolute Positioning */
@media (min-width: 992px) {
  .service-menu-container {
    position: relative;
  }

  .services-submenu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: max-content;
    z-index: 1060;
  }

  .service-menu-container:hover .services-submenu {
    max-height: 150px;
    opacity: 1;
    margin-top: 5px;
  }

  .services-submenu.show {
    max-height: 150px;
    /* enough to show buttons on desktop horizontally */
  }

  .nav-pill-wrapper-sub {
    display: flex;
    flex-direction: row;
    gap: 4px;
    background-color: #FFFFFF;
    padding: 10px;
    border-radius: 8px;
    box-shadow: none;
    border: 1px solid var(--color-border-pill);
  }
}

/* Burger Toggle Style */
.mobile-menu-toggle {
  border: none;
  background: transparent;
  font-size: 1.5rem;
  color: var(--color-primary-navy);
  padding: 0 5px;
  display: inline-flex;
  align-items: center;
}

.mobile-menu-toggle:focus {
  box-shadow: none;
  outline: none;
}

/* ==========================================================================
   DESKTOP REFERENCE LAYOUT (min-width: 992px)
   ========================================================================== */
@media (min-width: 992px) {
  :root {
    --desktop-content-gutter: 3rem;
    --desktop-container-max-width: 1440px;
    /* Kept for Bootstrap .container if needed */
    --desktop-container-edge-space: 0px;
    --desktop-title-size: clamp(1.1rem, 2.5vh, 1.25rem);
    --desktop-subtitle-size: clamp(0.95rem, 2vh, 1.15rem);
    --desktop-body-size: clamp(13px, 2vh, 15px);
    --desktop-paragraph-gap: clamp(1em, 2vh, 1.5em);
  }

  html,
  body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    /* Prevent native scrolling, act like an app */
    background-color: #FFFFFF;
  }

  .page-outer-frame {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0 auto;
    background-color: #FFFFFF;
    border: none;
    overflow: hidden;
    /* Contain children */
  }

  /* Make the middle content section scrollable */
  .page-outer-frame>section.section-padding,
  .page-outer-frame>.hero-viewport-carousel {
    flex: 1 1 auto;
    overflow-y: auto;
    overflow-x: hidden;
  }

  .page-outer-frame .container {
    max-width: 100% !important;
    padding-left: 4rem !important;
    padding-right: 4rem !important;
  }

  .header-main-bar {
    flex: 0 0 auto;
    position: relative;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    padding-left: 4rem !important;
    padding-right: 4rem !important;
    z-index: 1050;
  }

  .btn-floating-other {
    position: absolute !important;
  }

  .footer-exact-bar {
    flex: 0 0 auto;
    padding: clamp(5px, 0.8vh, 8px) 4rem !important;
    font-size: clamp(0.85rem, 1.5vh, 0.95rem);
    position: relative;
    border-top: 1px solid #E2E8F0;
  }

  .page-outer-frame>.container,
  .page-outer-frame>section,
  .page-outer-frame>.carousel,
  .hero-viewport-carousel {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding-top: clamp(18px, 3vh, 32px) !important;
    padding-bottom: clamp(12px, 1.8vh, 22px) !important;
  }

  .page-outer-frame>.container,
  .page-outer-frame>section>.container {
    width: 100%;
    max-width: var(--desktop-container-max-width) !important;
    padding-left: clamp(20px, 2.5vw, 36px) !important;
    padding-right: clamp(20px, 2.5vw, 36px) !important;
    margin-left: auto !important;
    margin-right: auto !important;
    --bs-gutter-x: var(--desktop-content-gutter);
  }

  .page-outer-frame>section>.container {
    flex: 1 1 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }

  .hero-viewport-carousel .carousel-inner {
    height: 100%;
    flex-grow: 1;
  }

  .page-outer-frame>.container p,
  .page-outer-frame>.container li,
  .page-outer-frame>.container td,
  .page-outer-frame>.container th,
  .page-outer-frame>section p,
  .page-outer-frame>section li,
  .page-outer-frame>section td,
  .page-outer-frame>section th,
  .service-card p,
  .card-text,
  .contact-text-block,
  .contact-text-block td,
  .contact-text-block th {
    font-size: var(--desktop-body-size) !important;
    line-height: 1.75 !important;
    margin-bottom: var(--desktop-paragraph-gap) !important;
  }

  .page-outer-frame>.container p.mb-0,
  .page-outer-frame>section p.mb-0 {
    margin-bottom: 0 !important;
  }

  :is(body.about-page, body.csr-page) .page-outer-frame>.container p,
  :is(body.about-page, body.csr-page) .page-outer-frame>.container li,
  :is(body.about-page, body.csr-page) .page-outer-frame>section p,
  :is(body.about-page, body.csr-page) .page-outer-frame>section li {
    line-height: 2.4 !important;
  }

  body.why-us-page .page-outer-frame>.container p,
  body.why-us-page .page-outer-frame>.container li,
  body.why-us-page .page-outer-frame>section p,
  body.why-us-page .page-outer-frame>section li {
    line-height: 2.2 !important;
  }

  body.service-inland-page .page-outer-frame>.container p,
  body.service-inland-page .page-outer-frame>.container li,
  body.service-inland-page .page-outer-frame>section p,
  body.service-inland-page .page-outer-frame>section li {
    line-height: 1.5 !important;
  }

  /* Short content service pages (Custom, Asuransi, Sertifikat) */
  :is(body.service-asuransi-page, body.service-sertifikat-page) .page-outer-frame>.container p,
  :is(body.service-asuransi-page, body.service-sertifikat-page) .page-outer-frame>.container li,
  :is(body.service-asuransi-page, body.service-sertifikat-page) .page-outer-frame>section p,
  :is(body.service-asuransi-page, body.service-sertifikat-page) .page-outer-frame>section li {
    line-height: 2.7 !important;
  }

  /* Short content service pages (Custom, Asuransi, Sertifikat) */
  :is(body.service-custom-page) .page-outer-frame>.container p,
  :is(body.service-custom-page) .page-outer-frame>.container li,
  :is(body.service-custom-page) .page-outer-frame>section p,
  :is(body.service-custom-page) .page-outer-frame>section li {
    line-height: 1.7 !important;
  }


  /* Medium content service pages (Freight, Inland, Consolidation) */
  :is(body.service-freight-page, body.service-inland-page, body.service-consolidation-page) .page-outer-frame>.container p,
  :is(body.service-freight-page, body.service-inland-page, body.service-consolidation-page) .page-outer-frame>.container li,
  :is(body.service-freight-page, body.service-inland-page, body.service-consolidation-page) .page-outer-frame>section p,
  :is(body.service-freight-page, body.service-inland-page, body.service-consolidation-page) .page-outer-frame>section li {
    line-height: 2.0 !important;
  }


  .page-outer-frame>.container ul,
  .page-outer-frame>section ul {
    line-height: 1.7 !important;
    margin-bottom: var(--desktop-paragraph-gap) !important;
  }

  .page-outer-frame>.container h3,
  .page-outer-frame>.container h4,
  .page-outer-frame>.container h5,
  .page-outer-frame>section h3,
  .page-outer-frame>section h4,
  .page-outer-frame>section h5,
  .section-title,
  .page-banner-title {
    font-size: var(--desktop-title-size) !important;
    line-height: 1.2 !important;
    margin-bottom: var(--desktop-paragraph-gap) !important;
  }

  .page-outer-frame>.container h6,
  .page-outer-frame>section h6 {
    font-size: var(--desktop-subtitle-size) !important;
    line-height: 1.3 !important;
    margin-top: clamp(0.5rem, 1vh, 0.75rem) !important;
    margin-bottom: clamp(0.375rem, 0.85vh, 0.625rem) !important;
  }

  .page-outer-frame .container .service-card h6 {
    font-size: clamp(0.82rem, 0.8vh, 1.15rem) !important;
    line-height: 1.25 !important;
    margin-bottom: 0 !important;
  }

  .img-fluid,
  .client-logo,
  .gallery-img,
  .certificate-img {
    max-height: 100%;
    object-fit: contain;
  }

  #diagramImage {
    max-height: min(600px, calc(100vh - 310px)) !important;
  }

  .page-outer-frame>.container>.row,
  .page-outer-frame>section .container>.row {
    flex: 1 1 0;
    min-height: 0;
    margin-bottom: 0 !important;
  }

  .page-outer-frame>.container>.row>[class*="col-"],
  .page-outer-frame>section .container>.row>[class*="col-"] {
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  /* Compress service icon grid horizontally on desktop */
  #service-icon-grid {
    padding-left: 15%;
    padding-right: 15%;
  }

  .page-outer-frame>section .row.g-4 {
    flex: 1 1 0;
    min-height: 0;
    align-content: stretch;
  }

  .service-card {
    flex: 1 1 0;
    min-height: 0;
  }

  body.service-page .page-outer-frame>.container>.row>.col-md-5,
  body.service-page .page-outer-frame>.container>.row>.col-lg-5:last-child {
    align-self: stretch;
  }

  body.service-page .page-outer-frame>.container>.row>.col-md-5>.img-fluid,
  body.service-page .page-outer-frame>.container>.row>.col-lg-5:last-child>.img-fluid {
    width: 100%;
    height: auto !important;
    max-height: 100% !important;
    flex: 1 1 0;
    min-height: 0;
    object-fit: cover;
  }

  body.gallery-page .gallery-wrapper {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
  }

  body.gallery-page .gallery-wrapper>.row {
    --gallery-landscape-height: clamp(8rem, 20vh, 12.5rem);
    width: 100%;
    align-content: flex-start;
  }

  body.gallery-page .gallery-wrapper>.row>.col-md-3:nth-child(-n + 4)>.lightbox-img {
    height: var(--gallery-landscape-height) !important;
    aspect-ratio: auto !important;
  }

  body.gallery-page .gallery-wrapper>.row>.col-md-3:nth-child(n + 5)>.lightbox-img {
    height: calc(var(--gallery-landscape-height) * 2 + var(--bs-gutter-y)) !important;
    aspect-ratio: auto !important;
  }

  body.gallery-page .gallery-wrapper>.row>.col-md-3.d-flex>.lightbox-img {
    height: var(--gallery-landscape-height) !important;
    flex: 0 0 auto !important;
  }

  body.client-page .section-padding>.container>.d-none.d-md-block {
    display: flex !important;
    align-items: center;
    justify-content: center;
    min-height: 0;
  }

  body.client-page .section-padding>.container>.d-none.d-md-block.mb-3 {
    flex: 3 1 0;
    margin-bottom: var(--desktop-paragraph-gap) !important;
  }

  body.client-page .section-padding>.container>.d-none.d-md-block:not(.mb-3) {
    flex: 1 1 0;
  }

  body.client-page .section-padding>.container>.d-none.d-md-block>img {
    max-height: none !important;
  }



  .page-outer-frame>.container .fa-solid:not(.fa-phone-volume):not(.fa-bars),
  .page-outer-frame>section .container .fa-solid:not(.fa-phone-volume):not(.fa-bars) {
    font-size: clamp(2.5rem, 8vh, 6rem) !important;
  }

  .header-main-bar .fa-solid,
  .header-main-bar .phone-hunting-link .fa-solid {
    font-size: inherit !important;
  }
}

@media (min-width: 992px) and (max-width: 1199.98px) {
  body.service-page .page-outer-frame>.container {
    padding-top: 10px !important;
  }
}

/* Specific Line Height for Service Freight Page */
body.service-freight-page ul.freight-list li {
  line-height: 1.4 !important;
  margin-bottom: 0.3rem !important;
}

body.service-freight-page .page-banner-title {
  font-size: var(--desktop-title-size) !important;
  line-height: 1.2 !important;
  margin-bottom: 0.5em !important;
}