@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');
*{
  margin: 0;
  padding: 0;
  font-family: 'Inter', sans-serif;
}

/* ==== COLOR VARIABLES ==== */
:root {
  --primary-color: #202020;
  --second-color: #ffffff;
  --button-color: #516BFF;
  --buttonhover-color: #6f85ff;
}

/* ==== Reusable CSS ==== */
a {
  text-decoration: none;
  color: var(--second-color);
}

a:hover{
  text-decoration: underline;
}


/* ==== MAIN PAGE ==== */

body {
  margin: 0;
  padding: 0;
  background-color: var(--primary-color);
  color: #fff;
  font-size: 16px;
}

.container {
  /* background-color: #111111; */
  max-width: 1200px;
  margin: 100px auto;
  padding: 20px;
  /* border: 2px solid #303030; */
  border-radius: 10px;
}

h1 {
  font-size: 40px;
  margin-top: 10px;
  text-align: center;
  margin-bottom: 20px;
  padding: 0 20px;
}

p {
  text-align: center;
  color: #b0b0b0;
  padding: 0 20px;
  font-size: 18px;
}

.input-section {
  /* background-color: #000000; */
  padding: 0 20px;
  border-radius: 8px;
  margin-bottom: 20px;
  margin-top: 20px;
}

.prompt-box {
  margin-bottom: 10px;
  
}

.prompt-box label {
  display: block;
  margin-bottom: 5px;
}

textarea {
  width: 100%;
  padding: 10px;
  font-size: 16px;
  border: 2px solid #303030;
  border-radius: 10px;
  box-sizing: border-box;
  margin-bottom: 10px;
  resize:vertical;
  min-height: 80px;
  background-color: var(--second-color);
  color: #494949;
}

textarea:focus {
  border-color: var(--button-color); 
  outline: none; 
  box-shadow: 0 0 5px var(--button-color);
}

/* ======= OPTIONS DROPDOWN LISTS ======== */
.options {
  display: flex;
  justify-content: center;
}

.custom-style-options {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px; /* Отступы между кнопками */
}

.style-option {
  cursor: pointer;
  transition: transform 0.3s, box-shadow 0.3s, background-color 0.3s;
  width: 120px; /* Задаем фиксированную ширину для всех опций */
  text-align: center; /* Центрируем текст под кнопками */
  margin: 5px; /* Дополнительные отступы вокруг каждой кнопки */
  padding: 10px;
  border-radius: 10px; /* Добавляем радиус границы для кнопок */
}

.style-option img {
  width: 120px;
  height: 120px; /* Фиксированная высота для всех изображений */
  object-fit: cover;
  border-radius: 10px;
}

.style-option p {
  margin-top: 5px;
  font-size: 14px; /* Размер шрифта текста под изображением */
  height: 42px;
}

.style-option[selected] {
  /* box-shadow: 0 0 10px rgba(0, 0, 0, 0.5); */
  transform: scale(1.1);
  /* background-color: rgba(0, 128, 0, 0.2);  */
  border: 2px solid var(--button-color);
}

select {
  padding: 15px 30px;
  font-size: 16px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  position: relative;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 4 5"><path fill="none" stroke="%23000" stroke-width=".5" d="M2 0L0 2h4zm0 5L0 3h4z"/></svg>');
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 10px 10px;
  text-align: center;
  margin-left: 10px;
  margin-top: 50px;
  border-radius: 10px;
}

/* Стили для опций */
select option {
  padding: 10px;
}

/* Стили для выпадающих списков при фокусе */
select:focus {
  border-color: var(--button-color);
  outline: none;
  box-shadow: 0 0 5px var(--button-color);
}

#design-label {
  color: rgb(255, 255, 255); /* Пример стиля - синий цвет текста */
  font-size: 16px; /* Пример стиля - размер шрифта 16 пикселей */
  /* Другие стили, которые вы хотите применить к label с идентификатором "design" */
}


/* Дополнительные стили для конкретных размеров */
/* #size {
  width: 100%;
}

#count {
  width: 100%;
} */

/* ======= OPTIONS DROPDOWN LISTS END ======== */

.settings {
  border-bottom: 1px solid #ffffff5b;
}
/*
.settings label {
  margin-right: 10px;
} */


.create-button img.balance-icon {
  vertical-align: middle;
  width: 24px;
  height: 24px;
}
.create-button {
  vertical-align: middle;
  width: 300px;
  height: 60px;
  color: white;
  background: var(--button-color);
  font-size: 20px;
  font-weight: bold;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: .3s;
  margin-bottom: 20px;
  margin-top: 50px;
}

.create-button:hover {
  background: var(--buttonhover-color);
}

.gallery {
  margin-top: 20px;
}

.tab {
  overflow: hidden;
  border-bottom: 1px solid #2a2a2a;
  margin-bottom: 10px;
}

.tab button {
  background-color: inherit;
  border: none;
  outline: none;
  cursor: pointer;
  padding: 14px 16px;
  transition: 0.3s;
  color: #ffffff;
}

.tab button:hover {
  background-color: #575757;
}

.tab button.active {
  background-color: #575757;
}

.tabcontent {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.image-card {
  border-radius: 8px;
  width: calc(25% - 20px);
  box-sizing: border-box;
}

.image-card img {
  width: 100%;
  border-radius: 8px;
}

.loading-card {
  background-color: rgb(48, 48, 48);
  display: flex;
  align-items: center;
  justify-content: center;
  height: auto;
  width: calc(25% - 20px);
  
}

.spinner {
  border: 2px solid #c7c7c7;
  border-radius: 50%;
  border-top: 2px solid var(--button-color);
  width: 30px;
  height: 30px;
  animation: spin 2s linear infinite;
}

.spinner-content {
  border: 2px solid #c7c7c7;
  border-radius: 50%;
  border-top: 2px solid var(--button-color);
  width: 35px;
  height: 35px;
  animation: spin 2s linear infinite;
  margin-left: 50%;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.error-message {
  color: #494949;
  background-color: white;
  border: 1px solid #c7c7c7;
  padding: 7px;
  border-radius: 10px;
  text-align: center;
}

.alert-modal {
  display: none;
  position: fixed;
  z-index: 1001;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgb(0, 0, 0);
  background-color: rgba(255,255,255,255,0.9);
}

.alert-modal-content {
  margin: 20% auto;
  display: block;
  max-width: 70%;
  max-height: 85%;
  border: 1px solid #c7c7c7;
  border-radius: 10px;
  padding: 20px;
  text-align: right;
}
.alert-button{
  background-color: #ffffff;
  border: none;
  color: rgb(43, 43, 43);
  padding: 10px 15px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 16px;
  margin: 15px 0px;
  cursor: pointer;
  border-radius: 10px;
  transition: background-color 0.3s;
}
.alert-button:hover {
  background-color: #d4d4d4;
} 

.modal {
  display: none;
  position: fixed;
  z-index: 9000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgb(0,0,0);
  background-color: rgba(0,0,0,0.9);
}

.modal-content {
  margin: auto;
  padding-top: 10px;
  display: block;
  max-width: 90%;
  max-height: 90%;
  /* border: 1px solid #bf00ff;
  border-radius: 10px;
  padding: 20px; */
}

.close {
  position: absolute;
  top: 20px;
  right: 35px;
  color: #fff;
  font-size: 20px;
  font-weight: bold;
  transition: 0.3s;
  cursor: pointer;
}

.close:hover,
.close:focus {
  color: #bbb;
  text-decoration: none;
  cursor: pointer;
}

.download-button {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #007bff00;
  color: #fff;
  padding: 10px 20px;
  text-decoration: none;
  border-radius: 10px;
}

.download-button:hover {
  background-color: #ffffff00;
}

/* .generate-button {
  background-color: #9E00FF;
  border: none;
  color: white;
  padding: 15px 25px;
  text-align: center;
  text-decoration: none;
  display: inline-block;
  font-size: 15px;
  margin: 10px 5px;
  cursor: pointer;
  border-radius: 10px;
  transition: background-color 0.3s;
}
.generate-button:hover {
  background-color: #4d007d;
} */

/* .image-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  grid-gap: 10px;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  top: 2%;
  transform: translateY(-75%);
}

.image-container img {
  width: 100%;
  height: auto;
  display: block;
  opacity: 0.5;
} */

/* ====== HEADER ====== */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: var(--primary-color);
  transition: background-color 0.3s;
  border-bottom: solid 1px #494949;
}

header .header-content {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

header.scrolled {
  background-color: rgba(0, 0, 0, 0.5);
}

.logo img {
  height: 50px;
  padding: 5px;
}

.header-right {
  display: flex;
  align-items: center;
}

.user-info {
  display: flex;
  align-items: center;
}
.balance-container {
  display: flex;
  align-items: center;
  font-size: 18px;
  color: #fff;
  margin-right: 20px;
}

.balance-container-content {
  display: flex;
  align-items: center;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
  margin-top: 20px;
  margin-left: 45%;
}

.balance-container .spinner {
  width: 15px;
  height: 15px;
}

.balance-icon {
  width: 24px;
  height: 24px;
  margin-left: 5px;
}

.balance-icon-content {
  width: 34px;
  height: 34px;
  margin-left: 5px;
  color: var(--button-color);
}

.profile-container {
  position: relative;
  display: inline-block;
  padding: 0px 40px;
}

.profile-button {
  background-color: transparent;
  border: none;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.profile-button:hover {
  background-color: rgba(81, 107, 255, 0.1);
}

.profile-button:focus {
  outline: none;
}

.header-email {
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.dropdown-menu {
  display: none; 
  position: absolute;
  right: 0;
  top: 50px;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  z-index: 4;
  min-width: 280px;
  border-radius: 12px;
  padding: 20px;
}

.dropdown-menu a,
.dropdown-menu button {
  color: var(--primary-color);
  padding: 12px 16px;
  text-decoration: none;
  display: block;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
  font-size: 16px;
  width: 100%;
  border-radius: 8px;
  transition: all 0.3s ease;
  margin: 2px 0;
}

.dropdown-menu a:hover,
.dropdown-menu button:hover {
  background: rgba(81, 107, 255, 0.1);
  color: var(--button-color);
  text-decoration: none;
}

.dropdown-menu p {
  padding-bottom: 15px;
  font-size: 16px;
  text-align: center;
  margin-bottom: 10px;
  color: var(--primary-color);
}

.dropdown-tokens-display {
  background: rgba(81, 107, 255, 0.05);
  border-radius: 12px;
  padding: 15px;
  margin-bottom: 15px;
  border: 1px solid rgba(81, 107, 255, 0.2);
}

.balance-container-dropdown {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 16px;
  color: var(--primary-color);
}

.balance-icon-dropdown {
  width: 24px;
  height: 24px;
}

.spinner-dropdown {
  width: 15px;
  height: 15px;
  border: 2px solid #c7c7c7;
  border-radius: 50%;
  border-top: 2px solid var(--button-color);
  animation: spin 2s linear infinite;
}

.tokens-label {
  font-size: 14px;
  color: #666666;
  margin-left: 5px;
}

.dropdown-divider {
  height: 1px;
  background: #e0e0e0;
  margin: 15px 0;
}

.menu-icon {
  width: 20px; 
  height: 20px; 
  margin-right: 15px; 
}

.profile-container.show .dropdown-menu {
  display: block;
}

.logout-button {
  padding: 0;
}

.content-purple-text{
  align-items: center;
  font-size: 40px;
  color: var(--button-color);
}

#dynamicEmail {
  color: var(--button-color);
}

/* ====== FAQ ====== */

.faq-container {
  max-width: 100%;
  margin: 80px auto;
  padding: 60px 20px;
  background-color: var(--primary-color);
  border-radius: 15px;
  border: 1px solid #494949;
  position: relative;
}

.faq-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--button-color), var(--buttonhover-color));
  border-radius: 15px 15px 0 0;
}

.faq-insider {
  max-width: 1200px;
  margin: 0 auto;
}

.faq-container h1 {
  text-align: center;
  margin: 0 auto 50px auto;
  font-size: 40px;
  font-weight: 700;
  color: var(--second-color);
  position: relative;
  width: fit-content;
}

.faq-container h1::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--button-color);
  border-radius: 2px;
}

.faq-container p {
  padding: 0 0;
}

.faq-item {
  margin-bottom: 20px;
  background-color: transparent;
  border-radius: 8px;
  border: 1px solid #494949;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: var(--button-color);
  box-shadow: 0 4px 15px rgba(81, 107, 255, 0.1);
}
}

.question {
  cursor: pointer;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 18px;
  font-weight: 600;
  color: var(--second-color);
  transition: all 0.3s ease;
  position: relative;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
  border-bottom: 1px solid #494949;
}

.question::after {
  content: '+';
  font-size: 20px;
  font-weight: 400;
  color: var(--button-color);
  transition: all 0.3s ease;
  flex-shrink: 0;
  margin-left: 16px;
}

.question:hover {
  color: var(--button-color);
  background-color: rgba(81, 107, 255, 0.05);
}

.answer {
  display: none;
  padding: 20px 24px;
  background-color: rgba(255, 255, 255, 0.02);
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.answer p {
  margin: 0;
  font-size: 16px;
  line-height: 1.6;
  color: #cccccc;
  text-align: left;
}

.question-checkbox {
  display: none;
}

.question-checkbox:checked + .question::after {
  content: '−';
  color: var(--buttonhover-color);
}

.question-checkbox:checked + .question + .answer {
  display: block;
}

.question-checkbox:checked + .question {
  color: var(--button-color);
  background-color: rgba(81, 107, 255, 0.08);
  border-bottom-color: var(--button-color);
}



.hidden {
  display: none;
}
#error-message {
  color: white;
  background-color: white;
  border: 1px solid #c7c7c7;
  padding: 7px;
  border-radius: 10px;
  text-align: center;
}

/* ====== FOOTER ====== */
footer {
  background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 40% 80%, rgba(120, 219, 255, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

.container-footer {
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 40px 40px;
  position: relative;
  z-index: 1;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

.footer-section {
  position: relative;
}

.footer-section::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 0;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, #7c77c6, #ff77c6);
  border-radius: 2px;
}

.footer-section h3 {
  color: #fff;
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 25px;
  margin-top: 15px;
  letter-spacing: 0.5px;
}

.footer-section pfooter {
  line-height: 1.8;
  color: #b8b8d1;
  font-size: 15px;
  display: block;
}

.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-section ul li {
  margin-bottom: 12px;
  position: relative;
  padding-left: 0;
  transition: all 0.3s ease;
}

.footer-section ul li::before {
  content: '→';
  position: absolute;
  left: -20px;
  color: #7c77c6;
  opacity: 0;
  transition: all 0.3s ease;
}

.footer-section ul li:hover::before {
  opacity: 1;
  left: -15px;
}

.footer-section ul li a {
  color: #b8b8d1;
  text-decoration: none;
  font-size: 15px;
  transition: all 0.3s ease;
  position: relative;
}

.footer-section ul li a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #7c77c6, #ff77c6);
  transition: width 0.3s ease;
}

.footer-section ul li a:hover {
  color: #fff;
  transform: translateX(5px);
}

.footer-section ul li a:hover::after {
  width: 100%;
}

.footer-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(184, 184, 209, 0.3), transparent);
  margin: 40px 0;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 30px;
  border-top: 1px solid rgba(184, 184, 209, 0.2);
}

.footer-copyright {
  color: #8a8aa8;
  font-size: 14px;
}

.footer-logos {
  display: flex;
  gap: 15px;
  align-items: center;
}

.footer-logos img {
  width: 45px;
  height: auto;
  opacity: 0.8;
  transition: all 0.3s ease;
  filter: brightness(0.9);
}

.footer-logos img:hover {
  opacity: 1;
  transform: translateY(-3px);
  filter: brightness(1.1);
}

@media only screen and (max-width: 768px) {

  h1{
    font-size: 30px;
  }
  h2{
    font-size: 20px;
  }
  
  .faq-container {
    padding: 40px 15px;
    margin: 20px 10px;
    border-radius: 12px;
  }
  
  .faq-container h1 {
    font-size: 32px;
    margin-bottom: 30px;
  }
  
  .question {
    padding: 16px 20px;
    font-size: 16px;
  }
  
  .answer {
    padding: 16px 20px;
  }
  .container{
    width: 95%;
    margin: 0 auto;
    margin-top: 75px;
    /* background-color: #111111; */
    padding: 10px;
    /* box-shadow: 0 4px 8px rgba(0,0,0,0.1); */
  }

  .options select {
    padding: 10px 20px;
  }
  select {
    padding: 15px 25px;
    font-size: 14px;
  }

  .container2{
    padding-top: 40px;
  }
  
  /* Footer responsive styles for mobile */
  .footer-content {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }
  
  .container-footer {
    padding: 60px 20px 30px;
  }
  
  .footer-section::before {
    left: 50%;
    transform: translateX(-50%);
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }
  
  .footer-section h3 {
    font-size: 18px;
    margin-bottom: 15px;
  }
  
  .footer-section pfooter {
    font-size: 14px;
    line-height: 1.6;
  }
  
  .footer-section ul li a {
    font-size: 14px;
  }
  
  .footer-section::before {
    width: 25px;
    height: 2px;
  }
  
  .footer-logos img {
    width: 35px;
  }
  
  .footer-copyright {
    font-size: 12px;
  }

  .balance-container {
    margin-right: 0;
  }

  .profile-container {
    padding: 0 20px;
  }

  .modal-content{
    left: 0;
    top: 50%;
  }
}
