* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth;
}

*::selection {
    font-weight: bold;
    background-color: rgba(255, 255, 255, 0.05);
}

*::-webkit-scrollbar {
    width: 7px;
}

*::-webkit-scrollbar-thumb {
    background: rgb(255, 255, 255);
    border: 3px solid transparent;
    background-clip: padding-box;
}

*::-webkit-scrollbar-thumb:hover {
    border: 0;
    background: rgba(255, 255, 255, 0.5);
}

*::-webkit-scrollbar-thumb:active {
    background: rgba(255, 255, 255, 0.2);
}

*::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0);
}

:root {
  --bg-color: #0a0a0a;
  --text-main: #e0e0e0;
  --text-muted: #888888;
  --card-bg: #141414;
  --accent: #ffffff;
  --border: #2a2a2a;
}

body {
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif;
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

.container {
  max-width: 900px;
  margin: 0 auto;
}

header {
  background: radial-gradient(circle,rgba(32, 32, 32, 1) 0%, var(--bg-color) 40%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  height: 692px;
  border-bottom: 1px solid var(--border);
}

header .container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

h1 {
  font-size: 3rem;
  color: var(--accent);
  margin-bottom: 20px;
  letter-spacing: -1px;
}

header p {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

header a {
  margin-top: 16px;
  padding: 12px 48px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  overflow: hidden;
  border-radius: 8px;
  color: var(--accent);
  text-decoration: none;
  transition: border-color 0.2s ease-out;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

header a:hover {
  border-color: rgba(255, 255, 255, 1);
}

.image {
  width: 100%;
  /* background-color: var(--card-bg); */
  border: 1px solid var(--border);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-weight: 500;
  margin: 40px 0;
  margin-bottom: 0;
  font-size: 1.1rem;
  overflow: hidden;
  transition: all 0.3s ease;
  padding: 8px;
}

.image img {
    width: 100%;
    object-fit: contain;
    object-position: center;
    overflow: hidden;
    border-radius: 12px;
}

section {
  padding: 60px 0;
  border-bottom: 1px solid var(--border);
}

h2 {
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 30px;
}

.flex {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.card {
  background-color: var(--card-bg);
  padding: 30px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.card h3 {
  margin-bottom: 15px;
  font-size: 1.3rem;
  color: var(--accent);
}

.code-block-container {
    width: 100%;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.code-block {
  width: 100%;
  padding: 20px;
  border-radius: 8px 8px 0 0;
  border: 1px solid var(--border);
  overflow-x: auto;
  font-size: 18px;
  font-weight: 800;
  font-family: 'consolas', "Courier New", Courier, monospace;
  color: #d4d4d4;
  margin: 0 auto;
}

.code-block-container a {
    background-color: var(--accent);
    color: var(--bg-color);
    padding: 8px;
    border-radius: 0 0 8px 8px;
    text-align: center;
    text-decoration: none;
    font-size: 18px;
    font-weight: 500;
    transition: background-color 0.2s ease-out;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.code-block-container a:hover {
    background-color: #dbdbdb;
}

.code-highlight {
  color: #aaaaaa;
}

#scrollTopBtn {
  display: none;
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 99;
  border: 1px solid var(--border);
  outline: none;
  background-color: var(--card-bg);
  color: var(--accent);
  cursor: pointer;
  padding: 15px;
  border-radius: 50%;
  font-size: 18px;
  width: 64px;
  height: 64px;
  transition: 0.3s;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  animation: scrollTopBtn 0.2s ease-out;
}

@keyframes scrollTopBtn {
  0% {
    transform: translateY(100%);
  }
  100% {
    transform: translateY(0%);
  }
}

#scrollTopBtn:hover {
  background-color: #222;
  border-color: #555;
}

footer {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
  font-size: 0.9rem;
}

code {
    background-color: var(--card-bg);
    padding: 2px;
    border-radius: 4px;
}

.code-clr1 {
    color: #808080;
}

.code-clr2 {
    color: #569cd6;
}

.code-clr3 {
    color: #9cdcfe;
}

.code-clr4 {
    color: #ce9178;
}

@media screen and (max-width: 950px) {
    body {
        padding: 8px;
    }

    h2 {
        text-align: center;
    }
}