/* Mackaron Studio: black base, red (#cd3737) UI, white text, Rajdhani. Square corners, no divider lines. */

:root {
  --bg: #000;
  --text: #fff;
  --muted: #b0b0b7;
  --red: #cd3737;
  --red-dark: #b32c2c; /* button hover, keeps white text readable */
  --wrap: 1080px;
  --font: 'Rajdhani', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
  scroll-padding-top: 88px;
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 500 1.1875rem/1.55 var(--font);
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--red);
  color: #fff;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 48px);
  margin-inline: auto;
  padding-inline: 24px;
}

.skip {
  position: absolute;
  left: 16px;
  top: -64px;
  z-index: 100;
  padding: 10px 16px;
  background: #fff;
  color: #000;
  font-weight: 700;
  text-decoration: none;
}
.skip:focus {
  top: 12px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 28px;
  border: 1px solid var(--red);
  background: var(--red);
  color: #fff;
  font: 700 1.125rem/1 var(--font);
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease;
}
.btn:hover {
  background: var(--red-dark);
  border-color: var(--red-dark);
}
.btn-sm {
  min-height: 40px;
  padding: 0 20px;
  font-size: 1.0625rem;
}
.btn-ghost {
  background: transparent;
  border-color: #3a3a40;
}
.btn-ghost:hover {
  background: transparent;
  border-color: #fff;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
}

.bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 1.375rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-decoration: none;
}
.brand img {
  width: 40px;
  height: auto;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
}
.nav a:not(.btn) {
  padding: 8px 14px;
  color: var(--muted);
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.15s ease;
}
.nav a:not(.btn):hover {
  color: #fff;
}
.nav .btn {
  margin-left: 10px;
}

.menu-btn {
  display: none;
  position: relative;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid #2c2c31;
  background: transparent;
  color: #fff;
  cursor: pointer;
}
.menu-btn span {
  position: absolute;
  left: 12px;
  right: 12px;
  height: 2px;
  background: currentColor;
  transition:
    transform 0.2s ease,
    top 0.2s ease;
}
.menu-btn span:nth-child(1) {
  top: 16px;
}
.menu-btn span:nth-child(2) {
  top: 25px;
}
.menu-btn[aria-expanded='true'] span:nth-child(1) {
  top: 20px;
  transform: rotate(45deg);
}
.menu-btn[aria-expanded='true'] span:nth-child(2) {
  top: 20px;
  transform: rotate(-45deg);
}

/* ---------- Hero (centred) ---------- */

.hero {
  padding: clamp(80px, 14vw, 184px) 0 clamp(80px, 13vw, 168px);
  text-align: center;
}

h1 {
  max-width: 13ch;
  margin: 0 auto 24px;
  font-size: clamp(3.25rem, 9vw, 7rem);
  line-height: 0.96;
  font-weight: 700;
}

.lead {
  max-width: 34ch;
  margin-inline: auto;
  color: var(--muted);
  font-size: clamp(1.25rem, 2.2vw, 1.625rem);
  line-height: 1.4;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 40px;
}

/* ---------- Sections ---------- */

.section {
  padding: clamp(48px, 7vw, 88px) 0;
}

.split {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 24px 48px;
  align-items: start;
}

h2 {
  font-size: 2rem;
  line-height: 1.1;
  font-weight: 700;
}

h3 {
  font-size: 1.5rem;
  line-height: 1.2;
  font-weight: 700;
}

.big {
  max-width: 28ch;
  font-size: clamp(1.625rem, 3vw, 2.25rem);
  font-weight: 600;
  line-height: 1.2;
}

/* ---------- Projects ---------- */

.project + .project {
  margin-top: 52px;
}
.project h3 {
  margin-bottom: 6px;
  font-size: clamp(2rem, 4.4vw, 3rem);
  line-height: 1.05;
}
.project p:not(.status) {
  max-width: 52ch;
  color: var(--muted);
}

.status {
  display: inline-block;
  margin-bottom: 12px;
  padding: 1px 10px;
  background: var(--red);
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* ---------- About ---------- */

.prose p:not(.big) {
  max-width: 46ch;
  color: var(--muted);
}
.prose .big + p {
  margin-top: 20px;
}
.team {
  margin-top: 28px;
}
.team strong {
  color: #fff;
  font-weight: 700;
}

/* ---------- News ---------- */

.news li {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 4px 28px;
}
.news li + li {
  margin-top: 28px;
}
.news time {
  color: var(--muted);
  padding-top: 3px;
}
.news h3 {
  margin-bottom: 2px;
}
.news p {
  color: var(--muted);
}

/* ---------- Contact ---------- */

.mail {
  display: inline-block;
  margin-top: 22px;
  color: var(--red);
  font-size: clamp(1.75rem, 4.8vw, 2.75rem);
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color 0.15s ease;
}
.mail:hover {
  color: #fff;
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: clamp(24px, 4vw, 48px);
  color: var(--muted);
}
.foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 32px;
  padding-block: 28px;
}
.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 24px;
}
.foot nav a {
  text-decoration: none;
  transition: color 0.15s ease;
}
.foot nav a:hover {
  color: #fff;
}

/* ---------- Small screens ---------- */

@media (max-width: 860px) {
  .split {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 760px) {
  .wrap {
    padding-inline: 16px;
  }
  .menu-btn {
    display: block;
  }
  .js .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 16px 20px;
    background: var(--bg);
  }
  .js .nav.open {
    display: flex;
  }
  .js .nav a:not(.btn) {
    padding: 14px 4px;
    color: #fff;
    font-size: 1.25rem;
  }
  .js .nav .btn {
    margin: 14px 0 0;
    min-height: 48px;
    font-size: 1.125rem;
  }
  .news li {
    grid-template-columns: 1fr;
  }
  .actions .btn {
    flex: 1 1 auto;
  }
}
