:root {
  --ink: #18212f;
  --ink-soft: #526071;
  --paper: #f3f5f8;
  --surface: rgba(255, 255, 255, 0.92);
  --line: #dfe4eb;
  --blue: #2563eb;
  --blue-dark: #1749b2;
  --teal: #0f8d76;
  --shadow: 0 18px 50px rgba(29, 44, 68, 0.1);
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--paper); }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 8%, rgba(37, 99, 235, 0.08), transparent 28rem),
    radial-gradient(circle at 91% 18%, rgba(15, 141, 118, 0.07), transparent 24rem),
    var(--paper);
  font-family: 'DM Sans', system-ui, sans-serif;
}

button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }

.ambient { position: fixed; border-radius: 999px; filter: blur(80px); opacity: .22; pointer-events: none; z-index: -1; }
.ambient-one { width: 320px; height: 320px; background: #5d83ff; top: 8%; left: -180px; }
.ambient-two { width: 260px; height: 260px; background: #68d7bf; top: 30%; right: -150px; }

.topbar {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(22px, 5vw, 72px);
  border-bottom: 1px solid rgba(150, 161, 177, .25);
  background: rgba(247, 249, 252, .78);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.brand { display: flex; align-items: center; gap: 12px; }
.brand-mark {
  width: 39px;
  height: 39px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: white;
  font: 800 19px/1 'Manrope', sans-serif;
  background: linear-gradient(145deg, #3878f4, #1749b2);
  box-shadow: 0 7px 18px rgba(37, 99, 235, .22);
}
.brand > span:last-child { display: flex; flex-direction: column; }
.brand strong { font: 800 14px/1.1 'Manrope', sans-serif; letter-spacing: .16em; }
.brand small { color: var(--ink-soft); margin-top: 3px; font-size: 11px; }
.brand.compact small { display: none; }

.topbar-meta { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-soft); }
.live-dot, .available i, .status-pill i { width: 7px; height: 7px; background: #18a77e; border-radius: 99px; box-shadow: 0 0 0 4px rgba(24, 167, 126, .1); }

.shell { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 68px 0 48px; }
.hero { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 44px; padding-bottom: 58px; }
.eyebrow { color: var(--blue); font-size: 10px; line-height: 1; font-weight: 700; letter-spacing: .18em; }
.hero h1 { margin: 14px 0 16px; font: 800 clamp(42px, 6vw, 74px)/.98 'Manrope', sans-serif; letter-spacing: -.052em; }
.hero h1 em { color: var(--blue); font-style: normal; }
.hero p { max-width: 610px; margin: 0; color: var(--ink-soft); font-size: 17px; line-height: 1.65; }

.summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  min-width: 390px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 14px 35px rgba(24, 33, 47, .06);
}
.summary div { display: flex; flex-direction: column; padding: 4px 18px; border-right: 1px solid var(--line); }
.summary div:last-child { border-right: 0; }
.summary strong { font: 800 25px/1 'Manrope', sans-serif; }
.summary span { margin-top: 7px; color: var(--ink-soft); font-size: 11px; }

.toolbar { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 42px; }
.search-box { min-width: 300px; height: 46px; display: flex; align-items: center; gap: 10px; padding: 0 15px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.8); }
.search-box:focus-within { border-color: #8aacf3; box-shadow: 0 0 0 4px rgba(37,99,235,.08); }
.search-box svg { width: 18px; fill: none; stroke: #7e8b9c; stroke-width: 1.8; stroke-linecap: round; }
.search-box input { width: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); }
.search-box input::placeholder { color: #95a0ae; }
.filters { display: flex; align-items: center; gap: 6px; padding: 5px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.8); }
.filter { border: 0; padding: 9px 14px; color: var(--ink-soft); background: transparent; border-radius: 9px; cursor: pointer; font-size: 12px; font-weight: 600; }
.filter:hover { color: var(--ink); }
.filter.active { color: white; background: var(--ink); box-shadow: 0 5px 14px rgba(24,33,47,.15); }

.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 18px; }
.section-heading h2 { margin: 8px 0 0; font: 800 28px/1 'Manrope', sans-serif; letter-spacing: -.03em; }
.result-count { color: var(--ink-soft); font-size: 12px; }
.clients-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.client-card { min-width: 0; }
.client-card > a { min-height: 255px; height: 100%; display: flex; flex-direction: column; overflow: hidden; position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 8px 25px rgba(24,33,47,.045); transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; }
.client-card > a:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #c9d3e1; }
.card-topline { height: 3px; background: var(--client-color); opacity: .9; }
.card-head { display: flex; justify-content: space-between; align-items: center; padding: 21px 22px 10px; }
.client-monogram { width: 45px; height: 45px; display: grid; place-items: center; border-radius: 14px; color: white; background: var(--client-color); font: 700 14px/1 'Manrope', sans-serif; box-shadow: 0 8px 20px color-mix(in srgb, var(--client-color), transparent 72%); }
.client-monogram.large { width: 62px; height: 62px; border-radius: 18px; font-size: 18px; flex: 0 0 auto; }
.arrow-button { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 10px; color: #7d8998; transition: all .2s ease; }
.client-card a:hover .arrow-button { color: white; background: var(--ink); border-color: var(--ink); transform: translateX(2px); }
.arrow-button svg { width: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.card-body { padding: 4px 22px 20px; flex: 1; }
.segment { color: var(--blue); text-transform: uppercase; font-size: 9px; font-weight: 700; letter-spacing: .13em; }
.card-body h3 { margin: 8px 0 9px; font: 700 19px/1.2 'Manrope', sans-serif; letter-spacing: -.02em; }
.card-body p { margin: 0; color: var(--ink-soft); font-size: 12px; line-height: 1.55; }
.card-footer { display: flex; justify-content: space-between; align-items: center; padding: 15px 22px; border-top: 1px solid #edf0f4; }
.type-pill, .status-pill { display: inline-flex; align-items: center; padding: 6px 9px; border-radius: 99px; font-size: 10px; font-weight: 700; }
.type-pill.completo { color: #2255bc; background: #eaf0ff; }
.type-pill.modular { color: #087260; background: #e5f6f1; }
.available { display: flex; align-items: center; gap: 7px; color: var(--ink-soft); font-size: 10px; }
.available i { width: 6px; height: 6px; box-shadow: none; }
.empty-state { padding: 70px 20px; border: 1px dashed #cbd3de; border-radius: 18px; text-align: center; color: var(--ink-soft); background: rgba(255,255,255,.45); }
.empty-state span { display: block; margin-bottom: 12px; }
.empty-state button { border: 0; color: var(--blue); background: transparent; cursor: pointer; font-weight: 700; }

footer { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 28px 0 38px; display: flex; justify-content: space-between; border-top: 1px solid var(--line); color: #7e8997; font-size: 11px; }

.client-page { background: #eef1f5; }
.client-topbar { height: 64px; }
.back-link { display: flex; align-items: center; gap: 7px; color: var(--ink-soft); font-size: 12px; font-weight: 600; }
.back-link:hover { color: var(--ink); }
.back-link svg, .open-full svg { width: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.client-shell { width: min(1440px, calc(100% - 32px)); margin: 0 auto; padding: 30px 0 40px; }
.client-header { display: flex; align-items: center; justify-content: space-between; gap: 30px; padding: 0 4px 24px; }
.client-identity { display: flex; align-items: center; gap: 17px; }
.client-badges { display: flex; gap: 7px; margin-bottom: 7px; }
.status-pill { gap: 7px; color: #14745f; background: #e4f5ef; }
.status-pill i { width: 5px; height: 5px; box-shadow: none; }
.client-identity h1 { margin: 0 0 5px; font: 800 clamp(25px, 3vw, 36px)/1.05 'Manrope', sans-serif; letter-spacing: -.04em; }
.client-identity p { margin: 0; color: var(--ink-soft); font-size: 12px; }
.open-full { display: inline-flex; align-items: center; gap: 9px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 11px; background: white; font-size: 11px; font-weight: 700; box-shadow: 0 6px 18px rgba(24,33,47,.05); }
.open-full:hover { color: var(--blue); border-color: #b8c9ea; }
.report-panel { overflow: hidden; border: 1px solid #d7dde6; border-radius: 19px; background: white; box-shadow: 0 18px 48px rgba(24,33,47,.09); }
.report-panel-head { display: flex; align-items: end; justify-content: space-between; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.report-panel-head h2 { margin: 7px 0 0; font: 700 17px/1.1 'Manrope', sans-serif; }
.account-id { padding: 6px 9px; border-radius: 8px; color: var(--ink-soft); background: #f1f3f6; font-size: 10px; }
.iframe-wrap { position: relative; min-height: calc(100vh - 230px); background: #0f1118; }
.iframe-wrap iframe { width: 100%; min-height: calc(100vh - 230px); display: block; border: 0; background: white; }
.report-loading { position: absolute; inset: 0; z-index: 2; display: grid; place-content: center; gap: 12px; justify-items: center; color: #7d8998; background: white; font-size: 12px; transition: opacity .25s, visibility .25s; }
.report-loading.done { opacity: 0; visibility: hidden; }
.spinner { width: 24px; height: 24px; border: 2px solid #dfe4eb; border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.not-found { min-height: calc(100vh - 76px); display: grid; place-content: center; justify-items: center; text-align: center; padding: 30px; }
.not-found span { color: var(--blue); font-size: 10px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
.not-found h1 { max-width: 600px; margin: 14px 0 20px; font: 800 clamp(30px, 5vw, 54px)/1.05 'Manrope', sans-serif; }
.not-found a { padding: 11px 16px; border-radius: 10px; color: white; background: var(--ink); font-size: 12px; font-weight: 700; }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; align-items: start; }
  .summary { min-width: 0; width: 100%; }
  .clients-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toolbar { align-items: stretch; flex-direction: column; }
  .search-box { min-width: 0; }
}

@media (max-width: 620px) {
  .topbar { height: 64px; padding: 0 18px; }
  .topbar-meta { display: none; }
  .shell { width: min(100% - 28px, 1180px); padding-top: 42px; }
  .hero { gap: 32px; padding-bottom: 38px; }
  .hero h1 { font-size: 42px; }
  .hero p { font-size: 14px; }
  .summary { padding: 13px 6px; }
  .summary div { padding: 4px 10px; }
  .summary strong { font-size: 21px; }
  .filters { width: 100%; overflow-x: auto; }
  .filter { flex: 1 0 auto; }
  .clients-grid { grid-template-columns: 1fr; }
  .client-card > a { min-height: 238px; }
  footer { width: calc(100% - 28px); flex-direction: column; gap: 7px; }
  .client-shell { width: calc(100% - 20px); padding-top: 20px; }
  .client-header { align-items: flex-start; flex-direction: column; }
  .open-full { width: 100%; justify-content: center; }
  .client-identity { align-items: flex-start; }
  .client-monogram.large { width: 50px; height: 50px; border-radius: 14px; }
  .client-badges { flex-wrap: wrap; }
  .report-panel-head { align-items: flex-start; gap: 10px; }
  .iframe-wrap, .iframe-wrap iframe { min-height: calc(100vh - 290px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

