/*
 * Styles for the static public pages in public/legal/ (privacy.html, terms.html, support.html,
 * delete-account.html).
 * These pages are plain HTML served outside the Next.js app, so they can't use Tailwind or next/font.
 * Tokens mirror app/globals.css :root; class rules mirror the Tailwind classes the pages used.
 * Fonts in ./fonts are copies of app/fonts/gilroy; logos are copies of assets/svgs. Keep in sync.
 */

@font-face {
  font-family: 'Gilroy';
  src: url('fonts/Gilroy-Regular.ttf') format('truetype');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'Gilroy';
  src: url('fonts/Gilroy-Medium.ttf') format('truetype');
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: 'Gilroy';
  src: url('fonts/Gilroy-SemiBold.ttf') format('truetype');
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: 'Gilroy';
  src: url('fonts/Gilroy-Bold.ttf') format('truetype');
  font-weight: 700;
  font-display: swap;
}

:root {
  --background: 0 0% 100%;
  --foreground: 0 0% 3.9%;
  --card: 0 0% 100%;
  --primary: 214.75 100% 35.88%; /* #004DB7 */
  --primary-foreground: 0 0% 100%;
  --muted: 0 0% 96.1%;
  --border: 0 0% 89.8%;
  --ring: 0 0% 3.9%;
  --radius: 0.5rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  border: 0 solid hsl(var(--border));
}

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

body {
  margin: 0;
  font-family: 'Gilroy', sans-serif;
  line-height: 1.5;
  color: hsl(var(--foreground));
  background: hsl(var(--background));
}

h1,
h2,
h3,
p,
ul,
ol,
address {
  margin: 0;
}

img,
svg {
  display: block;
}

/* Scrollbar, as in app/globals.css */
*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
*::-webkit-scrollbar-track {
  border-radius: 9999px;
  background: #f3f4f6;
}
*::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 9999px;
  background: #9ca3af padding-box;
}
*::-webkit-scrollbar-thumb:hover {
  background-color: #6b7280;
}
* {
  scrollbar-width: thin;
  scrollbar-color: #9ca3af #f3f4f6;
}

/* Shell */
.page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: hsl(var(--muted) / 0.4);
}

.site-header {
  display: flex;
  align-items: center;
  height: 4rem;
  flex-shrink: 0;
  padding: 0 1rem;
  border-bottom-width: 1px;
  background: hsl(var(--card));
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.brand-mark {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.brand-wordmark {
  height: 19.5px;
  width: auto;
  object-fit: contain;
}

main {
  flex: 1;
}

.site-footer {
  padding: 1.5rem 1rem;
  text-align: center;
  font-size: 0.875rem;
  line-height: 1.25rem;
  color: hsl(var(--primary-foreground) / 0.8);
  background: hsl(var(--primary));
}

/* Hero */
.hero {
  padding: 1.5rem 1rem;
  text-align: center;
  color: hsl(var(--primary-foreground));
  background: hsl(var(--primary));
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 48rem;
  margin: 0 auto;
}

.hero h1 {
  font-size: 1.5rem;
  line-height: 2rem;
  font-weight: 700;
}

.last-updated {
  margin-top: 0.5rem;
  font-size: 0.8125rem;
  line-height: 1.25rem;
  font-weight: 500;
  color: hsl(var(--primary-foreground) / 0.8);
}

.hero-description {
  margin-top: 0.5rem;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: hsl(var(--primary-foreground) / 0.9);
}

/* Content card */
.content {
  width: 100%;
  padding: 2rem 1rem;
}

.card {
  min-width: 0;
  padding: 1.25rem;
  border-width: 1px;
  border-radius: 0.75rem;
  background: hsl(var(--card));
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
}

article {
  font-size: 1rem;
  line-height: 1.625;
  overflow-wrap: break-word;
  color: hsl(var(--foreground) / 0.8);
}

article section {
  padding: 2rem 0;
  border-top-width: 1px;
  scroll-margin-top: 1.5rem;
}

article section:first-child {
  padding-top: 0;
  border-top-width: 0;
}

article section:last-child {
  padding-bottom: 0;
}

article section > * + * {
  margin-top: 1rem;
}

article h2 {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 1.25rem;
  line-height: 1.75rem;
  font-weight: 600;
  color: hsl(var(--foreground));
}

.section-number {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  margin-top: 0.125rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-weight: 600;
  color: hsl(var(--primary));
  background: hsl(var(--primary) / 0.1);
}

.section-title {
  min-width: 0;
}

article h3 {
  padding-top: 0.5rem;
  font-size: 1.125rem;
  line-height: 1.75rem;
  font-weight: 600;
  color: hsl(var(--foreground));
}

article ol,
article ul {
  padding-left: 1.5rem;
}

article ol {
  list-style: decimal;
}

article ul {
  list-style: disc;
}

article ul.plain {
  list-style: none;
}

article ol > li + li,
article ul.plain > li + li {
  margin-top: 0.5rem;
}

article ul:not(.plain) > li + li {
  margin-top: 0.75rem;
}

article strong {
  font-weight: 700;
  color: hsl(var(--foreground));
}

.emphasis {
  font-weight: 600;
  color: hsl(var(--foreground));
}

.contact {
  padding: 1rem;
  border-width: 1px;
  border-radius: var(--radius);
  font-style: normal;
  background: hsl(var(--muted) / 0.4);
}

.notice {
  padding: 1rem;
  border-width: 1px;
  border-left-width: 4px;
  border-left-color: hsl(var(--primary));
  border-radius: var(--radius);
  color: hsl(var(--foreground));
  background: hsl(var(--primary) / 0.05);
}

.link {
  border-radius: calc(var(--radius) - 4px);
  font-weight: 500;
  color: hsl(var(--primary));
  text-decoration: underline;
  text-underline-offset: 4px;
}

.link:hover {
  color: hsl(var(--primary) / 0.8);
}

.link:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px hsl(var(--background)),
    0 0 0 4px hsl(var(--ring));
}

/* sm */
@media (min-width: 640px) {
  .site-header {
    padding: 0 1.5rem;
  }
  .brand {
    gap: 0.5rem;
  }
  .site-footer {
    padding: 1.5rem;
  }
  .hero {
    padding: 2rem 1rem;
  }
  .hero h1 {
    font-size: 1.75rem;
    line-height: 2.25rem;
  }
  .content {
    padding: 3rem 1.5rem;
  }
  .card {
    padding: 2rem;
  }
  article h2 {
    font-size: 1.5rem;
    line-height: 2rem;
  }
}


/* lg */
@media (min-width: 1024px) {
  .site-header {
    padding: 0 2.5rem;
  }
  .content {
    padding: 3rem 2.5rem;
  }
  .card {
    padding: 2.5rem;
  }
}
