:root {
  --desktop-bg: #0b1020;
  --terminal-black: #000000;
  --titlebar: #2c2c2c;
  --tab-active: #000000;
  --tab-inactive: #2d2d2d;
  --tab-hover: #343434;
  --text: #f2f2f2;
  --muted: #bdbdbd;
  --accent: #6dd8ff;
  --success: #76e39a;
  --warning: #ffd166;
  --danger: #ff5f56;
  --shadow: 0 32px 90px rgba(0, 0, 0, 0.55), 0 6px 24px rgba(0, 0, 0, 0.35);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
}

body {
  font-family: "Segoe UI", sans-serif;
  background: url("../assets/background.png") center / cover no-repeat fixed;
  color: var(--text);
  overflow: hidden;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  text-decoration: underline;
}

button {
  font: inherit;
}

.desktop {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px 5vw;
}

.terminal-window {
  position: relative;
  z-index: 5;
  width: min(1320px, 92vw);
  height: min(900px, calc(100vh - 78px));
  min-width: min(520px, calc(100vw - 28px));
  min-height: 360px;
  display: grid;
  grid-template-rows: 46px 1fr;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  background: var(--terminal-black);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
  transition: border-radius 160ms ease, box-shadow 160ms ease;
  will-change: transform, opacity;
}

.terminal-window[hidden] {
  display: none;
}

.terminal-window.is-managed {
  position: fixed;
  z-index: 5;
}

.bucks-window {
  width: min(1180px, 94vw);
  height: min(820px, calc(100vh - 56px));
  grid-template-rows: 46px 1fr;
}

.terminal-window.is-dragging,
.terminal-window.is-resizing {
  transition: none;
  user-select: none;
}

.terminal-window.is-maximized {
  border-radius: 0;
  box-shadow: none;
}

.terminal-window.is-minimizing {
  animation: windowMinimize 240ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.terminal-window.is-closing {
  animation: windowClose 180ms ease-in forwards;
}

.terminal-window.is-restoring {
  animation: windowRestore 180ms ease-out both;
}

.titlebar {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  padding: 5px 0 0 8px;
  background: var(--titlebar);
  cursor: grab;
  user-select: none;
  touch-action: none;
}

.terminal-window.is-dragging .titlebar {
  cursor: grabbing;
}

.window-title {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
  padding: 0 14px 5px 4px;
  color: #f5f5f5;
  font-family: "Segoe UI", sans-serif;
  font-size: 13px;
}

.window-title img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}

.window-title span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tabs {
  position: relative;
  z-index: 11;
  min-width: 0;
  flex: 0 1 auto;
  display: flex;
  align-items: flex-end;
  gap: 0;
  overflow-x: auto;
  scrollbar-width: thin;
}

.mobile-tab-toggle {
  display: none;
}

.titlebar-actions {
  position: relative;
  z-index: 11;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 0;
  height: 32px;
  margin-top: 7px;
  margin-right: auto;
  padding: 0 4px 0 2px;
  color: #bdbdbd;
  font-family: "Segoe UI", sans-serif;
  font-size: 13px;
}

.titlebar-actions > button {
  position: relative;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.titlebar-actions > button + button {
  margin-left: 14px;
}

.titlebar-actions > button + button::after {
  content: "";
  position: absolute;
  left: -8px;
  top: 2px;
  bottom: 2px;
  width: 1px;
  background: rgba(255, 255, 255, 0.14);
}

.titlebar-actions > button:hover,
.titlebar-actions > button:focus-visible {
  background: rgba(255, 255, 255, 0.09);
  outline: none;
}

.new-tab::before,
.new-tab::after {
  content: "";
  position: absolute;
  background: #d0d0d0;
}

.new-tab::before {
  width: 12px;
  height: 1px;
  top: 14px;
  left: 8px;
}

.new-tab::after {
  width: 1px;
  height: 12px;
  top: 8px;
  left: 14px;
}

.tab-menu::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 9px;
  width: 8px;
  height: 8px;
  border-right: 1px solid #d0d0d0;
  border-bottom: 1px solid #d0d0d0;
  transform: rotate(45deg);
}

.tab-picker {
  position: absolute;
  top: 34px;
  left: 42px;
  z-index: 30;
  width: 310px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  background: rgba(32, 32, 32, 0.96);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(12px);
}

.tab-picker[hidden] {
  display: none;
}

.tab-picker button {
  position: relative;
  width: 100%;
  height: 34px;
  padding: 0 12px 0 42px;
  border: 0;
  border-radius: 3px;
  background: transparent;
  color: #f2f2f2;
  font-size: 13px;
  font-weight: 400;
  text-align: left;
  cursor: pointer;
}

.tab-picker button::before {
  content: "";
  position: absolute;
  left: 12px;
  top: 8px;
  width: 18px;
  height: 18px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

.tab-picker button.is-active {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.tab-picker button:hover,
.tab-picker button:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  outline: none;
}

.tab-picker button[data-tab-target="profile"]::before {
  background-image: url("../assets/profile.png");
}

.tab-picker button[data-tab-target="projects"]::before {
  background-image: url("../assets/projects.png");
}

.tab-picker button[data-tab-target="blog"]::before {
  background-image: url("../assets/blog.png");
}

.tab-picker button[data-tab-target="contact"]::before {
  background-image: url("../assets/contact.png");
}

.tab {
  position: relative;
  flex: 0 0 240px;
  width: 240px;
  height: 32px;
  margin-top: 5px;
  padding: 0 38px 0 40px;
  border: 0;
  border-radius: 8px 8px 0 0;
  background: var(--tab-inactive);
  color: var(--text);
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  text-align: left;
}

.tab + .tab {
  margin-left: 2px;
}

.tab:not(:last-child) {
  box-shadow: 1px 0 0 rgba(255, 255, 255, 0.12);
}

.tab::after {
  content: "";
  position: absolute;
  top: 10px;
  right: 14px;
  width: 12px;
  height: 12px;
  border-radius: 0;
  background:
    linear-gradient(45deg, transparent 46%, #d8d8d8 47%, #d8d8d8 53%, transparent 54%),
    linear-gradient(-45deg, transparent 46%, #d8d8d8 47%, #d8d8d8 53%, transparent 54%);
}

.tab::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 10px;
  width: 25px;
  height: 17px;
  background-position: center;
  background-repeat: no-repeat;
  background-size: 25px 17px;
}

.profile-tab::before {
  background-image: url("../assets/profile.png");
}

.projects-tab::before {
  background-image: url("../assets/projects.png");
}

.blog-tab::before {
  background-image: url("../assets/blog.png");
}

.certifications-tab::before {
  background-image: url("../assets/contact.png");
}

.tab:hover,
.tab:focus-visible {
  background: var(--tab-hover);
  outline: none;
}

.tab.is-active {
  background: var(--tab-active);
}

.tab.is-closed {
  display: none !important;
}

.window-controls {
  position: relative;
  z-index: 11;
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 34px);
  height: 32px;
  align-items: center;
  justify-items: center;
  margin-top: 2px;
  margin-right: 4px;
}

.control {
  position: relative;
  width: 34px;
  height: 32px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.control:hover {
  background: rgba(255, 255, 255, 0.09);
}

.control.close:hover {
  background: #c42b1c;
}

.minimize::before,
.maximize::before,
.close::before,
.close::after {
  content: "";
  position: absolute;
  inset: auto 11px 15px;
  height: 1px;
  background: #dcdcdc;
}

.maximize::before {
  inset: 10px 12px 11px;
  height: auto;
  border: 1px solid #dcdcdc;
  background: transparent;
}

.close::before,
.close::after {
  inset: 15px 11px auto;
  transform: rotate(45deg);
}

.close::after {
  transform: rotate(-45deg);
}

.resize-handles {
  position: absolute;
  inset: 0;
  z-index: 12;
  pointer-events: none;
}

.resize-handle {
  position: absolute;
  pointer-events: auto;
}

.resize-n,
.resize-s {
  left: 10px;
  right: 10px;
  height: 8px;
  cursor: ns-resize;
}

.resize-e,
.resize-w {
  top: 10px;
  bottom: 10px;
  width: 8px;
  cursor: ew-resize;
}

.resize-n { top: -4px; }
.resize-e { right: -4px; }
.resize-s { bottom: -4px; }
.resize-w { left: -4px; }

.resize-ne,
.resize-se,
.resize-sw,
.resize-nw {
  width: 16px;
  height: 16px;
}

.resize-ne {
  top: -4px;
  right: -4px;
  cursor: nesw-resize;
}

.resize-se {
  right: -4px;
  bottom: -4px;
  cursor: nwse-resize;
}

.resize-sw {
  bottom: -4px;
  left: -4px;
  cursor: nesw-resize;
}

.resize-nw {
  top: -4px;
  left: -4px;
  cursor: nwse-resize;
}

.terminal-window.is-maximized .resize-handles {
  display: none;
}

.desktop-program {
  position: fixed;
  left: 50%;
  top: 50%;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 6px;
  width: 74px;
  min-height: 86px;
  padding: 5px 4px 4px;
  border: 1px solid transparent;
  border-radius: 2px;
  background: transparent;
  color: #ffffff;
  font-family: "Segoe UI", sans-serif;
  font-size: 12px;
  line-height: 1.16;
  text-align: center;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.95), 0 0 4px rgba(0, 0, 0, 0.65);
  cursor: pointer;
  touch-action: none;
  user-select: none;
}

.desktop-program:hover,
.desktop-program:focus-visible,
.desktop-program.is-selected {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.12);
  outline: none;
}

.desktop-program:active {
  background: rgba(0, 120, 215, 0.22);
}

.desktop-program[hidden] {
  display: none;
}

.desktop-program-icon {
  display: block;
  width: 48px;
  height: 48px;
  object-fit: contain;
  pointer-events: none;
}

.desktop-program span {
  display: -webkit-box;
  max-width: 72px;
  min-height: 28px;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow-wrap: anywhere;
}

.power-program {
  left: calc(50% - 55px);
  top: 50%;
}

.bucks-program {
  left: calc(50% + 55px);
  top: 50%;
}

.bucks-content {
  position: relative;
  min-height: 0;
  overflow: hidden;
  padding: 18px;
  background:
    radial-gradient(circle at 16% 10%, rgba(0, 71, 27, 0.16), transparent 26%),
    radial-gradient(circle at 92% 18%, rgba(0, 119, 192, 0.13), transparent 28%),
    linear-gradient(135deg, rgba(238, 225, 198, 0.96), rgba(255, 255, 255, 0.9)),
    linear-gradient(145deg, #00471b 0%, #00471b 42%, #eee1c6 42%, #eee1c6 58%, #0077c0 58%, #0077c0 100%);
}

.bucks-hub {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(320px, 1.2fr);
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 14px;
  height: 100%;
  min-height: 100%;
  outline: none;
}

.bucks-hero,
.bucks-panel {
  border: 1px solid rgba(0, 71, 27, 0.18);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.15);
}

.bucks-hero {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 18px;
  padding: 28px;
  text-align: center;
  container-type: inline-size;
}

.bucks-hero > div {
  max-width: 100%;
  min-width: 0;
}

.bucks-news-panel {
  grid-row: span 2;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.bucks-panel {
  min-height: 0;
  padding: 16px;
}

.bucks-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  color: #00471b;
  font-family: "Segoe UI", sans-serif;
}

.bucks-panel-header h3 {
  margin: 0;
  color: #111111;
  font-size: 16px;
}

.bucks-panel-header span {
  color: #5d5d5d;
  font-size: 11px;
}

.bucks-browser-logo {
  width: 132px;
  height: 132px;
  object-fit: contain;
}

.bucks-browser-kicker {
  margin: 0 0 5px;
  color: #00471b;
  font-family: "Segoe UI", sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.bucks-hero h2 {
  margin: 0 0 18px;
  color: #111111;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(32px, 5vw, 58px);
  font-size: clamp(32px, 14cqw, 58px);
  line-height: 0.95;
  overflow-wrap: anywhere;
}

.bucks-link-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.bucks-official-link,
.bucks-secondary-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 4px;
  background: #00471b;
  color: #ffffff;
  font-family: "Segoe UI", sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.bucks-secondary-link {
  border: 1px solid rgba(0, 71, 27, 0.24);
  background: #ffffff;
  color: #00471b;
}

.bucks-official-link:hover,
.bucks-official-link:focus-visible {
  background: #0077c0;
  outline: none;
}

.bucks-secondary-link:hover,
.bucks-secondary-link:focus-visible {
  border-color: #0077c0;
  color: #0077c0;
  outline: none;
}

.bucks-feed-list {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 0;
  overflow-y: scroll;
  padding-right: 4px;
  scrollbar-gutter: stable;
  scrollbar-color: rgba(0, 71, 27, 0.42) rgba(0, 71, 27, 0.08);
}

.bucks-feed-item {
  display: block;
  padding: 12px;
  border: 1px solid rgba(0, 71, 27, 0.14);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.72);
  color: #111111;
  font-family: "Segoe UI", sans-serif;
  text-decoration: none;
}

.bucks-feed-item:hover,
.bucks-feed-item:focus-visible {
  border-color: #0077c0;
  outline: none;
}

.bucks-feed-item strong {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  line-height: 1.25;
}

.bucks-feed-item span,
.bucks-game-meta {
  color: #5d5d5d;
  font-size: 11px;
}

.bucks-games-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 12px;
}

.bucks-games-grid > div {
  display: grid;
  grid-template-rows: auto 1fr;
}

.bucks-games-grid h4 {
  margin: 0 0 8px;
  color: #00471b;
  font-family: "Segoe UI", sans-serif;
  font-size: 12px;
  text-transform: uppercase;
}

.bucks-game-card {
  min-height: 132px;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 12px;
  border: 1px solid rgba(0, 71, 27, 0.14);
  border-radius: 5px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(238, 225, 198, 0.32)),
    rgba(255, 255, 255, 0.72);
  color: #111111;
  font-family: "Segoe UI", sans-serif;
}

.bucks-game-teams {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
}

.bucks-game-team {
  min-width: 0;
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 8px 6px;
  border-radius: 5px;
  background: rgba(0, 71, 27, 0.055);
  text-align: center;
}

.bucks-game-badge {
  width: 46px;
  height: 46px;
  object-fit: contain;
}

.bucks-game-team-name {
  max-width: 100%;
  color: #111111;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.bucks-game-matchup {
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.bucks-game-score {
  color: #00471b;
  font-size: 22px;
  font-weight: 800;
}

.terminal-content {
  position: relative;
  z-index: 0;
  min-height: 0;
  overflow: auto;
  padding: 14px 18px 28px;
  background: var(--terminal-black);
  color: var(--text);
  font-family: "Cascadia Mono", Consolas, monospace;
  font-size: 14px;
  line-height: 1.3;
  outline: none;
  scroll-behavior: smooth;
}

.session {
  display: none;
  min-height: 100%;
}

.session.is-active {
  display: block;
  animation: sessionIn 160ms ease-out;
}

.line,
.command,
.output,
.list-item {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.command {
  color: var(--text);
  margin-top: 10px;
}

.max-tabs-message {
  margin-top: 2.6em;
}

.prompt {
  color: var(--text);
}

.muted {
  color: var(--muted);
}

.accent {
  color: var(--accent);
}

.warning {
  color: var(--warning);
}

.section-title {
  color: #ffd400;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 8px;
}

.separator {
  margin: 18px 0 14px;
  color: var(--muted);
}

.terminal-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 28px;
  align-items: start;
}

.terminal-grid > * {
  align-self: start;
}

.cv-section {
  max-width: 100%;
}

.profile-role-line {
  margin-top: 24px;
  margin-bottom: 8px;
  color: #f2f2f2;
  font-family: "Segoe UI", sans-serif;
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
}

.cv-main p {
  max-width: 100ch;
  margin: 0;
  line-height: 1.3;
}

.profile-summary-block > div:first-child {
  display: grid;
  align-content: start;
  gap: 0;
}

.profile-summary-block > div:first-child p {
  margin-top: 0;
}

.profile-summary-block {
  display: grid;
  gap: 24px;
}

.profile-education {
  display: grid;
  gap: 8px;
}

.profile-education .section-title {
  margin: 0;
}

.cv-lines {
  display: grid;
  gap: 8px;
}

.skills-sections {
  display: grid;
  gap: 1.3em;
}

.skills-label {
  display: block;
  margin-bottom: 0;
  color: #ffd400;
}

.skills-section {
  display: grid;
  gap: 0;
}

.skills-table {
  display: table;
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  color: var(--text);
}

.skills-table td {
  width: 33.333%;
  padding: 0 18px 0 0;
  height: 1.3em;
  line-height: 1.3;
  vertical-align: top;
  overflow-wrap: anywhere;
}

.profile-featured {
  display: grid;
  gap: 14px;
}

.profile-featured-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: auto 180px minmax(0, 1fr) auto;
  gap: 28px;
  max-width: 1180px;
}

.profile-feature-card {
  display: grid;
  grid-row: span 4;
  grid-template-rows: subgrid;
  min-width: 0;
  row-gap: 16px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.profile-feature-card p {
  margin: 0;
  line-height: 1.3;
}

.profile-feature-card:hover .showcase-link,
.profile-feature-card:focus-visible .showcase-link,
.profile-feature-card:hover .terminal-button,
.profile-feature-card:focus-visible .terminal-button {
  color: #b9efff;
  text-decoration: underline;
}

.profile-feature-card:focus-visible {
  outline: 1px solid #00a8ff;
  outline-offset: 4px;
}

.profile-feature-title {
  margin-bottom: 0;
}

.profile-feature-links {
  display: grid;
  gap: 2px;
  justify-items: start;
}

.profile-feature-media {
  width: 100%;
  height: 180px;
  overflow: hidden;
  border: 1px solid rgba(109, 216, 255, 0.22);
  background: #f8f9ff;
}

.profile-feature-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.experience-list {
  display: grid;
  gap: 1.6em;
}

.job-company {
  color: #ffd400;
  font-weight: 700;
}

.job {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: 22px;
  align-items: end;
  max-width: 100%;
}

.job-copy {
  width: min(875px, 100%);
  min-width: 0;
}

.job-line {
  margin-top: 5px;
}

.skill-bars {
  width: 400px;
  display: grid;
  gap: 4px;
  justify-items: start;
}

.skill-bar {
  position: relative;
  width: 0;
  max-width: 400px;
  height: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 48px;
  align-items: center;
  gap: 10px;
  padding: 0 10px;
  overflow: hidden;
  background: #ffffff;
  color: #050505;
  font-size: 11px;
  line-height: 28px;
  transition: width 900ms ease-out;
}

.skill-bar.is-visible {
  width: var(--skill-width);
}

.skill-bar span,
.skill-bar strong {
  display: block;
  height: 28px;
  line-height: 28px;
  white-space: nowrap;
}

.skill-bar strong {
  text-align: right;
  font-weight: 400;
}

.reveal-on-load {
  display: none;
  opacity: 0;
  transform: translateY(3px);
}

.reveal-on-load.is-revealed {
  display: block;
  animation: contentFadeIn 220ms ease-out forwards;
}

.showcase-list {
  display: grid;
  gap: 20px;
  margin-top: 30px;
  max-width: 1380px;
}

.showcase-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
  align-items: start;
  width: 100%;
  min-height: 200px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font-family: "Cascadia Mono", Consolas, monospace;
  font-size: 14px;
  line-height: 1.3;
  text-align: left;
  cursor: pointer;
}

.showcase-copy {
  min-height: 200px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.showcase-copy p {
  max-width: 98ch;
  margin: 0;
}

.showcase-link {
  margin-top: auto;
  color: #00a8ff;
}

.showcase-item:hover .showcase-link,
.showcase-item:focus-visible .showcase-link {
  text-decoration: underline;
}

.showcase-item:focus-visible {
  outline: 1px solid #00a8ff;
  outline-offset: 4px;
}

.showcase-thumb {
  width: 300px;
  height: 200px;
  background: #d9d9d9;
  object-fit: cover;
}

.showcase-thumb-diagram {
  padding: 8px;
  border: 1px solid rgba(109, 216, 255, 0.22);
  background: #f8f9ff;
  object-fit: contain;
}

.detail-view {
  position: relative;
  max-width: 92ch;
}

.project-command-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: baseline;
  justify-content: space-between;
  max-width: 92ch;
}

.project-command-row .terminal-button {
  flex: 0 0 auto;
  margin: 0;
}

.project-command-text {
  min-width: 0;
  overflow-wrap: anywhere;
}

.project-detail {
  max-width: min(1180px, 100%);
}

.project-detail > :not(.project-visual) {
  max-width: 92ch;
}

.project-visual {
  width: 100%;
  max-width: 92ch;
  margin: 18px 0 22px;
  overflow: hidden;
  border: 1px solid rgba(109, 216, 255, 0.26);
  background: #f8f9ff;
}

.project-visual img {
  display: block;
  width: 100%;
  height: auto;
}

.blog-detail-with-image {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(340px, 34vw, 420px);
  gap: 36px;
  align-items: start;
  max-width: calc(92ch + 456px);
}

.blog-post-copy {
  min-width: 0;
}

.blog-post-image {
  position: sticky;
  top: 18px;
  width: clamp(340px, 34vw, 420px);
  aspect-ratio: 3 / 2;
  margin-top: 78px;
  overflow: hidden;
  background: transparent;
}

.blog-post-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-view .terminal-button {
  position: relative;
  z-index: 1;
}

.detail-view p {
  margin: 0 0 12px;
}

.contact-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 48px;
  max-width: 780px;
}

.contact-email,
.contact-citizenship,
.contact-location {
  grid-column: 1;
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 28px;
  align-items: start;
  margin-top: 34px;
  max-width: 1180px;
}

.contact-photo {
  justify-self: end;
}

.profile-photo {
  display: block;
  width: 350px;
  height: 350px;
  border: 0;
  border-radius: 0;
  background: #d9d9d9;
  object-fit: cover;
}

.terminal-button {
  display: inline-block;
  margin: 6px 14px 6px 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent);
  font-family: "Cascadia Mono", Consolas, monospace;
  font-size: inherit;
  line-height: inherit;
  cursor: pointer;
}

.terminal-button:hover,
.terminal-button:focus-visible {
  color: #b9efff;
  text-decoration: underline;
  outline: none;
}

.markdown h1,
.markdown h2,
.markdown h3 {
  margin: 20px 0 10px;
  font-size: 1em;
  color: var(--accent);
}

.markdown p,
.markdown ul,
.markdown ol,
.markdown pre,
.markdown table,
.markdown blockquote {
  margin: 0 0 16px;
}

.markdown hr {
  height: 1px;
  margin: 18px 0;
  border: 0;
  background: rgba(109, 216, 255, 0.32);
}

.markdown table {
  width: 100%;
  border-collapse: collapse;
}

.markdown th,
.markdown td {
  padding: 6px 10px;
  border: 1px solid rgba(109, 216, 255, 0.24);
  text-align: left;
  vertical-align: top;
}

.markdown th {
  color: var(--accent);
  font-weight: 700;
}

.markdown blockquote {
  padding-left: 14px;
  border-left: 2px solid var(--accent);
  color: var(--muted);
}

.markdown blockquote p {
  margin: 0;
}

.markdown code,
.markdown pre {
  color: var(--warning);
}

.cursor {
  display: inline-block;
  width: 0.64em;
  height: 1.05em;
  margin-left: 2px;
  vertical-align: -0.14em;
  background: var(--text);
  animation: blink 1s steps(1) infinite;
}

.skip-hint {
  position: sticky;
  bottom: 0;
  display: inline-block;
  margin-top: 24px;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.09);
  color: var(--muted);
  font-size: 14px;
}

@keyframes blink {
  50% { opacity: 0; }
}

@keyframes sessionIn {
  from { opacity: 0.72; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes contentFadeIn {
  from { opacity: 0; transform: translateY(3px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes windowMinimize {
  to {
    opacity: 0;
    transform: translate(-42vw, 42vh) scale(0.16);
  }
}

@keyframes windowClose {
  to {
    opacity: 0;
    transform: scale(0.94);
  }
}

@keyframes windowRestore {
  from {
    opacity: 0;
    transform: translate(-18px, 18px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: translate(0, 0) scale(1);
  }
}

@media (max-width: 1024px) {
  .desktop {
    padding: 14px 4vw 4vh;
  }

  .site-label {
    width: 92vw;
  }

  .tab {
    flex-basis: 190px;
    width: 190px;
  }

  .terminal-grid {
    grid-template-columns: minmax(0, 1fr) minmax(220px, 280px);
    gap: 24px;
  }

  .showcase-item,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .profile-photo {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
  }
}

@media (max-width: 900px) {
  body {
    overflow: auto;
  }

  .desktop {
    min-height: 100svh;
    padding: 14px 4vw 20px;
    align-items: stretch;
  }

  .site-label {
    width: 100%;
    margin-bottom: 14px;
    font-size: 40px;
    overflow-wrap: anywhere;
  }

  .terminal-window {
    width: 100%;
    height: calc(100svh - 96px);
    min-height: 620px;
  }

  .terminal-window.is-managed {
    position: relative;
    left: auto !important;
    top: auto !important;
    width: 100% !important;
    height: calc(100svh - 96px) !important;
  }

  .titlebar {
    align-items: flex-start;
    padding: 5px 8px 0;
  }

  .tabs {
    flex: 1 1 auto;
    overflow: visible;
  }

  .tab {
    display: none;
    width: 100%;
    flex: 0 0 auto;
    margin-left: 0;
    padding-left: 36px;
  }

  .tab.is-active {
    display: block;
  }

  .tabs.is-open {
    position: absolute;
    top: 5px;
    left: 8px;
    right: 50px;
    z-index: 20;
    display: grid;
    gap: 2px;
  }

  .tabs.is-open .tab {
    display: block;
    border-radius: 8px;
    box-shadow: none;
  }

  .mobile-tab-toggle {
    position: relative;
    z-index: 21;
    order: 3;
    display: block;
    flex: 0 0 36px;
    width: 36px;
    height: 32px;
    margin: 4px 0 0 8px;
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: #d0d0d0;
    cursor: pointer;
  }

  .mobile-tab-toggle:hover,
  .mobile-tab-toggle:focus-visible {
    background: rgba(255, 255, 255, 0.09);
    outline: none;
  }

  .mobile-tab-toggle span,
  .mobile-tab-toggle::before,
  .mobile-tab-toggle::after {
    content: "";
    position: absolute;
    left: 9px;
    width: 18px;
    height: 2px;
    background: currentColor;
    pointer-events: none;
  }

  .mobile-tab-toggle span {
    top: 15px;
  }

  .mobile-tab-toggle::before {
    top: 9px;
  }

  .mobile-tab-toggle::after {
    top: 21px;
  }

  .terminal-content {
    padding: 8px 10px 30px;
    font-size: 13px;
    overflow-x: hidden;
  }

  .bucks-window,
  .terminal-window.is-managed.bucks-window {
    height: auto !important;
    min-height: calc(100svh - 96px);
  }

  .bucks-content {
    padding: 10px;
  }

  .bucks-hub {
    grid-template-columns: 1fr;
  }

  .bucks-hero {
    padding: 22px 16px;
  }

  .bucks-news-panel {
    grid-row: auto;
  }

  .bucks-games-grid {
    grid-template-columns: 1fr;
  }

  .bucks-game-card {
    min-height: 188px;
  }

  .skills-table,
  .skills-table tbody,
  .skills-table tr,
  .skills-table td {
    display: block;
    width: 100%;
  }

  .skills-table td {
    padding-right: 0;
  }

  .terminal-grid,
  .profile-featured-grid,
  .job,
  .showcase-item,
  .blog-detail-with-image,
  .contact-layout,
  .contact-panel {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .contact-photo {
    justify-self: start;
  }

  .blog-post-image {
    position: static;
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
    margin-top: 8px;
  }

  .job {
    align-items: start;
  }

  .skill-bars,
  .skill-bar {
    width: 100%;
    max-width: 100%;
  }

  .showcase-copy {
    height: auto;
    min-height: 0;
  }

  .showcase-link {
    margin-top: 12px;
  }

  .showcase-thumb {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
  }

  .profile-photo {
    width: min(260px, 100%);
    height: auto;
    aspect-ratio: 1;
  }

  .titlebar-actions {
    order: 2;
    display: flex;
    margin-right: 0;
  }

  .titlebar-actions .tab-menu {
    display: none;
  }

  .window-controls {
    display: none;
  }

  .resize-handles {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
  }
}