/*
 Theme Name:   Astra Child
 Theme URI:    https://webkernel.net/
 Description:  My custom child theme for Astra
 Author:       Movasaghi
 Author URI:   https://webkernel.net/
 Template:     astra
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  http://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  astra-child
*/
/* Basic Reset & Box-Sizing for Modern Layouts */
/* @font-face {
  font-family: yekan;
  font-style: normal;
  font-weight: bold;
  src: url("fonts/woff/IRANYekanXFaNum-Bold.woff") format("woff"),
    url("fonts/woff2/IRANYekanXFaNum-Bold.woff2") format("woff2");
}

@font-face {
  font-family: yekan;
  font-style: normal;
  font-weight: normal;
  src: url("fonts/woff/IRANYekanXFaNum-Regular.woff") format("woff"),
    url("fonts/woff2/IRANYekanXFaNum-Regular.woff2") format("woff2");
}

@font-face {
  font-family: IRANSansX;
  font-style: normal;
  font-weight: bold;
  src: url("fonts/woff/IRANSansXFaNum-Bold.woff") format("woff"),
    url("fonts/woff2/IRANSansXFaNum-Bold.woff2") format("woff2");
}

@font-face {
  font-family: IRANSansX;
  font-style: normal;
  font-weight: normal;
  src: url("fonts/woff/IRANSansXFaNum-Regular.woff") format("woff"),
    url("fonts/woff2/IRANSansXFaNum-Regular.woff2") format("woff2");
} */
@font-face {
  font-family: Vazirmatn;
  font-style: normal;
  font-weight: normal;
  src: url("fonts/woff2/Vazirmatn-Regular.woff2") format("woff2");
}
@font-face {
  font-family: Vazirmatn;
  font-style: normal;
  font-weight: bold;
  src: url("fonts/woff2/Vazirmatn-Bold.woff2") format("woff2");
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
body {
  font-family: "Vazirmatn", sans-serif; /* Or any modern font you prefer */
  line-height: 1.6;
  color: #333;
  background-color: #f4f7f6;
      max-width: 500px;
    margin: auto;
}

/* Container for overall layout */
.ai-page-container {
  max-width: 900px;
  margin: -10px auto 0 auto;
  border-radius: 0 0 15px 15px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  display: flex;
  width: 100%;
  flex-direction: column;
  gap: 10px;
  background: linear-gradient(190deg, #e6e6e6, #b3b3b3);
      height: calc(100% - 70px);
          position: absolute;
          padding: 15px;
}
.top_bar {
  background: #e6e6e6;
  border-radius: 15px 15px 0 0;
  box-shadow: 0px 5px 5px #d3d3d3;
  position: relative;
  z-index: 2;
}
.head_but {
  width: 40%;
  float: left;
  height: 70px;
  padding: 5px;
}
/* AI Results Section */
.ai-results-section {
  padding: 5px;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  word-break: break-word;
  height: 80%;
  overflow: scroll;
}
.ai-results-section h2 {
  color: #2e7d32; /* Darker green */
  margin-top: 0;
  font-size: 1.8em;
}
.ai-output-content {
    font-size: 1em;
    color: #000000;
    text-align: initial;
    width: 100%;
    height: 100%;
    margin-bottom: 0;
    overflow: scroll;
    padding-bottom: 15px;
}
/* Styling for AI text (to preserve formatting like bold, lists, etc.) */
.ai-output-content p {
  margin-bottom: 1em;
}
.ai-output-content strong,
.ai-output-content b {
  font-weight: bold;
  color: #005e07;
}
.ai-output-content em,
.ai-output-content i {
  font-style: italic;
  color: #388e3c;
}
.ai-output-content ul,
.ai-output-content ol {
  margin-left: 25px;
  margin-bottom: 1em;
}
.ai-output-content li {
  margin-bottom: 0.5em;
}
.ai-output-content h1,
.ai-output-content h2,
.ai-output-content h3,
.ai-output-content h4,
.ai-output-content h5,
.ai-output-content h6 {
  color: #005e07;
  margin-top: 1.5em;
  margin-bottom: 0.8em;
}
.ai-output-content pre {
  background-color: #f0f4c3; /* Light yellow for code blocks */
  padding: 15px;
  border-radius: 8px;
  overflow-x: auto;
  font-family: "Roboto Mono", monospace; /* Monospaced font for code */
  font-size: 0.9em;
}
.ai-output-content code {
  background-color: #f0f4c3;
  padding: 2px 5px;
  border-radius: 4px;
  font-family: "Roboto Mono", monospace;
}
/* User Input Section */
.user-input-section {
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 3px 4px rgb(0 0 0 / 18%);
  padding: 5px;
}
.user-input-section h2 {
  color: #424242;
  margin-top: 0;
  font-size: 1.6em;
  text-align: center;
  margin-bottom: 20px;
}
.user-input-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  position: relative;
}
.user-input-form textarea {
  width: 100%;
  padding: 5px;
  border: none;
  border-radius: 8px;
  font-size: 1.1em;
  min-height: 80px;
  resize: vertical;
  font-family: "Inter", sans-serif;
  box-shadow: none;
}
.user-input-form textarea:focus {
  outline: none;
  border-color: none;
  box-shadow: none;
}
.user-input-form button {
  background-color: #fff;
  color: white;
  width: 32px;
  padding: 0;
  height: 32px;
  display: block;
  border: none;
  border-radius: 5px;
  font-size: 1.2em;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  position: absolute;
  bottom: 0;
  left: 0;
  overflow: hidden;
}
.user-input-form button:hover {
  transform: translateY(-5px);
}
.user-input-form button:active {
  transform: translateY(-2px);
}
.loading-spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #03A9F4;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    animation: spin 1s linear infinite;
    display: none;
    margin: 20px auto;
    bottom: 45px;
    position: absolute;
    left: 25px;
    z-index: 99;
}
label[for="pro"] {
  font-size: 12px;
  margin-top: -25px;
  display: block;
  margin-right: 25px;
}
input#pro {
  transform: scale(1);
  margin: 5px;
}
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}
a.head_logo img {
  float: right;
  width: 45px;
  margin: 5px;
}
.current_charge {
  margin-top: 5px;
}
h1.head_name {
  float: right;
  clear: none;
  margin-top: 15px;
  color: #202020;
  font-size: 16px;
}
.head_title {
  display: inline-block;
  width: 60%;
  border-radius: 50px 50px 0 0;
  padding: 5px;
  height: 60px;
}
a.head_logo {
  float: right;
  display: block;
}
div#content {
  max-width: 780px;
  position: relative;
  margin: auto;
  width: 100%;
}
.ai-output-content .your_q {
  padding: 20px 10px;
  background: #c1c1c1;
  box-shadow: 0 0 5px #c9c9c9;
  width: 80%;
  border-radius: 15px;
  margin: 15px 15px;
}
.ai_answer {
  padding: 10px 5px;
  border-radius: 10px;
  /* border-bottom: 1px solid #00bcd4; */
}
.ai_answer.error {
  border-bottom: 1px solid #ff5722;
}
/* Mobile Responsiveness */
@media (max-width: 768px) {
  .ai-results-section h2 {
    font-size: 1.6em;
  }
  .user-input-section h2 {
    font-size: 1.4em;
  }
}
