/* Atelier — design system tokens + local fonts */

@font-face {
  font-family: "Blosta";
  src: url("../fonts/Blosta-Regular.woff2") format("woff2"),
       url("../fonts/Blosta-Regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Cormorant Garamond";
  src: url("../fonts/CormorantGaramond-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Cormorant Garamond";
  src: url("../fonts/CormorantGaramond-Italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --color-plum: #2D1027;
  --color-lavender: #8D809D;
  --color-cream: #E0E0CC;
  --color-olive: #867632;
  --color-amber: #CB7A00;

  --bg: var(--color-plum);
  --bg-alt: var(--color-cream);
  --text: var(--color-cream);
  --text-on-light: var(--color-plum);
  --text-muted: var(--color-lavender);
  --accent: var(--color-amber);
  --accent-2: var(--color-olive);

  --font-logo: "Blosta", sans-serif;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Jost", system-ui, sans-serif;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 48px;
  --space-7: 64px;
  --space-8: 96px;

  --radius-sm: 2px;
  --radius-md: 4px;
  --ease: cubic-bezier(.2, .6, .2, 1);
}

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

html {
  height: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.6;
  letter-spacing: .01em;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.15;
  margin: 0;
}

a {
  color: inherit;
}

.label {
  font-family: var(--font-body);
  font-size: 1.75rem;
  line-height: 1;
  font-weight: 500;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0;
}

.logo {
  font-family: var(--font-logo);
  font-weight: 400;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: .02em;
  color: var(--text);
  line-height: 1;
}

.rule {
  display: block;
  width: 64px;
  height: 1px;
  background: var(--accent);
  border: 0;
  margin: 0;
}

.quote {
  font-weight: 400;
  font-size: 1.3rem;
  line-height: 1.4;
  max-width: 65ch;
  margin: 0;
  font-family: var(--font-body);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  font: 500 .875rem/1 var(--font-body);
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 14px 32px;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--accent);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease);
}

.btn:hover {
  background: var(--accent);
  color: var(--color-plum);
}

.btn:focus-visible {
  outline: 2px solid var(--color-cream);
  outline-offset: 3px;
}

.input {
  width: 100%;
  min-height: 48px;
  padding: 12px 0;
  font: 400 1rem/1.5 var(--font-body);
  letter-spacing: .01em;
  color: var(--text);
  background: transparent;
  border: 0;
  border-bottom: 1px solid color-mix(in srgb, var(--color-lavender) 40%, transparent);
  border-radius: 0;
  outline: none;
  transition: border-color .25s var(--ease);
}

.input::placeholder {
  color: var(--text-muted);
}

.input:focus {
  border-bottom-color: var(--accent);
}

.link-muted {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--color-lavender);
  text-underline-offset: 4px;
  transition: text-decoration-color .25s var(--ease);
}

.link-muted:hover {
  text-decoration-color: var(--accent);
}

.link-muted:focus-visible {
  outline: 2px solid var(--color-cream);
  outline-offset: 3px;
}

/* Entrance motion */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes rule-grow {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.anim-fade-up {
  opacity: 0;
  animation: fade-up .7s var(--ease) forwards;
}

.anim-fade-in {
  opacity: 0;
  animation: fade-in .8s var(--ease) forwards;
}

.anim-rule {
  transform-origin: center;
  transform: scaleX(0);
  animation: rule-grow .6s var(--ease) forwards;
}

.d1 { animation-delay: .05s; }
.d2 { animation-delay: .2s; }
.d3 { animation-delay: .35s; }
.d4 { animation-delay: .5s; }
.d5 { animation-delay: .65s; }
.d6 { animation-delay: .8s; }

@media (prefers-reduced-motion: reduce) {
  .anim-fade-up,
  .anim-fade-in,
  .anim-rule {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
