/* Shared styles of all pages. home.css adds the home page sections. */

@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url("/fonts/plus-jakarta-sans-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;
}

@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url("/fonts/plus-jakarta-sans-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;
}

:root {
  --color-bg: #f0f0f0;
  --color-surface: #ffffff;
  --color-surface-muted: #fafbf9;
  --color-surface-note: #f4f6f3;
  --color-ink: #1d2420;
  --color-text: #3f4943;
  --color-muted: #6b756f;
  --color-muted-strong: #5b655f;
  --color-subtle: #4d5751;
  --color-accent: #059669;
  --color-accent-strong: #047857;
  --color-accent-deep: #065f46;
  --color-accent-soft: #e7f5ef;
  --color-border: #e3e7e1;
  --color-border-input: #e1e5df;
  --color-border-soft: #eef0ec;
  --color-rule: #e3e5e1;
  --color-danger: #b42318;
  --color-danger-strong: #912018;
  --color-danger-text: #7a271a;
  --color-danger-border: #f3c9c4;
  --color-danger-soft: #fdf1ef;
  --color-hover-soft: #f1f3ef;

  --radius-input: 14px;
  --radius-icon: 18px;
  --radius-panel: 24px;
  --radius-card: 28px;
  --radius-pill: 999px;

  --shadow-card:
    0 1px 2px rgba(20, 40, 30, 0.04), 0 24px 60px -32px rgba(20, 60, 40, 0.25);
  --shadow-button: 0 8px 24px -10px rgba(5, 150, 105, 0.6);
  --focus-ring: 0 0 0 4px rgba(5, 150, 105, 0.12);
  --focus-ring-danger: 0 0 0 4px rgba(180, 35, 24, 0.1);

  --page-width: 1180px;
  --font-family: "Plus Jakarta Sans", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-family);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--color-accent-strong);
  text-decoration: none;
  font-weight: 600;
}

a:hover {
  color: var(--color-accent-deep);
}

img,
svg {
  display: block;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Page frame */

.page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* The fixed height matches the logo, so the logo stays in place on every
   page, however tall the buttons beside it are. */
.site-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
  height: 72px;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 18px 28px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-ink);
  font-weight: 800;
  font-size: 22px;
  letter-spacing: -0.02em;
}

.brand:hover {
  color: var(--color-ink);
}

.brand img {
  width: 36px;
  height: 36px;
}

.head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 20px;
}

.head-tools {
  display: flex;
  align-items: center;
  gap: 20px;
}

.open-app {
  display: inline-flex;
  align-items: center;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  color: #fff;
  font-size: 15px;
}

.open-app:hover {
  background: var(--color-accent-strong);
  color: #fff;
}

.signout-form {
  margin: 0;
}

.signout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-ink);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.signout:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-strong);
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.lang-switch > * {
  padding: 5px 11px;
  border-radius: var(--radius-pill);
}

.lang-switch > a {
  color: var(--color-subtle);
  font-weight: 700;
}

.lang-switch > a:hover {
  color: var(--color-accent-strong);
}

.lang-switch > [aria-current] {
  background: var(--color-ink);
  color: #fff;
}

.site-foot {
  border-top: 1px solid #eef0eb;
}

.site-foot-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  max-width: var(--page-width);
  margin: 0 auto;
  padding: 40px 28px;
  font-size: 14px;
}

.foot-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-ink);
  font-weight: 700;
}

.foot-brand img {
  width: 28px;
  height: 28px;
}

.foot-links {
  display: flex;
  gap: 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-foot a {
  color: var(--color-muted);
  font-weight: 500;
}

.site-foot a:hover {
  color: var(--color-accent-strong);
}

/* Cookie banner. display: flex would otherwise override the hidden
   attribute. */

.cookie-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 20px;
  padding: 12px 20px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-surface);
  font-size: 14px;
  line-height: 1.5;
  color: var(--color-text);
}

.cookie-banner[hidden] {
  display: none;
}

.cookie-banner p {
  margin: 0;
}

.cookie-banner button {
  height: 34px;
  padding: 0 18px;
  border: none;
  border-radius: var(--radius-pill);
  background: var(--color-ink);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.cookie-banner button:hover {
  background: var(--color-accent-strong);
}

/* Floating contact button in the lower right corner of every page */

.contact-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 22px;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  box-shadow: var(--shadow-button);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}

.contact-fab:hover {
  background: var(--color-accent-strong);
  color: #fff;
}

/* Centered card pages: sign-in, registration, links from mails and their
   confirmations */

.card-main {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 24px 20px 96px;
}

.card-aside {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  text-align: center;
}

.card-aside a {
  color: var(--color-subtle);
  font-weight: 500;
}

.card-aside a:hover {
  color: var(--color-accent-strong);
}

.card-aside em {
  color: var(--color-accent-strong);
  font-style: normal;
  font-weight: 600;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.card {
  width: 100%;
  max-width: 440px;
  padding: clamp(32px, 6vw, 48px);
  border-radius: var(--radius-card);
  background: var(--color-surface);
  box-shadow: var(--shadow-card);
}

.card h1 {
  margin: 0 0 12px;
  font-size: 34px;
  line-height: 1.1;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.card .card-title-small {
  font-size: 30px;
  line-height: 1.15;
}

.card-lead {
  margin: 0 0 32px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-muted-strong);
  text-wrap: pretty;
}

.card-lead strong {
  color: var(--color-ink);
}

.icon-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin-bottom: 28px;
  border-radius: var(--radius-icon);
  background: var(--color-accent-soft);
  color: var(--color-accent);
}

.status-chip {
  display: inline-flex;
  margin-top: 0;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: var(--color-accent-soft);
  color: var(--color-accent-deep);
  font-size: 13px;
  font-weight: 600;
}

.notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: -12px 0 28px;
  padding: 14px 16px;
  border-radius: var(--radius-input);
  background: var(--color-surface-note);
  font-size: 14px;
  line-height: 1.55;
  color: var(--color-text);
  text-wrap: pretty;
}

.notice svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--color-accent);
}

.notice-standalone {
  margin-top: 0;
}

.notice-danger {
  margin-top: 0;
  background: var(--color-danger-soft);
  color: var(--color-danger-text);
}

.notice-danger svg {
  color: var(--color-danger);
}

.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.card-actions > a {
  padding: 14px 10px;
  font-size: 15px;
}

.card-actions > .pill-link {
  padding: 14px 26px;
}

.pill-link {
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  color: #fff;
}

.pill-link:hover {
  background: var(--color-accent-strong);
  color: #fff;
}

/* Forms */

.form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin: 0;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field-label {
  font-size: 14px;
  font-weight: 600;
}

.input {
  width: 100%;
  height: 52px;
  padding: 0 18px;
  border: 1.5px solid var(--color-border-input);
  border-radius: var(--radius-input);
  background: var(--color-surface-muted);
  color: var(--color-ink);
  font: inherit;
  font-size: 16px;
  outline: none;
}

.input:focus {
  border-color: var(--color-accent);
  background: var(--color-surface);
  box-shadow: var(--focus-ring);
}

.form-danger .input:focus {
  border-color: var(--color-danger);
  box-shadow: var(--focus-ring-danger);
}

.textarea {
  height: auto;
  min-height: 140px;
  padding: 14px 18px;
  resize: vertical;
}

.field-error {
  margin: -8px 0 0;
  font-size: 14px;
  color: var(--color-danger);
}

.password-input {
  position: relative;
}

.password-input .input {
  padding-right: 80px;
}

.password-toggle {
  position: absolute;
  top: 8px;
  right: 8px;
  height: 36px;
  padding: 0 12px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: var(--color-subtle);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.password-toggle:hover {
  background: var(--color-hover-soft);
}

.password-toggle[hidden] {
  display: none;
}

.password-rules {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: -6px 0 0;
  padding: 0;
  list-style: none;
}

.password-rule {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--color-muted);
  transition: color 0.2s;
}

.password-rule-dot {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: 1.5px solid #cfd6cd;
  border-radius: var(--radius-pill);
  background: #fff;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  transition: all 0.2s;
}

.password-rule.is-ok {
  color: var(--color-accent-deep);
}

.password-rule.is-ok .password-rule-dot {
  border-color: var(--color-accent);
  background: var(--color-accent);
}

.password-rule.is-ok .password-rule-dot::after {
  content: "✓";
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--color-subtle);
  cursor: pointer;
}

.consent input {
  flex: none;
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  accent-color: var(--color-accent);
  cursor: pointer;
}

.consent input:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.consent + .field-error {
  margin: 8px 0 0;
  padding-left: 32px;
}

.button {
  height: 52px;
  border: none;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  box-shadow: var(--shadow-button);
  color: #fff;
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.button:hover {
  background: var(--color-accent-strong);
}

.button-danger {
  background: var(--color-danger);
  box-shadow: none;
}

.button-danger:hover {
  background: var(--color-danger-strong);
}

/* Account pages */

.account-main {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 72px 20px 120px;
}

.page-intro {
  margin-bottom: 28px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--color-accent);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.page-title {
  margin: 0;
  font-size: clamp(34px, 5vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.panel {
  padding: 8px 28px;
  border-radius: var(--radius-panel);
  background: var(--color-surface);
}

.account-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 0;
  border-bottom: 1px solid var(--color-border-soft);
}

.account-row:last-child {
  border-bottom: none;
}

.account-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  margin: 0;
}

.account-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-muted);
}

.account-value {
  font-size: 17px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.account-value-secret {
  letter-spacing: 0.12em;
}

.outline-button {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 18px;
  border: 1px solid var(--color-border-input);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-ink);
  font-size: 14px;
  font-weight: 600;
}

.outline-button:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-strong);
}

.outline-button-danger {
  border-color: var(--color-danger-border);
  color: var(--color-danger);
}

.outline-button-danger:hover {
  border-color: var(--color-danger-border);
  background: var(--color-danger-soft);
  color: var(--color-danger);
}

.panel-danger {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 28px;
  padding: 28px;
}

.panel-danger-text {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 420px;
  margin: 0;
}

.panel-danger-title {
  font-size: 17px;
  font-weight: 700;
}

.panel-danger-body {
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-muted);
  text-wrap: pretty;
}

.account-notice {
  margin: 0;
}

/* Static text pages: contact, imprint, privacy policy */

.text-main {
  flex: 1;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  padding: 32px 28px 120px;
}

.text-main h1 {
  margin: 0 0 40px;
  font-size: clamp(34px, 5vw, 48px);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.text-body {
  font-size: 17px;
  line-height: 1.7;
  color: var(--color-text);
}

.placeholder {
  padding: 8px 16px;
  border-left: 4px solid #c58b00;
  background: #fff6dc;
}

.text-body p {
  margin: 0 0 16px;
}

.text-body > .panel {
  margin-top: 28px;
}

.text-section {
  margin-top: 48px;
}

.text-section h2 {
  margin: 0 0 16px;
  color: var(--color-ink);
  font-size: 22px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  font-weight: 800;
  text-wrap: balance;
}

.text-subsection {
  margin-top: 32px;
}

.text-subsection h3 {
  margin: 0 0 16px;
  color: var(--color-ink);
  font-size: 19px;
  line-height: 1.3;
  font-weight: 800;
  text-wrap: balance;
}

.text-subsection h4 {
  margin: 24px 0 8px;
  color: var(--color-ink);
  font-size: 17px;
  line-height: 1.4;
  font-weight: 700;
}

.text-body ul {
  margin: 0 0 16px;
  padding-left: 24px;
}

/* Label and value rows in a panel, like the account page */

.fact-list {
  margin: 0;
}

.fact-row {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 4px 24px;
  padding: 20px 0;
  border-bottom: 1px solid var(--color-border-soft);
}

.fact-row:last-child {
  border-bottom: none;
}

.fact-row dt {
  padding-top: 3px;
  color: var(--color-muted);
  font-size: 13px;
  font-weight: 600;
}

.fact-row dd {
  margin: 0;
  color: var(--color-ink);
  font-size: 17px;
  line-height: 1.55;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.fact-row address {
  font-style: normal;
}

/* Below 1450px the contact button shows only its icon and sits near the
   bottom edge. */

@media (max-width: 1450px) {
  .contact-fab {
    bottom: 6rem;
    width: 52px;
    height: 52px;
    padding: 0;
    justify-content: center;
  }

  .contact-fab span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
}

/* Phones */

@media (max-width: 600px) {
  .site-head {
    flex-wrap: wrap;
    gap: 4px 16px;
    height: auto;
    padding: 12px 16px;
  }

  /* Logo, Open GroLi, sign-out and language switch share one row. */
  .head-actions {
    display: contents;
  }

  .head-tools {
    gap: 8px;
  }

  /* Open GroLi shrinks and sign-out shows only its icon; both are as tall
     as the language switch. */
  .open-app {
    height: 34px;
    height: calc(1lh + 18px);
    padding: 0 12px;
    font-size: 13px;
    white-space: nowrap;
  }

  .signout {
    justify-content: center;
    width: 34px;
    height: 34px;
    width: calc(1lh + 18px);
    height: calc(1lh + 18px);
    padding: 0;
    font-size: 13px;
  }

  .signout-label,
  .brand-word {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  /* Labels sit above their values. */
  .fact-row {
    grid-template-columns: 1fr;
  }

  /* The account buttons sit on their own full-width row below the value. */
  .account-row {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .account-row > a {
    justify-content: center;
  }
}
