@layer components {
  /* --- HERO STYLES (Public & App Modes) --- */

  /* Default (Public Mode) - Dark Blue Gradient */
  .d1-property-hero {
    background: linear-gradient(135deg, #0a1b2a 0%, #163654 100%);
    color: #e6edf3;
    border: none;
    box-shadow: 0 20px 40px -10px rgba(10, 27, 42, 0.25);
  }

  /* Text adjustments for Public Dark Hero */
  .d1-property-hero .dig-text-muted {
    color: #94a3b8 !important;
  }
  .d1-property-hero .d1-hero__title {
    color: #ffffff !important;
  }
  .d1-property-hero .dig-label {
    color: #cbd5e1 !important;
  }
  .d1-property-hero .dig-value {
    color: #ffffff !important;
  }
  .d1-property-hero .dig-value.dig-text-success {
    color: #10b981 !important;
  }

  /* The Radar Card (Needs to be light on public dark hero for contrast) */
  body:not(.d1-theme-enterprise) .d1-hero__radar {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1) !important;
  }
  body:not(.d1-theme-enterprise) .d1-hero__radar .d1-hero__radar-score {
    color: #0f172a !important;
  }
  body:not(.d1-theme-enterprise) .d1-hero__radar .d1-hero__radar-label {
    color: #64748b !important;
  }
  body:not(.d1-theme-enterprise) .d1-hero__radar .d1-hero__radar-status {
    color: #0f172a !important;
  }
  body:not(.d1-theme-enterprise) .d1-hero__radar .d1-hero__radar-reasons {
    color: #64748b !important;
  }

  /* --- OVERRIDE FOR ENTERPRISE MODE (Logged In) --- */
  /* When logged in, the dashboard is already dark, so the hero becomes "Glass" */
  .d1-theme-enterprise .d1-property-hero {
    background: rgba(6, 19, 31, 0.7) !important;
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.3) !important;
  }

  .d1-theme-enterprise .d1-hero__radar {
    background: rgba(255, 255, 255, 0.03) !important; /* Subtle glass radar */
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    color: #e6edf3 !important;
  }
  .d1-theme-enterprise .d1-hero__radar .d1-hero__radar-score {
    color: #ffffff !important;
  }
  .d1-theme-enterprise .d1-hero__radar .d1-hero__radar-status {
    color: #ffffff !important;
  }
}

@layer components {
  /*
   * ==========================================
   * COMPONENT: Marketing Hero
   * ==========================================
   */

  .dig-hero-eyebrow {
    width: fit-content;
    margin: 0 auto 1rem;

    color: #536879;
    font-family: var(--dig-font-mono);
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.14em;
    text-transform: uppercase;
  }

  .dig-site-wrapper {
    overflow-x: clip;
  }

  .d1-main.dig-container > .dig-hero {
    width: 100vw;
    max-width: none;
    margin-top: calc(0px - var(--dig-spacing-md));
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
  }

  .dig-hero {
    width: 100%;
    min-height: auto;
    padding-block: clamp(4.5rem, 7vw, 6rem) clamp(2.5rem, 4vw, 3.5rem);
  }

  .dig-hero__container {
    width: min(calc(100% - 2rem), 1440px);
    margin-inline: auto;
    padding: 0;
  }

  .dig-hero-title {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto 1.5rem;

    color: #02152a;
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -0.045em;
    text-align: center;
    text-wrap: balance;
  }

  .dig-hero-title.dig-nowrap {
    max-width: none;
    white-space: nowrap;
  }

  .dig-hero-subtitle {
    width: 100%;
    max-width: 760px;
    margin: 0 auto;

    color: #536879;
    font-size: 1.15rem;
    line-height: 1.65;
    text-align: center;
    text-wrap: balance;
  }

  .dig-hero-actions {
    margin-top: 2rem;
  }

  .dig-hero-credibility {
    padding-block: 0.75rem 1.75rem;
    color: #607486;
    font-weight: 700;
    letter-spacing: 0.08em;
  }

  @media (max-width: 900px) {
    .dig-hero-title,
    .dig-hero-title.dig-nowrap {
      max-width: 760px;
      white-space: normal;
    }
  }

  @media (max-width: 680px) {
    .dig-hero {
      min-height: auto;
      padding-block: 3rem 2rem;
    }

    .dig-hero__container {
      width: min(calc(100% - 1.25rem), 1440px);
    }

    .dig-hero-title {
      font-size: clamp(2.1rem, 11vw, 3rem);
      text-wrap: initial;
    }

    .dig-hero-subtitle {
      font-size: 1rem;
    }
  }
}

