* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  color: #111827;
  background: #fff;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

.center {
  text-align: center;
}

.small {
  font-size: 14px;
}

/* --- HERO SECTION UPDATES --- */
.hero {
  background: linear-gradient(135deg, #1E3A8A 0%, #10B981 60%, #752FA8 100%);
  color: #fff;
  padding: 80px 0 72px;
}

.hero-inner {
  display: flex;
  gap: 48px;
  align-items: center;
  justify-content: space-between;
}

.hero-copy {
  flex: 1;
  min-width: 300px;
}

.hero h1 {
  font-size: 44px;
  line-height: 1.2;
  margin: 0 0 12px;
}

.hero p {
  font-size: 18px;
  opacity: 0.95;
  max-width: 660px;
}

/* --- FIX: FORCE 520px WIDTH --- */
.hero-visual {
  /* Stop flex from growing/shrinking. Lock to 520px. */
  flex: 0 0 520px !important;
  width: 520px !important;
  
  /* Ensure it fits on smaller screens */
  max-width: 100%; 
  
  display: flex;
  justify-content: flex-end;
  position: relative;
}

/* Force image to fit the container and ignore HTML width attributes */
.hero-visual img {
  width: 100% !important;
  max-width: 520px !important; 
  height: auto !important;
  
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* --- BUTTONS --- */
.btn {
  display: inline-block;
  padding: 12px 20px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  cursor: pointer;
}

.btn-primary {
  background: #10B981;
  color: #fff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .2);
  border: 0;
}

.btn-primary:hover {
  background: #0ea472;
}

.hero .btn-primary {
  padding: 14px 24px;
  font-size: 18px;
}

.btn-primary:hover {
  background: #0ea472;
  box-shadow: 0 10px 28px rgba(16, 185, 129, .35);
}

/* --- SECTIONS --- */
.problem-solution {
  padding: 72px 0;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.bullets {
  list-style: none;
  padding: 0;
  margin: 16px 0 12px;
}

.bullets li {
  margin: 8px 0;
  font-size: 18px;
  line-height: 1.55;
}

.muted {
  color: #6B7280;
}

.how-it-works {
  background: #f9fafb;
  padding: 72px 0;
}

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 24px;
}

.card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .06);
  padding: 20px;
}

.video iframe {
  margin-top: 24px;
}

.video .visual-placeholder {
  height: 340px;
  margin-top: 24px;
  border: 2px dashed #cbd5e1;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6B7280;
}

.chip {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  margin-right: 6px;
}

.low { background: #22C55E; color: #053b12; }
.med { background: #FACC15; color: #2c2200; }
.high { background: #EF4444; color: #fff; }

.showcase {
  padding: 48px 0 24px;
}

.screenshot img {
  display: block;
  width: 100%;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .1);
}

.trust {
  background: #0f172a;
  color: #fff;
  padding: 48px 0;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 24px;
}

.card.inv {
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .12);
}

.cta {
  background: linear-gradient(135deg, #1E3A8A 0%, #10B981 60%, #752FA8 100%);
  color: #fff;
  padding: 72px 0;
}

.form {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .08);
  padding: 24px;
  margin-top: 24px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}

.field label {
  font-weight: 600;
}

.field input,
.field textarea {
  padding: 12px 14px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font-size: 16px;
}

.field.check {
  flex-direction: row;
  align-items: center;
  gap: 10px;
}

.footer {
  background: #1E3A8A;
  color: #fff;
  padding: 24px 0;
  text-align: center;
}

.footer a {
  color: #fff;
  text-decoration: underline;
}

.success {
  min-height: 70vh;
  display: flex;
  align-items: center;
}

/* --- TYPOGRAPHY --- */
section h2 {
  font-size: 40px;
  line-height: 1.2;
  margin: 0 0 12px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.card h3 {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 6px;
}

.cta p {
  color: #ffffff;
  opacity: .98;
  font-size: 18px;
  margin: 8px 0 24px;
}

.cta p.muted {
  color: #ffffff;
  opacity: 1;
}

.form .field label {
  color: #0f172a;
  font-size: 15px;
}

.field input::placeholder,
.field textarea::placeholder {
  color: #9aa3af;
}

.field input,
.field textarea {
  border: 1.5px solid #d1d5db;
  background: #ffffff;
}

.field input:focus,
.field textarea:focus {
  outline: 0;
  border-color: #10B981;
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15);
}

.field.check label {
  color: #0f172a;
  font-weight: 600;
}

/* --- LOGO SIZING --- */
.brand-logo {
  display: block;
  margin-left: auto;
  margin-right: auto;
  width: auto;
  height: auto;
  position: relative;
  margin-top: -24px; 
}

/* --- RESPONSIVE MEDIA QUERIES (UPDATED) --- */
@media (max-width: 960px) {
  .hero-inner {
    flex-direction: column;
    align-items: center; 
  }

  .hero-visual {
    /* Reset width for mobile/tablet to be fluid */
    width: 100% !important;
    max-width: 520px; /* Optional: keep it from getting massive on tablets */
    flex: auto !important; 
    justify-content: center;
    margin-top: 2rem;
  }
  
  .hero-visual img {
    max-width: 100% !important;
  }
  
  .hero-copy {
    width: 100%;
    text-align: center;
  }
  
  .hero p {
      margin-left: auto;
      margin-right: auto;
  }

  .two-col {
    grid-template-columns: 1fr;
  }

  .steps {
    grid-template-columns: 1fr 1fr;
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }
  
  .trust .grid-3 {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  
  .showcase .container.two-col {
    display: grid;
    grid-template-columns: 1fr;
  }
  .showcase .container.two-col > div:first-child {
    order: 1;
  }
  .showcase .container.two-col .risk-panel, 
  .showcase .container.two-col .cl-risk-card {
    order: 2;
    margin-top: 20px;
    width: 100%;
  }
}

/* Small Screens */
@media (max-width: 680px) {
  .hero .btn-primary {
    width: 100%;
  }
  .btn-primary {
    width: 100%;
  }
  .trust .grid-3 {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .trust h2 {
    font-size: 28px;
    line-height: 1.2;
  }
}

@media (max-width: 600px) {
  .steps {
    grid-template-columns: 1fr;
  }
  .hero h1 {
    font-size: 34px;
  }
  .brand-logo {
    width: 30%;
    max-width: 100px;
  }
  .risk-panel {
    padding: 20px;
  }
  .risk-meta {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .risk-title {
    font-size: 20px;
    line-height: 1.3;
  }
}

@media (max-width: 430px) {
  .hero h1 { font-size: 1.6rem; }
  .hero p { font-size: 1rem; }
  .cta-button { padding: 0.875rem 1rem; }
}


/* --- COGNILENS RISK CARD (Namespaced cl-*) --- */
.cl-risk-card {
  --cl-bg: linear-gradient(135deg, #1E3A8A 0%, #10B981 60%, #752FA8 100%);
  --cl-text: #ffffff;
  --cl-badge: #ef4444;
  --cl-glass: rgba(255, 255, 255, 0.08);
  --cl-radius: 16px;
  color: var(--cl-text);
  background: var(--cl-bg);
  border-radius: var(--cl-radius);
  padding: 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .15);
  margin: 16px 0;
}

.cl-risk-card__head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px 16px;
  align-items: center;
  margin-bottom: 12px;
}

.cl-badge {
  display: inline-block;
  background: var(--cl-badge);
  color: #fff;
  font-weight: 700;
  font-size: 12px;
  line-height: 1;
  padding: 6px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

.cl-risk-card__title {
  margin: 0;
  font-size: 20px;
  line-height: 1.25;
  margin-right: 8px;
}

.cl-risk-card__body {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 8px;
}

.cl-metrics {
  margin-left: auto;
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  line-height: 1;
  opacity: 0.9;
}

.cl-metrics .cl-metric strong {
  font-weight: 800;
  margin-right: 4px;
}

.cl-metrics .cl-sep {
  opacity: 0.6;
}

/* Content blocks inside card */
.cl-brief {
  display: grid;
  gap: 6px;
}

.cl-brief p {
  margin: 0 0 12px 0;
  line-height: 1.55;
}

.cl-more {
  margin-top: 8px;
}

.cl-more>summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  padding: 6px 0;
}

.cl-more>summary::-webkit-details-marker {
  display: none;
}

.cl-detail {
  margin-top: 4px;
  display: grid;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 10px 12px;
}

.cl-risk-card details.cl-citation {
  margin-top: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 8px 10px;
}

.cl-risk-card details.cl-citation>summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.cl-risk-card details.cl-citation>summary::-webkit-details-marker {
  display: none;
}

.cl-risk-card details.cl-citation[open]>summary {
  opacity: 0.9;
}

/* Mobile adjustments for Risk Card */
@media (max-width: 768px) {
  .cl-risk-card {
    padding: 18px;
    border-radius: 14px;
  }

  .cl-risk-card__head {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .cl-risk-card__title {
    font-size: 18px;
  }

  .cl-metrics {
    margin: 2px 0 0 0;
  }

  .cl-brief {
    gap: 8px;
  }

  .cl-detail {
    padding: 10px;
  }
}

/* Large desktop adjustments */
@media (min-width: 769px) {
  .cl-risk-card {
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
  }
}

@media (min-width: 1200px) {
  .cl-risk-card {
    padding: 28px;
  }

  .cl-risk-card__title {
    font-size: 22px;
  }
}

/* --- UTILITIES & LAYOUT ADJUSTMENTS --- */
[data-case-illustrative="true"] {
  margin-top: 24px !important;
  margin-bottom: 24px !important;
  padding-top: 16px;
  padding-bottom: 8px;
}

[data-case-illustrative="true"] h2,
[data-case-illustrative="true"] h3 {
  margin-top: 0.25rem;
  margin-bottom: 0.5rem;
}

.showcase {
  padding-top: 60px;
  padding-bottom: 40px;
  margin-bottom: 0;
}

.trust {
  padding-top: 40px;
  padding-bottom: 60px;
  margin-top: 0;
}

.cl-risk-card {
  margin-top: 12px;
  margin-bottom: 8px;
}

.risk-title,
.risk-meta,
.risk-body,
.risk-mitigation {
  display: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
}

.container, .risk-panel {
  box-sizing: border-box;
}