:root {
    --modern-ink: #18212f;
    --modern-muted: #64748b;
    --modern-line: #e5e7eb;
    --modern-panel: #ffffff;
    --modern-soft: #f7fafc;
    --modern-accent: #15a36d;
    --modern-sand: #d8b45f;
}

html {
    scroll-behavior: smooth;
    max-width: 100%;
    overflow-x: hidden;
}

body {
    background: var(--modern-soft);
    color: var(--modern-ink);
    font-size: 15px;
    max-width: 100%;
    overflow-x: hidden;
}

header {
    background: rgba(255,255,255,.94);
    border-bottom: 1px solid rgba(15,23,42,.08);
    box-shadow: 0 18px 45px rgba(15,23,42,.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}

#topbar {
    background: #162131;
    box-shadow: none;
}

#header {
    max-width: 1180px;
    height: auto;
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 18px;
}

#logo,
#logo h1,
#logo a {
    display: flex;
    align-items: center;
    height: auto;
}

#logo img {
    max-height: 62px;
    width: auto;
}

#menu {
    float: none;
}

#menu a {
    border-radius: 6px;
    color: var(--modern-ink);
    font-size: 13px;
    letter-spacing: 0;
    padding: 13px 16px;
}

#menu li {
    border: 0;
}

#menu li:first-child {
    border: 0;
}

#menu li:hover > a {
    background: #162131;
    color: #fff;
}

#menu .sub-menu {
    background: #162131;
    border: 0;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 20px 45px rgba(15,23,42,.24);
    display: none !important;
    overflow: visible;
    visibility: visible;
    right: auto;
}

#menu li:hover > .sub-menu {
    display: block !important;
}

#menu .sub-menu li,
#menu .sub-menu a {
    height: auto;
    line-height: 1.35;
}

#menu > ul > li > .sub-menu {
    left: 0;
    right: auto;
}

#menu > ul > li:nth-last-child(-n+2) > .sub-menu {
    left: auto;
    right: 0;
}

#menu .sub-menu .sub-menu {
    left: auto !important;
    right: 100% !important;
    margin: -1px 1px 0 0 !important;
}

#slider {
    background: #162131;
}

#main,
.innerContainer {
    max-width: 1180px;
}

#home .postsWidget,
.xbox,
.widgetContent,
.post.standard {
    border: 1px solid var(--modern-line);
    border-radius: 8px;
    box-shadow: 0 14px 34px rgba(15,23,42,.08);
}

.postsWidget.homeWidget {
    background: transparent;
    border: 0;
    box-shadow: none;
    margin: 26px 0;
}

.heading {
    background: transparent;
    border: 0;
    color: var(--modern-ink);
    font-size: 22px;
    line-height: 1.25;
    padding: 18px 10px 8px;
}

.heading .icon {
    color: var(--modern-accent);
}

.postsWidget .items.scroll {
    display: block !important;
}

.postsWidget.advanced2 .items,
.articleList {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin: 0;
}

.postsWidget.advanced2 .list .container,
.postsWidget.advanced2 .container,
.articleList .container {
    float: none;
    width: auto;
    padding: 0;
    margin: 0;
}

.post.standard {
    overflow: hidden;
    background: var(--modern-panel);
    transition: transform .2s ease, box-shadow .2s ease;
}

.post.standard:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 42px rgba(15,23,42,.14);
}

.post.standard .thumb img {
    width: 100% !important;
    height: 180px !important;
    object-fit: cover;
}

.post.standard .title {
    border: 0;
    padding: 12px;
    text-transform: none;
}

.post.standard .title a,
.post.standard .title a span {
    height: auto;
    max-height: none;
    color: var(--modern-ink);
    line-height: 1.35;
}

.post.standard .summary {
    height: 58px;
    color: var(--modern-muted);
    font-size: 13px;
    line-height: 1.5;
    margin: 0 12px 12px;
}

.post.standard .meta .more,
.safirbutton,
#content form input[type=submit] {
    background: var(--modern-accent);
    color: #fff;
    border-radius: 6px;
}

.post.standard .meta .more:hover,
.safirbutton:hover,
#content form input[type=submit]:hover {
    background: #117a55;
    color: #fff;
}

#featured {
    background: #162131;
}

#featured a {
    color: #fff;
}

#featured span.icon {
    color: var(--modern-sand);
}

#content,
aside {
    margin-top: 10px;
}

.mainHeading {
    background: #162131;
    color: #fff;
    border-radius: 8px 8px 0 0;
}

footer {
    background: #111827;
}

.floating-phone,
.floating-whatsapp {
    left: auto !important;
    right: 18px;
}

.floating-phone a,
.floating-whatsapp a {
    width: auto;
    height: auto;
    border-radius: 999px;
    box-shadow: 0 12px 28px rgba(15,23,42,.2);
}

.floating-phone img,
.floating-whatsapp img {
    display: block;
    width: 150px;
    height: auto;
}

.floating-phone .tooltiptext,
.floating-whatsapp .tooltiptext {
    display: none;
    left: auto;
    right: 105%;
}

.floating-phone:hover .tooltiptext,
.floating-whatsapp:hover .tooltiptext {
    display: block;
}

#footer-menu ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px 12px;
}

#footer-menu li::before {
    display: none;
}

@media all and (max-width: 950px) {
    #header {
        display: block;
        padding: 8px 12px;
    }

    #menu .toggleMenu {
        color: var(--modern-ink);
        line-height: 54px;
    }

    #menu ul li,
    #menu ul li:first-child,
    #menu ul .sub-menu li,
    #menu ul .sub-menu li:first-child {
        background: #162131;
    }

    #menu a,
    #menu .sub-menu a {
        border-top: 1px solid rgba(255,255,255,.12);
        border-radius: 0;
        white-space: normal;
        word-break: break-word;
    }

    #menu .sub-menu,
    #menu > ul > li:nth-last-child(-n+2) > .sub-menu,
    #menu .sub-menu .sub-menu {
        display: block !important;
        left: 0;
        right: auto;
        width: 100%;
        margin: 0;
    }
}

@media all and (max-width: 860px) {
    .postsWidget.advanced2 .items,
    .articleList {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media all and (max-width: 560px) {
    body {
        font-size: 14px;
    }

    #header {
        min-height: 66px;
    }

    #logo img {
        max-height: 52px;
    }

    .postsWidget.advanced2 .items,
    .articleList {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .heading {
        font-size: 19px;
    }

    .floating-phone img,
    .floating-whatsapp img {
        width: 108px;
    }

    .floating-phone .tooltiptext,
    .floating-whatsapp .tooltiptext {
        display: none !important;
    }

    #footer-menu ul {
        justify-content: center;
    }
}

/* Strong modern layer loaded last to override the legacy theme safely. */
#topbar .innerContainer,
#header,
#main,
#home .innerContainer,
footer .innerContainer {
    width: min(1180px, calc(100% - 32px));
    max-width: 1180px;
    padding-left: 0;
    padding-right: 0;
}

#topbar {
    font-size: 13px;
}

#topInfo,
#topbar .rightBlock {
    margin-top: 8px;
    margin-bottom: 8px;
}

#header {
    background: #fff;
    border-radius: 0 0 8px 8px;
}

#menu > ul {
    display: flex;
    align-items: center;
    gap: 4px;
}

#menu > ul > li > a {
    color: #172033;
    background: transparent;
}

#menu > ul > li:hover > a {
    background: #172033;
    color: #fff;
}

#slider {
    padding: 22px 0;
    background: linear-gradient(135deg, #172033 0%, #1b8f6a 100%);
}

#slider .rev_slider_wrapper {
    width: min(1180px, calc(100% - 32px)) !important;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(15,23,42,.22);
}

#featured .innerContainer {
    width: min(1180px, calc(100% - 32px));
}

#featured .table,
#featured .table > ul {
    display: block;
}

#featured ul {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    padding: 14px 0;
}

#featured li {
    display: block;
    width: auto;
    float: none;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 8px;
    background: rgba(255,255,255,.06) !important;
}

#featured a {
    padding: 16px 10px;
    line-height: 1.35;
}

.postsWidget.categories,
.postsWidget.advanced2 {
    padding: 16px 0 28px;
}

.postsWidget.categories .items.scroll {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 18px;
}

.postsWidget.categories .item {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 14px 34px rgba(15,23,42,.08);
    margin: 0;
    padding: 18px 12px;
}

.postsWidget.categories .item .thumb {
    border-radius: 8px;
    border-width: 0;
    max-width: 140px;
}

.postsWidget.categories .item .thumb img {
    width: 140px !important;
    height: 120px !important;
    object-fit: cover;
    border-radius: 8px;
}

.postsWidget.categories .item .shape {
    display: none;
}

#main {
    background: transparent;
}

#content,
aside {
    box-sizing: border-box;
}

#content .xbox,
#single,
#contactBlock,
.reading {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 14px 34px rgba(15,23,42,.08);
    padding: 18px;
}

#contactBlock .form form input,
#contactBlock .form form textarea,
#content form input[type=text],
#content form input[type=password],
#content form input[type=email],
#content form textarea,
#content form select {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    border-radius: 6px;
    border: 1px solid #d8dee8;
    background: #fff;
}

.wpcf7-form-control-wrap.telefon {
    position: relative !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    display: block !important;
    width: 100% !important;
}

.wpcf7-form-control-wrap.telefon input {
    width: 100% !important;
}

#footer-menu a {
    display: inline-flex;
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
}

@media all and (max-width: 950px) {
    #menu > ul {
        display: none;
    }

    #menu > ul.open,
    #menu div.menu > ul.open {
        display: block;
    }
}

@media all and (max-width: 860px) {
    #featured ul,
    .postsWidget.categories .items.scroll {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media all and (max-width: 560px) {
    #topbar .innerContainer,
    #header,
    #main,
    #home .innerContainer,
    footer .innerContainer,
    #slider .rev_slider_wrapper {
        width: min(calc(100% - 20px), 1180px) !important;
    }

    #slider {
        padding: 12px 0;
    }

    #featured ul,
    .postsWidget.categories .items.scroll {
        grid-template-columns: 1fr;
    }

    #content .xbox,
    #single,
    #contactBlock,
    .reading {
        padding: 14px;
    }
}
