/* popity.ro — plain Linux terminal look: green prompt, grey text, dark background */

@font-face {
  font-family: "Roboto Mono";
  font-style: normal;
  font-weight: 100 700;
  font-display: swap;
  src: url("/assets/fonts/roboto-mono-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: "Roboto Mono";
  font-style: normal;
  font-weight: 100 700;
  font-display: swap;
  src: url("/assets/fonts/roboto-mono-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 {
  --bg: #0d0d0d;
  --text: #b0b0b0;
  --bright: #e4e4e4;
  --dim: #6b6b6b;
  --green: #5fbf5f;
  --font: "Roboto Mono", ui-monospace, "DejaVu Sans Mono", Consolas, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font: 400 15px/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
}

.term { width: 100%; max-width: 820px; margin: 0 auto; padding: 8vh 24px 0; flex: 1; }

a { color: var(--bright); text-decoration: underline; text-decoration-color: var(--dim); text-underline-offset: 3px; }
a:hover, a:focus-visible { color: var(--green); text-decoration-color: var(--green); }
:focus-visible { outline: 1px dashed var(--green); outline-offset: 2px; }
::selection { background: var(--green); color: var(--bg); }

p { margin: 0; }

/* Prompt line: seba@popity:~$ command */
.cmd { margin: 22px 0 4px; color: var(--bright); overflow-wrap: anywhere; }
.cmd:first-child { margin-top: 0; }
.ps1 { color: var(--green); font-weight: 700; margin-right: .6ch; }

.out { margin: 0; }
.out p + p { margin-top: 10px; }
.bright { color: var(--bright); }
.dim { color: var(--dim); }

/* Navigation as the first prompt */
.nav { display: flex; flex-wrap: wrap; gap: 0 2ch; margin: 4px 0 0; padding: 0; list-style: none; }
.nav a { text-decoration: none; color: var(--text); }
.nav a::after { content: "/"; color: var(--dim); }
.nav a:hover, .nav a[aria-current="page"] { color: var(--bright); }
.nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--green); }

/* Two-column listings (name  description) */
.list { display: grid; grid-template-columns: max-content 1fr; gap: 2px 3ch; margin: 0; }
.list dt { color: var(--bright); }
.list dd { margin: 0; }

.ls { display: flex; flex-wrap: wrap; gap: 0 3ch; margin: 0; padding: 0; list-style: none; }

ul.dash { margin: 0; padding: 0; list-style: none; }
ul.dash li::before { content: "- "; color: var(--dim); }
ul.dash.indent { padding-left: 2ch; }

h2 { font-size: inherit; font-weight: 700; color: var(--bright); margin: 18px 0 2px; }
h2::before { content: "# "; color: var(--dim); }

/* Contact form, styled like the mail command */
.mailform { max-width: 640px; }
.field { display: flex; align-items: baseline; gap: 1ch; border-bottom: 1px solid #2a2a2a; padding: 6px 0; }
.field:focus-within { border-bottom-color: var(--green); }
.field label { color: var(--bright); white-space: nowrap; }
.field-msg { flex-direction: column; gap: 4px; border-bottom: 0; padding-top: 14px; }
.field-msg label { color: var(--dim); }
.mailform input, .mailform textarea {
  flex: 1;
  width: 100%;
  min-width: 0;
  background: transparent;
  border: 0;
  color: var(--text);
  font: inherit;
  caret-color: var(--green);
  padding: 0;
}
.mailform textarea { border: 1px solid #2a2a2a; padding: 8px 10px; resize: vertical; min-height: 9em; }
.mailform textarea:focus { border-color: var(--green); }
.mailform input:focus, .mailform textarea:focus { outline: none; }
.mailform input::placeholder { color: #444; }
.mailform [aria-invalid="true"] { color: #e06c6c; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.small { font-size: 13px; margin-top: 12px; }
.send {
  margin-top: 14px;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-weight: 700;
  color: var(--green);
  cursor: pointer;
}
.send:hover, .send:focus-visible { color: var(--bright); }
.send:disabled { color: var(--dim); cursor: wait; }
.status { margin-top: 10px; min-height: 1.65em; }
.status.ok { color: var(--green); }
.status.err { color: #e06c6c; }

.cursor { display: inline-block; width: .6em; height: 1.15em; vertical-align: -.2em; background: var(--text); animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.footer { width: 100%; max-width: 820px; margin: 0 auto; padding: 40px 24px 24px; color: var(--dim); font-size: 13px; }
.footer a { color: var(--dim); }
.footer a:hover { color: var(--green); }

@media (max-width: 560px) {
  body { font-size: 14px; }
  .term { padding: 18px 16px 0; }
  .footer { padding: 32px 16px 18px; }
  .list { grid-template-columns: 1fr; }
  .list dd { margin-bottom: 8px; color: var(--dim); }
}

@media (prefers-reduced-motion: reduce) {
  .cursor { animation: none; }
}
