/* =========================================================
   MGT Europe — Homepage Stylesheet
   Scope-first, homepage-specific layout and component rules.
   Comments are technical only.
   Structure:
   1) Homepage spacing & section rhythm
   2) Hero block
   3) Section headings
   4) Main categories grid
   5) Our Products / Key contacts split
   6) Panel internals: bullets, note, CTAs, contacts
   7) Responsive rules
   ========================================================= */

/* ------------------------------
   1) Homepage spacing & section rhythm
   ------------------------------ */

.home-main {
    padding: 34px 0 8px;
}

.home-section {
    padding: 0 0 34px;
}

.home-section+.home-section {
    padding-top: 10px;
}

.brand-sites {
    margin-top: 6px;
}

/* ------------------------------
   2) Hero block
   ------------------------------ */

.home-hero .wrap {
    max-width: var(--max);
}

.home-hero-box {
    background: linear-gradient(180deg, #ffffff 0%, #f7f9ff 100%);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--sh);
    padding: 34px 34px 30px;
    overflow: hidden;
}

.home-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.72fr) minmax(360px, 0.72fr);
    gap: 26px;
    align-items: start;
}

.home-hero-main {
    min-width: 0;
}

.home-hero-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 14px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid rgba(20, 42, 128, .12);
    box-shadow: 0 4px 10px rgba(9, 20, 60, .05);
    color: var(--purple);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.home-hero-title {
    margin: 0;
    color: #1c2550;
    letter-spacing: -.02em;
}

.hero-title-line1,
.hero-title-line2 {
    display: block;
    font-size: clamp(24px, 2.85vw, 42px);
    line-height: 1.04;
    font-weight: 800;
}

.hero-title-line1 {
    white-space: nowrap;
}

.home-hero h1 {
    margin: 0;
    max-width: none;
    line-height: 1.08;
    letter-spacing: -.02em;
    color: #1c2550;
    text-wrap: balance;
}

.nowrap {
    white-space: nowrap;
}

.home-hero-text {
    margin: 22px 0 0;
    max-width: 980px;
    font-size: clamp(16px, 1.02vw, 18px);
    line-height: 1.72;
    color: #3a4666;
    text-wrap: pretty;
}

.home-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.home-hero-actions .link-pill {
    padding: 10px 16px;
    min-height: 46px;
}

.home-hero-side {
    display: grid;
    gap: 16px;
    padding-top: 28px;
}

.home-hero-side-card {
    background: rgba(255, 255, 255, .9);
    border: 1px solid rgba(20, 42, 128, .10);
    border-radius: 14px;
    box-shadow: 0 8px 18px rgba(9, 20, 60, .05);
    padding: 18px 20px 16px;
}

.home-hero-side-title {
    margin: 0 0 10px;
    font-size: 14px;
    line-height: 1.3;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--purple);
}

.home-hero-side-card p {
    margin: 0;
    font-size: 15px;
    line-height: 1.72;
    color: var(--ink-2);
}

.home-hero-points {
    margin: 0;
    padding-left: 18px;
}

.home-hero-points li {
    margin: 8px 0;
    font-size: 15px;
    line-height: 1.58;
    color: var(--ink);
}

/* ------------------------------
   3) Section headings
   ------------------------------ */

.home-section-head {
    margin-bottom: 18px;
}

.home-section-head h2 {
    margin: 0;
    font-size: clamp(28px, 3vw, 40px);
    line-height: 1.12;
    letter-spacing: -.015em;
    color: #1d2550;
}

.home-section-head p {
    margin: 10px 0 0;
    max-width: 860px;
    font-size: 18px;
    line-height: 1.6;
    color: var(--ink-2);
}

.home-section-head-categories {
    margin-bottom: 18px;
}

.home-section-head-categories h2 {
    position: relative;
    display: inline-block;
    margin: 0;
    padding-bottom: 16px;
    font-size: clamp(28px, 3vw, 40px);
    line-height: 1.12;
    letter-spacing: -.015em;
    color: #1d2550;
    /*text-transform: uppercase;*/
}

.home-section-head-categories h2::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 96px;
    height: 4px;
    border-radius: 999px;
    background: var(--purple);
}

/* ------------------------------
   4) Main categories grid
   ------------------------------ */

.home-core .cat-grid {
    margin-top: 20px;
}

.home-core .cat-card {
    min-height: 100%;
    padding: 20px;
    gap: 14px;
    border-radius: 16px;
}

.home-core .cat-card::before {
    top: 18px;
    bottom: 18px;
}

.home-core .cat-top {
    align-items: flex-start;
}

.home-core .cat-name {
    font-size: 16px;
    line-height: 1.3;
    letter-spacing: .04em;
}

.home-core .cat-desc {
    font-size: 16px;
    line-height: 1.65;
}

.home-core .cat-cta {
    margin-top: auto;
}

.home-section-cta {
    margin-top: 22px;
    display: flex;
    justify-content: flex-start;
}

/* ------------------------------
   5) Our Products / Key contacts split
   ------------------------------ */

.home-about-contacts .wrap {
    max-width: var(--max);
}

.home-split {
    display: grid;
    grid-template-columns: minmax(0, 1.62fr) minmax(320px, 0.78fr);
    gap: 22px;
    align-items: stretch;
}

.home-split>* {
    min-width: 0;
}

.home-panel {
    background: linear-gradient(180deg, #ffffff 0%, #f7f9ff 100%);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--sh);
    padding: 28px 28px 24px;
    height: 100%;
}

.home-panel h2 {
    margin: 0 0 14px;
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.14;
    letter-spacing: -.015em;
    color: #1d2550;
}

.home-panel p {
    margin: 0 0 12px;
    font-size: 17px;
    line-height: 1.72;
    color: var(--ink-2);
}

.home-panel-about {
    position: relative;
    grid-column: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.home-panel-about,
.home-panel-contacts {
    min-width: 0;
}

.home-panel-contacts {
    grid-column: 2;
    margin-top: 0;
    min-width: 0;
}

.home-contact-block p,
.home-contact-block a {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.home-panel-about::before {
    content: "";
    position: absolute;
    left: 0;
    top: 20px;
    bottom: 20px;
    width: 4px;
    border-radius: 2px;
    background: var(--purple);
}

/* ------------------------------
   6) Panel internals: bullets, note, CTAs, contacts
   ------------------------------ */

.about-subtitle {
    margin: 22px 0 10px;
    font-size: 14px;
    line-height: 1.3;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--purple);
}

.home-bullets {
    margin: 14px 0 6px;
    padding-left: 22px;
}

.home-bullets li {
    margin: 8px 0;
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink);
}

.product-note {
    margin: 24px 0 0;
    padding: 14px 0 0;
    background: transparent;
    border: 0;
    border-top: 1px solid rgba(20, 42, 128, 0.12);
    border-radius: 0;
    box-shadow: none;
    font-size: 15px;
    line-height: 1.72;
    color: #465271;
    max-width: 92%;
}

.product-note::before {
    content: "Enquiries";
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--purple);
}

.home-panel-cta {
    margin-top: auto;
    padding-top: 22px;
}

.home-panel-contacts h2 {
    margin-bottom: 18px;
}

.home-contact-block+.home-contact-block {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid rgba(20, 42, 128, .10);
}

.home-contact-block h3 {
    margin: 0 0 10px;
    font-size: 14px;
    line-height: 1.3;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--purple);
}

.home-contact-block p {
    margin: 0 0 8px;
    font-size: 17px;
    line-height: 1.55;
    color: var(--ink);
}

.home-contact-block a {
    color: #213076;
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid transparent;
}

.home-contact-block a:hover,
.home-contact-block a:focus-visible {
    color: var(--purple);
    border-bottom-color: currentColor;
    outline: none;
}

/* ------------------------------
   7) Responsive rules
   ------------------------------ */

@media (max-width: 1280px) {
    .home-hero-grid {
        grid-template-columns: minmax(0, 1.62fr) minmax(340px, 0.78fr);
    }

    .hero-title-line1,
    .hero-title-line2 {
        font-size: clamp(24px, 2.7vw, 39px);
    }
}

@media (max-width: 1200px) {
    .home-hero-box {
        padding: 30px 28px 28px;
    }

    .home-panel {
        padding: 24px 24px 22px;
    }

    .home-hero-grid {
        gap: 22px;
    }
}

@media (max-width: 980px) {
    .home-main {
        padding-top: 28px;
    }

    .home-split {
        grid-template-columns: 1fr;
    }

    .home-hero h1 {
        max-width: none;
    }

    .hero-title-line1 {
        white-space: nowrap;
    }

    .hero-title-line2 {
        white-space: nowrap;
    }

    .home-hero-text {
        max-width: 100%;
    }

    .home-panel-contacts {
        grid-column: auto;
        margin-top: 0;
    }
}

@media (max-width: 820px) {
    .mainnav .tabs {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0;
    }

    .mainnav .tab {
        min-width: 0;
        position: relative;
        border: 0;
    }

    .mainnav .tab::before,
    .mainnav .tab::after,
    .mainnav .label::before,
    .mainnav .label::after {
        content: none !important;
        display: none !important;
    }

    /* Horizontal separators only */
    .mainnav .tab:nth-child(n + 3) {
        border-top: 1px solid rgba(255, 255, 255, 0.22);
    }

    /* Last item full width */
    .mainnav .tab:last-child {
        grid-column: 1 / -1;
    }

    .mainnav .label {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        flex-wrap: wrap;
        text-align: center;
        padding: 18px 16px;
    }

    .mainnav .label a {
        display: inline;
        white-space: normal;
        word-break: normal;
        line-height: 1.35;
        text-align: center;
    }

    .mainnav .tab .badge {
        position: static;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        width: auto;
        vertical-align: middle;
    }

    .home-hero-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .home-hero-side {
        padding-top: 6px;
    }

    .home-hero h1 {
        max-width: none;
    }

    .hero-title-line1,
    .hero-title-line2 {
        white-space: normal;
        font-size: clamp(28px, 6vw, 38px);
        line-height: 1.04;
    }
}

@media (max-width: 680px) {
    .home-main {
        padding-top: 22px;
    }

    .home-section {
        padding-bottom: 26px;
    }

    .home-hero-box {
        padding: 22px 18px 20px;
        border-radius: 14px;
    }

    .home-hero-kicker {
        margin-bottom: 14px;
    }

    .home-hero h1 {
        max-width: 100%;
        font-size: clamp(30px, 8vw, 42px);
        line-height: 1.06;
    }

    .home-hero-text {
        font-size: 16px;
        line-height: 1.68;
        margin-top: 16px;
    }

    .home-hero-actions {
        flex-direction: column;
        align-items: stretch;
        margin-top: 20px;
    }

    .home-hero-actions .link-pill {
        width: 100%;
        justify-content: space-between;
    }

    .hero-title-line1,
    .hero-title-line2 {
        white-space: normal;
    }

    .home-section-head {
        margin-bottom: 14px;
    }

    .home-section-head h2,
    .home-panel h2,
    .home-section-head-categories h2 {
        font-size: clamp(24px, 7vw, 32px);
    }

    .home-section-head p,
    .home-panel p {
        font-size: 16px;
    }

    .home-core .cat-card {
        padding: 16px;
        border-radius: 14px;
    }

    .home-core .cat-name,
    .home-core .cat-desc,
    .home-bullets li,
    .home-contact-block p,
    .home-hero-side-card p,
    .home-hero-points li,
    .product-note {
        font-size: 15px;
    }

    .home-panel {
        padding: 20px 18px 18px;
        border-radius: 14px;
    }

    .home-panel-about::before {
        top: 16px;
        bottom: 16px;
    }

    .home-section-cta,
    .home-panel-cta {
        display: flex;
    }

    .home-section-cta .link-pill,
    .home-panel-cta .link-pill {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 560px) {
    .mainnav .tabs {
        display: grid;
        grid-template-columns: 1fr;
    }

    .mainnav .tab {
        min-width: 0;
        position: relative;
        border: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.22);
    }

    .mainnav .tab:first-child {
        border-top: 0;
    }

    .mainnav .tab:last-child {
        grid-column: auto;
    }

    .mainnav .tab::before,
    .mainnav .tab::after,
    .mainnav .label::before,
    .mainnav .label::after {
        content: none !important;
        display: none !important;
    }

    .mainnav .label {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        flex-wrap: wrap;
        text-align: center;
        padding: 16px 14px;
    }

    .mainnav .label a {
        display: inline;
        white-space: normal;
        word-break: normal;
        line-height: 1.35;
        text-align: center;
    }

    .mainnav .tab .badge {
        position: static;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        width: auto;
        vertical-align: middle;
    }

    .mainnav .dropdown {
        display: none !important;
    }

    .mainnav .tab:nth-child(n + 3) {
        border-top: 1px solid rgba(255, 255, 255, 0.22);
    }
}

@media (max-width: 420px) {

    .home-hero-box,
    .home-panel,
    .home-core .cat-card,
    .home-hero-side-card {
        border-radius: 12px;
    }

    .home-hero-box {
        padding: 18px 14px 16px;
    }

    .home-panel {
        padding: 18px 14px 16px;
    }

    .home-core .cat-card {
        padding: 14px;
    }

    .home-hero-text,
    .home-section-head p,
    .home-panel p,
    .home-core .cat-desc,
    .home-bullets li,
    .home-contact-block p,
    .home-hero-side-card p,
    .home-hero-points li,
    .product-note {
        font-size: 15px;
    }
}

@media (prefers-reduced-motion: reduce) {

    .home-core .cat-card,
    .home-hero-actions .link-pill,
    .home-contact-block a {
        transition: none;
    }
}