/* Reading scale and spacing for the main TECHMEN pages. */
body[data-tm-page] {
  --tm-section-space: clamp(40px, 5.3vw, 72px);
  --tm-page-gutter: clamp(16px, 4vw, 54px);
  --tm-title-size: clamp(29px, 3.65vw, 48px);
  --tm-heading-size: clamp(25px, 3.05vw, 40px);
  --tm-copy-size: clamp(14px, 1.24vw, 16px);
  --tm-card-radius: 23px;
}

html body[data-tm-page] main > section:not(.hero, #tmLayeredHome) {
  padding-block: var(--tm-section-space) !important;
}

html body[data-tm-page]:not([data-tm-page="home"]) main > section > .container {
  width: min(1200px, calc(100% - 2 * var(--tm-page-gutter))) !important;
  margin-inline: auto !important;
  padding-inline: 0 !important;
}

html body[data-tm-page]:not([data-tm-page="home"]) main > .hero {
  padding-block: clamp(92px, 10vw, 124px) var(--tm-section-space) !important;
  min-height: 0 !important;
}

html body[data-tm-page]:not([data-tm-page="home"]) main .hero h1 {
  font-size: var(--tm-title-size) !important;
  line-height: 1.1 !important;
  text-wrap: balance;
}

html body[data-tm-page]:not([data-tm-page="home"]) main h2 {
  font-size: var(--tm-heading-size) !important;
  line-height: 1.16 !important;
  text-wrap: balance;
}

html body[data-tm-page]:not([data-tm-page="home"]) main :is(.hero p, .services-head p, .section-copy, .stage-head p, .packages-head p, .compare-head p, .payment-copy p, .decision-copy p, .contact-shell-head p, .cta-copy p, .hero-copy p) {
  max-width: 65ch;
  font-size: var(--tm-copy-size) !important;
  line-height: 1.62 !important;
  text-wrap: pretty;
}

html[dir="rtl"] body[data-tm-page] main :is(h1, h2, h3) {
  letter-spacing: normal !important;
  line-height: 1.34 !important;
}

html body[data-tm-page]:not([data-tm-page="home"]) main :is(.service-block, .stage-card, .decision-card, .payment-card, .contact-shell, .info-card, .story-card, .value-card) {
  border-radius: var(--tm-card-radius) !important;
}

html body[data-tm-page] :is(.tm-unified-footer .tm-footer-box, .tm-unified-footer .tm-footer-social a) {
  min-width: 0;
}

html body[data-tm-page] .tm-unified-footer .tm-footer-box {
  padding: clamp(15px, 2vw, 26px) !important;
  border-radius: 20px !important;
}

html body[data-tm-page] .tm-unified-footer :is(.tm-footer-box p, .tm-footer-links a, .tm-footer-social a, .tm-footer-title) {
  font-size: 12px !important;
  line-height: 1.48 !important;
}

html body[data-tm-page] .tm-unified-footer :is(.tm-footer-bottom, .tm-footer-social small) {
  font-size: 11px !important;
}

html body[data-tm-page] :is(.tm-unified-footer .tm-footer-social a[href^="mailto:"] > span, main a[href^="mailto:"] strong) {
  width: auto !important;
  max-width: none !important;
  direction: ltr;
  unicode-bidi: isolate;
  white-space: nowrap !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
  font-size: clamp(11px, 1.15vw, 13px) !important;
  letter-spacing: 0 !important;
  font-weight: 650 !important;
  text-transform: none !important;
}

html body[data-tm-page] .tm-unified-footer .tm-footer-social a[href^="mailto:"] small {
  font-size: 11px !important;
}

html[dir="rtl"] body[data-tm-page] .tm-unified-footer .tm-footer-social a[href^="mailto:"] small {
  direction: rtl;
}

html body[data-tm-page="home"] main#top {
  --home-space: var(--tm-section-space);
  --home-title: var(--tm-heading-size);
}

html body[data-tm-page="home"] main#top #contact .contact-copy h2 {
  max-width: 15ch !important;
  margin-inline: 0 !important;
  text-align: start !important;
}

html body[data-tm-page="home"] main#top #contact .contact-copy {
  min-width: 0;
  text-align: start !important;
}

html body[data-tm-page="home"] main#top #contact .contact-option {
  position: relative;
  min-width: 0 !important;
  min-height: 88px !important;
  padding: 12px 14px !important;
  grid-template-columns: 30px minmax(0, 1fr) !important;
  column-gap: 8px !important;
}

html body[data-tm-page="home"] main#top #contact .contact-option .option-icon {
  width: 30px !important;
  height: 30px !important;
}

html body[data-tm-page="home"] main#top #contact .email-option strong {
  font-size: clamp(10.5px, .91vw, 12px) !important;
  white-space: nowrap !important;
}

html body[data-tm-page="home"] main#top #contact .contact-option :is(small, span) {
  font-size: 11px !important;
  line-height: 1.45 !important;
}

html body[data-tm-page="home"] main#top #programs .packages-head::after {
  display: none !important;
  content: none !important;
}

html body[data-tm-page] main .tm-flex-note {
  font-size: 12px !important;
  line-height: 1.45 !important;
  padding: 7px 12px !important;
  border-radius: 13px !important;
}

html body[data-tm-page="services"] main .services-head { margin-block-end: 30px !important; }

html body[data-tm-page="services"] main .service-block {
  margin-block: 0 clamp(20px, 3vw, 38px) !important;
  scroll-margin-top: 104px;
}

html body[data-tm-page="services"] main .service-content .service-description,
html body[data-tm-page="services"] main .subservice span {
  font-size: 13px !important;
  line-height: 1.55 !important;
}

html body[data-tm-page="services"] main .subservice {
  min-width: 0;
  min-height: 0 !important;
  padding: clamp(12px, 1.4vw, 18px) !important;
  border-radius: 15px !important;
}

html body[data-tm-page="services"] main .subservice::before { margin-block-end: 9px !important; }

html body[data-tm-page="services"] main .subservice b {
  font-size: 14px !important;
  line-height: 1.3 !important;
}

html body[data-tm-page="about"] main :is(.story-card, .service-card, .mission-point, .hero-stat) :is(p, span) {
  font-size: 13px !important;
  line-height: 1.57 !important;
}

html body[data-tm-page="contact"] main .info-card {
  min-width: 0;
  gap: 10px !important;
  padding: 12px !important;
}

html body[data-tm-page="contact"] main .info-card :is(small, span) {
  font-size: 12px !important;
  line-height: 1.5 !important;
}

@media (max-width: 1160px) {
  html body[data-tm-page="home"] main#top #contact .contact-card { grid-template-columns: minmax(0, 1fr) !important; }
}

@media (max-width: 800px) {
  html body[data-tm-page] .tm-unified-footer {
    padding: 14px 0 8px !important;
  }

  html body[data-tm-page] .tm-unified-footer .container {
    width: calc(100% - 24px) !important;
    padding-inline: 0 !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 9px !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-box {
    padding: 7px !important;
    border: 1px solid #ffffff1f !important;
    border-radius: 13px !important;
    background: #ffffff08 !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-box:first-child :is(h2, p) {
    display: none !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-box:first-child {
    padding-block: 0 !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-logo {
    width: fit-content;
    min-height: 44px;
    padding-inline: 4px;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-title {
    margin: 0 0 5px !important;
    padding-inline: 3px;
    color: #d8cfe0 !important;
    font-size: 11px !important;
    line-height: 1.4 !important;
  }

  html body[data-tm-page] .tm-unified-footer :is(.tm-footer-links, .tm-footer-social) {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 4px !important;
  }

  html body[data-tm-page] .tm-unified-footer :is(.tm-footer-links a, .tm-footer-social a) {
    min-width: 0 !important;
    min-height: 44px !important;
    padding: 4px 5px !important;
    justify-content: center !important;
    text-align: center !important;
    border: 1px solid #ffffff1c !important;
    border-radius: 8px !important;
    background: #ffffff08 !important;
    font-size: 11px !important;
    line-height: 1.25 !important;
    white-space: normal !important;
    overflow-wrap: anywhere;
  }

  @media (hover: hover) {
    html body[data-tm-page] .tm-unified-footer :is(.tm-footer-links, .tm-footer-social) a:hover {
      background: #ffffff16 !important;
    }
  }

  html body[data-tm-page] .tm-unified-footer :is(.tm-footer-links, .tm-footer-social) a > b {
    display: none !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-social a > span {
    max-width: 100% !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-social .tm-footer-contact-method {
    grid-column: 1 / -1;
    padding-inline: 9px !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-social .tm-footer-contact-method > span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    width: 100% !important;
    direction: inherit;
    text-align: start;
    white-space: normal !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-contact-method small {
    margin: 0 !important;
    color: #cec1d7 !important;
    font-size: 10px !important;
    line-height: 1.3 !important;
    letter-spacing: normal !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-contact-value {
    direction: ltr;
    unicode-bidi: isolate;
    white-space: nowrap !important;
    font-size: 11px !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-social :is(.tm-footer-handle, a[href="/contact/"] small) {
    display: none !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-social a:has(.tm-footer-handle) small {
    color: inherit !important;
    font-size: inherit !important;
    line-height: inherit !important;
    letter-spacing: normal !important;
  }

  html body[data-tm-page] .tm-unified-footer .tm-footer-bottom {
    min-height: 44px !important;
    margin-top: 8px !important;
    padding: 5px 0 !important;
    flex-wrap: wrap;
    gap: 3px 10px !important;
    font-size: 10px !important;
    line-height: 1.35 !important;
  }
}

@media (max-width: 700px) {
  body[data-tm-page] {
    --tm-section-space: clamp(34px, 8.5vw, 46px);
    --tm-page-gutter: 16px;
    --tm-title-size: clamp(27px, 7.7vw, 38px);
    --tm-heading-size: clamp(23px, 6.2vw, 32px);
  }

  html body[data-tm-page="home"] main#top #contact .contact-copy h2 { max-width: none !important; }
  html body[data-tm-page="home"] main#top #contact .contact-options { grid-template-columns: minmax(0, 1fr) !important; }

  html body[data-tm-page="services"] main .subservices {
    grid-template-columns: repeat(auto-fit, minmax(min(130px, 100%), 1fr)) !important;
    gap: 9px !important;
  }
}


html body[data-tm-page="packages"] main .why-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
}

html body[data-tm-page="packages"] main .table-wrap { max-width: 100%; }

html body[data-tm-page="home"] main#top #contact .contact-option > b {
  position: absolute;
  inset: 9px 10px auto auto;
}

html[dir="rtl"] body[data-tm-page="home"] main#top #contact .contact-option > b {
  inset: 9px auto auto 10px;
}

@media (min-width: 801px) and (max-width: 1050px) {
  html body[data-tm-page] .tm-unified-footer .tm-footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  html body[data-tm-page] .tm-unified-footer .tm-footer-box:first-child { grid-column: 1 / -1; }
}

@media (max-width: 800px) {
  html body[data-tm-page="packages"] main .why-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
}

@media (max-width: 370px) {
  html body[data-tm-page="home"] main#top #contact .contact-option {
    padding-inline: 10px !important;
    grid-template-columns: 26px minmax(0, 1fr) !important;
    column-gap: 6px !important;
  }
  html body[data-tm-page="home"] main#top #contact .contact-option .option-icon {
    width: 26px !important;
    height: 26px !important;
  }
}

html body[data-tm-page="packages"] main .trust-row {
  display: flex !important;
  flex-wrap: wrap;
}

html body[data-tm-page="packages"] main :is(.trust-pill, .why-card h3) {
  min-width: 0;
  white-space: normal !important;
  overflow-wrap: anywhere;
}

html body[data-tm-page] .tm-surface.tm-surface-active { filter: none !important; }

html body[data-tm-page] main > section[id] { scroll-margin-top: 92px; }

/* Calm the type scale while keeping the package card typography intact. */
html[lang] body[data-tm-page] main :is(h1, h2, h3):not(.tm-plan-name h3),
html[lang] body[data-tm-page] main :is(h1, h2, h3):not(.tm-plan-name h3) :is(span, em) {
  text-transform: none !important;
}

html[lang] body[data-tm-page] .tm-unified-footer .tm-footer-box h2 {
  font-size: clamp(21px, 2.1vw, 31px) !important;
  line-height: 1.2 !important;
  text-transform: none !important;
}

html[lang] body[data-tm-page="home"] main#top #tmLayeredHome .home-copy h1 {
  font-size: clamp(31px, 4.1vw, 56px) !important;
  line-height: 1.09 !important;
  letter-spacing: -.035em !important;
}

html[lang^="ar"] body[data-tm-page="home"] main#top #tmLayeredHome .home-copy h1 {
  line-height: 1.32 !important;
  letter-spacing: normal !important;
}

html[lang] body[data-tm-page="home"] main#top #system .system-intro h2 {
  font-size: clamp(26px, 3.2vw, 41px) !important;
  line-height: 1.18 !important;
}

html[lang] body[data-tm-page] main :is(.contact-copy, .cta-copy, .decision-copy, .contact-shell-head, .final-card, .cta-card) h2 {
  font-size: clamp(23px, 2.8vw, 34px) !important;
  line-height: 1.18 !important;
}

html[lang] body[data-tm-page="services"] main .service-content h3 {
  font-size: clamp(20px, 2.5vw, 32px) !important;
  line-height: 1.18 !important;
  letter-spacing: -.025em !important;
  text-wrap: balance;
}

/* Compact labels and padding with a 44px minimum target for touch. */
html[lang] body[data-tm-page] main :is(a.btn-primary, a.btn-secondary, a.btn-dark, a.btn-light, a.final-btn, button.submit-btn, .service-cta) {
  min-width: 0 !important;
  width: fit-content !important;
  max-width: 100% !important;
  min-height: 44px !important;
  height: auto !important;
  padding: 8px 15px !important;
  gap: 8px !important;
  font-size: 13px !important;
  line-height: 1.35 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  white-space: normal !important;
}

html[lang] body[data-tm-page] main .hero-actions {
  gap: 8px !important;
}

html[lang] body[data-tm-page="home"] main#top #tmLayeredHome .home-actions {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
}

html[lang] body[data-tm-page="home"] main#top #tmLayeredHome .home-actions > a {
  width: fit-content !important;
  max-width: 100% !important;
  min-height: 44px !important;
  height: auto !important;
  padding: 8px 13px !important;
  gap: 8px !important;
  font-size: clamp(12px, 1.02vw, 13px) !important;
  line-height: 1.35 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
}

html[lang] body[data-tm-page="home"] main#top #tmLayeredHome .home-actions i {
  width: 25px !important;
  height: 25px !important;
  flex: 0 0 25px !important;
  margin: 0 !important;
}

html[lang] body[data-tm-page="home"] main#top #contact .contact-final-action .btn-primary {
  padding: 8px 15px !important;
  min-height: 44px !important;
  width: fit-content !important;
}

/* The Solvy showcase stays in normal flow. Only its actual link is interactive. */
#solvy .solvy-showcase {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(18px, 3.5vw, 46px);
  padding: clamp(18px, 4vw, 50px);
  border: 1px solid #3b3150;
  border-radius: 26px;
  background: radial-gradient(ellipse at 92% 0, #43245f, transparent 63%), #1b1527;
  color: #fff;
  box-shadow: 0 16px 44px #29153a1c;
}

#solvy .solvy-showcase > * { min-width: 0; }

#solvy .solvy-showcase-label {
  color: #d7beee;
  font-size: 12px;
  font-weight: 700;
}

html body main#top #solvy .solvy-showcase h2 {
  color: #fff !important;
  font-weight: 680 !important;
  text-wrap: pretty;
}

#solvy-title > span { color: #e2bafa; }

@supports (background-clip: text) {
  #solvy-title > span {
    background: linear-gradient(105deg, #c99afa 15%, #ffbf94 95%);
    background-clip: text;
    color: transparent;
  }
}

#solvy .solvy-showcase-copy > p {
  max-width: 45ch;
  margin: 0;
  color: #e2d8ed;
  font-size: var(--tm-copy-size);
  line-height: 1.6;
}

#solvy .solvy-benefits,
#solvy .solvy-workflow-steps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 0;
  list-style: none;
}

#solvy .solvy-benefits {
  margin: 16px 0;
  color: #f1e9f8;
}

#solvy .solvy-benefits li {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 13px;
  line-height: 1.45;
}

#solvy .solvy-benefits li::before { content: "✓"; color: #deb4ff; }

#solvy .solvy-showcase-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px 14px;
  border-radius: 12px;
  background: #edddfb;
  color: #2c183e;
  font-size: 13px;
  font-weight: 740;
  line-height: 1.35;
  text-decoration: none;
}

#solvy .solvy-workflow {
  padding: clamp(12px, 2vw, 22px);
  border: 1px solid #e3c4ff38;
  border-radius: 18px;
  background: #1a1428;
}

#solvy .solvy-workflow-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-block-end: 12px;
  font-size: 14px;
  line-height: 1.4;
}

#solvy .solvy-workflow-mark {
  display: grid;
  place-items: center;
  flex: 0 0 35px;
  height: 35px;
  border-radius: 11px;
  background: linear-gradient(130deg, #5b3981, #684043);
  color: #ffddc5;
}

#solvy .solvy-workflow-steps { margin: 0; }

#solvy .solvy-workflow-steps li {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border: 1px solid #e3c4ff24;
  border-radius: 12px;
  background: linear-gradient(145deg, #2c2140, #251e34);
  line-height: 1.35;
}

#solvy .solvy-workflow-steps li > span { color: #ffcda8; font-size: 10px; }
#solvy .solvy-workflow-steps li > strong { color: #fff; font-size: 13px; }
#solvy .solvy-workflow-steps li > small { color: #d7cbe2; font-size: 12px; }

@media (max-width: 800px) {
  #solvy .solvy-showcase { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 700px) {
  html[lang] body[data-tm-page="home"] main#top #tmLayeredHome .home-copy h1 {
    font-size: clamp(29px, 7.9vw, 43px) !important;
  }

  html[lang] body[data-tm-page] main .hero-actions {
    display: flex !important;
    flex-wrap: wrap !important;
  }

  html[lang] body[data-tm-page] main :is(a.btn-primary, a.btn-secondary, a.btn-dark, a.btn-light, a.final-btn, button.submit-btn, .service-cta) {
    padding-inline: 12px !important;
    font-size: 12px !important;
  }
}
