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

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    font-family: monospace;
    color: hsl(200, 37%, 73%);
    line-height: 1.5;
}

html {
    background: #000000;
}

#canvasWrapper {
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    position: fixed;
    z-index: -999;
    display: block;
    overflow: hidden;
}

canvas {
    width: 100%;
    height: 100%;
    filter: blur(2px);
    opacity: 0.4;
}

/* Typography & Headings */
h1, h2, h3, h4 {
    margin: 0 0 12px 0;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #fff;
    overflow-wrap: break-word;
    word-break: break-word;
}

h1 {
    font-size: clamp(22px, 4vw, 28px);
}

h2 {
    font-size: clamp(18px, 3vw, 22px);
    margin-top: 1em;
}
h3 {
    font-size: 20px;
}

.subtitle {
    font-size: 18px;
    color: #fff;
    margin-bottom: 4px;
}

p {
    margin: 8px 0;
    font-size: 16px;
}

/* Accessible & high-contrast links */
a {
    text-decoration: underline;
    text-underline-offset: 3px;
    color: hsl(200, 80%, 70%);
    transition: color 0.2s ease;
}

a:hover, a:focus-visible {
    color: rgb(200, 145, 58);
    outline: none;
}

section {
    margin: 2.5em 15vw;
}

.center {
    text-align: center;
}

.section-intro {
    margin-top: 1.5em;
    font-weight: bold;
}

/* Flex Card Layout */
.card {
    background: hsl(24, 14%, 10%);
    color: hsl(200, 27%, 83%);
    margin: 1.5em 0;
    display: flex;
    flex-direction: row;
    border: rgb(200, 145, 58) solid 2px;
    border-radius: 4px;
    overflow: hidden;
}

.card-content {
    flex: 1;
    padding: 1.25em;
    display: flex;
    align-items: center;
}

.card-content p {
    margin: 0;
}

/* Fixed aspect ratio & CLS prevention */
.card .imageContainer {
    flex: 0 0 40%;
    max-width: 40%;
    aspect-ratio: 16 / 9;
    padding: 4px;
    background: hsl(24, 14%, 8%);
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.imageContainer img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Prevents image distortion */
    display: block;
}

/* Lists */
ul {
    padding-left: 1.2em;
    font-size: 1.2em;
}

li {
    margin-bottom: 6px;
}

/* Footer & Navigation */
footer {
    background: hsl(24, 14%, 10%);
    padding: 2em 15vw;
    color: hsl(200, 27%, 83%);
    border-top: rgb(200, 145, 58) solid 2px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5em;
}

.footer-links {
    display: flex;
    gap: 1.2em;
    flex-wrap: wrap;
}

/* Mobile & Tablet Media Query */
@media (max-width: 850px) {
    section {
        margin-left: 6vw;
        margin-right: 6vw;
    }
    footer {
        padding-left: 6vw;
        padding-right: 6vw;
    }
}

@media (max-width: 640px) {
    section {
        margin: 1.5em 6vw;
    }

    footer {
        padding: 1.5em 6vw;
    }

    .card {
        flex-direction: column;
    }

    .card .imageContainer {
        flex: 0 0 100%;
        max-width: 100%;
        width: 100%;
    }

    .footer-content {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* .tag-cloud h3 {
    display: inline;
    line-height: 1em;
    margin: 0;
} */
.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 1.5em;
}

.tech-tag {
  background: hsl(24, 14%, 10%);
  color: hsl(200, 27%, 73%);
  border: 1px solid rgba(200, 145, 58, 0.5);
  font-size: 18px;
  border-radius: 3px;
  transition: all 0.2s ease;
  padding: 0 8px;
}

.tech-tag svg {
    fill: hsl(200, 27%, 73%);
    height: 1.4em;
    padding-bottom: 2px;
    vertical-align: middle;
}
.tech-tag span {
    padding: 4px 0;
}
.tech-tag:hover {
  border-color: rgb(200, 145, 58);
  color: hsl(200, 27%, 83%);
  transform: translateY(-1px);
}
.tech-tag:hover svg {
  fill: hsl(200, 27%, 83%);
}
.stroke {
    stroke: hsl(200, 27%, 83%);
    fill: none !important;
}