/* Valvonta-page rules. Loaded after site.css.
   Typography now matches the homepage (Audiowide / Montserrat, from site.css) so
   the two pages read as one site. This block keeps only the surface-color and
   motion-timing variance that was already there. */

:root {
    --bg-card: #141414;
    --accent-glow: rgba(255, 215, 0, 0.4);
    --border-subtle: #262626;
    --globe-orange: #FF7A18;
    --ease-standard: cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: 0.2s var(--ease-standard);
}

/* --- VALVONTA HERO --- */
.valvonta-hero-wrapper {
    padding-top: var(--nav-height);
}

.valvonta-hero {
    background: linear-gradient(180deg, rgba(10, 10, 10, 0.45) 0%, rgba(10, 10, 10, 0.75) 100%), url('../img/valvonta-hero.webp') no-repeat center center / cover;
    padding: clamp(60px, 10vw, 110px) 5% clamp(50px, 8vw, 95px) 5%;
    border-bottom: 1px solid var(--border-subtle);
    text-align: left;
    margin-bottom: 5rem;
}

.valvonta-hero-content {
    max-width: 1404px;
    margin: 0 auto;
}

.valvonta-hero h1 {
    font-size: clamp(1.98rem, 5vw, 3.78rem);
    color: var(--accent);
    margin-bottom: 1.5rem;
    line-height: 1.15;
}

.valvonta-hero p {
    font-size: clamp(1.15rem, 2vw, 1.35rem);
    color: var(--text-main);
    line-height: 1.8;
    max-width: 920px;
}

/* --- MAIN CONTENT & GLOBE --- */
.valvonta-container {
    margin: 0 auto 5rem auto;
    padding: 0 5%;
    max-width: 1404px;
}

.valvonta-grid {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 3.5rem;
    align-items: center;
    margin: 0 auto;
}

.valvonta-text-col h2 {
    font-size: clamp(1.44rem, 2.7vw, 2.07rem);
    color: var(--accent);
    line-height: 1.25;
    margin-bottom: 1.4rem;
}

.valvonta-text-col p {
    font-size: clamp(1.1rem, 1.8vw, 1.3rem);
    color: var(--text-muted);
    line-height: 1.75;
}

/* This page's CTA box sits above the footer and needs bottom breathing room. */
.valvonta-container .cta-box {
    margin-top: 5rem;
    margin-bottom: 6rem;
}

/* --- ANIMATED GLOBE --- */
.valvonta-globe-col {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

#globe-wrapper {
    position: relative;
    width: 100%;
    max-width: 620px;
    aspect-ratio: 1 / 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Logo shining through the transparent globe core */
#globe-core-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 46%;
    height: auto;
    opacity: 0.5;
    /* The logo PNG has a solid black plate — screen-blend it away and feather the
       edges so only the mark itself glows through the globe core. */
    mix-blend-mode: screen;
    -webkit-mask-image: radial-gradient(ellipse at center, #000 42%, transparent 72%);
    mask-image: radial-gradient(ellipse at center, #000 42%, transparent 72%);
    z-index: 1;
    pointer-events: none;
    animation: logoShine 5s ease-in-out infinite;
}

@keyframes logoShine {
    0%, 100% { opacity: 0.45; }
    50%      { opacity: 0.85; }
}

/* Warm halo behind the logo, so the mark reads as lit from inside the globe. */
#globe-wrapper::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 58%;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 122, 24, 0.30) 0%, rgba(255, 122, 24, 0.10) 45%, transparent 70%);
    z-index: 0;
    pointer-events: none;
    animation: coreShine 5s ease-in-out infinite;
}

@keyframes coreShine {
    0%, 100% { opacity: 0.55; transform: translate(-50%, -50%) scale(0.94); }
    50%      { opacity: 1;    transform: translate(-50%, -50%) scale(1.06); }
}

#globe-canvas {
    position: relative;
    width: 100%;
    height: 100%;
    z-index: 2;
    cursor: grab;
    touch-action: none;
}

#globe-canvas:active { cursor: grabbing; }

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
    .valvonta-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }
    .valvonta-text-col p {
        max-width: 800px;
        margin: 0 auto;
    }
    #globe-wrapper {
        max-width: 500px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .valvonta-hero {
        margin-bottom: 3.5rem;
        padding-top: 40px;
        padding-bottom: 40px;
    }
    .valvonta-container {
        margin-bottom: 3.5rem;
    }
    .valvonta-container .cta-box {
        margin-top: 3.5rem;
        margin-bottom: 4rem;
    }
    #globe-wrapper {
        max-width: 380px;
    }
}

@media (max-width: 480px) {
    .valvonta-hero h1 {
        font-size: clamp(1.53rem, 6.75vw, 2.16rem);
    }
    .valvonta-text-col h2 {
        font-size: clamp(1.26rem, 5.4vw, 1.66rem);
    }
    #globe-wrapper {
        max-width: min(320px, 90vw);
    }
}

/* The globe is decorative motion. Under reduced-motion the canvas still paints
   one static frame (see globe.js); these two purely ornamental pulses stop. */
@media (prefers-reduced-motion: reduce) {
    #globe-core-logo,
    #globe-wrapper::before {
        animation: none;
    }
}
