:root {
  color-scheme: light;
  --bg: #ffad4d;
  --paper: #fff;
  --ink: #1f2e3d;
  --muted: #3f5669;
  --border: #d9d7d2;
  --primary: #f28c28;
  --primary-text: #8b4114;
  --secondary: #91cee9;
  --secondary-text: #235f7d;
  --secondary-soft: #d7edf8;
  --deep: #173a50;
  --accent: #ffb76b;
  --radius: 17px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
a:focus-visible { outline: 3px solid #235f7d; outline-offset: 4px; border-radius: 5px; }
::selection { background: #cfeffc; color: #16354b; }
.container { width: min(1180px, calc(100% - 64px)); margin-inline: auto; }
.skip-link { position: absolute; top: -100px; left: 16px; background: var(--deep); color: white; padding: 12px 18px; z-index: 30; }
.skip-link:focus { top: 12px; }
.site-header { position: sticky; top: 0; z-index: 10; background: linear-gradient(110deg, #173a50 0%, #245c7a 100%); border-bottom: 4px solid #f28c28; box-shadow: 0 5px 22px rgba(23,58,80,.15); }
.header-inner { min-height: 88px; display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.brand { display: inline-flex; gap: 10px; align-items: center; color: #20354a; font-size: 29px; font-weight: 800; letter-spacing: -.065em; line-height: 1; }
.brand-stop { color: var(--primary); }
.site-header .brand { color: #f7fbfe; }
.site-header .brand-stop { color: #ffb76b; }
.site-header .brand-symbol { background: #f28c28; }
.site-header .brand-symbol span { border-color: #173a50; }
.site-header a:focus-visible { outline-color: #ffd8b0; }
.brand-symbol { display: grid; place-items: center; width: 31px; height: 31px; background: linear-gradient(135deg, var(--primary), #ffae56); border-radius: 8px; transform: rotate(-8deg); }
.brand-symbol span { width: 13px; height: 13px; border: 3.5px solid #fff; border-radius: 100%; }
.main-nav { display: flex; align-items: center; gap: 36px; font-size: 13px; font-weight: 650; color: #f7fbfe; }
.main-nav > a:not(.nav-contact) { padding-block: 12px; transition: color .2s; }
.main-nav > a:hover:not(.nav-contact) { color: #ffc88b; }
.nav-contact { background: #f28c28; color: #173a50; border: 1px solid #f28c28; padding: 13px 17px; border-radius: 9px; transition: background .2s, border-color .2s; }
.nav-contact:hover { background: #ffad5a; border-color: #ffad5a; }
.nav-contact span { margin-left: 18px; }
.hero { padding-block: clamp(54px, 6vw, 90px) 72px; }
.hero-grid { display: grid; grid-template-columns: 1fr .95fr; align-items: center; gap: clamp(32px, 4vw, 65px); }
.hero-copy { padding-block: 20px; }
.eyebrow { display: inline-flex; align-items: center; gap: 12px; margin: 0 0 30px; color: var(--primary-text); font-size: 11px; font-weight: 800; letter-spacing: .145em; }
.eyebrow-line { width: 26px; height: 2px; background: currentColor; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { letter-spacing: -.05em; }
h1 { font-size: clamp(43px, 4.65vw, 68px); line-height: 1.095; font-weight: 750; margin-bottom: 28px; }
h1 span { color: var(--primary-text); }
.hero-lead { max-width: 520px; font-size: clamp(16px, 1.55vw, 18px); line-height: 1.8; color: var(--muted); margin-bottom: 34px; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 24px; }
.button { display: inline-flex; align-items: center; justify-content: space-between; gap: 28px; min-height: 52px; padding: 15px 21px; border-radius: 9px; font-size: 13px; font-weight: 750; transition: transform .2s, background .2s; }
.button:hover { transform: translateY(-2px); }
.button-primary { background: var(--primary); color: var(--deep); }
.button-primary:hover { background: #ffad5a; }
.text-link { font-size: 13px; font-weight: 750; border-bottom: 1px solid #bdcfe0; padding-block: 8px; }
.text-link span { margin-left: 9px; }
.text-link:hover { color: var(--primary-text); border-color: var(--primary); }
.hero-art { min-height: 475px; width: 100%; isolation: isolate; overflow: hidden; position: relative; border-radius: var(--radius); background: radial-gradient(circle at 72% 27%, #ffa34b 0%, rgba(255,163,75,.58) 28%, transparent 54%), linear-gradient(135deg, #275d7b 0%, #94d0e8 53%, #356681 100%); box-shadow: 0 22px 50px rgba(20,50,74,.15); }
.art-grid { position: absolute; inset: 0; opacity: .26; background-image: linear-gradient(#ffffff22 1px,transparent 1px),linear-gradient(90deg,#ffffff22 1px,transparent 1px); background-size: 41px 41px; mask-image: linear-gradient(125deg, transparent, black 20%, black 75%, transparent); }
.art-orbit { position: absolute; border: 1px solid rgba(255,255,255,.22); border-radius: 100%; left: 50%; top: 50%; transform: translate(-50%,-50%); }
.orbit-outer { width: 355px; height: 355px; }
.orbit-inner { width: 235px; height: 235px; border-color: rgba(255,255,255,.38); }
.art-core { width: 126px; height: 126px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%); background: #ffd6aa; color: var(--deep); box-shadow: 0 0 0 15px rgba(255,255,255,.08), 0 15px 50px rgba(7,29,27,.2); }
.core-glyph { font-family: Georgia, serif; font-size: 56px; line-height: 1; font-weight: 400; }
.art-line { position: absolute; border-radius: 50%; background: var(--accent); width: 10px; height: 10px; }
.art-line-one { left: 30%; top: 26%; box-shadow: 0 0 0 9px rgba(255,210,154,.23); }
.art-line-two { right: 21%; bottom: 28%; box-shadow: 0 0 0 9px rgba(255,210,154,.23); }
.section { padding-block: 116px; }
.services { background: #d7edf8; }
.section-heading { display: flex; gap: 50px; justify-content: space-between; align-items: end; margin-bottom: 44px; }
h2 { font-size: clamp(35px, 3.6vw, 52px); line-height: 1.17; font-weight: 750; margin: 0; }
.service-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 19px; }
.service-card { display: flex; flex-direction: column; min-height: 258px; background: var(--paper); padding: 30px 28px; border: 1px solid #c9dfec; border-radius: 13px; box-shadow: 0 8px 22px rgba(32,67,106,.06); transition: transform .25s, box-shadow .25s; }
.service-card:hover { transform: translateY(-4px); box-shadow: 0 16px 30px rgba(32,67,106,.12); }
.service-card-accent { background: #ffcd98; border-color: #e9a568; }
.service-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 26px; }
.service-number { color: var(--primary-text); font-size: 12px; font-weight: 800; letter-spacing: .06em; }
.service-icon { display: grid; place-items: center; border: 1px solid #d6e5ef; border-radius: 50%; width: 37px; height: 37px; color: var(--secondary-text); font-size: 19px; }
.service-card h3 { font-size: clamp(22px, 2vw, 26px); line-height: 1.23; margin-bottom: 15px; }
.service-card p { line-height: 1.75; font-size: 14px; color: var(--muted); margin-bottom: 0; }
.approach { background: #e4f1fa; }
.approach-grid { display: grid; grid-template-columns: .92fr 1fr; gap: clamp(55px, 8vw, 140px); align-items: start; }
.steps { border-top: 1px solid #edaf72; }
.step { display: grid; grid-template-columns: 90px 1fr; gap: 22px; padding-block: 29px; border-bottom: 1px solid #edaf72; }
.step-number { color: var(--primary-text); font-size: 21px; font-weight: 800; line-height: 1.3; white-space: nowrap; }
.step h3 { font-size: 21px; margin-bottom: 10px; }
.step p { margin: 0; color: var(--muted); line-height: 1.7; font-size: 14px; max-width: 375px; }
.people { background: #ffa83d; padding-block: 76px; }
.people-grid { display: grid; grid-template-columns: 1fr .85fr; align-items: center; gap: clamp(24px, 6vw, 90px); }
.people-status { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.8; }
.contact { background: linear-gradient(120deg, #b2dbed 0%, #d6eef8 58%, #a9d5ea 100%); color: var(--deep); padding-block: 84px; }
.contact-inner { display: grid; grid-template-columns: 1fr .65fr; align-items: end; gap: 45px; }
.contact h2 { max-width: 730px; font-size: clamp(37px, 4.8vw, 61px); }
.contact-inner > div:first-child > p:last-child { max-width: 530px; color: #375871; line-height: 1.8; margin: 22px 0 0; font-size: 15px; }
.contact-action { padding: 23px 0; border-top: 1px solid rgba(23,58,80,.35); display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }
.contact-status { margin: 0; color: var(--deep); font-size: 15px; font-weight: 650; }
.site-footer { background: linear-gradient(110deg, #173a50 0%, #245c7a 100%); border-top: 4px solid #f28c28; color: #f7fbfe; padding-block: 43px; }
.footer-inner { display: flex; justify-content: space-between; align-items: end; gap: 20px; }
.footer-brand { font-size: 25px; }
.footer-brand .brand-symbol { width: 26px; height: 26px; border-radius: 6px; }
.footer-brand .brand-symbol span { width: 11px; height: 11px; border-width: 3px; }
.footer-details { display: flex; flex-direction: column; align-items: end; gap: 7px; color: #f7fbfe; font-size: 12px; }
@media (max-width: 1050px) {
  .container { width: min(100% - 48px, 1180px); }
  .hero-grid { gap: 28px; }
  .hero-art { min-height: 410px; }
  .orbit-outer { width: 300px; height: 300px; }
  .orbit-inner { width: 210px; height: 210px; }
  h1 { font-size: clamp(39px, 4.55vw, 55px); }
  .service-card { padding: 27px 22px; }
}
@media (max-width: 800px) {
  .header-inner { min-height: 72px; }
  .hero { padding-block: 60px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-copy { padding-block: 0; }
  .hero-lead { max-width: 640px; }
  .hero-art { max-width: none; min-height: 380px; }
  .hero-art .orbit-outer { width: 340px; height: 340px; }
  .section { padding-block: 80px; }
  .section-heading { align-items: start; flex-direction: column; gap: 17px; }
  .service-grid { grid-template-columns: 1fr 1fr; }
  .service-card:last-child { grid-column: span 2; min-height: 260px; }
  .service-card { min-height: 245px; }
  .service-top { margin-bottom: 27px; }
  .approach-grid { grid-template-columns: 1fr; gap: 35px; }
  .people-grid { grid-template-columns: 1fr; gap: 28px; }
  .contact-inner { grid-template-columns: 1fr; gap: 35px; }
  .contact-action { max-width: 520px; }
}
@media (max-width: 550px) {
  .container { width: calc(100% - 36px); }
  .header-inner { min-height: 68px; }
  .brand { font-size: 26px; }
  .main-nav { gap: 13px; font-size: 12px; }
  .main-nav a[href="#palvelut"], .main-nav a[href="#toimintatapa"] { display: none; }
  .main-nav .nav-contact { padding: 10px 11px; }
  .main-nav .nav-contact span { margin-left: 3px; }
  .hero { padding-block: 42px 50px; }
  .eyebrow { margin-bottom: 23px; font-size: 10px; }
  h1 { font-size: clamp(39px, 9vw, 54px); margin-bottom: 22px; }
  .hero-lead { font-size: 16px; line-height: 1.75; }
  .hero-actions { gap: 16px; }
  .hero-art { min-height: 340px; }
  .orbit-outer, .hero-art .orbit-outer { width: 285px; height: 285px; }
  .orbit-inner { width: 200px; height: 200px; }
  .art-core { width: 110px; height: 110px; }
  .section { padding-block: 70px; }
  h2 { font-size: clamp(34px, 8vw, 43px); }
  .service-grid { grid-template-columns: 1fr; gap: 12px; }
  .service-card, .service-card:last-child { min-height: 235px; grid-column: auto; padding: 24px; }
  .service-top { margin-bottom: 25px; }
  .service-card p { margin-bottom: 0; }
  .people { padding-block: 52px; }
  .contact h2 { font-size: 40px; }
  .footer-inner { flex-direction: column; align-items: start; gap: 35px; }
  .footer-details { align-items: start; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}


.brand-logo { display: block; width: 76px; height: 76px; object-fit: contain; }
@media (max-width: 550px) { .brand-logo { width: 56px; height: 56px; } }
.hero-logo { width: 100%; max-width: 540px; margin-inline: auto; overflow: hidden; border-radius: var(--radius); background: #fff; }
.hero-logo img { display: block; width: 100%; height: auto; }
.training-subtitle { display: block; margin-top: 0.15em; font-size: 53.9%; line-height: 1.2; font-weight: 400; }
.approach-list-heading { font-size: 1.521em; }
.contact-action p { margin: 0; }
.contact-action .contact-social { margin-top: 1em; }
.contact-subtitle { font-size: 37.73%; }
.footer-logos { display: flex; align-items: center; gap: 16px; }

main > section + section { border-top: 4px solid var(--deep); }

/* Readable prose and responsive navigation. */
body { line-height: 1.65; }
.training .approach-grid > div:last-child,
.software .approach-grid > div:last-child,
.people .approach-grid > div:last-child { max-width: 65ch; }
.training-subtitle { letter-spacing: normal; line-height: 1.4; margin-top: .35em; }
.contact-subtitle { font-size: clamp(18px, 1.6vw, 23px); }
.step p { font-size: 16px; }
.footer-details { font-size: 14px; }
.main-nav { font-size: 14px; gap: 24px; }
.main-nav > a { min-height: 44px; }
.service-list { padding-left: 1.3em; margin-top: -.5em; }
.service-list li + li { margin-top: .3em; }
.contact-action a { text-decoration: underline; text-underline-offset: .2em; }
.menu-toggle { border: 1px solid #ffd8b0; border-radius: 8px; background: transparent; color: #fff; font: inherit; font-weight: 650; padding: 10px 14px; min-height: 44px; cursor: pointer; }
.menu-toggle span { margin-left: 8px; }
.menu-toggle:focus-visible { outline: 3px solid #ffd8b0; outline-offset: 4px; }
@media (max-width: 1100px) {
  .header-inner { flex-wrap: wrap; gap: 0; padding-block: 8px; }
  .menu-toggle:not([hidden]) { display: inline-flex; align-items: center; }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    flex-wrap: wrap;
    gap: 8px 20px;
    padding: 12px 20px;
    background: #245c7a;
    box-shadow: 0 12px 22px rgba(23,58,80,.2);
    max-height: calc(100dvh - 80px);
    overflow-y: auto;
  }
  .main-nav.is-collapsed { display: none; }
  .main-nav > a, .main-nav a[href="#toimintatapa"] { display: flex; align-items: center; padding: 10px 12px; }
  .main-nav .nav-contact { padding: 10px 12px; }
  .main-nav .nav-contact span { margin-left: 8px; }
}
@media (max-width: 550px) {
  .main-nav { font-size: 16px; flex-direction: column; align-items: stretch; gap: 4px; }
  .main-nav > a { width: 100%; }
}

@media (min-width: 1101px) { .menu-toggle { display: none; } }

/* Portrait photographs retain their original aspect ratio without cropping. */
.profile-photo { width: 100%; max-width: 340px; margin: 32px 0 0; }
.profile-photo img { display: block; width: 100%; height: auto; border-radius: var(--radius); }
.profile-photo--together { max-width: 440px; }
@media (max-width: 800px) {
  .profile-photo { margin-top: 24px; }
}

/* Alternate the JONI section with the stronger orange sections. */
.software { background: #e4f1fa; }

.site-footer a:focus-visible { outline-color: #ffd8b0; }
.site-footer a:hover { color: #ffc88b; }

/* Phone layout refinements. */
@media (max-width: 550px) {
  html { scroll-padding-top: 88px; }
  .container { width: calc(100% - 40px); }
  .header-inner { min-height: 68px; padding-block: 6px; }
  .site-header .brand-logo { width: 48px; height: 48px; }
  .main-nav { max-height: calc(100dvh - 80px); overflow-y: auto; overscroll-behavior: contain; }
  .main-nav > a { min-height: 48px; }
  .hero { padding-block: 32px 40px; }
  .hero-grid { gap: 24px; }
  h1 { font-size: clamp(32px, 9vw, 40px); line-height: 1.15; margin-bottom: 20px; }
  .hero-lead { margin-bottom: 20px; }
  .hero-copy > :last-child { margin-bottom: 0; }
  .hero-logo { max-width: 220px; }
  .section, .people, .contact { padding-block: 48px; }
  .approach-grid { gap: 24px; min-width: 0; }
  .approach-grid > div { min-width: 0; }
  h2 { font-size: clamp(30px, 8vw, 36px); line-height: 1.2; }
  .training-subtitle { font-size: 18px; margin-top: 8px; }
  .training p, .software p, .people p { line-height: 1.75; margin-bottom: 20px; }
  .training .approach-grid > div:last-child > :last-child,
  .software .approach-grid > div:last-child > :last-child,
  .people .approach-grid > div:last-child > :last-child { margin-bottom: 0; }
  .approach-list-heading { font-size: 22px; margin-block: 12px 8px; }
  .step { grid-template-columns: 64px minmax(0, 1fr); gap: 16px; padding-block: 22px; }
  .step-number { font-size: 16px; line-height: 1.5; }
  .step h3 { font-size: 20px; line-height: 1.3; margin-bottom: 8px; }
  .step p { line-height: 1.65; }
  .profile-photo { max-width: 224px; margin-top: 20px; }
  .profile-photo--together { max-width: 320px; }
  .contact h2 { font-size: clamp(32px, 8.5vw, 38px); }
  .contact-subtitle { font-size: 19px; }
  .contact-inner { gap: 24px; }
  .contact-action { padding-block: 20px 0; gap: 12px; }
  .contact-action a { display: inline-block; padding-block: 8px; overflow-wrap: anywhere; }
  .site-footer { padding-block: 28px; }
  .footer-inner { gap: 24px; }
  .footer-logos { flex-wrap: wrap; }
  .footer-details { gap: 8px; }
  .footer-details a { display: inline-block; padding-block: 8px; }
}

/* Color-only variation: original orange hero + blue-white reading sections (2026-10-23).
   No HTML or wording changes; preserve the original #ffad4d hero. */
.approach,
.training,
.software,
.people,
.contact {
  color: #173a50;
  background: linear-gradient(125deg, #e8f4fb 0%, #f5fbfe 100%);
}
.training,
.people {
  background: linear-gradient(125deg, #f7fbfe 0%, #e4f2fa 100%);
}
.software,
.contact {
  background: linear-gradient(125deg, #e4f2fa 0%, #f8fcff 100%);
}

/* Orange headings; existing subtitles and wording stay in their original positions. */
.approach h2,
.training h2,
.software h2,
.people h2,
.contact h2 {
  display: inline-block;
  padding: 14px 20px;
  margin-bottom: 26px;
  background: #f6a443;
  color: #173a50;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(23, 58, 80, .08);
}
.approach p,
.training p,
.software p,
.people p,
.contact p,
.approach li,
.training li,
.software li,
.people li,
.contact li { color: #24475f; }
.contact a,
.people a,
.software a,
.training a,
.approach a { color: #1e6287; }
.approach .step,
.contact-action,
.approach .steps { border-color: #a9cbdd; }
@media (max-width: 700px) {
  .approach h2,
  .training h2,
  .software h2,
  .people h2,
  .contact h2 {
    padding: 12px 16px;
    line-height: 1.2;
  }
}


/* Full-bleed orange section headings on narrow screens.
   Keep desktop rounded highlights and all original HTML/text. */
@media (max-width: 800px) {
  main > .section { --title-bleed-gutter: 24px; }
  main > .section.approach h2,
  main > .section.training h2,
  main > .section.software h2,
  main > .section.people h2,
  main > .section.contact h2 {
    display: block;
    width: calc(100% + 2 * var(--title-bleed-gutter));
    max-width: none;
    margin-left: calc(-1 * var(--title-bleed-gutter));
    margin-top: -80px;
    padding: 22px var(--title-bleed-gutter);
    border-radius: 0;
    box-shadow: none;
  }
}
@media (max-width: 550px) {
  main > .section { --title-bleed-gutter: 20px; }
  main > .section.approach h2,
  main > .section.training h2,
  main > .section.software h2,
  main > .section.people h2,
  main > .section.contact h2 {
    margin-top: -48px;
    padding-block: 20px;
  }
}

/* Desktop-only full-width orange title bands above photos and readable content.
   The phone/tablet rules at 800px and below remain entirely untouched. */
@media (min-width: 801px) {
  main > .section:is(.approach, .training, .software, .people, .contact) {
    padding-top: 0;
  }

  /* Lift the existing titles out of their left-hand column without moving
     or rewriting any markup. The full-bleed title uses the existing orange. */
  main > .section:is(.approach, .training, .software, .people) .approach-grid {
    grid-template-rows: auto auto;
    row-gap: clamp(44px, 5vw, 72px);
    align-items: start;
  }
  main > .section:is(.approach, .training, .software, .people) .approach-intro {
    display: contents;
  }
  main > .section:is(.approach, .training, .software, .people) .approach-intro > h2,
  main > .contact .contact-inner h2 {
    grid-column: 1 / -1;
    grid-row: 1;
    display: block;
    width: 100vw;
    max-width: none;
    margin: 0 0 0 calc(50% - 50vw);
    padding: clamp(37px, 3.5vw, 54px) max(32px, calc((100vw - 1180px) / 2));
    border-radius: 0;
    box-shadow: none;
  }
  /* The headings have no new copy: their existing subtitles sit inside
     the orange full-width band, while pictures and paragraphs move below. */
  main > .section:is(.training, .software, .people) .approach-intro > figure {
    grid-column: 1;
    grid-row: 2;
    margin-top: 0;
    align-self: start;
  }
  main > .section:is(.training, .software, .people) .approach-grid > div:last-child {
    grid-column: 2;
    grid-row: 2;
    max-width: none;
    min-width: 0;
  }
  main > .approach .steps {
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
  }
  main > .contact .contact-inner {
    grid-template-columns: 1fr;
    row-gap: clamp(38px, 4vw, 58px);
    align-items: start;
  }
  main > .contact .contact-inner > div:first-child {
    display: contents;
  }
  main > .contact .contact-action {
    grid-column: 1;
    grid-row: 2;
    max-width: none;
    width: 100%;
  }
}
@media (min-width: 801px) and (max-width: 1050px) {
  main > .section:is(.approach, .training, .software, .people) .approach-intro > h2,
  main > .contact .contact-inner h2 { padding-inline: 24px; }
}


/* Match the site-header navy-to-blue gradient on the approach title only.
   Applies to phones, tablets and desktop without changing layout or text. */
#toimintatapa #approach-heading {
  background: linear-gradient(110deg, #173a50 0%, #245c7a 100%);
  color: #f7fbfe;
}
