:root {
  --bg: #d2dbe4;
  --card: #f9f9fa;
  --card-alt: #bac4e0;
  --card-accent: #e8ecf0;
  --text: #303030;
  --text-alt: #ffffff;
  --accent: #5c5c5c;
  --stroke: #0e1426;
  --code-bg: #ebebeb;
  --bshadow-alt: 0 0 20px 2px rgba(196, 243, 237, 0.527);
  --bshadow: 0 0 20px 2px rgba(42, 43, 42, 0.527);
  --transition-speed: 0.3s;
}

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

body {
  margin: 20px;
  padding: 32px;
  background: var(--bg);
  font-family: Inter, system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.6;
  color: var(--text);
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}
img {
  display: block;
}

h1,
h2,
h3,
h4,
h5,
h6,
p {
  margin: 0;
}

h1,
h2 {
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 20px;
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  max-width: 1200px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}

header {
  padding: 20px;
  margin-bottom: 20px;
  background-color: var(--card-alt);
  border: 1px solid #383838;
  border-radius: 8px;
  box-shadow: var(--bshadow);
}

/* .wrapper {
  margin-bottom: 20px;
  width: 100%;
} */
.header-menu {
  display: flex;
  justify-content: center;
  gap: 16px;
}

/* .header-item {
  display: flex;
  justify-content: center;
  align-items: center;
} */

.header-link {
  display: inline-flex;
  justify-content: space-around;
  align-items: center;
  min-width: 140px;
  white-space: nowrap;
  padding: 0 8px;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  font-weight: 500;
  height: 40px;
  border: 1px solid #383838;
  border-radius: 8px;
  background: var(--card);
  color: var(--text-logo);
  text-align: center;
  box-shadow: inset 0 4px 6px rgba(0, 0, 0, 0.3), inset 0 -3px 4px rgba(255, 255, 255, 0.3);
  transition: background 0.3s, color 0.3s, transform 0.3s;
}
.header-link:hover {
  background: var(--card-accent);
  color: var(--text);
  transform: translateY(-2px);
}

.icon {
  width: 24px;
  height: 24px;
  fill: currentColor;
  filter: drop-shadow(1px 1px 3px black);
  flex-shrink: 0;
}

.wrap-content {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

.tools {
  position: sticky;
  top: 0;
  left: 0;

  display: flex;
  gap: 10px;
  width: 100%;
  padding: 15px;

  border: 1px solid black;
  border-radius: 8px;
  background: linear-gradient(0deg, var(--card-accent), var(--card-alt));
  box-shadow: 0 0 15px var(--text);
  z-index: 3;
}

.tools input[type='search'] {
  flex: 1 1 260px;
  padding: 10px 12px;
  font-size: 18px;
  border-radius: 8px;

  border: 1px solid var(--stroke);
  background-color: var(--card);
  color: var(--text);

  outline: none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.tools input[type='search']:focus {
  border-color: var(--accent);
  box-shadow: 0 0 6px var(--accent);
}

.btn {
  flex: 0 0 auto;
  padding: 10px 16px;

  border-radius: 8px;
  font-size: 18px;
  border: 1px solid var(--stroke);

  background: var(--code-bg);
  color: var(--text);
  cursor: pointer;

  user-select: none;
  transition: transform 0.1s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  background: var(--card-alt);
  border-color: #444242;
  color: var(--text);
}

.btn:active {
  transform: translateY(1px);
}

details.faq {
  width: 100%;
  max-width: 1200px;
  margin: 12px auto;
  padding: 10px;

  border: 1px solid var(--stroke);
  border-radius: 8px;
  box-sizing: border-box;

  background: linear-gradient(180deg, var(--card), var(--card-alt));
  overflow: hidden;
  cursor: pointer;
}

summary {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: 0.2px;
  user-select: none;
}

.chev {
  display: inline-block;
  transition: transform 0.3s ease;
  scale: 1.5;
}

details[open] .chev {
  transform: rotate(90deg) scale(1.2);
  display: inline-block;
  transition: transform 0.3s ease;
  color: var(--accent);
}

.answer {
  margin-top: 8px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow-wrap: break-word;
}

pre,
code {
  background: var(--code-bg);
  color: var(--text);
  border-radius: 4px;
  border: 1px solid var(--text);
  padding: 3px 5px;
  font-family: Consolas, monospace;
  white-space: pre-wrap;
  word-break: break-word;
  max-width: 100%;
  font-size: 18px;
  overflow-x: auto;
}

pre {
  display: block;
  padding: 10px;
  background: var(--code-bg);
  overflow-x: auto;
  font-size: 14px;
}

.theme-circle {
  position: fixed;
  top: 0;
  right: 0;
  display: flex;
  gap: 6px;
  margin: 6px;
  padding: 3px;
  border-radius: 6px;
  border: 1px solid var(--stroke);
  cursor: pointer;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
}
.circle {
  width: 13px;
  height: 13px;
  background: rgb(255, 0, 0);
  border: 1px solid rgb(228, 227, 227);
  outline: 1px solid rgb(36, 36, 36);
  border-radius: 50%;
  cursor: pointer;
}

/* scroll -----------------*/
.icon-scroll-up {
  position: fixed;
  top: 40px;
  right: 20px;
  transform: rotate(180deg);
  z-index: 4;
}
.icon-scroll-down {
  position: fixed;
  top: 940px;
  right: 20px;
  z-index: 4;
}
.hero-icon-scroll-down {
  position: absolute;
  content: '';
  top: 50%;
  right: 50%;
  color: #19161a;
  transform: translate(50%, -50%);
}

/* --------Плаваюча---- */
.swim-scroll {
  display: inline-flex;
  animation: bounce 1.5s infinite;
  position: relative;
  background-color: rgb(255, 255, 255);
  height: 28px;
  width: 28px;
  border-radius: 50%;
  border: 1px rgb(40, 40, 41) solid;
  justify-content: end;
}
@keyframes bounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(6px);
  }
}

/* ----------response----------- */
/* 576 */
/* @media (min-width: 768px) {
} */
 /* 1024 */
/* @media (min-width: 1158px) {
  } */

@media (min-width: 320px) {
  body {
    margin: 0;
    padding: 0;
    font-size: 16px;
    line-height: 1.4;
  }
  .theme-circle {
    top: 0;
    right: 50%;
    transform: translateX(50%);
    gap: 9px;
    margin: 0;
    /* border-radius: 50px; */
    background-color: #c0c0c0;
    padding: 9px 60px;
    z-index: 3;
    /* box-shadow: 30px 0 20px var(--accent); */
  }
  .circle {
  width: 24px;
  height: 10px;
   border-radius: 0;
  }
  header {
    padding: 8px;
    border: none;
    border-radius: 0;
    margin-bottom: 0;
  }
  .header-menu {
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0;
    margin: 1rem 0;
  }

  .container {
    padding-left: 8px;
    padding-right: 8px;
  }
  .header-link {
    min-width: 100px;
    white-space: nowrap;
    padding: 0 2px;
    font-weight: 400;
    height: 30px;
    border: 1px solid #383838;
    border-radius: 6px;
  }

  .icon {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
  }

  p {
    padding: 5px;
    overflow-wrap: break-word;
  }
  h1 {
    font-size: 1.5rem;
    text-align: center;
    padding-top: 30px;
  }
  h2 {
    font-size: 1.3rem;
    text-align: center;
    padding: 0 0 10px 0;
  }
    img {
      max-width: 100%;
      height: auto;
      display: block;
    }

    /* scroll -----------------*/
.icon-scroll-up {
  top:0;
  right:0;
  transform: rotate(180deg) scale(0.7);
}
.icon-scroll-down {

  top: 680px;
  right: 0;
  z-index: 4;
   transform:  scale(0.7);
}
.hero-icon-scroll-down {
  position: absolute;
  content: '';
  top: 50%;
  right: 50%;
  color: #19161a;
  transform: translate(50%, -50%);
}
.wrap-content {
  padding: 6px;
}

.tools {

  top: 30px;
  left: 0;

 flex-wrap: wrap;
  gap: 6px;
  padding: 6px;
  margin-bottom: 10px;
  border-radius: 6px;
}

.tools input[type='search'] {
  flex: 1 1 150px;
  padding: 4px;
  font-size: 16px;
  border-radius: 6px;
  outline: none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.btn {
  flex: 1 1 auto;
  padding: 4px 6px;
  border-radius: 6px;
  font-size: 16px;
}
details.faq {
 
  margin: 6px auto;
  padding: 3px;
  border-radius: 6px;
}

summary {
display: block;
  gap: 5px;
  }

  .chev {
  scale: 1;
}
.answer {
  margin-top:6px;
}

pre,
code {
display: inline-block;
  padding:0;
   /* width: 100%; */
  border-radius: 4px;
  font-family: Consolas, monospace;
  font-size:1em;
  white-space: pre-wrap;   /* зберігає пробіли/переноси */
  word-break: break-word;  /* переносить довгі слова */
 
       }       /* щоб не вилазив */
pre {
  /* display: flex; */
  /* padding: 1px; */

  font-size: clamp(14px, 2vw, 16px);
}

    @media print {
      .theme-circle {
        display: none;
      }
      .btn {
        display: none;
      }
    }

    
  }
