:root {
    --public-green: #087463;
    --public-green-dark: #075b4f;
    --public-green-soft: #eaf4f1;
    --public-gold: #c69a3a;
    --public-blue: #2f67c7;
    --public-ink: #1f2933;
    --public-muted: #65727e;
    --public-line: #dfe5e3;
    --public-bg: #f2f5f4;
    --public-radius: 6px;
    --public-shadow: 0 8px 24px rgba(24, 50, 43, 0.08);
}

body.app-default,
body.officialPortal {
    color: var(--public-ink);
    background: var(--public-bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
    letter-spacing: 0;
}

body.app-default *,
body.officialPortal *,
body.app-default *::before,
body.officialPortal *::before,
body.app-default *::after,
body.officialPortal *::after {
    box-sizing: border-box;
}

body.app-default a,
body.officialPortal a,
body.app-default input,
body.officialPortal input,
body.app-default button,
body.officialPortal button {
    letter-spacing: 0;
}

.srOnly {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Portal home */
.officialPortal.indexBody {
    display: block;
    height: auto;
    min-height: 100vh;
    margin: 0;
    background: var(--public-bg);
}

.portalShell {
    width: calc(100% - 48px);
    max-width: 1240px;
    margin: 0 auto;
}

.portalHeader {
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 72px;
    background: #fff;
    border-bottom: 1px solid var(--public-line);
    box-shadow: 0 2px 12px rgba(24, 50, 43, 0.06);
}

.portalHeaderInner {
    display: flex;
    align-items: center;
    height: 100%;
}

.portalBrand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    flex: 0 0 auto;
    color: var(--public-ink);
    text-decoration: none !important;
}

.portalBrand img {
    width: 46px;
    height: 46px;
    object-fit: contain;
}

.portalBrand span {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
}

.portalBrand strong {
    font-size: 18px;
    font-weight: 700;
}

.portalBrand small {
    color: var(--public-muted);
    font-size: 12px;
}

.portalNav {
    align-self: stretch;
    display: flex;
    align-items: stretch;
    gap: 4px;
    margin-left: 64px;
}

.portalNav a {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 84px;
    padding: 0 14px;
    color: #44515c;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none !important;
}

.portalNav a::after {
    position: absolute;
    right: 16px;
    bottom: 0;
    left: 16px;
    height: 3px;
    background: var(--public-gold);
    content: "";
    opacity: 0;
}

.portalNav a:hover,
.portalNav a.active {
    color: var(--public-green-dark);
    background: #f7faf9;
}

.portalNav a.active::after {
    opacity: 1;
}

.portalSearch {
    position: relative;
    width: 230px;
    margin-left: auto;
}

.portalSearch input[type="text"] {
    width: 100%;
    height: 38px;
    padding: 0 42px 0 13px;
    color: var(--public-ink);
    background: #f8faf9;
    border: 1px solid #d4dcda;
    border-radius: var(--public-radius);
    outline: none;
}

.portalSearch input[type="text"]:focus {
    background: #fff;
    border-color: var(--public-green);
    box-shadow: 0 0 0 3px rgba(8, 116, 99, 0.11);
}

.portalSearch button {
    position: absolute;
    top: 0;
    right: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 38px;
    color: var(--public-green-dark);
    background: transparent;
    border: 0;
    cursor: pointer;
}

.portalMain {
    height: auto;
    min-height: 0;
}

.portalWelcome {
    padding: 44px 0 38px;
    background: #fff;
    border-bottom: 1px solid var(--public-line);
}

.portalWelcomeInner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(420px, 0.85fr);
    gap: 64px;
    align-items: center;
}

.portalIdentity {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    grid-template-rows: auto auto;
    align-items: center;
    column-gap: 18px;
}

.portalIdentity img {
    grid-row: 1 / 3;
    width: 76px;
    height: 76px;
    object-fit: contain;
}

.portalIdentity h1 {
    align-self: end;
    margin: 0;
    color: var(--public-ink);
    font-size: 30px;
    font-weight: 750;
    line-height: 1.35;
}

.portalIdentity p {
    align-self: start;
    margin: 4px 0 0;
    color: var(--public-muted);
    font-size: 13px;
    font-weight: 600;
}

.portalEntry {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) 28px;
    gap: 14px;
    align-items: center;
    min-height: 104px;
    padding: 20px 24px;
    color: #fff !important;
    background-color: var(--public-green-dark);
    background-image: url('../img/bmrkbg.png');
    background-position: center;
    background-size: cover;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--public-radius);
    box-shadow: 0 10px 24px rgba(7, 91, 79, 0.18);
    text-decoration: none !important;
    cursor: pointer;
    touch-action: manipulation;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.portalEntry:hover {
    color: #fff;
    box-shadow: 0 14px 28px rgba(7, 91, 79, 0.24);
    transform: translateY(-2px);
}

.portalEntry.is-loading {
    pointer-events: none;
    cursor: wait;
    opacity: 0.92;
    transform: none;
}

.portalEntry.is-loading .portalEntryArrow {
    animation: portal-entry-loading 0.8s linear infinite;
}

@keyframes portal-entry-loading {
    to {
        transform: rotate(360deg);
    }
}

.portalEntryIcon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    color: var(--public-green-dark);
    background: #fff;
    border-radius: 50%;
    font-size: 22px;
}

.portalEntryText {
    display: flex;
    flex-direction: column;
}

.portalEntryText strong {
    font-size: 22px;
    font-weight: 700;
}

.portalEntryText small {
    margin-top: 3px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
}

.portalEntryArrow {
    font-size: 18px;
}

.portalNewsBand {
    padding: 38px 0 52px;
}

.portalNewsGrid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    background: #fff;
    border: 1px solid var(--public-line);
    border-radius: var(--public-radius);
    box-shadow: var(--public-shadow);
}

.portalNewsColumn {
    min-width: 0;
    padding: 26px 30px 28px;
}

.portalNewsColumn + .portalNewsColumn {
    border-left: 1px solid var(--public-line);
}

.portalNewsColumn > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--public-line);
}

.portalNewsColumn h2 {
    margin: 0;
    color: var(--public-ink);
    font-size: 19px;
    font-weight: 700;
}

.portalNewsColumn h2 i {
    margin-right: 7px;
    color: var(--public-green);
}

.portalNewsColumn > header > a {
    color: var(--public-muted);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none !important;
}

.portalNewsColumn > header > a:hover {
    color: var(--public-green);
}

.portalNewsList a {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr) 42px;
    gap: 9px;
    align-items: center;
    min-height: 47px;
    color: #35414c;
    border-bottom: 1px solid #edf0ef;
    font-size: 14px;
    text-decoration: none !important;
}

.portalNewsList a:last-child {
    border-bottom: 0;
}

.portalNewsList a:hover .portalNewsTitle {
    color: var(--public-green);
}

.portalNewsIndex {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    color: var(--public-green-dark);
    background: var(--public-green-soft);
    border-radius: 50%;
    font-size: 11px;
    font-weight: 700;
}

.portalNewsTitle {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.portalNewsList time {
    color: #8a949d;
    font-size: 12px;
    text-align: right;
}

.portalFooter {
    color: rgba(255, 255, 255, 0.72);
    background: #25302e;
}

.portalFooterInner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 112px;
    font-size: 13px;
}

.portalFooterContact {
    display: grid;
    gap: 8px;
    max-width: 890px;
    line-height: 1.55;
}

.portalFooterMeta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 22px;
    color: rgba(255, 255, 255, 0.9);
}

/* Public news and information pages */
body.app-default #kt_app_header {
    height: 72px;
    background: #fff;
    border-bottom: 1px solid var(--public-line);
    box-shadow: 0 2px 12px rgba(24, 50, 43, 0.06);
}

body.app-default .app-container.container-xxl {
    max-width: 1280px;
}

.publicBrand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: var(--public-ink);
    text-decoration: none !important;
}

.publicBrandText {
    color: var(--public-ink);
    font-size: 16px;
    font-weight: 700;
    white-space: nowrap;
}

body.app-default #kt_app_header_menu .menu-link {
    min-height: 44px;
    padding: 0 16px;
    border-radius: 0;
}

body.app-default #kt_app_header_menu .menu-title {
    color: #44515c;
    font-size: 14px !important;
    font-weight: 600;
}

body.app-default #kt_app_header_menu .menu-item.here > .menu-link {
    color: var(--public-green-dark);
    background: var(--public-green-soft);
    box-shadow: inset 0 -3px 0 var(--public-gold);
}

body.app-default #kt_app_toolbar,
body.app-default .app-main {
    background: var(--public-bg);
}

body.app-default .page-title {
    margin-top: 20px !important;
}

body.app-default .card {
    overflow: hidden;
    border: 1px solid var(--public-line);
    border-radius: var(--public-radius);
    box-shadow: var(--public-shadow);
}

.publicListCard .card-header,
.publicPopularCard .card-header {
    min-height: 62px;
    padding: 0 24px;
    border-bottom: 1px solid var(--public-line);
}

.publicListCard .card-body {
    padding: 8px 24px 24px;
}

.publicNewsItem {
    min-height: 132px;
    padding: 18px 0 !important;
    border-bottom: 1px solid #e8eceb;
}

.publicNewsItem:last-of-type {
    border-bottom: 0;
}

.publicNewsThumb {
    width: 104px !important;
    height: 96px !important;
}

.publicNewsThumb .symbol,
.publicNewsThumb .symbol-label {
    width: 96px !important;
    height: 96px !important;
    margin: 0 !important;
    border-radius: var(--public-radius);
}

.publicNewsFallback,
.publicPopularFallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--public-green);
    background: var(--public-green-soft);
    border: 1px solid #d1e3de;
    border-radius: var(--public-radius);
}

.publicNewsFallback {
    width: 96px;
    height: 96px;
    font-size: 27px;
}

.publicNewsContent {
    min-width: 0;
    margin-left: 20px !important;
}

.publicNewsContent .article-title {
    margin-bottom: 8px;
}

.publicNewsContent .article-title a {
    color: var(--public-ink) !important;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.5;
}

.publicNewsContent .article-title a:hover {
    color: var(--public-green) !important;
}

.publicNewsContent > p {
    display: -webkit-box;
    overflow: hidden;
    color: var(--public-muted) !important;
    font-size: 13px !important;
    font-weight: 400 !important;
    line-height: 1.7;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.publicNewsContent .article-tag {
    margin-top: 8px;
}

.publicPopularCard .card-body {
    padding: 16px 22px 22px;
}

.publicPopularItem {
    justify-content: flex-start !important;
    min-width: 0;
    margin-bottom: 16px !important;
    padding-bottom: 16px;
    border-bottom: 1px solid #e9edec;
}

.publicPopularItem:last-child {
    margin-bottom: 0 !important;
    border-bottom: 0;
}

.publicPopularItem > .m-0 {
    min-width: 0;
}

.publicPopularFallback {
    flex: 0 0 56px;
    width: 56px;
    height: 56px;
    font-size: 18px;
}

.publicArticleCard {
    padding: 38px 42px !important;
}

.publicArticleTitle {
    margin: 0 0 16px;
    color: var(--public-ink) !important;
    font-size: 27px;
    line-height: 1.45;
}

.publicArticleBody {
    color: #46525d !important;
    font-size: 16px !important;
    font-weight: 400 !important;
    line-height: 1.9;
}

.publicArticleBody img {
    max-width: 100%;
    height: auto;
}

.publicArticleBody table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
}

body.app-default #kt_app_footer {
    background: #25302e;
}

body.app-default #kt_app_footer .text-dark,
body.app-default #kt_app_footer .menu-link {
    color: rgba(255, 255, 255, 0.68) !important;
}

@media (max-width: 991px) {
    .portalWelcomeInner {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .portalNewsGrid {
        grid-template-columns: 1fr;
    }

    .portalNewsColumn + .portalNewsColumn {
        border-top: 1px solid var(--public-line);
        border-left: 0;
    }

    .publicBrandText {
        display: none;
    }

    body.app-default #kt_app_header_menu .menu-item.here > .menu-link {
        box-shadow: inset 3px 0 0 var(--public-gold);
    }
}

@media (max-width: 720px) {
    .portalShell {
        width: calc(100% - 24px);
    }

    .portalHeader {
        height: auto;
    }

    .portalHeaderInner {
        display: grid;
        grid-template-columns: 1fr auto;
        grid-template-areas:
            "brand search"
            "nav nav";
        min-height: 108px;
        padding-top: 8px;
    }

    .portalBrand {
        grid-area: brand;
    }

    .portalBrand img {
        width: 40px;
        height: 40px;
    }

    .portalBrand strong {
        font-size: 16px;
    }

    .portalSearch {
        grid-area: search;
        width: 42px;
        margin-left: 10px;
    }

    .portalSearch input[type="text"] {
        position: absolute;
        right: 0;
        width: 42px;
        padding: 0;
        color: transparent;
        background: #f4f7f6;
    }

    .portalSearch input[type="text"]::placeholder {
        color: transparent;
    }

    .portalSearch input[type="text"]:focus {
        width: min(260px, calc(100vw - 24px));
        padding: 0 42px 0 13px;
        color: var(--public-ink);
    }

    .portalSearch input[type="text"]:focus::placeholder {
        color: #929ca4;
    }

    .portalNav {
        grid-area: nav;
        align-self: auto;
        justify-content: center;
        height: 44px;
        margin-left: 0;
        border-top: 1px solid var(--public-line);
    }

    .portalNav a {
        flex: 1;
        min-width: 0;
        padding: 0 8px;
    }

    .portalWelcome {
        padding: 30px 0;
    }

    .portalIdentity {
        grid-template-columns: 58px minmax(0, 1fr);
        column-gap: 13px;
    }

    .portalIdentity img {
        width: 58px;
        height: 58px;
    }

    .portalIdentity h1 {
        font-size: 23px;
    }

    .portalIdentity p {
        font-size: 11px;
    }

    .portalEntry {
        grid-template-columns: 42px minmax(0, 1fr) 22px;
        min-height: 88px;
        padding: 16px 18px;
    }

    .portalEntryIcon {
        width: 42px;
        height: 42px;
        font-size: 19px;
    }

    .portalEntryText strong {
        font-size: 19px;
    }

    .portalNewsBand {
        padding: 20px 0 30px;
    }

    .portalNewsColumn {
        padding: 20px 18px 22px;
    }

    .portalNewsList a {
        grid-template-columns: 22px minmax(0, 1fr);
    }

    .portalNewsList time {
        display: none;
    }

    .portalFooterInner {
        display: grid;
        gap: 7px;
        padding: 18px 0;
    }

    .portalFooterMeta {
        display: grid;
        gap: 3px;
    }

    .publicListCard .card-body {
        padding: 4px 16px 18px;
    }

    .publicNewsItem {
        align-items: flex-start !important;
        min-height: 0;
        padding: 16px 0 !important;
    }

    .publicNewsContent {
        margin-left: 0 !important;
    }

    .publicArticleCard {
        padding: 24px 20px !important;
    }

    .publicArticleTitle {
        font-size: 22px;
    }

    .publicArticleBody {
        font-size: 15px !important;
    }
}
