/* ==========================================================================
   NASHORN – Responsive
   Developed by webndo

   Desktop  >= 1200px (base styles)
   Tablet   768px – 1199px
   Mobile   <= 767px
   ========================================================================== */

/* --------------------------------------------------------------------------
   Large desktop refinements
   -------------------------------------------------------------------------- */
@media (min-width: 1600px) {
  .hero__panel::before {
    width: calc((100vw - var(--container)) / 2 + 560px);
  }
}

/* --------------------------------------------------------------------------
   Tablet and below
   -------------------------------------------------------------------------- */
@media (max-width: 1199.98px) {
  :root {
    --header-h: 76px;
    --header-h-compact: 68px;
  }

  body:not(.site-shell) .primary-nav {
    display: none;
  }

  body:not(.site-shell) .menu-toggle {
    display: grid;
  }

  body:not(.site-shell) .site-header__inner {
    gap: 16px;
  }

  body:not(.site-shell) .site-header__logo img {
    height: 46px;
  }

  body:not(.site-shell) .site-header.is-scrolled .site-header__logo img {
    height: 40px;
  }

  /* Hero */
  .hero {
    --hero-body: clamp(620px, 78vw, 820px);
  }

  .hero__panel::before {
    width: 62%;
  }

  .hero__media img {
    object-position: 18% 50%;
  }

  /* Product lines */
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  /* Rokmob feature */
  .feature__media {
    inset: 0 0 0 38%;
  }

  .feature__content {
    max-width: 440px;
  }

  .benefit-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 0;
  }

  .benefit-list__item:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }

  /* Categories */
  .category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }

  /* Featured */
  .featured__media {
    inset: 0 0 0 42%;
  }

  .featured__content {
    max-width: 420px;
  }

  /* Applications */
  .applications__head {
    margin-bottom: 36px;
  }

  .application-grid {
    height: clamp(300px, 35vh, 336px);
  }

  .application-card__body {
    padding: 0 28px 28px;
  }

  .application-card__icon {
    top: 40px;
    left: 28px;
    width: 50px;
    height: 50px;
    transform: translateY(-16px);
  }

  .application-card__arrow {
    top: 28px;
    right: 28px;
    width: 28px;
    height: 28px;
  }

  .application-card__text {
    font-size: var(--fs-xs);
  }

  /* Engineering */
  .engineering__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
  }

  .engineering__content {
    align-self: stretch;
    max-width: 620px;
  }

  /* Duo */
  .duo {
    grid-template-columns: minmax(0, 1fr);
  }

  .about__inner {
    max-width: none;
    width: min(var(--container), 100% - 2 * var(--gutter));
    margin-inline: auto;
    padding: var(--space-section-sm) 0;
  }

  .about__text {
    max-width: 640px;
  }

  .highlight-list {
    max-width: 760px;
  }

  /* News */
  .news__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
  }

  /* CTA */
  .cta__media {
    inset: 0 0 0 20%;
  }

  /* Footer */
  body:not(.site-shell) .site-footer__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 36px 28px;
  }

  body:not(.site-shell) .site-footer__brand {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 0 0 32px;
    border-right: 0;
    border-bottom: 1px solid var(--line-light);
  }

  body:not(.site-shell) .site-footer__statement {
    max-width: 320px;
    margin-top: 0;
    text-align: right;
  }

  body:not(.site-shell) .site-footer__contact {
    grid-column: 1 / -1;
  }

  body:not(.site-shell) .site-footer__contact address {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 22px;
  }
}

@media (max-width: 1023.98px) {
  .application-grid {
    container-type: normal;
    display: flex;
    flex-direction: column;
    height: auto;
    gap: 14px;
  }

  .application-grid > li,
  .application-grid > li:nth-child(1),
  .application-grid > li:nth-child(2),
  .application-grid > li:nth-child(3) {
    position: relative;
    left: auto;
    right: auto;
    width: 100%;
    height: auto;
    pointer-events: auto;
  }

  .application-grid > li:nth-child(n) .application-card {
    height: 340px;
    clip-path: none;
  }

  .application-grid > li:nth-child(n) .application-card__body {
    padding: 0 28px 28px;
  }

  .application-grid > li:nth-child(n) .application-card__arrow {
    right: 28px;
  }

  .application-card__icon {
    width: 48px;
    height: 48px;
    transform: translateY(-14px);
  }

  .application-card__text {
    max-height: none;
    margin-top: 8px;
    opacity: 1;
    transform: none;
  }
}

/* --------------------------------------------------------------------------
   Mobile
   -------------------------------------------------------------------------- */
@media (max-width: 767.98px) {
  :root {
    --header-h: 68px;
    --header-h-compact: 62px;
  }

  body {
    font-size: 1rem;
  }

  body:not(.site-shell) .site-header__cta {
    display: none;
  }

  body:not(.site-shell) .site-header__logo img {
    height: 40px;
  }

  body:not(.site-shell) .site-header.is-scrolled .site-header__logo img {
    height: 36px;
  }

  .eyebrow {
    gap: 14px;
    margin-bottom: 18px;
    font-size: 0.6875rem;
    letter-spacing: 0.16em;
  }

  .eyebrow::before {
    width: 24px;
  }

  .btn {
    min-height: 54px;
  }

  /* Hero: content over the light upper part of the portrait image */
  .hero {
    --hero-body: auto;
    min-height: 0;
  }

  .hero__panel {
    min-height: 0;
  }

  .hero__panel::before {
    width: 100%;
    background: linear-gradient(180deg, rgba(244, 246, 249, 0.96) 0%, rgba(244, 246, 249, 0.9) 52%, rgba(244, 246, 249, 0.55) 68%, rgba(244, 246, 249, 0) 84%);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .hero__media img {
    object-position: 50% 100%;
  }

  .hero__content {
    padding-top: 44px;
    padding-bottom: 78vw;
  }

  .hero__title {
    margin-bottom: 22px;
    font-size: clamp(2.125rem, 1.2rem + 4.6vw, 2.625rem);
    line-height: 1.1;
  }

  .hero__line {
    display: inline;
  }

  .hero__line > span {
    display: inline;
  }

  .hero__line:first-child::after {
    content: "\A";
    white-space: pre;
  }

  .hero__line:nth-child(2)::after {
    content: " ";
  }

  .hero__lead {
    margin-bottom: 26px;
    font-size: 1.0625rem;
  }

  .hero__actions {
    flex-direction: column;
    margin-bottom: 0;
  }

  .hero__actions .btn {
    justify-content: space-between;
  }

  /* Section heads */
  .section-head--split {
    gap: 16px;
  }

  .product-lines__head,
  .applications__head {
    padding-inline: 0;
  }

  /* Horizontal snap sliders */
  .product-grid,
  .category-grid {
    display: grid;
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: 80%;
    gap: 14px;
    margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter);
    padding-bottom: 12px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }

  .product-grid::-webkit-scrollbar,
  .category-grid::-webkit-scrollbar {
    display: none;
  }

  .product-grid > li,
  .category-grid > li {
    scroll-snap-align: start;
  }

  .container--wide .product-grid {
    margin-inline: calc(min(var(--gutter), 40px) * -1);
    padding-inline: min(var(--gutter), 40px);
  }

  .product-card__body {
    padding: 20px 18px 22px;
  }

  .product-card__title {
    font-size: 1.25rem;
  }

  /* Media-first layouts */
  .feature,
  .featured,
  .showroom,
  .cta {
    display: block;
    min-height: 0;
  }

  .feature__media,
  .featured__media,
  .showroom__media {
    position: relative;
    inset: auto;
    aspect-ratio: 4 / 3;
    -webkit-mask-image: none;
    mask-image: none;
  }

  .feature__media img {
    object-position: 55% 60%;
  }

  .featured__media {
    aspect-ratio: 1 / 0.9;
  }

  .featured__media img {
    object-position: 58% 70%;
  }

  .feature__inner,
  .featured__inner {
    padding-block: 44px 64px;
  }

  .feature__content,
  .featured__content {
    max-width: none;
  }

  .benefit-list {
    max-width: none;
  }

  .about__inner {
    padding-block: 64px;
  }

  .highlight-list {
    grid-template-columns: minmax(0, 1fr);
    border-top: 0;
  }

  .highlight-list__item,
  .highlight-list__item + .highlight-list__item {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 2px 14px;
    padding: 18px 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .highlight-list__icon {
    grid-row: span 2;
    margin: 2px 0 0;
  }

  /* Applications */
  .application-grid > li:nth-child(n) .application-card {
    height: 320px;
  }

  .application-grid > li:nth-child(n) .application-card__body {
    padding: 0 22px 24px;
  }

  .application-card__icon {
    top: 36px;
    left: 22px;
    width: 46px;
    height: 46px;
  }

  .application-card__arrow {
    top: 22px;
    right: 22px;
  }

  /* News */
  .news-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .news-card__body {
    padding: 22px 22px 24px;
  }

  /* CTA */
  .cta__media {
    inset: 0;
  }

  .cta__media::after {
    background: linear-gradient(180deg, rgba(13, 28, 39, 0.72) 0%, rgba(13, 28, 39, 0.9) 60%, var(--navy-900) 100%);
  }

  .cta__inner {
    padding-block: 72px;
  }

  .cta__actions {
    flex-direction: column;
  }

  .cta__actions .btn {
    justify-content: space-between;
  }

  /* Footer */
  body:not(.site-shell) .site-footer__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 20px;
    padding-top: 44px;
  }

  body:not(.site-shell) .site-footer__brand {
    display: block;
    padding-bottom: 28px;
  }

  body:not(.site-shell) .site-footer__statement {
    margin-top: 18px;
    text-align: left;
  }

  body:not(.site-shell) .site-footer__contact address {
    display: grid;
  }

  body:not(.site-shell) .site-footer__col a {
    display: inline-block;
    padding-block: 4px;
  }

  body:not(.site-shell) .site-footer__bottom {
    flex-direction: column-reverse;
    align-items: flex-start;
  }
}

/* Small phones */
@media (max-width: 379.98px) {
  .product-grid,
  .category-grid {
    grid-auto-columns: 86%;
  }
}
