/* askcarry.com's landing page. One stylesheet, no script: the page's
   Content-Security-Policy (_headers) allows only same-origin styles, fonts and
   images, so nothing here may be inlined into the HTML. */

/* Gowun Batang (SIL Open Font License 1.1, fonts/OFL.txt), cut down to the
   characters these pages use by scripts/landing-assets.ts. A character added
   to a page without rerunning it falls back to the system fonts below. */
@font-face {
  font-family: "Gowun Batang";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/gowun-batang-400.woff2") format("woff2");
}

:root {
  /* Paper and ink lean toward the green the app already uses. */
  --paper: #efede3;
  --ink: #1e261c;
  --moss: #4a5c44;
  --line: #d3d2c3;

  --serif:
    "Gowun Batang", "Iowan Old Style", "Palatino Linotype", "AppleMyungjo",
    "Nanum Myeongjo", "Batang", Georgia, serif;
  --sans:
    ui-sans-serif, system-ui, -apple-system, "Apple SD Gothic Neo",
    "Noto Sans KR", "Malgun Gothic", sans-serif;

  --gutter: clamp(1.25rem, 5vw, 4.5rem);
  /* The headline's large line; the small line and the spacing follow it. */
  --display: clamp(3.25rem, 11.5vw, 9.5rem);

  color-scheme: light;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Korean breaks between words, never inside one. */
:lang(ko) {
  word-break: keep-all;
  overflow-wrap: anywhere;
}

::selection {
  background: var(--moss);
  color: var(--paper);
}

a {
  color: inherit;
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
  text-decoration-color: var(--moss);
}

a:hover {
  color: var(--moss);
}

a:focus-visible {
  outline: 2px solid var(--moss);
  outline-offset: 3px;
  border-radius: 2px;
}

p {
  margin: 0;
}

/* Top: the wordmark and the other language. */
.top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: clamp(1.25rem, 3vw, 2.25rem) var(--gutter) 0;
}

.wordmark {
  font-size: 1.625rem;
  line-height: 1;
  letter-spacing: -0.01em;
}

.language {
  font-family: var(--sans);
  font-size: 0.9375rem;
  color: var(--moss);
  text-decoration-color: transparent;
}

.language:hover {
  text-decoration-color: var(--moss);
}

/* The headline says it in its sizes: the first line small, the second large. */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(4rem, 14vh, 10rem) var(--gutter) clamp(3rem, 8vh, 6rem);
}

.headline {
  margin: 0;
  font-weight: 400;
  font-size: var(--display);
  line-height: 1;
  letter-spacing: -0.035em;
}

.headline span {
  display: block;
}

.headline .less {
  font-size: 0.4em;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--moss);
  /* Lines the small line's first letter up with the large line's stem. */
  padding-left: 0.08em;
}

.headline .more {
  margin-top: 0.06em;
}

.headline:lang(ko) {
  letter-spacing: -0.05em;
}

.headline:lang(ko) .less {
  letter-spacing: -0.035em;
}

.about {
  display: grid;
  gap: 2.5rem;
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
}

.story {
  max-width: 34em;
}

.story p + p,
.now p + p {
  margin-top: 0.9em;
}

.lead {
  font-size: 1.375rem;
  line-height: 1.5;
  letter-spacing: -0.01em;
}

.now {
  max-width: 24em;
  color: var(--moss);
}

.now a {
  color: var(--ink);
}

.now a:hover {
  color: var(--moss);
}

@media (min-width: 60rem) {
  .about {
    grid-template-columns: minmax(0, 34em) minmax(0, 22em);
    justify-content: space-between;
    align-items: end;
    gap: 4rem;
  }
}

/* The business's registered details. */
.business {
  margin: 0 var(--gutter);
  padding: 1.75rem 0 2.25rem;
  border-top: 1px solid var(--line);
  font-family: var(--sans);
  font-size: 0.875rem;
  line-height: 1.55;
}

.business h2 {
  margin: 0 0 1rem;
  font-size: inherit;
  font-weight: 600;
}

.business dl {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 0.9rem 2.5rem;
}

.business dt {
  color: var(--moss);
}

.business dd {
  margin: 0;
}

.fine {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 2rem;
  margin-top: 1.75rem;
  color: var(--moss);
}

.fine nav {
  display: flex;
  gap: 1.5rem;
}
