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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  width: 100%;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  color: #1a252f;
  min-height: 100vh;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(circle at 20% 50%, rgba(52, 152, 219, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 50%, rgba(52, 73, 94, 0.1) 0%, transparent 50%);
  pointer-events: none;
  z-index: 1;
}

.container {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0;
  position: relative;
  z-index: 2;
}

header {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.98) 100%);
  color: #1a252f;
  padding: 30px 40px;
  border-radius: 20px 20px 0 0;
  margin: 0;
  box-shadow: none;
  border: 1px solid rgba(52, 152, 219, 0.1);
  border-bottom: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

header h1 {
  margin: 0;
  font-size: 2.5em;
  background: linear-gradient(135deg, #3498db 0%, #2c3e50 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.nav-toggle {
  display: none !important;
}

.nav-toggle-label {
  display: none !important;
  position: absolute;
  top: 20px;
  right: 20px;
  width: 30px;
  height: 30px;
  cursor: pointer;
  z-index: 10;
}

.nav-toggle-label span {
  display: block;
  width: 100%;
  height: 4px;
  background: white;
  margin-bottom: 4px;
  border-radius: 2px;
  transition: 0.3s;
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(1) {
  transform: rotate(-45deg) translate(-5px, 5px);
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(2) {
  opacity: 0;
}

.nav-toggle:checked ~ .nav-toggle-label span:nth-child(3) {
  transform: rotate(45deg) translate(-5px, -5px);
}

nav {
  display: flex;
  align-items: center;
}

nav a {
  color: #34495e;
  text-decoration: none;
  margin-right: 20px;
  padding: 8px 16px;
  border-radius: 10px;
  transition: all 0.3s ease;
  font-weight: 500;
}

nav a:hover {
  background: rgba(52, 152, 219, 0.1);
  color: #3498db;
  transform: translateY(-2px);
}

main {
  margin: 0;
  padding: 40px;
  background: linear-gradient(135deg, rgba(247, 250, 252, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  border-radius: 0 0 20px 20px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.2);
  border: 1px solid rgba(52, 152, 219, 0.1);
  border-top: none;
  position: relative;
}

h1, h2, h3 {
  color: #1a252f;
  font-weight: 300;
}

h1 {
  font-size: 2.2em;
  margin-bottom: 20px;
}

h2 {
  font-size: 1.8em;
  margin-top: 40px;
  margin-bottom: 15px;
  color: #2c3e50;
  padding-bottom: 10px;
}

h3 {
  font-size: 1.4em;
  margin-top: 30px;
  margin-bottom: 10px;
}

a {
  color: #3498db;
  text-decoration: none;
  transition: all 0.3s ease;
  border-bottom: 1px solid rgba(52, 152, 219, 0.3);
}

a:hover {
  color: #2c3e50;
  border-bottom-color: #2c3e50;
}

code {
  background: #ecf0f1;
  padding: 2px 6px;
  border-radius: 3px;
  font-family: 'Courier New', monospace;
}

pre {
  background: white;
  color: #1a252f;
  padding: 15px;
  border-radius: 10px;
  overflow-x: auto;
  border: 1px solid #ecf0f1;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

blockquote {
  border-left: 4px solid transparent;
  border-image: linear-gradient(180deg, #3498db 0%, #2c3e50 100%);
  border-image-slice: 1;
  padding-left: 20px;
  margin: 20px 0;
  font-style: italic;
  color: #7f8c8d;
  background: rgba(52, 152, 219, 0.05);
  padding: 15px 20px;
  border-radius: 0 10px 10px 0;
}

footer {
  text-align: center;
  padding: 30px;
  color: white;
  margin: 0 auto 2rem;
  max-width: 1200px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
  position: relative;
  z-index: 2;
}

footer a {
  color: #61d4e1;
  text-decoration: none;
  border-bottom: 1px solid rgba(97, 212, 225, 0.5);
  transition: all 0.3s ease;
}

footer a:hover {
  color: white;
  border-bottom-color: white;
}

/* Scrollbar styling - minimal/hidden */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(52, 152, 219, 0.3);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(52, 152, 219, 0.5);
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(52, 152, 219, 0.3) transparent;
}

/* Selection styling */
::selection {
  background: rgba(52, 152, 219, 0.3);
  color: #1a252f;
}

::-moz-selection {
  background: rgba(52, 152, 219, 0.3);
  color: #1a252f;
}

/* Cover image hover effect */
main a img:hover {
  transform: scale(1.02);
  box-shadow: 0 15px 40px rgba(0,0,0,0.3) !important;
}

/* Responsive design */
@media (max-width: 768px) {
  .container {
    margin: 1rem;
    max-width: none;
  }

  footer {
    margin: 0 1rem 1rem;
  }

  header {
    padding: 20px 15px;
    position: relative;
    flex-direction: column;
    align-items: flex-start;
  }

  header h1 {
    font-size: 2em;
  }

  .nav-toggle-label {
    display: block !important;
  }

  nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(247, 250, 252, 0.98) 100%);
    flex-direction: column;
    padding: 20px 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    border-radius: 0;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 10;
  }

  .nav-toggle:checked ~ nav {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  nav a {
    display: block;
    margin-bottom: 10px;
    margin-right: 0;
    text-align: center;
  }

  main {
    padding: 20px;
  }

  h1 {
    font-size: 1.8rem;
  }
}
