:root {
  --bg: #0f1115;
  --card: #171a21;
  --side: #1c2028;
  --raised: #242933;
  --raised-hover: #2d333f;
  --border: #3a404c;
  --text: #e7e9ec;
  --muted: #b4bbc6;
  --focus: #7cc4ff;
  --success: #8fd8a3;
  --tip: #2d333f;
}

* {
  box-sizing: border-box;
}

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

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 100%;
  overflow-wrap: break-word;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 1.5rem;
  background:
    linear-gradient(rgba(15, 17, 21, 0.72), rgba(15, 17, 21, 0.85)),
    url("assets/bg-home.jpg") center / cover no-repeat,
    var(--bg);
  background:
    linear-gradient(rgba(15, 17, 21, 0.72), rgba(15, 17, 21, 0.85)),
    image-set(url("assets/bg-home.webp") type("image/webp"), url("assets/bg-home.jpg") type("image/jpeg")) center / cover no-repeat,
    var(--bg);
}

.panel {
  width: 100%;
  max-width: 60rem;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 1.25rem 3.75rem rgba(0, 0, 0, 0.5);
}

.intro {
  padding: 2.5rem 2.75rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.icon {
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 0 1.25rem;
  display: block;
}

.status-code {
  font-size: 0.875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 0.5rem;
}

h1 {
  font-size: 1.875rem;
  line-height: 1.25;
  margin: 0 0 1rem;
  font-weight: 600;
  max-width: 22ch;
}

p.message {
  color: var(--muted);
  font-size: 1.0625rem;
  line-height: 1.65;
  margin: 0;
  max-width: 40ch;
}

.about {
  margin: 1.25rem 0 0;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
  max-width: 40ch;
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--text);
}

.contact {
  background: var(--side);
  border-left: 1px solid var(--border);
  padding: 2.5rem 2.5rem;
}

.contact h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.contact-lead {
  color: var(--muted);
  font-size: 0.9375rem;
  line-height: 1.6;
  margin: 0 0 1.25rem;
}

address {
  font-style: normal;
}

.contact-list {
  list-style: none;
  text-align: left;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.625rem;
}

.contact-card {
  position: relative;
}

.card-main {
  display: grid;
  grid-template-columns: 1.25rem minmax(0, 1fr);
  column-gap: 0.875rem;
  align-items: start;
  min-height: 2.75rem;
  padding: 0.875rem 3.75rem 0.875rem 1rem;
  border: 1px solid var(--border);
  border-radius: 0.625rem;
  background: var(--raised);
  color: var(--text);
  text-decoration: none;
  overflow-wrap: anywhere;
}

.contact-card:hover .card-main {
  background: var(--raised-hover);
}

a.card-main:hover .value {
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.card-icon {
  grid-row: span 2;
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.125rem;
  fill: var(--muted);
}

.card-main .label {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.card-main .ext {
  width: 0.875rem;
  height: 0.875rem;
  fill: currentColor;
}

.card-main .value {
  font-size: 1rem;
  line-height: 1.45;
  font-weight: 500;
}

.card-row {
  position: relative;
}

.has-directions .card-main {
  border-radius: 0.625rem 0.625rem 0 0;
}

.call-cta {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  margin: 1.5rem 0 0;
  min-height: 3rem;
  padding: 0.875rem 1.25rem;
  border-radius: 0.625rem;
  background: var(--text);
  color: var(--bg);
  font-size: 1.0625rem;
  font-weight: 600;
  text-decoration: none;
}

.call-cta svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

@media (hover: none) and (pointer: coarse) {
  .call-cta {
    display: flex;
  }
}

.directions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0.625rem 1rem;
  border: 1px solid var(--border);
  border-top: 0;
  border-radius: 0 0 0.625rem 0.625rem;
  background: var(--raised);
  color: var(--text);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
}

.directions:hover {
  background: var(--raised-hover);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.directions svg {
  width: 1.125rem;
  height: 1.125rem;
  fill: currentColor;
}

.copy {
  position: absolute;
  top: 50%;
  right: 0.625rem;
  transform: translateY(-50%);
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  opacity: 0;
}

.copy[hidden] {
  display: none;
}

.copy:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.copy svg {
  grid-area: 1 / 1;
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.copy .i-check,
.copy.is-copied .i-copy {
  visibility: hidden;
}

.copy.is-copied .i-check {
  visibility: visible;
  fill: var(--success);
}

.contact-card:hover .copy,
.contact-card:focus-within .copy,
.copy.show-tip {
  opacity: 1;
}

.copied-tip {
  position: absolute;
  bottom: calc(100% + 0.375rem);
  right: 0;
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 0.375rem;
  background: var(--tip);
  color: var(--text);
  font-size: 0.75rem;
  line-height: 1.2;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
}

.copy.show-tip .copied-tip {
  opacity: 1;
}

@media (hover: none), (max-width: 30rem) {
  .copy {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .copy,
  .copied-tip {
    transition: opacity 0.15s ease, background-color 0.15s ease;
  }
}

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

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 0.5rem;
}

@media (max-width: 56rem) {
  .panel {
    grid-template-columns: minmax(0, 1fr);
    max-width: 32rem;
  }
  .intro {
    display: block;
    padding: 2.25rem 1.75rem 2rem;
    text-align: center;
  }
  .icon {
    margin: 0 auto 1.25rem;
  }
  h1 {
    font-size: 1.5rem;
  }
  h1,
  p.message,
  .about {
    margin-left: auto;
    margin-right: auto;
  }
  .contact {
    border-left: 0;
    border-top: 1px solid var(--border);
    padding: 2rem 1.75rem 2.25rem;
  }
}

@media (max-width: 30rem) {
  body {
    padding: 1rem;
  }
  .intro {
    padding: 2rem 1.25rem 1.75rem;
  }
  .contact {
    padding: 1.75rem 1.25rem 2rem;
  }
}

@media (forced-colors: active) {
  .panel,
  .card-main {
    border: 1px solid CanvasText;
  }
  .card-icon,
  .copy svg,
  .card-main .ext {
    fill: CanvasText;
  }
  .directions {
    border: 1px solid CanvasText;
    border-top: 0;
  }
  .copy {
    opacity: 1;
  }
}
