

:root {
  --bg: #0b0b0b;
  --terminal: #000;
  --border: #1a1a1a;
  --panel: #050505;
  --text: #cfcfcf;
  --muted: #666;
  --accent: #FFA8C0;        
  --link-accent: #5BCEFA;   
  --field-bg: rgba(255,255,255,0.04);
}


html.light {
  --bg: #f3eef0;
  --terminal: #fbf8f9;
  --border: #e2d7dc;
  --panel: #f1e9ec;
  --text: #2b2330;
  --muted: #9a8a92;
  --accent: #d63384;
  --link-accent: #1f7fb8;
  --field-bg: rgba(0,0,0,0.04);
}

* { margin: 0; padding: 0; box-sizing: border-box; }


[hidden] { display: none !important; }

body {
  background: var(--bg);
  font-family: 'JetBrains Mono', monospace;
  display: flex;
  justify-content: center;
  padding: 3rem 1rem;
  color: var(--text);
  transition: background 0.25s ease, color 0.25s ease;
}

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--panel); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #ffbfd4; }

.terminal {
  width: 100%;
  max-width: 820px;
  background: var(--terminal);
  border: 1px solid var(--border);
  box-shadow: 0 0 0 1px rgba(0,0,0,0.4) inset, 0 0 40px rgba(255,168,192,0.08);
  position: relative;
  overflow: hidden;
}
.terminal::after {
  content: "";
  pointer-events: none;
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(to bottom,
    rgba(255,255,255,0.015), rgba(255,255,255,0.015) 1px, transparent 1px, transparent 3px);
  mix-blend-mode: overlay;
  z-index: 3;
}


.terminal-header {
  display: flex; align-items: center;
  padding: 0.6rem 1rem;
  border-bottom: 1px solid var(--border);
  background: var(--panel);
}
.dot { width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; }
.red { background: #ff5f56; } .yellow { background: #ffbd2e; } .green { background: #27c93f; }
.title { margin-left: 10px; font-size: 0.8rem; color: var(--muted); }
.clock { color: var(--accent); opacity: 0.7; }


.termnav {
  display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem 0.7rem;
  padding: 0.55rem 1rem;
  border-bottom: 1px solid var(--border);
  background: rgba(255,255,255,0.012);
  font-size: 0.8rem;
  position: relative; z-index: 4;
}
.termnav-prompt { color: var(--muted); white-space: nowrap; }
.termnav-prompt .prompt { color: var(--accent); }
.termnav-tabs { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.tab {
  color: var(--text); text-decoration: none;
  padding: 2px 8px; border: 1px solid transparent; border-radius: 4px;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.tab:hover { border-color: var(--border); background: var(--field-bg); text-decoration: none; }
.tab.is-active { color: var(--accent); border-color: var(--accent); }
.tab .ext { font-size: 0.6rem; opacity: 0.6; }
.termnav-right { margin-left: auto; display: flex; align-items: center; gap: 0.1rem; }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border: 0; background: transparent;
  color: var(--accent); cursor: pointer; border-radius: 6px; font-size: 0.95rem;
  text-decoration: none; transition: background 0.15s ease;
}
.icon-btn:hover { background: var(--field-bg); text-decoration: none; }


.terminal-body {
  position: relative; z-index: 1;
  padding: 1.5rem; font-size: 0.85rem; line-height: 1.6;
  overflow-y: auto; max-height: 78vh;
  animation: pagein 0.3s ease both;
}
@keyframes pagein { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.prompt { color: var(--accent); }
.cmd { color: var(--text); }
.command { margin-bottom: 0.3rem; }
.output { margin-bottom: 1.4rem; }

a { color: var(--link-accent); text-decoration: none; }
a i { color: var(--accent); text-decoration: inherit; }
a:hover { text-decoration: underline; }

.pfp { width: 50px; height: 50px; border: 1px solid var(--accent); margin-bottom: 0.8rem; object-fit: cover; }

.hero { display: block; font-size: 1.5rem; font-weight: 800; color: var(--text); margin-bottom: 0.4rem; letter-spacing: -0.5px; }
html.dark .hero { color: #fff; }
.section { display: block; font-size: 1.05rem; font-weight: 600; color: var(--accent); margin-bottom: 0.4rem; }

.wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.4s ease-in-out infinite; }
@keyframes wave { 0%,60%,100% { transform: rotate(0); } 10% { transform: rotate(14deg); } 20% { transform: rotate(-8deg); } 30% { transform: rotate(14deg); } 40% { transform: rotate(-4deg); } 50% { transform: rotate(10deg); } }


.tech-grid { margin-top: 0.7rem; padding: 0.8rem; border: 1px solid var(--border); background: var(--panel); display: flex; flex-wrap: wrap; gap: 6px; }
.tech { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border: 1px solid var(--border); background: var(--field-bg); border-radius: 4px; font-size: 0.78rem; color: var(--text); transition: border-color 0.15s, transform 0.15s, background 0.15s; }
.tech:hover { border-color: var(--accent); transform: translateY(-1px); }
.tech-icon { display: block; }
.tech-name { white-space: nowrap; }


.repo-grid { margin-top: 0.8rem; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }
.repo { display: flex; flex-direction: column; min-height: 8.5rem; padding: 0.85rem; border: 1px solid var(--border); background: var(--field-bg); border-radius: 4px; color: var(--text); transition: border-color 0.15s, transform 0.15s; }
.repo:hover { border-color: var(--accent); transform: translateY(-2px); text-decoration: none; }
.repo-name { font-weight: 600; color: var(--text); margin-bottom: 0.35rem; word-break: break-word; }
html.dark .repo-name { color: #fff; }
.repo-name i { color: var(--accent); margin-right: 4px; }
.repo-desc { font-size: 0.76rem; color: var(--muted); line-height: 1.5; margin-bottom: auto; }
.repo-meta { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 0.7rem; font-size: 0.74rem; color: var(--text); opacity: 0.8; }
.repo-meta i { color: var(--accent); margin-right: 2px; }
.repo-lang { display: inline-flex; align-items: center; gap: 5px; }
.lang-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.repo-empty { margin-top: 0.6rem; color: var(--muted); font-size: 0.8rem; }


.panel { border: 1px solid var(--border); background: var(--field-bg); border-radius: 6px; padding: 1rem; }


.field-label { display: block; font-size: 0.72rem; font-weight: 600; color: var(--muted); letter-spacing: 0.08em; margin-bottom: 0.3rem; }
.field {
  width: 100%; padding: 0.6rem 0.7rem; margin-bottom: 1rem;
  font-family: inherit; font-size: 0.82rem;
  color: var(--text); background: var(--panel);
  border: 1px solid var(--border); border-radius: 5px; outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field::placeholder { color: var(--muted); }
.field:focus { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(255,168,192,0.15); }
textarea.field { min-height: 9rem; resize: vertical; }

.form-row { display: flex; align-items: center; justify-content: space-between; gap: 0.8rem; }
.form-err { color: var(--accent); font-size: 0.78rem; min-height: 1em; }

.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: inherit; font-size: 0.8rem; font-weight: 600;
  color: var(--text); background: var(--field-bg);
  border: 1px solid var(--accent); border-radius: 999px;
  padding: 0.5rem 1.1rem; cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease;
}
.btn:hover { background: rgba(255,168,192,0.16); }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: 0.6; cursor: default; }
.btn-icon, .btn-spinner { color: var(--accent); }
.btn-wide { padding: 0.7rem 2rem; }
.btn-ghost { margin-top: 0.9rem; background: none; border: 0; color: var(--link-accent); font-family: inherit; font-size: 0.78rem; cursor: pointer; }
.btn-ghost:hover { text-decoration: underline; }

.form-done { color: var(--muted); font-size: 0.85rem; text-align: center; padding: 2.5rem 0; }


.time-status { color: var(--muted); font-size: 0.82rem; margin: 0.4rem 0 1.3rem; }
.ts-time, .ts-state { color: var(--accent); font-weight: 600; }
.contact-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 0.8rem; align-items: start; }
.msg-form { min-height: 21rem; }
.contact-links { display: flex; flex-direction: column; gap: 0.6rem; }
.link-card { display: flex; align-items: center; gap: 0.7rem; padding: 0.85rem; color: var(--text); transition: border-color 0.15s ease, transform 0.15s ease; }
.link-card:hover { border-color: var(--hover, var(--accent)); transform: translateY(-2px); text-decoration: none; }
.link-name { flex: 1; font-size: 0.8rem; }
.link-ext { color: var(--muted); font-size: 0.75rem; }


.lookup { margin-top: 0.4rem; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 0.25rem 1rem; font-size: 0.82rem; }
.kv dt { color: var(--muted); font-weight: 600; }
.kv dd { color: var(--text); word-break: break-word; }
.lookup-result { display: flex; flex-direction: column; }
.lookup-media { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 1rem; }
.lookup-logo { display: inline-flex; flex-direction: column; gap: 0.4rem; padding: 0.7rem; border: 1px solid var(--border); border-radius: 6px; background: var(--panel); color: var(--muted); font-size: 0.75rem; margin-top: 1rem; transition: border-color 0.15s ease; }
.lookup-media .lookup-logo { margin-top: 0; }
.lookup-logo:hover { border-color: #5865F2; text-decoration: none; }
.lookup-logo img { max-width: 160px; max-height: 160px; border-radius: 6px; }


.invite-box { display: flex; justify-content: center; padding: 2.5rem 0; }


.qa { list-style: none; margin-top: 0.4rem; }
.qa li { position: relative; padding-left: 1.2rem; margin-bottom: 0.35rem; color: var(--text); }
.qa li::before { content: "›"; position: absolute; left: 0; color: var(--accent); }


.socials { margin-top: 0.6rem; }
.socials a { display: block; margin-bottom: 0.3rem; }


.footer { margin-top: 1.6rem; padding-top: 1rem; border-top: 1px solid var(--border); display: flex; flex-direction: column; }
.footer-name { color: var(--text); opacity: 0.55; font-size: 1.1rem; font-weight: 600; }
.footer-sub { color: var(--muted); font-size: 0.78rem; }


.spotify {
  position: fixed; left: 1.2rem; bottom: 1.2rem; width: 20rem; max-width: calc(100vw - 2.4rem);
  background: var(--terminal); border: 1px solid var(--border); border-radius: 8px;
  padding: 0.8rem; box-shadow: 0 0 30px rgba(255,168,192,0.10); z-index: 50;
  animation: pagein 0.4s ease both;
}
.spotify[hidden] { display: none; }
.spotify-head { display: flex; align-items: center; gap: 0.5rem; font-size: 0.8rem; font-weight: 600; color: var(--text); margin-bottom: 0.6rem; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: #1DB954; box-shadow: 0 0 0 0 rgba(29,185,84,0.6); animation: ping 1.4s infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(29,185,84,0.5); } 70% { box-shadow: 0 0 0 8px rgba(29,185,84,0); } 100% { box-shadow: 0 0 0 0 rgba(29,185,84,0); } }
.spotify-body { display: flex; align-items: center; gap: 0.8rem; }
.spotify-art { width: 4rem; height: 4rem; border-radius: 6px; object-fit: cover; }
.spotify-meta { display: flex; flex-direction: column; overflow: hidden; }
.spotify-song { color: var(--link-accent); font-weight: 600; font-size: 0.82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spotify-artist { color: var(--muted); font-size: 0.76rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 1100px) { .spotify { display: none; } }


@media (max-width: 640px) {
  body { padding: 1rem 0.5rem; }
  .terminal-body { padding: 1.1rem; font-size: 0.82rem; }
  .repo-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .hero { font-size: 1.25rem; }
  .termnav { font-size: 0.74rem; }
}

@media (prefers-reduced-motion: reduce) {
  .wave, .live-dot, .terminal-body { animation: none; }
  body.js-anim .terminal-body > * { opacity: 1 !important; transform: none !important; }
}


body.js-anim[data-page="home"] #terminal > .command,
body.js-anim[data-page="home"] #terminal > .output,
body.js-anim[data-page="home"] #terminal > .pfp,
body.js-anim[data-page="home"] #terminal > .footer { opacity: 0; transform: translateY(6px); }
body.js-anim[data-page="home"] .reveal { opacity: 1 !important; transform: none !important; transition: opacity 0.35s ease, transform 0.35s ease; }

