@font-face {
    font-family: 'Boldonse';
    src: url('../fonts/Boldonse-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* =========================================================
   GLOBAL DESIGN VARIABLES
   ========================================================= */

:root {
    --gd-black: #171717;
    --gd-text: #252525;
    --gd-muted: #777777;
    --gd-white: #ffffff;
    --gd-soft: #f7f7f7;

    --gd-purple: #750787;
    --gd-pink: #e40372;
    --gd-blue: #004dff;
    --gd-orange: #ff8c00;

    --gd-rainbow:
        linear-gradient(
            90deg,
            #e40303 0%,
            #f44747 6%,
            #ff7043 12%,
            #ff9f43 18%,
            #ffd166 25%,
            #f5ef6d 32%,
            #8bcf6a 40%,
            #35a873 48%,
            #42c2b8 56%,
            #48a9e8 64%,
            #4f73d9 72%,
            #7656c9 79%,
            #9b59b6 85%,
            #d14a9b 91%,
            #f4477a 96%,
            #e40303 100%
        );

    --gd-radius: 18px;
    --gd-radius-small: 12px;

    --gd-shadow:
        0 12px 35px rgba(0, 0, 0, 0.08);

    --gd-shadow-hover:
        0 18px 45px rgba(117, 7, 135, 0.15);
}


/* =========================================================
   BASE
   ========================================================= */

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;

    font-size: 1rem;
    line-height: 1.7;
    font-weight: 400;

    color: var(--gd-text);
    background: var(--gd-white);

    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}


/* =========================================================
   SELECTION
   ========================================================= */

::selection {
    background: #750787;
    color: #ffffff;
}


/* =========================================================
   HEADINGS
   ========================================================= */

h1,
h2,
h3,
h4,
h5,
h6 {
    margin-top: 0;
    margin-bottom: 1rem;

    color: var(--gd-black);

    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.025em;
}

h1 {
    font-family: 'Boldonse', sans-serif;
    font-weight: 400;
    font-size: clamp(1.9rem, 4vw, 3.4rem);

    line-height: 1.45;
    letter-spacing: -0.025em;

    padding: 1rem 0 1.2rem;

    background: var(--gd-rainbow);
    background-size: 200% auto;

    -webkit-background-clip: text;
    background-clip: text;

    color: transparent;

    animation: gd-pride-gradient 9s linear infinite;
}

@keyframes gd-pride-gradient {
    from {
        background-position: 0% 50%;
    }

    to {
        background-position: 200% 50%;
    }
}

h2 {
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
}

h3 {
    font-size: clamp(1.35rem, 2.5vw, 2rem);
}

#g-footer h3 {
    color: pink;
}

h4 {
    font-size: 1.4rem;
}

h5 {
    font-size: 1.2rem;
}

h6 {
    font-size: 1rem;
}


/* =========================================================
   LINKS
   ========================================================= */

a {
    color: var(--gd-pink);
    text-decoration: none;

    transition:
        color 0.2s ease,
        opacity 0.2s ease;
}


/* =========================================================
   NAVIGATION
   ========================================================= */

#g-navigation {
    position: relative;

    background: #ffffff;
    color: #171717;

    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

#g-navigation::after {
    content: "";

    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;

    height: 3px;

    background: var(--gd-rainbow);

    opacity: 1;
}

#g-navigation .g-main-nav .g-menu-item-container,
#g-navigation .g-main-nav .g-menu-item-container > a,
#g-navigation .g-main-nav .g-menu-item-container > span {
    color: #171717 !important;
}

#g-navigation .g-main-nav .g-menu-item:hover .g-menu-item-container,
#g-navigation .g-main-nav .g-menu-item:hover .g-menu-item-container > a,
#g-navigation .g-main-nav .g-menu-item:hover .g-menu-item-container > span {
    color: #750787 !important;
}

#g-navigation .g-main-nav .g-menu-item.active .g-menu-item-container,
#g-navigation .g-main-nav .g-menu-item.active .g-menu-item-container > a,
#g-navigation .g-main-nav .g-menu-item.active .g-menu-item-container > span {
    color: #750787 !important;
}

#g-navigation .g-main-nav .g-menu-item-container {
    position: relative;
}

#g-navigation .g-main-nav .g-menu-item-container::after {
    content: "";

    position: absolute;
    left: 0.25rem;
    right: 0.25rem;
    bottom: -5px;

    height: 3px;

    border-radius: 999px;

    background: var(--gd-rainbow);

    transform: scaleX(0);
    transform-origin: center;

    transition:
        transform 0.3s ease;
}

#g-navigation .g-main-nav .g-menu-item:hover .g-menu-item-container::after,
#g-navigation .g-main-nav .g-menu-item.active .g-menu-item-container::after {
    transform: scaleX(1);
}


/* =========================================================
   DROPDOWN
   ========================================================= */

#g-navigation .g-dropdown {
    background: #ffffff !important;
    border: 1px solid rgba(0, 0, 0, 0.08);

    box-shadow:
        0 15px 40px rgba(0, 0, 0, 0.12);
}

#g-navigation .g-dropdown .g-menu-item-container,
#g-navigation .g-dropdown .g-menu-item-container > a,
#g-navigation .g-dropdown .g-menu-item-container > span {
    color: #171717 !important;
}

#g-navigation .g-dropdown .g-menu-item:hover .g-menu-item-container,
#g-navigation .g-dropdown .g-menu-item:hover .g-menu-item-container > a {
    color: #750787 !important;
}


/* =========================================================
   LOGO
   ========================================================= */

#g-navigation .g-logo {
    transition:
        transform 0.25s ease,
        opacity 0.25s ease;

    transform:
        rotate(-2deg)
        scale(1.04);
}


/* =========================================================
   SOCIAL ICONS
   ========================================================= */

#g-navigation .g-social {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 0.4rem;
}

#g-navigation .g-social a {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;

    border-radius: 50%;

    background: var(--gd-purple);
    color: #ffffff;

    transition:
        transform 0.25s ease,
        background 0.25s ease,
        color 0.25s ease;

    transform:
        translateY(-2px)
        rotate(-5deg);
}


/* =========================================================
   MAIN CONTENT
   ========================================================= */

.g-content {
    min-width: 0;
}

.g-mainbody .g-content {
    max-width: 100%;
}

.g-mainbody {
    line-height: 1.7;
}


/* =========================================================
   CUSTOM SECTIONS
   ========================================================= */

#g-nosto,
#g-ala1,
#g-ala2,
#g-kaupat {
    position: relative;

    padding-top: 4rem;
    padding-bottom: 4rem;
}

#g-nosto {
    padding-top: 5rem;
    padding-bottom: 5rem;

    overflow: hidden;

    background:
        radial-gradient(
            circle at 10% 20%,
            rgba(255, 0, 128, 0.06),
            transparent 30%
        ),
        radial-gradient(
            circle at 90% 10%,
            rgba(0, 102, 255, 0.06),
            transparent 30%
        ),
        #ffffff;
}

#g-ala1::before,
#g-ala2::before,
#g-kaupat::before {
    content: "";

    display: block;

    width: 90px;
    height: 3px;

    margin-bottom: 2rem;

    border-radius: 999px;

    background: var(--gd-rainbow);

    opacity: 0.7;
}

#g-nosto::after {
    content: "";

    position: absolute;

    width: 300px;
    height: 300px;

    right: -120px;
    top: -120px;

    border-radius:
        42% 58% 65% 35% /
        45% 35% 65% 55%;

    background:
        linear-gradient(
            135deg,
            rgba(255, 0, 128, 0.12),
            rgba(117, 7, 135, 0.05)
        );

    transform: rotate(20deg);

    pointer-events: none;
}


/* =========================================================
   HOMEPAGE CARDS
   ========================================================= */

.view-category .g-array-item {
    position: relative;

    height: 100%;

    padding-bottom: 1.5rem;

    background: #ffffff;

    border-radius: var(--gd-radius);

    transition:
        box-shadow 0.35s ease;
}

.view-category .g-array-item::before {
    content: "";

    position: absolute;

    top: 0;
    left: 14px;
    right: 14px;

    height: 3px;

    border-radius: 999px;

    background: var(--gd-rainbow);

    opacity: 0;

    transition:
        opacity 0.3s ease;
}

.view-category .g-array-item:hover::before {
    opacity: 1;
}


/* =========================================================
   CARD IMAGE 1:1
   ========================================================= */

.view-category .g-array-item-image {
    position: relative;

    width: 100%;
    aspect-ratio: 1 / 1;

    overflow: hidden;

    border-radius: var(--gd-radius);

    background: #111111;
}

.view-category .g-array-item-image > a {
    display: block;

    width: 100%;
    height: 100%;
}

.view-category .g-array-item-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center;

    transition:
        filter 0.5s ease;
}


/* =========================================================
   PRIDE LIGHT SWEEP
   ========================================================= */

.view-category .g-array-item-image::after {
    content: "";

    position: absolute;

    inset: -60%;

    z-index: 2;

    background:
        linear-gradient(
            120deg,
            transparent 35%,
            rgba(255, 0, 80, 0.22) 45%,
            rgba(255, 140, 0, 0.22) 48%,
            rgba(255, 237, 0, 0.18) 50%,
            rgba(0, 128, 38, 0.20) 52%,
            rgba(0, 77, 255, 0.22) 54%,
            rgba(117, 7, 135, 0.22) 57%,
            transparent 67%
        );

    transform:
        translateX(-100%)
        rotate(12deg);

    opacity: 0;

    pointer-events: none;

    transition:
        transform 0.9s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.2s ease;
}

.view-category .g-array-item:hover .g-array-item-image::after {
    transform:
        translateX(100%)
        rotate(12deg);

    opacity: 1;
}

.view-category .g-array-item-image img {
    filter:
        saturate(1.08)
        contrast(1.03);
}

.view-category .g-array-item-image::before {
    content: "";

    position: absolute;

    top: 14px;
    right: 14px;

    width: 11px;
    height: 11px;

    z-index: 3;

    border-radius: 50%;

    background:
        linear-gradient(
            135deg,
            #ff0080,
            #7928ca,
            #00c6ff
        );

    opacity: 0;

    transform: scale(0);

    transition:
        opacity 0.2s ease,
        transform 0.35s cubic-bezier(
            0.34,
            1.56,
            0.64,
            1
        );

    pointer-events: none;
}

.view-category .g-array-item:hover .g-array-item-image::before {
    opacity: 1;
    transform: scale(1);
}


/* =========================================================
   CARD TITLE
   ========================================================= */

.view-category .g-array-item-title {
    padding-top: 1.2rem;
}

.view-category .g-array-item-title .g-item-title {
    margin: 0;

    font-family: 'Boldonse', sans-serif;

    font-weight: 400;

    font-size:
        clamp(
            1.05rem,
            1.5vw,
            1.4rem
        );

    line-height: 1.35;

    letter-spacing: -0.015em;
}

.view-category .g-array-item-title .g-item-title a {
    color: var(--gd-purple);
}


/* =========================================================
   CARD DETAILS
   ========================================================= */

.view-category .g-array-item-details {
    display: flex;
    flex-wrap: wrap;

    gap: 0.35rem 0.8rem;

    margin-top: 0.7rem;

    color: var(--gd-muted);

    font-size: 0.72rem;
    font-weight: 700;

    letter-spacing: 0.06em;

    text-transform: uppercase;
}


/* =========================================================
   CARD TEXT
   ========================================================= */

.view-category .g-array-item-text {
    margin-top: 0.8rem;

    color: #555555;

    font-size: 0.95rem;
    line-height: 1.6;
}


/* =========================================================
   READ MORE
   ========================================================= */

.view-category .g-array-item-read-more {
    margin-top: 1rem;
}

.view-category .g-array-item-read-more .button {
    display: inline-flex;

    padding:
        0.45rem
        0.95rem;

    min-height: auto;

    border-radius: 999px;

    background: var(--gd-purple);
    color: #ffffff;

    font-size: 0.72rem;
    font-weight: 800;

    letter-spacing: 0.08em;

    text-transform: uppercase;

    transition:
        background 0.25s ease,
        transform 0.25s ease,
        box-shadow 0.25s ease;

    transform: translateY(-2px);

    box-shadow:
        0 8px 20px rgba(117, 7, 135, 0.22);
}

.view-category .g-array-item-read-more .button::after {
    display: none;
}


/* =========================================================
   ARTICLE PAGE
   ========================================================= */

.view-article .com-content-article.item-page {
    position: relative;
}

.view-article .page-header {
    position: relative;

    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
}

.view-article .page-header::after {
    content: "";

    display: block;

    width: 110px;
    height: 5px;

    margin-top: 1rem;

    border-radius: 999px;

    background: var(--gd-rainbow);

    background-size: 200% 100%;

    animation:
        gd-pride-gradient 6s linear infinite;
}

.view-article .page-header h1 {
    max-width: 100%;

    margin-bottom: 0;

    font-size:
        clamp(
            2rem,
            4vw,
            3.8rem
        );

    line-height: 1.45;
}


/* =========================================================
   ARTICLE META
   ========================================================= */

.view-article .article-info {
    display: flex;
    flex-wrap: wrap;

    gap: 0.4rem 1.2rem;

    margin-bottom: 1.25rem;
    padding: 0;

    color: #777777;

    font-size: 0.72rem;
    font-weight: 700;

    letter-spacing: 0.05em;

    text-transform: uppercase;
}

.view-article .article-info-term {
    display: none;
}

.view-article .article-info dd {
    margin: 0;
}

.view-article .article-info a {
    color: var(--gd-purple);
}

.view-article .article-info a::after {
    display: none;
}


/* =========================================================
   TAGS
   ========================================================= */

.view-article .tags {
    display: flex;
    flex-wrap: wrap;

    gap: 0.45rem;

    margin:
        0
        0
        2rem;

    padding: 0;

    list-style: none;
}

.view-article .tags li {
    margin: 0;
}

.view-article .tags .btn {
    display: inline-flex;
    align-items: center;

    min-height: auto;

    padding:
        0.35rem
        0.75rem;

    border: 1px solid rgba(117, 7, 135, 0.15);

    border-radius: 999px;

    background: var(--gd-rainbow);

    color: #ffffff;

    font-size: 0.68rem;
    font-weight: 800;

    letter-spacing: 0.06em;

    text-transform: uppercase;

    transition:
        background 0.25s ease,
        color 0.25s ease,
        transform 0.25s ease;

    transform: translateY(-2px);

    border-color: transparent;
}

.view-article .tags .btn::after {
    display: none;
}


/* =========================================================
   ARTICLE BODY
   ========================================================= */

.view-article .com-content-article__body {
    font-size: 1.05rem;
    line-height: 1.8;
}

.view-article .com-content-article__body p {
    margin-bottom: 1.45rem;
}


/* =========================================================
   ARTICLE SUBHEADINGS
   ========================================================= */

.view-article .com-content-article__body h2,
.view-article .com-content-article__body h3 {
    position: relative;

    margin-top: 3.5rem;
    margin-bottom: 1.2rem;

    padding-left: 0;
    padding-bottom: 0.65rem;

    border-left: none !important;
    border-right: none !important;
}

.view-article .com-content-article__body h2,
.view-article .com-content-article__body h3 {
    position: relative;
    margin-top: 3.5rem;
    margin-bottom: 1.2rem;
    padding-bottom: 0.65rem;
    border: none !important;
}

/* Luodaan tasan yksi sateenkaariviiva perusmuodossa */
.view-article .com-content-article__body h2::after,
.view-article .com-content-article__body h3::after {
    content: "" !important;
    display: block !important;
    position: static !important;
    width: 75px !important;
    height: 4px !important;
    margin-top: 0.65rem !important;
    border-radius: 999px !important;
    background: linear-gradient(
        90deg,
        #e40303 0%,
        #ff8c00 20%,
        #ffed00 40%,
        #008026 60%,
        #004dff 80%,
        #750787 100%
    ) !important;
    background-size: 200% 100% !important;
    transition: width 0.4s ease !important;
}

/* Hover-tila: Vain viivan leveys kasvaa, mikään muu ei muutu */
.view-article .com-content-article__body h2:hover::after,
.view-article .com-content-article__body h3:hover::after {
    width: 140px !important;
}

/* Varmistetaan, ettei mahdollisten linkkien kautta tule toista viivaa */
.view-article .com-content-article__body h2 a::after,
.view-article .com-content-article__body h3 a::after {
    display: none !important;
    content: none !important;
}

.view-article .com-content-article__body h2 {
    font-size:
        clamp(
            1.7rem,
            3vw,
            2.4rem
        );
}

.view-article .com-content-article__body h3 {
    font-size:
        clamp(
            1.3rem,
            2.2vw,
            1.8rem
        );
}


/* =========================================================
   ARTICLE IMAGES
   ========================================================= */

.view-article .com-content-article__body figure {
    position: relative;

    margin: 2.5rem 0;
    padding: 0;

    border: none !important;
}

.view-article .com-content-article__body figure img {
    display: block;

    width: 100%;
    height: auto;

    border-radius: var(--gd-radius);

    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.10);
}

.view-article .com-content-article__body figcaption {
    margin-top: 0.8rem;
    padding: 0;

    border: none !important;

    color: #777777;

    font-size: 0.8rem;
    font-style: italic;
    line-height: 1.5;
}

.view-article .com-content-article__body figure::before,
.view-article .com-content-article__body figure::after,
.view-article .com-content-article__body figcaption::before,
.view-article .com-content-article__body figcaption::after {
    display: none !important;

    content: none !important;

    border: none !important;
}


/* =========================================================
   ARTICLE LINKS
   ========================================================= */

.view-article .com-content-article__body a:not(.btn) {
    position: relative;

    color: var(--gd-purple);

    font-weight: 600;
}

.view-article .com-content-article__body a:not(.btn)::after {
    content: "";

    position: absolute;

    left: 0;
    right: 0;
    bottom: -2px;

    height: 2px;

    background: var(--gd-rainbow);

    transform: scaleX(0);
    transform-origin: right;

    transition:
        transform 0.25s ease;
}

.view-article .com-content-article__body a:not(.btn):hover::after {
    transform: scaleX(1);
    transform-origin: left;
}


/* =========================================================
   ARTICLE LISTS
   ========================================================= */

.view-article .com-content-article__body ul {
    padding-left: 0;
    list-style: none;
}

.view-article .com-content-article__body li {
    position: relative;

    margin-bottom: 0.75rem;
    padding-left: 1.4rem;
}

.view-article .com-content-article__body li::before {
    content: "✦";

    position: absolute;
    left: 0;

    color: var(--gd-pink);

    font-size: 0.85em;
}


/* =========================================================
   ARTICLE NAVIGATION
   ========================================================= */

.view-article .pagenavigation {
    margin-top: 3rem;

    padding-top: 1.5rem;

    border-top: 1px solid #eeeeee;
}

.view-article .pagenavigation .btn {
    border-radius: 999px;

    background: var(--gd-purple);
    color: #ffffff;
}


/* =========================================================
   SIDEBAR
   ========================================================= */

.view-article #g-sidebar,
.view-article #g-sidebar *,
.view-article .g-sidebar,
.view-article .g-sidebar * {
    border-left: none !important;
    border-right: none !important;
}

.view-article #g-sidebar .moduletable {
    position: relative;

    margin-bottom: 1.5rem;
    padding: 1.3rem;

    border: none !important;
    border-radius: var(--gd-radius);

    background: #f8f8f8;

    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.04);
}

.view-article #g-sidebar .g-title {
    position: relative;

    margin-bottom: 1rem;
    padding-bottom: 0.75rem;

    border: none !important;

    font-family: 'Boldonse', sans-serif;
    font-size: 1.25rem;
    font-weight: 400;
    line-height: 1.35;
}

.view-article #g-sidebar .g-title::after {
    content: "";

    display: block;

    width: 45px;
    height: 3px;

    margin-top: 0.6rem;

    border-radius: 999px;

    background: var(--gd-rainbow);
}

.view-article #g-sidebar ul,
.view-article #g-sidebar ol,
.view-article #g-sidebar li,
.view-article #g-sidebar .mod-list {
    border: none !important;
    border-top: none !important;
    border-bottom: none !important;

    box-shadow: none !important;
}

.view-article #g-sidebar .mod-list {
    margin: 0;
    padding: 0;

    list-style: none;
}

.view-article #g-sidebar .mod-list li {
    margin: 0;
    padding: 0.65rem 0;

    border: none !important;
}

.view-article #g-sidebar .mod-list a {
    display: inline;

    color: var(--gd-purple);

    font-size: 0.9rem;
    line-height: 1.4;
}


/* =========================================================
   SIDEBAR - GENERIC GANTRY DIVIDERS
   ========================================================= */

#g-sidebar .module-title,
#g-sidebar .module-title *,
#g-sidebar .moduletable,
#g-sidebar .moduletable *,
#g-sidebar .g-content,
#g-sidebar .g-content *,
#g-sidebar .g-title {
    border-left: none !important;
    border-right: none !important;
}

#g-sidebar .moduletable {
    border-top: none !important;
    border-bottom: none !important;
}


/* =========================================================
   FOOTER
   ========================================================= */

#g-footer {
    position: relative;

    margin-top: 4rem;

    background: #171717;
    color: #ffffff;
}

#g-footer::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;
    right: 0;

    height: 5px;

    background: var(--gd-rainbow);
}

#g-footer a {
    color: #ffffff;
}

#g-footer a::after {
    display: none;
}

#g-footer .g-logo {
    transition:
        transform 0.3s ease;

    transform:
        rotate(-3deg)
        scale(1.05);
}

#g-footer .g-horizontalmenu {
    display: flex;
    flex-wrap: wrap;

    justify-content: flex-end;

    gap: 0.8rem 1.2rem;
}

#g-footer .g-horizontalmenu li {
    margin: 0;
}

#g-footer .g-totop a {
    display: inline-flex;
    align-items: center;

    gap: 0.35rem;

    padding:
        0.45rem
        0.8rem;

    border-radius: 999px;

    background: var(--gd-purple);
    color: #ffffff;

    font-size: 0.75rem;
    font-weight: 700;

    transition:
        background 0.25s ease,
        transform 0.25s ease;

    transform: translateY(-2px);
}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

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

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;

        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;

        transition-duration: 0.01ms !important;
    }

    h1 {
        animation: none;
    }
}




/* 1. Pakotetaan kuvien korkeus (kumoaa Bootstrapin height: auto) */
.sppb-addon-articles .sppb-addon-article-layout-magazine-content img {
    height: 250px !important;
    object-fit: cover; /* Varmistaa, ettei kuva veny muodottomaksi */
}
.sppb-addon-articles .sppb-article-info-wrap h3 a {
    text-decoration: none !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

/* 2. Pakotetaan otsikon marginaali (kumoaa Heliumin h3-vakioasetukset) */
.sppb-addon-articles .sppb-article-info-wrap h3 {
    margin-top: 50px !important;
    font-size: 1.4rem;
}
/* Poistetaan alaviiva Magazine-layoutin artikkelien otsikoista */
.sppb-addon-articles .sppb-article-info-wrap h3 a {
    text-decoration: none !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

/* Varmistetaan, ettei alaviiva ilmesty myöskään silloin, kun hiiri viedään otsikon päälle */
.sppb-addon-articles .sppb-article-info-wrap h3 a:hover {
    text-decoration: none !important;
}

/* 3. Varmistetaan Grid-asettelu ja palstojen määrä (kumoaa teeman mahdolliset flex-pakotukset) */
.sppb-addon-articles .sppb-addon-article-layout-magazine-row {
    display: grid !important;
    grid-template-columns: repeat(5, 1fr) !important;
    gap: 15px !important;
}

/* Responsiivisuus: 4 palstaa tableteille (valinnainen, mutta suositeltu) */
@media (max-width: 1199.98px) {
    .sppb-addon-articles .sppb-addon-article-layout-magazine-row {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

/* Responsiivisuus: 2 palstaa pienille tableteille / isoille puhelimille */
@media (max-width: 767.98px) {
    .sppb-addon-articles .sppb-addon-article-layout-magazine-row {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* Responsiivisuus: 1 palsta pienille ruuduille */
@media (max-width: 575.98px) {
    .sppb-addon-articles .sppb-addon-article-layout-magazine-row {
        grid-template-columns: repeat(1, 1fr) !important;
    }
}
/* =========================================================
   GANTRY GRID RESET
   ========================================================= */

.most-watched .g-grid {
    display: block;

    width: 100%;

    margin: 0 !important;
    padding: 0 !important;

    border: none !important;
}


.most-watched .g-block {
    width: 100% !important;

    margin: 0 !important;
    padding: 0 !important;

    border: none !important;
}


.most-watched .g-content {
    margin: 0 !important;
    padding: 0 !important;

    border: none !important;
}


/* =========================================================
   ARTICLE ITEM
   ========================================================= */

.most-watched .g-array-item {
    position: relative;

    display: flex;
    align-items: center;

    width: 100%;

    min-height: 96px;

    margin: 0 !important;
    padding: 0.65rem 0;

    border: none !important;

    background: transparent;

    overflow: visible;
}


/* Separation between articles */

.most-watched .g-grid + .g-grid {
    margin-top: 0.35rem !important;
    padding-top: 0.35rem !important;
}


/* =========================================================
   IMAGE CONTAINER
   ========================================================= */

.most-watched .g-array-item-image {
    position: relative;

    flex: 0 0 84px;

    width: 84px;
    height: 84px;

    margin: 0 1rem 0 0;
    padding: 0;

    aspect-ratio: 1 / 1;

    border-radius: 50%;

    background: #111111;

    overflow: hidden;


    /*
     * Keeps all visual effects inside the image.
     */
    isolation: isolate;

    transition:
        transform 0.35s
        cubic-bezier(
            0.34,
            1.56,
            0.64,
            1
        );
}


/* =========================================================
   IMAGE
   ========================================================= */

.most-watched .g-array-item-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;

    /*
     * Strong default zoom.
     *
     * Small sidebar images benefit from
     * showing more of the actual artwork.
     */

    border-radius: 50%;

    border: 3px solid #ffffff;

    box-sizing: border-box;

    filter:
        saturate(1.08)
        contrast(1.04);

   transform: scale(2); 

    transition:
        transform 0.6s
        cubic-bezier(
            0.22,
            1,
            0.36,
            1
        ),
        filter 0.4s ease;
}



/* =========================================================
   IMAGE LINK
   ========================================================= */

.most-watched .g-array-item-image > a {
    display: block;

    width: 100%;
    height: 100%;

    border-radius: 50%;
}


/* =========================================================
   PRIDE COLOUR OVERLAY
   ========================================================= */

.most-watched .g-array-item-image::before {
    content: "";

    position: absolute;

    inset: 0;

    z-index: 2;

    border-radius: 50%;

    background:
        linear-gradient(
            135deg,
            rgba(255, 0, 128, 0.20),
            transparent 35%,
            transparent 65%,
            rgba(0, 77, 255, 0.20)
        );

    opacity: 0.35;

    mix-blend-mode: screen;

    pointer-events: none;

    transition:
        opacity 0.4s ease;
}


/* =========================================================
   SHINE
   ========================================================= */

.most-watched .g-array-item-image::after {
    content: "";

    position: absolute;

    inset: -70%;

    z-index: 3;

    border-radius: 50%;

    background:
        linear-gradient(
            120deg,
            transparent 40%,
            rgba(255, 255, 255, 0.78) 49%,
            transparent 58%
        );

    transform:
        translateX(-80%)
        rotate(25deg);

    opacity: 0;

    pointer-events: none;

    transition:
        transform 0.8s
        cubic-bezier(
            0.22,
            1,
            0.36,
            1
        ),
        opacity 0.2s ease;
}


/* =========================================================
   HOVER
   ========================================================= */

.most-watched .g-array-item:hover
.g-array-item-image {
    transform:
        scale(1.08)
        rotate(-4deg);
}


.most-watched .g-array-item:hover
.g-array-item-image img {
    transform: scale(1.52);

    filter:
        saturate(1.30)
        contrast(1.08)
        brightness(1.05);
}


.most-watched .g-array-item:hover
.g-array-item-image::before {
    opacity: 0.65;
}


.most-watched .g-array-item:hover
.g-array-item-image::after {
    opacity: 1;

    transform:
        translateX(80%)
        rotate(25deg);
}


/* =========================================================
   ARTICLE TITLE
   ========================================================= */

.most-watched .g-array-item-title {
    flex: 1;

    min-width: 0;

    margin: 0 !important;
    padding: 0 !important;

    border: none !important;
}


.most-watched .g-array-item-title
.g-item-title {
    margin: 0;

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;

    font-size: 0.95rem;

    font-weight: 700;

    line-height: 1.35;

    letter-spacing: -0.01em;
}


.most-watched .g-array-item-title
.g-item-title a {
    color: #252525;

    text-decoration: none;

    transition:
        color 0.2s ease;
}


.most-watched .g-array-item-title
.g-item-title a:hover {
    color: #750787;
}


/* =========================================================
   PRIDE HOVER DOT
   ========================================================= */

.most-watched .g-array-item::before {
    content: "";

    position: absolute;

    left: 74px;
    top: 12px;

    width: 9px;
    height: 9px;

    z-index: 5;

    border-radius: 50%;

    background:
        linear-gradient(
            135deg,
            #ff0080,
            #750787
        );

    border: 2px solid #ffffff;

    opacity: 0;

    transform: scale(0);

    transition:
        opacity 0.2s ease,
        transform 0.3s
        cubic-bezier(
            0.34,
            1.56,
            0.64,
            1
        );

    pointer-events: none;
}


.most-watched .g-array-item:hover::before {
    opacity: 1;

    transform: scale(1);
}


/* =========================================================
   READ MORE
   ========================================================= */

.most-watched .g-array-item-read-more {
    margin-top: 0.35rem;
}


.most-watched .g-array-item-read-more .button {
    min-height: auto;

    padding:
        0.3rem
        0.65rem;

    border-radius: 999px;

    background: #171717;

    color: #ffffff;

    font-size: 0.65rem;

    line-height: 1;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}


.most-watched .g-array-item-read-more .button:hover {
    background: #750787;

    color: #ffffff;

    transform: translateY(-1px);
}


/* =========================================================
   REMOVE GANTRY BORDERS
   ========================================================= */

.most-watched,
.most-watched *,
.most-watched .g-content,
.most-watched .g-array-item,
.most-watched .g-grid,
.most-watched .g-block {
    border-left: none !important;
    border-right: none !important;
}

.view-article .article-info {
    padding-top: 40px;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

    .most-watched {
        padding: 1.25rem;
    }

    .most-watched .g-array-item {
        min-height: 86px;
    }

    .most-watched .g-array-item-image {
        flex: 0 0 72px;

        width: 72px;
        height: 72px;

        margin-right: 0.85rem;
    }

    .most-watched .g-array-item-image img {
        transform: scale(1.35);
    }

    .most-watched .g-array-item:hover
    .g-array-item-image img {
        transform: scale(1.48);
    }

    .most-watched .g-array-item-title
    .g-item-title {
        font-size: 0.9rem;
    }
}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

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

    .most-watched .g-array-item-image,
    .most-watched .g-array-item-image img,
    .most-watched .g-array-item-image::before,
    .most-watched .g-array-item-image::after {
        transition: none !important;
    }
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

    html {
        font-size: 15px;
    }

    body {
        line-height: 1.65;
    }


    /* H1 */

    h1 {
        font-size:
            clamp(
                1.8rem,
                8vw,
                2.7rem
            );

        line-height: 1.45;

        letter-spacing: -0.02em;

        padding:
            0.75rem
            0
            1rem;
    }


    /* Article H1 */

    .view-article .page-header h1 {
        font-size:
            clamp(
                1.8rem,
                8vw,
                2.7rem
            );

        line-height: 1.45;
    }


    /* Sections */

    #g-nosto,
    #g-ala1,
    #g-ala2,
    #g-kaupat {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }


    /* Cards */

    .view-category .g-array-item-image {
        border-radius: 15px;
    }


    .view-category .g-array-item-title
    .g-item-title {
        font-size: 1.15rem;

        line-height: 1.35;
    }


    /* Article body */

    .view-article .com-content-article__body {
        font-size: 1rem;
    }


    /* Article headings */

    .view-article .com-content-article__body h2,
    .view-article .com-content-article__body h3 {
        margin-top: 2.5rem;
    }


    /* Article images */

    .view-article .com-content-article__body figure {
        margin:
            2rem
            0;
    }


    /* Sidebar */

    .view-article #g-sidebar {
        margin-top: 2rem;
    }


    /* Footer */

    #g-footer .g-horizontalmenu {
        justify-content: flex-start;
    }
}

/* =========================================================
   SP PAGE BUILDER – ARTICLES CAROUSEL
   Pyöreät kuvat + 50 % zoom
   ========================================================= */

.sppb-addon-articles-carousel .sppb-articles-carousel-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 50%;
}

.sppb-addon-articles-carousel .sppb-articles-carousel-img-link {
    display: block;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 50%;
}

.sppb-addon-articles-carousel .sppb-articles-carousel-img img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    
    /* 50 % suurempi */
    transform: scale(2);
    
    /* Pehmeä zoom hoverissa */
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Hoverilla hieman lisää funky-efektiä */
.sppb-addon-articles-carousel .sppb-articles-carousel-img-link:hover img {
    transform: scale(1.6);
}

.sppb-addon-articles-carousel .sppb-articles-carousel-img {
    position: relative;
    padding: 5px;
    background: linear-gradient(
        135deg,
        #e40303,
        #ff8c00,
        #ffed00,
        #008026,
        #004dff,
        #750787
    );
}

.sppb-articles-carousel-meta-date {
    display: none;
}
.view-article .pagenavigation .btn {
    margin: 0 5px 0 0;
}
.container, .container-fluid, .container-xxl, .container-xl, .container-lg, .container-md, .container-sm {
    
    padding-left: var(--bs-gutter-x, 0); */

}