/* Bloom website — shared styles: fonts, base, navigation, buttons, footer.
   Tokens live in palette.css. Fonts are served from this site (no third-party requests);
   Fraunces and Figtree are open source (SIL Open Font License). */

/* Figtree italic latin-ext */
@font-face {
  font-family: 'Figtree';
  font-style: italic;
  font-weight: 300 900;
  font-display: swap;
  src: url('assets/fonts/figtree-italic-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Figtree italic latin */
@font-face {
  font-family: 'Figtree';
  font-style: italic;
  font-weight: 300 900;
  font-display: swap;
  src: url('assets/fonts/figtree-italic-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Figtree normal latin-ext */
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('assets/fonts/figtree-normal-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Figtree normal latin */
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('assets/fonts/figtree-normal-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Fraunces normal latin-ext */
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('assets/fonts/fraunces-normal-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Fraunces normal latin */
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('assets/fonts/fraunces-normal-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* === Base ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + 16px);
}

body {
  margin: 0;
  background: var(--warm-white);
  color: var(--text-secondary);
  font-family: var(--font-text);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, video, svg { display: block; max-width: 100%; }
img, video { height: auto; }

h1, h2, h3, p, ol, ul, figure { margin: 0; }
ol[class], ul[class] { padding: 0; list-style: none; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-variation-settings: 'SOFT' 100, 'WONK' 0;
  font-optical-sizing: auto;
  font-weight: 420;
  color: var(--text);
  text-wrap: balance;
}

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--clay-deep);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* === Navigation ====================================================== */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 251, 248, 0.86);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}

.site-nav.is-stuck { border-bottom-color: var(--hairline); }

.site-nav__inner {
  display: flex;
  align-items: center;
  gap: 32px;
  height: var(--nav-height);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
  text-decoration: none;
  color: var(--text);
}

.brand__icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

.brand__name {
  font-family: var(--font-display);
  font-variation-settings: 'SOFT' 100, 'WONK' 0;
  font-size: 23px;
  font-weight: 480;
  letter-spacing: -0.01em;
}

.site-nav__links {
  display: flex;
  gap: 28px;
}

.site-nav__links a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  padding-block: 6px;
}

.site-nav__links a:hover { color: var(--text); }

/* === Buttons and links =============================================== */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 22px;
  border-radius: 999px;
  background: var(--warm-charcoal);
  color: var(--light-on-dark);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.15s ease;
}

.button:hover { background: var(--espresso); }

.text-link {
  color: var(--clay-deep);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.text-link:hover { text-decoration-thickness: 2px; }

/* === Store badges ==================================================== */
.store-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.store-badge { display: inline-block; border-radius: 10px; }
.store-badge img { height: 52px; width: auto; }

.store-other {
  display: none;
  font-size: 15px;
  color: var(--text-secondary);
}

/* When the visitor's phone is known, show its store first and the other as a text link. */
[data-os='ios'] .store-badge[data-store='android'],
[data-os='android'] .store-badge[data-store='ios'] { display: none; }
[data-os='ios'] .store-other[data-store='android'],
[data-os='android'] .store-other[data-store='ios'] { display: inline; }

/* === Footer ========================================================== */
.site-footer {
  background: var(--espresso);
  color: var(--peach-on-dark);
  padding-block: 40px;
  font-size: 14px;
}

.site-footer__inner {
  display: flex;
  align-items: center;
  gap: 32px;
}

.site-footer .brand { margin-right: 16px; color: var(--light-on-dark); }
.site-footer .brand__icon { width: 30px; height: 30px; border-radius: 8px; }
.site-footer .brand__name { font-size: 19px; }

.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
}

.site-footer__links a {
  color: var(--peach-on-dark);
  text-decoration: none;
  padding-block: 4px;
}

.site-footer__links a:hover { text-decoration: underline; text-underline-offset: 4px; }

.site-footer__copy { margin-left: auto; color: rgba(232, 196, 160, 0.75); }

.site-footer :focus-visible { outline-color: var(--peach-on-dark); }

/* === Phone =========================================================== */
@media (max-width: 760px) {
  .site-nav__links { display: none; }
  .brand__icon { width: 32px; height: 32px; border-radius: 9px; }
  .brand__name { font-size: 21px; }

  .site-footer__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
  .site-footer .brand { margin-right: 0; }
  .site-footer__copy { margin-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
