/* =====================================================================
   myimmo.io brand — colours + the "myimmo.io" word mark as live HTML text.

   SINGLE SOURCE for www (myimmo.io), app (app.myimmo.io) and admin (admin.myimmo.io).
   Master copy: /var/www/myimmo/brand  →  copied into each repo's public/brand by bin/brand-sync.sh.
   Never edit public/brand/ inside a site: change the master and run the sync.
   Every site loads /brand/myimmo-brand.css BEFORE its own stylesheet; the site CSS
   maps its own tokens onto these (--accent: var(--mi-accent, …) etc.).
   Machine-readable copy of the same values: brand.json (keep both in step).

   Needs the Inter font, weights 500 and 800 (all three sites ship them in assets/fonts).

   HTML (header, light background):
     <a class="mi-logo" href="/" aria-label="myimmo.io">
       <img src="/assets/img/myimmo-icon.svg" alt="" width="44" height="44">
       <span class="mi-wm" aria-hidden="true"><small>my</small><b><span class="mi-i">ı<span></span></span>mmo</b><span class="mi-per">.</span><small>io</small></span>
     </a>
   Dark background: add class "mi-on-dark" to .mi-logo (or to any parent).
   Size: set font-size on .mi-logo (the website uses 25px text with a 44px icon = icon 1.76em, gap .48em).
   ===================================================================== */

:root {
  /* brand colours */
  --mi-teal-light: #3ccab6;   /* icon gradient start (top-left) */
  --mi-teal:       #22877d;   /* icon gradient middle */
  --mi-teal-deep:  #124f4a;   /* icon gradient end (bottom-right) */
  --mi-accent:     #26867c;   /* buttons, links (website/app accent) */
  --mi-accent-2:   #1d6f67;   /* hover / pressed */
  --mi-mint:       #5eead4;   /* accent on dark backgrounds */
  --mi-sun:        #f7a24e;   /* orange sun, i-dot and period */
  --mi-ink:        #121a20;   /* "immo" on light, dark backgrounds (app sidebar) */
  --mi-grey:       #5f6b73;   /* "my" / "io" on light */
  --mi-grey-dark:  rgba(255, 255, 255, .7); /* "my" / "io" on dark */

  /* shared UI colours (website, app "Modern" design, admin) */
  --mi-accent-top: #2b968b;   /* top of the primary-button gradient (→ --mi-accent-2) */
  --mi-accent-glow: rgba(29, 111, 103, .7); /* primary-button shadow */
  --mi-on-accent:  #ffffff;   /* text on accent */
  --mi-text:       #151c22;
  --mi-text-2:     #3c4852;
  --mi-muted:      #69767f;
  /* status / chart palette (softened) */
  --mi-orange:     #f0953f;
  --mi-green:      #2b9e8c;
  --mi-red:        #cf5f73;
  --mi-cyan:       #3f93a3;
  --mi-purple:     #8468c4;
  --mi-blue:       #5584c9;
  --mi-font:       Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* backgrounds + text gradient (website hero, app login, admin login) */
  --mi-hero-bg:    linear-gradient(160deg, #e6f3f0 0%, #f2f4f6 50%, #f7f0e7 100%);   /* light: website hero */
  --mi-dark-bg:    radial-gradient(700px 480px at 0% 0%, rgba(94, 234, 212, .20), transparent 70%),
                   radial-gradient(600px 460px at 100% 100%, rgba(247, 162, 78, .18), transparent 70%),
                   linear-gradient(150deg, #17323a, #121a20);                        /* dark: website demo band */
  --mi-text-grad:  linear-gradient(100deg, #26867c 10%, #34c3b1 60%, #f7a24e 120%);  /* "helder" on light */
  --mi-text-grad-dark: linear-gradient(100deg, #5eead4 0%, #3ccab6 62%, #f7a24e 150%); /* same on dark */
  --mi-grid-line:  rgba(18, 26, 32, .045);   /* the squares behind the website hero */
  --mi-grid-line-dark: rgba(255, 255, 255, .05);
  --mi-grid-size:  44px;
}

/* Gradient text, like "helder" in the website hero. Add .mi-on-dark (on it or a parent) on dark backgrounds. */
.mi-text-grad { background: var(--mi-text-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mi-on-dark .mi-text-grad, .mi-text-grad.mi-on-dark { background-image: var(--mi-text-grad-dark); }

/* The square grid behind the website hero: <div class="mi-grid-bg" aria-hidden="true"></div> as first child of a
   position:relative box (the box needs isolation:isolate or z-index for the layering). Fades out towards the edges. */
.mi-grid-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(var(--mi-grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--mi-grid-line) 1px, transparent 1px);
  background-size: var(--mi-grid-size) var(--mi-grid-size);
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 40%, #000 30%, transparent 78%);
          mask-image: radial-gradient(ellipse 75% 65% at 50% 40%, #000 30%, transparent 78%); }
.mi-on-dark .mi-grid-bg, .mi-grid-bg.mi-on-dark { --mi-grid-line: var(--mi-grid-line-dark); }

.mi-logo { display: inline-flex; align-items: center; gap: .48em; font-size: 25px; line-height: 1.6;
  font-family: Inter, system-ui, sans-serif; letter-spacing: -.03em; font-weight: 500; color: var(--mi-ink); text-decoration: none; }
.mi-logo img { width: 1.76em; height: 1.76em; border-radius: .48em; box-shadow: 0 .24em .56em -.24em rgba(18, 95, 88, .55); flex: none; }
.mi-wm { white-space: nowrap; }
.mi-wm b { font-weight: 800; color: var(--mi-ink); }
.mi-wm small { font-size: .86em; font-weight: 500; color: var(--mi-grey); letter-spacing: -.02em; }
.mi-wm .mi-per { font-weight: 800; color: var(--mi-sun); }
/* the i of "immo" is a dotless ı with an orange dot on top */
.mi-wm .mi-i { position: relative; display: inline-block; line-height: 1; }
.mi-wm .mi-i > span { position: absolute; left: 50%; top: .06em; width: .19em; height: .19em; border-radius: 50%;
  background: var(--mi-sun); transform: translateX(-50%); }

.mi-on-dark .mi-wm b, .mi-on-dark.mi-logo .mi-wm b { color: #fff; }
.mi-on-dark .mi-wm small, .mi-on-dark.mi-logo .mi-wm small { color: var(--mi-grey-dark); }
