/* Desktop-style layout for tablets and unfolded phones.
   Phones below 768px and full desktop pointer layouts remain unchanged. */
@media (min-width: 768px) and (max-width: 1199.98px),
       (min-width: 1200px) and (max-width: 1400px) and (hover: none) and (pointer: coarse) {
  body.home-v2 #smooth-content.home-hero-backdrop > section > .container {
    width: calc(100% - 48px);
    max-width: 1200px;
    margin-inline: auto;
  }

  /* Undo the old touch-device rule that stacked the hero at up to 1400px. */
  body.home-v2 .home-hero-refresh.hero-section.hero-1 { padding: 32px 0 48px; }
  body.home-v2 .home-hero-refresh.hero-1 > .container > .row.g-4 {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 24px;
    align-items: end;
    margin: 0;
    --bs-gutter-x: 0;
    --bs-gutter-y: 0;
  }
  body.home-v2 .home-hero-refresh.hero-1 .row.g-4 > .col-lg-6 {
    width: auto;
    max-width: none;
    min-width: 0;
    margin: 0;
    padding: 0;
    flex: none;
  }
  body.home-v2 .home-hero-refresh.hero-1 .hero-content {
    max-width: none;
    margin: 0;
    padding: 16px 0 24px;
    text-align: start;
  }
  body.home-v2 .home-hero-refresh.hero-1 .hero-content h1 {
    max-width: none;
    margin: 0 0 20px;
    font-size: clamp(38px, 4.8vw, 64px);
    font-weight: 500;
    line-height: 1.04;
    text-align: start;
  }
  body.home-v2 .home-hero-refresh.hero-1 .hero-content p.hero-subhead {
    max-width: none;
    margin: 0;
    font-size: clamp(16px, 1.65vw, 20px);
    line-height: 1.5;
    text-align: start;
  }
  body.home-v2 .home-hero-refresh.hero-1 .hero-btn {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
  }
  body.home-v2 .home-hero-refresh.hero-1 .hero-btn .theme-btn { padding: 14px 18px; font-size: 14px; }
  body.home-v2 .home-hero-refresh.hero-1 .home-hero-visual-column {
    display: flex;
    align-self: stretch;
    align-items: flex-end;
  }
  body.home-v2 .home-hero-refresh.hero-1 .hero-image.home-hero-video-surface {
    width: 100%;
    max-width: none;
    margin: 0 0 -2px;
  }
  body.home-v2 #smooth-content.home-hero-backdrop::before {
    width: var(--home-circle-diameter);
    height: auto;
    aspect-ratio: 1;
    left: calc(var(--home-hero-image-x) - 30px);
    top: calc(var(--home-hero-image-y) - var(--home-hero-image-height) * 0.15 - var(--home-circle-diameter) / 2 + 30px);
    border-radius: 48% 52% 42% 58% / 50% 46% 54% 50%;
    background-image: radial-gradient(ellipse 55% 48% at right top, color-mix(in srgb, var(--purple) 55%, transparent) 0%, transparent 100%);
    background-size: min(100%, calc(100vw - var(--home-hero-image-x) + 30px)) calc(var(--home-circle-diameter) / 2 + var(--home-hero-image-y) - var(--home-hero-image-height) * 0.15 + 30px);
    background-position: left bottom;
  }
  body.home-v2 .home-hero-refresh.hero-1 .home-hero-persona-name { font-size: max(10px, 1.859375cqw); }
  body.home-v2 .home-hero-refresh.hero-1 .home-hero-persona-outcome { font-size: max(16px, 3.984375cqw); }
  body.home-v2 .home-hero-refresh .home-hero-products { margin-top: 24px; }
  body.home-v2 .home-hero-refresh .home-hero-products a { min-width: 0; padding: 18px 14px; gap: 8px; }
  body.home-v2 .home-hero-refresh .home-hero-product-copy > span { font-size: 14px; }
  body.home-v2 .home-hero-refresh .home-hero-product-description { font-size: 12px; line-height: 1.4; }
  body.home-v2 .home-hero-refresh .home-hero-intro { width: min(100%, 760px); margin: 40px auto 0; }

  /* Keep the existing desktop sections, not the phone-only summaries. */
  body.home-v2 .home-template-section.section-padding,
  body.home-v2 .home-std-section.section-padding,
  body.home-v2 .team-section.section-padding,
  body.home-v2 .testimonial-section.section-padding { padding: 48px 0; }
  body.home-v2 .section-title h2 { font-size: clamp(30px, 3.6vw, 42px); line-height: 1.12; }
  body.home-v2 .home-template-section .section-title-area { gap: 24px; margin-bottom: 28px; }
  body.home-v2 .home-template-section .home-program-all { font-size: 14px; white-space: nowrap; }
  body.home-v2 .home-template-section .service-slider { padding-inline: 24px; }
  body.home-v2 .home-template-section .swiper-wrapper { align-items: stretch; }
  body.home-v2 .home-template-section .swiper-slide { height: auto; }
  body.home-v2 .home-template-section .service-box-item { height: 100%; min-height: 340px; padding: 24px; }
  body.home-v2 .home-template-section .service-box-item .icon { margin-bottom: 18px; }
  body.home-v2 .home-template-section .service-box-item .content h3 { font-size: 24px; line-height: 1.15; }
  body.home-v2 .home-template-section .service-box-item .content p { font-size: 15px; line-height: 1.5; }
  body.home-v2 .home-template-section .home-program-watch-button { padding: 10px; gap: 6px; font-size: 13px; }
  body.home-v2 .home-template-section .home-program-watch-meta { padding-inline-start: 6px; font-size: 12px; }

  body.home-v2 .home-std-section .project-box-wrapper { margin-top: 28px; }
  body.home-v2 .home-std-section .project-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
    align-items: center;
    gap: 24px;
    padding: 24px;
    margin-bottom: 24px;
  }
  body.home-v2 .home-std-section .project-panel .project-content { width: auto; min-width: 0; padding: 0; }
  body.home-v2 .home-std-section .project-panel .project-content h3 { font-size: clamp(24px, 2.65vw, 34px); line-height: 1.15; margin-bottom: 16px; }
  body.home-v2 .home-std-section .project-panel .project-content p { font-size: 15px; line-height: 1.55; margin-bottom: 16px; }
  body.home-v2 .home-std-section .project-panel .project-thumb.home-feature-media {
    /* Supersede the old fixed 280px !important tablet thumbnail. */
    width: 100% !important;
    height: auto !important;
    flex: none !important;
    max-width: 100%;
    aspect-ratio: 5 / 4;
  }
  body.home-v2 .home-std-section .renatus-card-cta { padding: 12px 16px; font-size: 14px; }

  body.home-v2 .team-section .team-wrapper > .row {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
    align-items: center;
    gap: 24px;
    margin: 0;
  }
  body.home-v2 .team-section .team-wrapper { padding: 32px; }
  body.home-v2 .team-section .team-wrapper > .row > [class*="col-"] { width: auto; min-width: 0; padding: 0; margin: 0; }
  body.home-v2 .team-section .counter-content { max-width: none; margin: 0; padding: 0; }
  body.home-v2 .team-section .counter-content .text { font-size: 16px; line-height: 1.5; margin-block: 20px; }
  body.home-v2 .team-section .counter-content > a.theme-btn { display: inline-flex !important; padding: 12px 18px; font-size: 14px; }
  body.home-v2 .team-section .renatus-pricing-cta-mobile { display: none; }
  body.home-v2 .team-section .team-wrapper > .row > [class*="col-"] > .row { --bs-gutter-x: 16px; --bs-gutter-y: 16px; }
  body.home-v2 .team-section .renatus-pricing-card { padding: 20px 16px; min-height: 220px; height: 100%; }
  body.home-v2 .team-section .renatus-pricing-card__price { flex-wrap: wrap; }
  body.home-v2 .team-section .renatus-pricing-card__amount { font-size: clamp(42px, 5vw, 64px); }
  body.home-v2 .team-section .renatus-pricing-card__body { font-size: 14px; line-height: 1.5; }
  body.home-v2 .testimonial-section .section-title-area { margin-bottom: 28px; }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  /* Keep the desktop pair of pricing cards, with a compact heading row above. */
  body.home-v2 .team-section .team-wrapper > .row { grid-template-columns: minmax(0, 1fr); }
  body.home-v2 .team-section .counter-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px 24px;
  }
  body.home-v2 .team-section .counter-content .section-title,
  body.home-v2 .team-section .counter-content .text { grid-column: 1; }
  body.home-v2 .team-section .counter-content .text { margin: 0; }
  body.home-v2 .team-section .counter-content > a.theme-btn { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
}

@media (min-width: 1200px) and (max-width: 1400px) and (hover: none) and (pointer: coarse) {
  body.home-v2 .home-hero-refresh.hero-section.hero-1 { padding-top: 96px; }
}
