/* Same display face as the Kairu app: Fraunces at the 72pt optical size. */

@font-face {
  font-family: Fraunces;
  src: url('/fonts/Fraunces_72pt-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: Fraunces;
  src: url('/fonts/Fraunces_72pt-SemiBold.ttf') format('truetype');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: Fraunces;
  src: url('/fonts/Fraunces_72pt-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Kairu Colors.brand / brandSubtle, and the primary-button glass pools
     from components/ui/GlassSurface.tsx (GLASS.brand). */
  --brand: #4f46e5;
  --brand-subtle: #818cf8;
  --highlight: #6f7bff;
  --accent: #b57bff;
  --deep: #211765;
  --ink: #07060d;
  --fg: #f1f1f5;
  --muted: #a9a9bc;
  color-scheme: dark;
  background: var(--ink);
  color: var(--fg);
  font-family:
    ui-sans-serif,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--ink);
}

body {
  min-height: 100vh;
  min-height: 100dvh;
}

/* The primary button's liquid glass, same pool positions as GlassSurface
   (highlight top-left, violet accent on the right, deep indigo at the
   bottom), at a fraction of the button's strength so the field stays
   near black. */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(
      90% 70% at 28% 0%,
      rgb(111 123 255 / 22%) 0%,
      rgb(129 140 248 / 8%) 46%,
      transparent 70%
    ),
    radial-gradient(55% 45% at 96% 20%, rgb(181 123 255 / 16%), transparent 66%),
    radial-gradient(80% 55% at 78% 120%, rgb(79 70 229 / 34%), transparent 62%);
}

::selection {
  background: rgb(129 140 248 / 35%);
  color: white;
}

main {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 1.75rem;
  padding: 2.5rem 1.5rem;
}

h1 {
  margin: 0;
  max-width: 100%;
  font-family: Fraunces, Georgia, serif;
  font-weight: 600;
  font-size: clamp(2.75rem, 10vw, 6.25rem);
  line-height: 0.95;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

/* A compact lexicon entry: italic label, bracketed etymology, then the sense.
   Georgia supplies the italic. Fraunces ships no italic cut. */
.entry {
  width: min(34rem, 100%);
  text-align: left;
}

.entry p {
  margin: 0;
}

.pos {
  font-family: Georgia, 'Iowan Old Style', Palatino, 'Palatino Linotype', serif;
  font-style: italic;
  font-size: 1.05rem;
  line-height: 1;
  color: var(--muted);
}

.etymology {
  margin-top: 0.4rem;
  font-family: Georgia, 'Iowan Old Style', Palatino, 'Palatino Linotype', serif;
  font-style: italic;
  font-size: 1rem;
  line-height: 1.45;
  color: var(--muted);
  text-wrap: pretty;
}

.etymology em,
.literal {
  white-space: nowrap;
}

.etymology em {
  font-family: Fraunces, Georgia, serif;
  font-style: normal;
  font-weight: 400;
  color: var(--brand-subtle);
}

.gloss {
  margin-top: 0.7rem;
  font-family: Fraunces, Georgia, serif;
  font-weight: 400;
  font-size: 1.2rem;
  line-height: 1.4;
  color: var(--fg);
  text-wrap: balance;
}
