/*
Theme Name: Woodcircles Child
Theme URI: https://www.icons.it/
Author: IconS People
Author URI: https://www.icons.it/people/
Description: Child theme of Woodcircles for the demonstrator site. Footer-on-top layout and custom ACF flexible sections.
Template: woodcircle
Version: 1.0.0
Requires at least: 5.0
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: woodcircle-child
*/

/* Child theme overrides — parent styles load via functions.php */

.footer-on-top {
  /* Visual footer sits at the top of the page on this site */
}

/* Logos-only footer: single full-width row like the reference banner */
.footer-on-top .footer {
  padding: 28px 50px;
}

.footer-on-top .footer-grid {
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  max-width: none;
}

.footer-on-top #w-node-a856a931-15cf-cc26-ab5f-3d8dcb9d0f5c-cb9d0f5a,
.footer-on-top .footer-logos-row {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  width: 100%;
}

.footer-on-top .logo-footer {
  width: auto;
  height: 52px;
  max-width: none;
  margin-bottom: 0;
  object-fit: contain;
  flex-shrink: 1;
}

.footer-on-top .logo-footer--eu {
  height: 56px;
}

.footer-on-top .logo-footer--brand {
  height: 48px;
}

.footer-on-top .logo-footer--ccri {
  height: 56px;
}

@media screen and (max-width: 991px) {
  .footer-on-top .footer {
    padding: 24px 20px;
  }

  .footer-on-top .footer-logos-row {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
  }

  .footer-on-top .logo-footer {
    height: 40px;
  }

  /* Mobile top bar: only woodcircles logo */
  .footer-on-top #w-node-a856a931-15cf-cc26-ab5f-3d8dcb9d0f5c-cb9d0f5a .logo-footer:not(.logo-footer--brand) {
    display: none;
  }
}

/* -------------------------------------------------------------------------
   Layout 1 — Demonstrator Hero
   ------------------------------------------------------------------------- */
.demonstrator-hero {
  background-color: var(--green, #004734);
  color: #fff;
  padding: 60px 50px 80px;
}

.demonstrator-hero__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-hero__top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 40px 60px;
  align-items: center;
}

.demonstrator-hero__title {
  margin: 0;
  font-size: clamp(36px, 5vw, 64px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #fff;
}

.demonstrator-hero__visual {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.demonstrator-hero__image {
  width: 100%;
  max-width: 560px;
  height: auto;
  display: block;
}

.demonstrator-hero__journey {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin: 72px 0 64px;
}

.demonstrator-hero__claim {
  margin: 0 0 16px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
}

.demonstrator-hero__arrow {
  display: inline-flex;
  color: #fff;
  text-decoration: none;
  transition: transform 0.2s ease;
}

.demonstrator-hero__arrow:hover,
.demonstrator-hero__arrow:focus {
  transform: translateY(4px);
  color: #fff;
}

.demonstrator-hero__about-label {
  margin: 0 0 16px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #fff;
}

.demonstrator-hero__content {
  max-width: 920px;
  font-size: 16px;
  line-height: 1.6;
  color: #fff;
}

.demonstrator-hero__content p {
  margin: 0 0 1em;
}

.demonstrator-hero__content p:last-child {
  margin-bottom: 0;
}

.demonstrator-hero__content a {
  color: #fff;
  text-decoration: underline;
}

@media screen and (max-width: 991px) {
  .demonstrator-hero {
    padding: 40px 30px 60px;
  }

  .demonstrator-hero__top {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .demonstrator-hero__visual {
    justify-content: center;
  }

  .demonstrator-hero__image {
    max-width: 420px;
  }

  .demonstrator-hero__journey {
    margin: 48px 0 40px;
  }
}

/* -------------------------------------------------------------------------
   Layout 2 — Itinerary timeline
   ------------------------------------------------------------------------- */
.demonstrator-itinerary {
  background-color: #f7f7f5;
  color: var(--green, #004734);
  padding: 80px 50px;
}

.demonstrator-itinerary__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-itinerary__title {
  margin: 0 0 64px;
  text-align: center;
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 500;
  color: var(--green, #004734);
}

.demonstrator-itinerary__timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  position: relative;
}

.demonstrator-itinerary__timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 0;
  border-left: 3px dashed var(--green, #004734);
  transform: translateX(-50%);
  z-index: 0;
}

.demonstrator-itinerary__stop {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 28px 40px;
  position: relative;
  z-index: 1;
  margin: 0 0 56px;
}

.demonstrator-itinerary__stop:last-child {
  margin-bottom: 0;
}

.demonstrator-itinerary__node {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  justify-content: center;
}

.demonstrator-itinerary__circle {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  border: 4px solid var(--green, #004734);
  overflow: hidden;
  background-color: #fff;
  flex-shrink: 0;
}

.demonstrator-itinerary__circle--empty {
  background-color: #fff;
}

.demonstrator-itinerary__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.demonstrator-itinerary__content {
  max-width: 320px;
}

.demonstrator-itinerary__stop--right .demonstrator-itinerary__content {
  grid-column: 3;
  grid-row: 1;
  justify-self: start;
  text-align: left;
}

.demonstrator-itinerary__stop--left .demonstrator-itinerary__content {
  grid-column: 1;
  grid-row: 1;
  justify-self: end;
  text-align: right;
}

.demonstrator-itinerary__name {
  margin: 0 0 8px;
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 700;
  line-height: 1.1;
  color: var(--green, #004734);
}

.demonstrator-itinerary__text {
  font-size: 16px;
  line-height: 1.5;
  color: var(--green, #004734);
}

.demonstrator-itinerary__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding: 8px 16px;
  border-radius: 999px;
  background-color: var(--green, #004734);
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
}

.demonstrator-itinerary__badge-icon {
  flex-shrink: 0;
}

.demonstrator-itinerary__stop--left .demonstrator-itinerary__badge {
  margin-left: auto;
}

@media screen and (max-width: 991px) {
  .demonstrator-itinerary {
    padding: 50px 30px;
  }

  .demonstrator-itinerary__title {
    margin-bottom: 40px;
  }

  .demonstrator-itinerary__timeline::before {
    left: 40px;
    transform: none;
    /* Start at center of first 80px circle — no dotted segment above it */
    top: 40px;
  }

  .demonstrator-itinerary__stop {
    grid-template-columns: 80px 1fr;
    gap: 16px 20px;
    margin-bottom: 40px;
  }

  .demonstrator-itinerary__node {
    grid-column: 1;
  }

  .demonstrator-itinerary__circle {
    width: 80px;
    height: 80px;
    border-width: 3px;
  }

  .demonstrator-itinerary__stop--right .demonstrator-itinerary__content,
  .demonstrator-itinerary__stop--left .demonstrator-itinerary__content {
    grid-column: 2;
    justify-self: start;
    text-align: left;
    max-width: none;
  }

  .demonstrator-itinerary__stop--left .demonstrator-itinerary__badge {
    margin-left: 0;
  }

  .demonstrator-itinerary__name {
    font-size: 28px;
  }
}

/* -------------------------------------------------------------------------
   Layout 3 — Big buttons
   ------------------------------------------------------------------------- */
.demonstrator-big-buttons {
  width: 100%;
  background-color: #f7f7f5;
  padding: 40px 50px;
}

.demonstrator-big-buttons__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-big-buttons__list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.demonstrator-big-buttons__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  padding: 32px 40px;
  background-color: var(--green, #004734);
  color: #fff;
  text-decoration: none;
  border: 2px solid var(--green, #004734);
  border-radius: 0;
  box-sizing: border-box;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.demonstrator-big-buttons__item:hover,
.demonstrator-big-buttons__item:focus {
  background-color: #fff;
  color: var(--green, #004734);
  border-color: var(--green, #004734);
  text-decoration: none;
  opacity: 1;
}

.demonstrator-big-buttons__label {
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 500;
  line-height: 1.3;
  transition: color 0.3s ease;
}

.demonstrator-big-buttons__arrow {
  display: inline-flex;
  flex-shrink: 0;
  color: inherit;
  transition: color 0.3s ease;
}

@media screen and (max-width: 991px) {
  .demonstrator-big-buttons {
    padding: 30px 30px;
  }

  .demonstrator-big-buttons__item {
    padding: 24px 24px;
  }

  .demonstrator-big-buttons__label {
    font-size: 18px;
  }

  .demonstrator-big-buttons__arrow svg {
    width: 22px;
    height: 16px;
  }
}

/* -------------------------------------------------------------------------
   Layout 4 — Meet the partners
   ------------------------------------------------------------------------- */
.demonstrator-partners {
  background-color: #f7f7f5;
  color: var(--green, #004734);
  padding: 80px 50px;
}

.demonstrator-partners__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-partners__title {
  margin: 0 0 48px;
  text-align: center;
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 500;
  color: var(--green, #004734);
}

.demonstrator-partners__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-bottom: 48px;
}

.demonstrator-partners__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: var(--green, #004734);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.demonstrator-partners__card:hover,
.demonstrator-partners__card:focus {
  color: var(--green, #004734);
  text-decoration: none;
  opacity: 0.85;
  transform: translateY(-2px);
}

.demonstrator-partners__media {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #e8e8e8;
  padding: 24px;
  box-sizing: border-box;
}

.demonstrator-partners__image {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.demonstrator-partners__name {
  display: block;
  margin-top: 14px;
  text-align: center;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
}

.demonstrator-partners__cta-wrap {
  display: flex;
  justify-content: center;
}

.demonstrator-partners__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 36px;
  border: 2px solid var(--green, #004734);
  border-radius: 0;
  background-color: #fff;
  color: var(--green, #004734);
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.demonstrator-partners__cta:hover,
.demonstrator-partners__cta:focus {
  background-color: var(--green, #004734);
  color: #fff;
  text-decoration: none;
}

@media screen and (max-width: 991px) {
  .demonstrator-partners {
    padding: 50px 30px;
  }

  .demonstrator-partners__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 36px;
  }
}

@media screen and (max-width: 600px) {
  .demonstrator-partners__grid {
    grid-template-columns: 1fr;
  }
}

/* -------------------------------------------------------------------------
   Desktop header / burger only on tablet + mobile
   Same container pattern as sections + site footer: padding + max-width 1280
   ------------------------------------------------------------------------- */
.demonstrator-top-bar {
  background-color: #fff;
  height: 100px;
  padding-left: 50px;
  padding-right: 50px;
  box-sizing: border-box;
}

.demonstrator-top-bar .content-menu {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.demonstrator-top-bar .logo {
  width: auto;
  max-width: 220px;
  flex-shrink: 0;
}

.demonstrator-top-bar .logo-image {
  width: auto;
  height: 40px;
  max-width: 100%;
  object-fit: contain;
}

.demonstrator-nav {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  flex: 1;
  gap: 0;
  min-width: 0;
}

.demonstrator-top-bar .link.menu {
  color: var(--green, #004734);
  margin-left: 40px;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
}

.demonstrator-top-bar .link.menu:first-child {
  margin-left: 0;
}

.demonstrator-top-bar .burger-link.demonstrator-burger {
  display: none;
  padding-left: 0;
  padding-right: 0;
}

@media screen and (max-width: 991px) {
  .demonstrator-nav {
    display: none;
  }

  .demonstrator-top-bar .burger-link.demonstrator-burger {
    display: flex;
    height: 80px;
    padding-right: 0;
  }

  .demonstrator-top-bar {
    padding-left: 30px;
    padding-right: 30px;
    height: 80px;
  }

  .demonstrator-top-bar .logo-image {
    height: 32px;
  }
}

/* -------------------------------------------------------------------------
   Site footer (black bottom bar)
   ------------------------------------------------------------------------- */
.demonstrator-site-footer {
  background-color: #000;
  color: #fff;
  padding: 48px 50px 40px;
}

.demonstrator-site-footer__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-site-footer__back {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 0 64px;
  padding-bottom: 8px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  transition: opacity 0.25s ease;
}

.demonstrator-site-footer__back:hover,
.demonstrator-site-footer__back:focus {
  color: #fff;
  opacity: 0.75;
  text-decoration: none;
}

.demonstrator-site-footer__back-arrow {
  font-size: 1.1em;
  line-height: 1;
}

.demonstrator-site-footer__logos {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  width: 100%;
}

.demonstrator-site-footer .logo-footer {
  width: auto;
  height: 52px;
  max-width: none;
  margin-bottom: 0;
  object-fit: contain;
  flex-shrink: 1;
}

.demonstrator-site-footer .logo-footer--eu {
  height: 56px;
}

.demonstrator-site-footer .logo-footer--brand {
  height: 48px;
}

.demonstrator-site-footer .logo-footer--ccri {
  height: 56px;
}

@media screen and (max-width: 991px) {
  .demonstrator-site-footer {
    padding: 36px 20px 28px;
  }

  .demonstrator-site-footer__back {
    margin-bottom: 48px;
  }

  .demonstrator-site-footer__logos {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
  }

  .demonstrator-site-footer .logo-footer {
    height: 40px;
  }
}

/* -------------------------------------------------------------------------
   Layout 5 — Panel header
   ------------------------------------------------------------------------- */
.demonstrator-panel-header {
  background-color: var(--green, #004734);
  color: #fff;
  padding: 50px;
}

.demonstrator-panel-header__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-panel-header__breadcrumb {
  margin: 0 0 28px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.4;
  color: #fff;
}

.demonstrator-panel-header__crumb a,
.demonstrator-panel-header__crumb span {
  color: #fff;
  text-decoration: none;
}

.demonstrator-panel-header__crumb a:hover,
.demonstrator-panel-header__crumb a:focus {
  text-decoration: underline;
  color: #fff;
}

.demonstrator-panel-header__sep {
  color: #fff;
  opacity: 0.9;
}

.demonstrator-panel-header__row {
  display: flex;
  flex-direction: row;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 40px;
}

.demonstrator-panel-header__title {
  margin: 0;
  flex: 1;
  min-width: 0;
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 600;
  line-height: 1.15;
  color: #fff;
}

.demonstrator-panel-header__title-spacer {
  flex: 1;
}

.demonstrator-panel-header__nav {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-shrink: 0;
}

.demonstrator-panel-header__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  padding: 12px 28px;
  border: 2px solid #fff;
  border-radius: 0;
  background-color: transparent;
  color: #fff;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.demonstrator-panel-header__btn:hover,
.demonstrator-panel-header__btn:focus {
  background-color: #fff;
  color: var(--green, #004734);
  text-decoration: none;
}

@media screen and (max-width: 991px) {
  .demonstrator-panel-header {
    padding: 40px 30px;
  }

  .demonstrator-panel-header__row {
    flex-direction: column;
    align-items: flex-start;
  }

  .demonstrator-panel-header__nav {
    width: 100%;
    justify-content: flex-start;
  }

  .demonstrator-panel-header__btn {
    flex: 1;
    min-width: 0;
  }
}

/* -------------------------------------------------------------------------
   Layout 6 — Numbered panel list
   ------------------------------------------------------------------------- */
.demonstrator-numbered-list {
  background-color: #fff;
  color: var(--green, #004734);
  padding: 50px;
}

.demonstrator-numbered-list__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-numbered-list__list {
  display: flex;
  flex-direction: column;
  width: 100%;
  border-top: 1px solid var(--green, #004734);
}

.demonstrator-numbered-list__item {
  display: flex;
  align-items: center;
  gap: 28px;
  width: 100%;
  padding: 28px 20px;
  border-bottom: 1px solid var(--green, #004734);
  box-sizing: border-box;
  color: var(--green, #004734);
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.demonstrator-numbered-list__item:hover,
.demonstrator-numbered-list__item:focus {
  background-color: var(--green, #004734);
  color: #fff;
  text-decoration: none;
}

.demonstrator-numbered-list__number {
  flex-shrink: 0;
  min-width: 2.5ch;
  font-size: clamp(40px, 5vw, 64px);
  font-weight: 700;
  line-height: 1;
}

.demonstrator-numbered-list__label {
  flex: 1;
  min-width: 0;
  font-size: clamp(24px, 3.2vw, 36px);
  font-weight: 500;
  line-height: 1.3;
}

.demonstrator-numbered-list__arrow {
  display: inline-flex;
  flex-shrink: 0;
  color: inherit;
  margin-left: auto;
}

@media screen and (max-width: 991px) {
  .demonstrator-numbered-list {
    padding: 40px 30px;
  }

  .demonstrator-numbered-list__item {
    gap: 16px;
    padding: 22px 12px;
  }

  .demonstrator-numbered-list__number {
    font-size: 40px;
  }

  .demonstrator-numbered-list__arrow svg {
    width: 22px;
    height: 16px;
  }
}

/* -------------------------------------------------------------------------
   Layout 7 — Rich text
   ------------------------------------------------------------------------- */
.demonstrator-richtext {
  background-color: #fff;
  color: var(--grey, #1a1a1a);
  padding: 50px;
}

.demonstrator-richtext__inner {
  width: 100%;
  max-width: var(--max-w-1280, 1280px);
  margin: 0 auto;
}

.demonstrator-richtext__content {
  max-width: 920px;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
}

.demonstrator-richtext__content > *:first-child {
  margin-top: 0;
}

.demonstrator-richtext__content > *:last-child {
  margin-bottom: 0;
}

.demonstrator-richtext__content p {
  margin: 0 0 1.5em;
}

.demonstrator-richtext__content strong,
.demonstrator-richtext__content b {
  font-weight: 700;
}

.demonstrator-richtext__content a {
  color: var(--green, #004734);
  text-decoration: underline;
}

.demonstrator-richtext__content img,
.demonstrator-richtext__content .alignnone,
.demonstrator-richtext__content .alignleft,
.demonstrator-richtext__content .aligncenter,
.demonstrator-richtext__content .wp-caption {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 0 1.5em;
}

.demonstrator-richtext__content img {
  border: 1px solid #d0d0d0;
}

.demonstrator-richtext__content ul,
.demonstrator-richtext__content ol {
  margin: 0 0 1.5em;
  padding-left: 1.5em;
}

.demonstrator-richtext__content li {
  margin: 0 0 0.5em;
}

.demonstrator-richtext__content li:last-child {
  margin-bottom: 0;
}

.demonstrator-richtext__content h1,
.demonstrator-richtext__content h2,
.demonstrator-richtext__content h3,
.demonstrator-richtext__content h4 {
  color: var(--green, #004734);
  margin: 0 0 0.75em;
  line-height: 1.25;
}

@media screen and (max-width: 991px) {
  .demonstrator-richtext {
    padding: 40px 30px;
  }
}

/* -------------------------------------------------------------------------
   Trimble demonstrator (panel-6) — JS iframes are height: 100%
   Class name matches upstream TrimbleDemonstrator.js (typo: demostrator).
   ------------------------------------------------------------------------- */
section.demostrator {
  height: 75vh;
  min-height: 75vh;
}
