/*
 * YounitedCapital visual identity
 * Night blue #09233F · Action blue #0877C9 · Turquoise #16B89B · White #FFFFFF
 * Loaded last so legacy page-specific themes inherit one coherent banking palette.
 */
:root{
  --yc-navy:#09233f;
  --yc-blue:#0877c9;
  --yc-green:#16b89b;
  --yc-green-soft:#e5f8f4;
  --yc-bg:#f4f8fc;
  --yl-navy:#09233f;
  --yl-blue:#0877c9;
  --yl-green:#16b89b;
}

html{accent-color:#0877c9}

/* The header logo keeps its transparent image; the footer retains its white badge. */
.topbar .brand-logo-image{background:transparent;padding:0;border-radius:0;box-sizing:border-box}

/* Keep the loan application header light before and after scrolling. */
body:has(.loan-application-main) .topbar,
body:has(.loan-application-main) .topbar.scrolled{
  background:#fff!important;
  border-bottom-color:#dfe7ef!important;
  box-shadow:0 6px 24px rgba(9,35,63,.08)!important;
}
body:has(.loan-application-main) .topbar nav>a:not(.nav-login){color:#263f59!important;border-color:#dfe7ef!important}
body:has(.loan-application-main) .topbar nav>a:not(.nav-login):hover{color:#0877c9!important}
body:has(.loan-application-main) .topbar .language-select{border-color:#dfe7ef!important}
body:has(.loan-application-main) .topbar .language-select select{background:#f4f8fc!important;border-color:#dfe7ef!important;color:#10243a!important}
body:has(.loan-application-main) .topbar .menu-toggle{background:#f4f8fc!important}
body:has(.loan-application-main) .topbar .menu-toggle span{background:#10243a!important}
@media(max-width:780px){
  body:has(.loan-application-main) .topbar nav{background:#fff!important;border-color:#dfe7ef!important}
  body:has(.loan-application-main) .topbar nav .language-select{background:#f4f8fc!important;border-color:#dfe7ef!important}
}

body:has(.yc-home) .topbar nav>a:not(.nav-login):hover{color:#0877c9!important}
.yc-button-primary{background:#0877c9;box-shadow:0 12px 26px rgba(8,119,201,.22)}
.yc-button-primary:hover{background:#0666ad;box-shadow:0 16px 32px rgba(8,119,201,.28)}
.yc-hero{background:linear-gradient(135deg,#f8fbff 0%,#eef7fd 58%,#e9f8f5 100%)}
.yc-preview-top>b{color:#087c68}
.yc-preview-top>b i,.yc-adviser figcaption>i{background:#16b89b}
.yc-preview-financing{background:#09233f}
.yc-progress>span i{background:#16b89b}
.yc-chart-head small{color:#16b89b}
.yc-chart-line{stroke:#16b89b;filter:drop-shadow(0 5px 8px rgba(22,184,155,.24))}
.yc-chart-dot{stroke:#16b89b;filter:drop-shadow(0 4px 6px rgba(22,184,155,.3))}
.yc-metrics .is-income{background:#e5f8f4;color:#16b89b}
.yc-spending-bars i{background:linear-gradient(#2cccb0,#16b89b)}
.yc-spending-bars i:nth-child(3n){background:linear-gradient(#35a0e7,#0877c9)}
.yc-spending-legend i{background:#16b89b}
.yc-spending-legend span:nth-child(2) i{background:#0877c9}
.yc-security{background:linear-gradient(135deg,#09233f,#063e6b)}
body:has(.yc-home) .site-footer{background:#06192d!important}

/* Readable footer typography and a high-contrast call to action in every locale. */
.site-footer .site-footer-cta span{font-size:11px}
.site-footer .site-footer-cta p{font-size:15px;line-height:1.6;color:#c8d6df!important}
.site-footer .site-footer-cta>a{min-height:54px;max-width:100%;padding:12px 22px;background:#c8efe3!important;color:#09233f!important;font-size:15px;line-height:1.35;white-space:normal;text-align:center}
.site-footer .site-footer-cta>a:hover{background:#a9e8d6!important;color:#09233f!important}
.site-footer .site-footer-cta>a .ui-icon{flex:0 0 18px}
.site-footer .site-footer-main h3{font-size:13px;line-height:1.4}
.site-footer .site-footer-main nav a,.site-footer .site-footer-main nav button{font-size:14px;line-height:1.55;color:#c4d3dc!important}
.site-footer .site-footer-main nav a:hover,.site-footer .site-footer-main nav button:hover{color:#fff!important}
.site-footer .site-footer-brand>p{font-size:14px;line-height:1.65;color:#b9cad5!important}
.site-footer .site-footer-brand>span b{font-size:12px}
.site-footer .site-footer-brand>small{font-size:12px;line-height:1.5;color:#9db4c2!important}
.site-footer .site-footer-contact>p{font-size:14px;line-height:1.6;color:#b9cad5!important}
.site-footer .site-footer-contact>a small{font-size:11px;color:#a9bfcb!important}
.site-footer .site-footer-contact>a strong{font-size:13px}
.site-footer .site-footer-bottom>p,.site-footer .site-footer-bottom>a{font-size:12px;line-height:1.5;color:#9db4c2!important}
.site-footer .site-footer-languages a{min-width:36px;height:32px;font-size:11px;color:#a9bfcb!important}
.site-footer .site-footer-languages a:hover,.site-footer .site-footer-languages a.is-active{color:#fff!important}

.yc-login-page{background:linear-gradient(135deg,#f8fbff 0%,#eef7fd 58%,#e9f8f5 100%)}
.yc-login-visual{background:#09233f!important}
.yc-login-image-shade{background:linear-gradient(180deg,rgba(9,35,63,.24) 0%,rgba(9,35,63,.08) 32%,rgba(9,35,63,.88) 78%,#09233f 100%),linear-gradient(90deg,rgba(9,35,63,.24),transparent 60%)}
.yc-login-visual-top>span,.yc-login-trust-list li{background:rgba(9,35,63,.52)}
.yc-login-visual-top>span i{background:#16b89b}

.loan-application-main .application-panel-head .eyebrow{color:#16b89b!important}
.loan-application-main .application-form-block .form-step-label>span{background:#0877c9!important}
.application-progress li.is-active{border-color:#a9dfd4;background:#effaf7;color:#087c68}
.application-progress li.is-active>span{background:#daf4ee;color:#087c68}
.application-panel-secure{border-color:#bde8df;background:#effaf7;color:#087c68}

.site-preloader-spinner{border-top-color:#16b89b!important;border-right-color:#09233f!important}
input:focus,select:focus,textarea:focus{border-color:#0877c9!important;box-shadow:0 0 0 4px rgba(8,119,201,.14)!important}

@media(prefers-reduced-motion:reduce){
  .yc-button-primary{transition:none}
}

/* Keep the customer menu below the fixed header while the page scrolls. */
@media(min-width:901px){
  .client-dashboard-body .client-dashboard{--client-sidebar-width:280px}
  .client-dashboard-body .client-dashboard>aside.dashboard-sidebar{
    position:fixed;
    z-index:60;
    top:74px;
    bottom:0;
    left:0;
    width:var(--client-sidebar-width);
    height:auto;
    max-height:calc(100dvh - 74px);
    margin:0;
    overflow:hidden;
  }
  .client-dashboard-body .client-dashboard>.dashboard-main{
    grid-column:2;
    min-width:0;
  }
}
@media(min-width:901px) and (max-width:1180px){
  .client-dashboard-body .client-dashboard{--client-sidebar-width:245px}
}

/* Give the horizontal brand mark enough room in the public mobile header. */
@media(max-width:600px){
  body:not(.admin-body):not(.client-dashboard-body):not(.kyc-onboarding-body) .topbar .brand-logo-image{
    width:auto!important;
    height:58px!important;
    max-height:60px!important;
    max-width:min(200px,calc(100vw - 100px))!important;
    object-fit:contain;
  }
}

/* On narrow screens, clear the fixed header and keep consent choices in view. */
@media(max-width:620px){
  body:has(.yc-home) .yc-hero{padding-top:108px!important}
  .cookie-consent{
    left:max(12px,env(safe-area-inset-left))!important;
    right:max(12px,env(safe-area-inset-right))!important;
    bottom:max(12px,env(safe-area-inset-bottom))!important;
    width:auto!important;
    max-width:420px;
    max-height:calc(100dvh - 94px);
    overflow-y:auto;
    overscroll-behavior:contain;
    padding:16px!important;
    grid-template-columns:36px minmax(0,1fr)!important;
    gap:10px 12px!important;
    border-radius:16px!important;
    box-shadow:0 16px 45px rgba(9,35,63,.2)!important;
  }
  .cookie-consent:before{background:linear-gradient(180deg,#0877c9,#16b89b)}
  .cookie-consent-icon{width:36px;height:36px;border-radius:10px;background:#e7f4ff;color:#0877c9;box-shadow:none}
  .cookie-consent-icon .ui-icon{width:19px;height:19px}
  .cookie-consent-copy{min-width:0}
  .cookie-consent-copy>span{font-size:9px;line-height:1.3;letter-spacing:.05em}
  body:has(.yc-home) .cookie-consent-copy h2,.cookie-consent-copy h2{font-size:17px!important;line-height:1.25}
  body:has(.yc-home) .cookie-consent-copy p,.cookie-consent-copy p{font-size:12px!important;line-height:1.5}
  .cookie-consent-actions{
    position:sticky;
    bottom:-16px;
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:8px!important;
    margin-top:2px;
    padding:8px 0 0;
    background:#fff;
  }
  .cookie-button{min-width:0;min-height:44px;padding:8px 10px;white-space:normal;line-height:1.2;overflow-wrap:anywhere}
  .cookie-button-accept,.cookie-button-refuse{grid-row:auto!important}
}
