/* =========================================================================
   Legal Tiger — Nova reskin
   Layered on Bootstrap 5.3.3. Tokens, type and components follow the Nova
   theme (themewagon.github.io/Nova-Bootstrap): Inter, teal #215C5C, mint
   #CCE8C9, 7px radius, 70px sections, pill subtitles, soft-shadow cards.

   Where Nova has no component for what this site does — a 76-standard
   catalogue, a long-form article, a certificate spec sheet — the pattern is
   built here in Nova's visual language rather than dropped.
   ========================================================================= */

:root,
[data-bs-theme="light"] {
  --bs-body-bg: #ffffff;
  --bs-body-color: #494B5B;
  --bs-primary: #215C5C;
  --bs-primary-rgb: 33, 92, 92;
  --bs-primary-hover: #144B4B;
  --bs-secondary: #CCE8C9;
  --bs-secondary-rgb: 204, 232, 201;
  --bs-heading-color: #16181B;
  --bs-link-color: var(--bs-primary);
  --bs-link-hover-color: var(--bs-primary-hover);
  --bs-border-color: #E6E8EC;

  --soft: #F6F9F6;
  --muted: #6B7280;
  --radius: 7px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(22, 24, 27, .06);
}

body {
  font: 1rem/1.7 "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  background-color: var(--bs-body-bg);
  color: var(--bs-body-color);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--bs-heading-color);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.2;
}
h1 { font-size: clamp(2.1rem, 4.4vw, 3.1rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.15rem; }

a { text-decoration: none; }
a:hover { color: var(--bs-primary-hover); }

:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 3px; border-radius: 3px; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 1080;
  background: var(--bs-primary); color: #fff; padding: .75rem 1.25rem; }
.skip-link:focus { left: 0; }

.section { padding: 70px 0; scroll-margin-top: 60px; }
.section-soft { background: var(--soft); }
@media (max-width: 767.98px) { .section { padding: 40px 0; } }

/* Nova's pill subtitle */
.subtitle {
  background-color: rgba(var(--bs-secondary-rgb), .35);
  color: var(--bs-primary);
  display: inline-block;
  padding: 5px 12px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: .75rem;
  margin-bottom: 10px;
}

/* --- buttons ------------------------------------------------------------- */

.btn {
  padding: 12px 20px;
  border-radius: var(--radius);
  font-weight: 600;
  border: 1px solid transparent;
}
.btn-primary { background-color: var(--bs-primary); border-color: var(--bs-primary); color: #fff; }
.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
  background-color: var(--bs-primary-hover) !important;
  border-color: var(--bs-primary-hover) !important; color: #fff !important;
}
.btn-outline-dark {
  background: transparent; border-color: var(--bs-border-color); color: var(--bs-heading-color);
}
.btn-outline-dark:hover { background: var(--soft); border-color: var(--bs-primary); color: var(--bs-primary); }
.btn-white-outline { background: transparent; border-color: rgba(255,255,255,.45); color: #fff; }
.btn-white-outline:hover { background: rgba(255,255,255,.12); border-color: #fff; color: #fff; }

/* --- hero ---------------------------------------------------------------- */

.hero { padding: 76px 0 60px; }
.hero h1 { margin-bottom: 1rem; }
.hero .lead { color: var(--muted); font-size: 1.05rem; max-width: 46ch; }

/* Nova floats a product card over the hero image. Here the equivalent
   artefact is the certificate itself, so the float is a certificate card. */
.hero-visual { position: relative; }
.hero-figure {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: linear-gradient(135deg, #1d5555 0%, #2d7070 55%, #3d8a86 100%);
  min-height: 400px;
  display: flex; align-items: flex-start;
  padding: 2.5rem 2.5rem 8rem;
}
.hero-figure .hero-mark { color: rgba(255,255,255,.9); }
.hero-figure .hero-mark .big {
  font-size: clamp(1.9rem, 3.4vw, 2.7rem); font-weight: 700; letter-spacing: -.03em; color: #fff;
  font-variant-numeric: tabular-nums; line-height: 1.05; white-space: nowrap;
}
.hero-figure .hero-mark .small { font-size: .85rem; color: rgba(255,255,255,.78); margin-top: .6rem; max-width: 26ch; }

.hero-card {
  position: absolute; right: -22px; bottom: -26px; width: 300px;
  background: #fff; border-radius: 12px; box-shadow: 0 12px 40px rgba(22,24,27,.14);
  padding: 1rem 1.15rem;
}
.hero-card .hc-head {
  display: flex; justify-content: space-between; align-items: center;
  font-size: .7rem; color: var(--muted); margin-bottom: .6rem;
}
.hero-card .hc-row {
  display: flex; justify-content: space-between; gap: .75rem; align-items: baseline;
  padding: .45rem 0; border-top: 1px solid var(--bs-border-color); font-size: .82rem;
}
.hero-card .hc-row strong { color: var(--bs-heading-color); font-weight: 600; }
.hero-card .hc-row span { color: var(--muted); }
.hero-card .hc-status {
  display: inline-block; background: rgba(var(--bs-secondary-rgb), .5); color: var(--bs-primary);
  border-radius: 20px; padding: 2px 10px; font-size: .7rem; font-weight: 600;
}

/* trusted-by row, understated, under the CTA */
.trusted { margin-top: 2.25rem; }
.trusted p { font-size: .72rem; font-weight: 600; color: var(--muted); margin-bottom: .65rem; }
.trusted .logos { display: flex; flex-wrap: wrap; gap: 1.75rem; align-items: center; }
.trusted .logos img { max-height: 30px; width: auto; opacity: .62; filter: grayscale(1); }

/* --- cards --------------------------------------------------------------- */

/* No height:100% here — a standalone card would stretch to fill its
   flex-stretched Bootstrap column. Add .h-100 where equal heights are wanted. */
.card-soft {
  background: #fff; border: 1px solid var(--bs-border-color);
  border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: 1.75rem;
}
.icon-circle {
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(var(--bs-secondary-rgb), .45); color: var(--bs-primary);
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: .9rem; flex: none;
}
.icon-circle svg { width: 20px; height: 20px; }

/* Nova's "Why choose us": intro left, feature grid right, one tinted panel */
.panel {
  background: var(--soft); border-radius: var(--radius-lg); padding: 3rem;
}
@media (max-width: 767.98px) { .panel { padding: 1.75rem; } }
.feature h3 { font-size: 1rem; margin-bottom: .3rem; }
.feature p { font-size: .9rem; color: var(--muted); margin: 0; }

/* --- the catalogue ------------------------------------------------------- */
/* Nova has no 76-item index. Built here in its idiom: soft rows, teal accents. */

.catalogue-group + .catalogue-group { margin-top: 2.5rem; }
.catalogue-group > h3 {
  font-size: .78rem; font-weight: 700; color: var(--bs-primary);
  background: rgba(var(--bs-secondary-rgb), .3);
  display: inline-block; padding: 5px 12px; border-radius: var(--radius); margin-bottom: .85rem;
}
.std-row {
  display: grid; grid-template-columns: minmax(170px, 240px) 1fr auto;
  gap: 1.25rem; align-items: center;
  padding: .95rem 1.15rem; border: 1px solid var(--bs-border-color);
  border-radius: var(--radius); margin-bottom: .5rem; background: #fff;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.std-row:hover {
  border-color: var(--bs-primary); box-shadow: var(--shadow); transform: translateY(-1px);
}
.std-code { font-weight: 700; color: var(--bs-heading-color); font-variant-numeric: tabular-nums; }
.std-name { color: var(--muted); font-size: .9rem; }
.std-go { color: var(--bs-primary); font-weight: 600; font-size: .85rem; }

/* --- standard page ------------------------------------------------------- */

.std-head { background: var(--soft); padding: 2.5rem 0 3rem; }
.breadcrumb-nav { font-size: .82rem; color: var(--muted); margin-bottom: 1.1rem; }
.breadcrumb-nav a { color: var(--muted); }
.breadcrumb-nav a:hover { color: var(--bs-primary); }
.breadcrumb-nav span { padding: 0 .45rem; opacity: .55; }

.std-title { font-size: clamp(2rem, 5vw, 3.1rem); margin-bottom: .35rem; font-variant-numeric: tabular-nums; }
.std-sub { color: var(--bs-primary); font-weight: 600; font-size: 1.05rem; margin-bottom: 1rem; }
.std-summary { color: var(--muted); max-width: 60ch; margin: 0; }

/* spec sheet — Nova-style card, not a bare rail */
.spec { position: sticky; top: 1.5rem; }
.spec .card-soft { padding: 1.4rem; }
.spec dl { margin: 0; }
.spec .r { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0;
  border-bottom: 1px solid var(--bs-border-color); font-size: .875rem; }
.spec .r:last-of-type { border-bottom: 0; }
.spec dt { color: var(--muted); margin: 0; }
.spec dd { margin: 0; font-weight: 600; color: var(--bs-heading-color); text-align: right; }
.spec .btn { width: 100%; margin-top: 1rem; }
.spec .advisor { margin-top: 1.1rem; padding-top: 1rem; border-top: 1px solid var(--bs-border-color); font-size: .85rem; }
.spec .advisor a { display: block; font-weight: 600; color: var(--bs-heading-color); }
.spec .advisor a:hover { color: var(--bs-primary); }
.spec .advisor p { color: var(--muted); font-size: .8rem; margin: .5rem 0 0; }

/* --- long-form article --------------------------------------------------- */
/* Nova has no article pattern; this keeps its type but sets a reading measure. */

.prose { max-width: 68ch; }
.prose h2 { font-size: 1.4rem; margin: 2.2rem 0 .8rem; }
.prose h3 { font-size: 1.08rem; margin: 1.8rem 0 .6rem; }
.prose > *:first-child { margin-top: 0; }
.prose p { margin-bottom: 1.1rem; }
.prose ul, .prose ol { padding-left: 1.25rem; margin-bottom: 1.2rem; }
.prose li { margin-bottom: .45rem; }
.prose a { color: var(--bs-primary); text-decoration: underline; }

/* --- process ------------------------------------------------------------- */

.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li {
  counter-increment: step; position: relative; padding-left: 3.25rem; margin-bottom: 1.35rem;
}
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--bs-primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: .82rem; font-weight: 700;
}

/* --- documents ----------------------------------------------------------- */

.doclist { list-style: none; padding: 0; margin: 0; }
.doclist li { padding: 1rem 0; border-bottom: 1px solid var(--bs-border-color); }
.doclist li:last-child { border-bottom: 0; }
.doclist strong { display: block; color: var(--bs-heading-color); margin-bottom: .2rem; }
.doclist p { margin: 0; font-size: .9rem; color: var(--muted); }

/* --- stats --------------------------------------------------------------- */

.stat { text-align: center; }
.stat .v { font-size: 2rem; font-weight: 700; color: var(--bs-primary); font-variant-numeric: tabular-nums; }
.stat .l { font-size: .85rem; color: var(--muted); }

/* --- accordion (Nova FAQ) ------------------------------------------------ */

.custom-accordion .accordion-item {
  border: 1px solid var(--bs-border-color); border-radius: var(--radius) !important;
  margin-bottom: .6rem; overflow: hidden;
}
.custom-accordion .accordion-button {
  font-weight: 600; color: var(--bs-heading-color); background: #fff; box-shadow: none;
}
.custom-accordion .accordion-button:not(.collapsed) {
  background: rgba(var(--bs-secondary-rgb), .25); color: var(--bs-primary);
}
.custom-accordion .accordion-button:focus { box-shadow: none; border-color: var(--bs-primary); }

/* --- CTA ----------------------------------------------------------------- */

.cta-panel {
  background: var(--bs-primary); color: rgba(255,255,255,.85);
  border-radius: var(--radius-lg); padding: 3rem;
}
.cta-panel h2 { color: #fff; }
.cta-panel p { max-width: 52ch; }
@media (max-width: 767.98px) { .cta-panel { padding: 1.75rem; } }

/* --- navbar -------------------------------------------------------------- */

.navbar { background: #fff; border-bottom: 1px solid var(--bs-border-color); padding: .85rem 0; }
.navbar-brand { font-weight: 800; color: var(--bs-heading-color); letter-spacing: -.03em; font-size: 1.15rem; }
.navbar-brand small { display: block; font-size: .68rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.navbar .nav-link {
  font-size: .92rem; font-weight: 500; color: var(--bs-heading-color);
  padding: .5rem .9rem !important; position: relative;
}
.navbar .nav-link:hover, .navbar .nav-link.active { color: var(--bs-primary); }
.navbar .nav-link.active::before {
  content: ""; position: absolute; left: .9rem; right: .9rem; bottom: .15rem;
  height: 2px; background: var(--bs-primary);
}
.topbar { background: var(--bs-primary); color: rgba(255,255,255,.85); font-size: .8rem; padding: .45rem 0; }
.topbar a { color: rgba(255,255,255,.9); }
.topbar a:hover { color: #fff; }

/* --- footer -------------------------------------------------------------- */

.footer { background: #16181B; color: #9AA3AD; padding: 3.5rem 0 1.75rem; font-size: .9rem; }
.footer h2 { color: #fff; font-size: .85rem; font-weight: 700; margin-bottom: 1rem; }
.footer a { color: #9AA3AD; }
.footer a:hover { color: var(--bs-secondary); }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin-bottom: .45rem; }
.footer-base {
  margin-top: 2.5rem; padding-top: 1.25rem; border-top: 1px solid rgba(255,255,255,.1);
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: .8rem; color: #6B7280;
}

/* --- whatsapp ------------------------------------------------------------ */

.whatsapp-fab {
  position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 1040;
  display: inline-flex; align-items: center; gap: .5rem;
  background: #1f9d55; color: #fff; padding: .75rem 1.1rem;
  border-radius: 50px; font-weight: 600; font-size: .875rem;
  box-shadow: 0 6px 20px rgba(31,157,85,.32);
}
.whatsapp-fab:hover { background: #178347; color: #fff; }

/* --- responsive ---------------------------------------------------------- */

@media (max-width: 991.98px) {
  .spec { position: static; margin-bottom: 2rem; }
  .hero-card { position: static; width: auto; margin-top: 1rem; }
}
@media (max-width: 575.98px) {
  .std-row { grid-template-columns: 1fr; gap: .25rem; }
  .std-go { display: none; }
  .hero { padding: 40px 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important; transition-duration: .001ms !important;
  }
}

/* --- service cards (Nova's services grid) -------------------------------- */

.service-card {
  display: flex; flex-direction: column; height: 100%;
  background: #fff; border: 1px solid var(--bs-border-color);
  border-radius: var(--radius-lg); padding: 1.75rem;
  color: inherit;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.service-card:hover {
  border-color: var(--bs-primary); box-shadow: var(--shadow); transform: translateY(-2px);
}
.service-card h3 { font-size: 1.05rem; margin-bottom: .5rem; }
.service-card p { color: var(--muted); font-size: .9rem; margin-bottom: 1.25rem; }
.service-card-foot {
  margin-top: auto; padding-top: .9rem; border-top: 1px solid var(--bs-border-color);
  display: flex; justify-content: space-between; align-items: center; font-size: .85rem;
}
.service-card-foot .count { color: var(--muted); }
.service-card-foot .more { color: var(--bs-primary); font-weight: 600; }
.service-card:hover .more { text-decoration: underline; }

/* group anchors sit under the sticky navbar */
.catalogue-group { scroll-margin-top: 90px; }

/* --- certification catalogue --------------------------------------------- */
/* 76 standards is past the point of scrolling, so the page offers both ways
   in: jump to a sector, or filter by the code a tender named. The code is the
   thing people search for, so it anchors each card; the sector headers carry
   the weight and the cards stay quiet. */

.cat-bar {
  position: sticky; top: var(--stick-top, 62px); z-index: 10;
  background: rgba(255, 255, 255, .94);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--bs-border-color);
  transition: box-shadow .18s ease;
}
.cat-bar.is-stuck { box-shadow: 0 6px 20px rgba(22, 24, 27, .07); }
.cat-bar-inner {
  display: flex; align-items: center; gap: 1.5rem;
  padding-top: .6rem; padding-bottom: .6rem;
}

.cat-jump {
  display: flex; gap: .3rem; flex: 1 1 auto; flex-wrap: wrap;
}
.cat-jump a {
  display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap;
  padding: .4rem .7rem; border-radius: var(--radius);
  font-size: .82rem; font-weight: 600; color: var(--muted);
  transition: background-color .15s ease, color .15s ease;
}
.cat-jump a:hover { background: var(--soft); color: var(--bs-primary); }
.cat-jump .n {
  font-size: .72rem; font-weight: 600; color: var(--bs-primary);
  background: rgba(var(--bs-secondary-rgb), .45);
  padding: 1px 6px; border-radius: 20px; font-variant-numeric: tabular-nums;
}

.cat-find { position: relative; flex: 0 0 258px; }
.cat-find svg {
  position: absolute; left: .7rem; top: 50%; transform: translateY(-50%);
  width: 14px; height: 14px; fill: var(--muted); pointer-events: none;
}
.cat-find input {
  width: 100%; padding: .5rem .7rem .5rem 2rem;
  border: 1px solid var(--bs-border-color); border-radius: var(--radius);
  font-size: .85rem; background: #fff; color: var(--bs-body-color);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.cat-find input::placeholder { color: var(--muted); }
.cat-find input:focus {
  outline: none; border-color: var(--bs-primary);
  box-shadow: 0 0 0 3px rgba(var(--bs-secondary-rgb), .5);
}
.cat-find input::-webkit-search-cancel-button { cursor: pointer; }

/* -- sector ---------------------------------------------------------------- */

.sector { scroll-margin-top: calc(var(--stick-top, 62px) + 72px); }
.sector + .sector { margin-top: 3.25rem; }
.sector[hidden] { display: none; }

.sector-head {
  display: flex; align-items: flex-start; gap: 1rem;
  padding-bottom: 1.05rem; margin-bottom: 1.3rem;
  border-bottom: 1px solid var(--bs-border-color);
}
.sector-head .icon-circle { margin-bottom: 0; }
.sector-head-text { flex: 1 1 auto; min-width: 0; }
.sector-head h2 { font-size: 1.22rem; margin: 0 0 .3rem; letter-spacing: -.01em; }
.sector-head p {
  margin: 0; color: var(--muted); font-size: .88rem;
  line-height: 1.5; max-width: 62ch;
}
.sector-count {
  flex: none; color: var(--muted); font-size: .82rem;
  padding-top: .25rem; font-variant-numeric: tabular-nums;
}
.sector-count strong { color: var(--bs-heading-color); font-weight: 700; }

/* -- the cards ------------------------------------------------------------- */

.std-grid {
  display: grid; gap: .7rem;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.std-card {
  display: flex; flex-direction: column; gap: .28rem;
  padding: 1rem 1.1rem;
  background: #fff;
  border: 1px solid var(--bs-border-color);
  border-radius: var(--radius-md);
  color: inherit; height: 100%;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.std-card:hover {
  border-color: var(--bs-primary);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.std-card[hidden] { display: none; }
.std-card-code {
  font-weight: 700; font-size: .98rem; line-height: 1.25;
  color: var(--bs-heading-color);
  font-variant-numeric: tabular-nums; letter-spacing: -.01em;
  transition: color .15s ease;
}
.std-card:hover .std-card-code { color: var(--bs-primary); }
.std-card-name {
  color: var(--muted); font-size: .83rem; line-height: 1.45;
}

.cat-empty {
  color: var(--muted); text-align: center; padding: 3.5rem 0; margin: 0;
}
.cat-empty strong { color: var(--bs-heading-color); font-variant-numeric: tabular-nums; }

@media (max-width: 991.98px) {
  .cat-bar-inner { flex-direction: column; align-items: stretch; gap: .55rem; }
  .cat-find { flex: 1 1 auto; }
  .cat-jump {
    order: 2; flex-wrap: nowrap; overflow-x: auto;
    scrollbar-width: none; -ms-overflow-style: none;
    -webkit-mask-image: linear-gradient(to right, #000 88%, transparent);
            mask-image: linear-gradient(to right, #000 88%, transparent);
  }
  .cat-jump::-webkit-scrollbar { display: none; }
  .sector { scroll-margin-top: calc(var(--stick-top, 62px) + 116px); }
}
@media (max-width: 575.98px) {
  .std-grid { grid-template-columns: 1fr; }
  .sector-head { flex-wrap: wrap; gap: .75rem; }
  .sector-count { padding-top: 0; }
}
