:root {
  --ink: #111111;
  --muted: #6b6b6b;
  --line: #111111;
  --paper: #ffffff;
  --tile: 17.5rem;
  --radius: 1.15rem;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 1.75rem 2rem 6.5rem;
}

.top {
  display: flex;
  justify-content: flex-start;
}

.brand {
  display: inline-block;
  text-decoration: none;
  color: inherit;
}

.brand-mark {
  display: block;
  width: 13.5rem;
  height: auto;
}

.apps {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(var(--tile), var(--tile)));
  gap: 1.25rem;
  margin-top: 3.25rem;
  flex: 1;
}

.tile {
  width: var(--tile);
  height: var(--tile);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.15rem 1.2rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.tile h2 {
  margin: 0.15rem 0 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.tile p,
.tile-kicker {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.tile-kicker {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-weight: 700;
  font-size: 0.62rem;
}

.tile:hover,
.tile:focus-visible {
  background: var(--ink);
  color: var(--paper);
  outline: none;
}

.tile:hover p,
.tile:hover .tile-kicker,
.tile:focus-visible p,
.tile:focus-visible .tile-kicker {
  color: #cfcfcf;
}

.tile-add {
  align-items: center;
  justify-content: center;
  border-style: dashed;
  gap: 0.65rem;
}

.tile-add .plus {
  font-size: 2.4rem;
  line-height: 1;
  font-weight: 400;
}

.tile-add span.label {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.panel {
  display: none;
  margin-top: 1.5rem;
  max-width: 36rem;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.panel.open { display: block; }

.panel h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
}

.panel p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.panel code {
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.82em;
  color: var(--ink);
}

footer {
  position: fixed;
  right: 1.5rem;
  bottom: 1.1rem;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.55rem;
}

footer p {
  margin: 0;
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.portrait {
  display: block;
  width: 7.25rem;
  height: auto;
}

@media (max-width: 640px) {
  body { padding: 1.25rem 1.25rem 6rem; }
  .brand-mark { width: 10.5rem; }
  .portrait { width: 5.5rem; }
  footer { right: 1rem; bottom: 0.85rem; }
  :root { --tile: min(17.5rem, calc(100vw - 2.5rem)); }
}
