@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Diphylleia&family=Special+Gothic+Expanded+One&display=swap');

html, body {
  width: 100%;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: sans-serif;
    background: linear-gradient(180deg, #0d1117 0%, #161b22 100%);
    color: #c9d1d9;
}

/* Scroll Reveal Animation */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Add stagger effect if there are multiple child elements */
.reveal-on-scroll.staggered > * {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-on-scroll.staggered.visible > * {
  opacity: 1;
  transform: translateY(0);
  transition-delay: var(--stagger-delay);
}

.landing-container{
    position: fixed;
    display: flex;
    flex-direction: column;
    justify-content: first center;
    align-items: center;
    background-size: 60% auto;
    background-repeat: no-repeat;
    background-position: center;
    background-color: black;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    z-index: 10000;
}

.landing-container *{
    opacity: 0;
}

.landing-container h1{
    font-family: "Bebas Neue", sans-serif;
    font-weight: 600;
    font-size: 4.5rem;
}

.loaderA{
    opacity: 0;
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 500px;
    height: 500px;
    background: #dddddd0a;
    clip-path: polygon(
        50% 0%,   /* top point */
        100% 100%, /* bottom right */
        75% 100%,  /* inner right leg */
        60% 65%,   /* right crossbar */
        40% 65%,   /* left crossbar */
        25% 100%,  /* inner left leg */
        0% 100%    /* bottom left */
    );
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.loaderA::after{
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background: #ffffff69;
    border-radius: 50%;
}

.loaderA.animate::after {
  animation: LoadingA 1s ease-in-out forwards;
}

.BackgroundA{
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 700px;
    height: 700px;
    background: rgba(90, 90, 90, 0.03);
    clip-path: polygon(
        50% 0%,   /* top point */
        100% 100%, /* bottom right */
        75% 100%,  /* inner right leg */
        60% 65%,   /* right crossbar */
        40% 65%,   /* left crossbar */
        25% 100%,  /* inner left leg */
        0% 100%    /* bottom left */
    );
}

.BackgroundA::after {
  content: '';
  position: absolute;
  bottom: 0; /* fills from bottom */
  left: 0;
  width: 100%;
  height: var(--fill-height, 0%); /* controlled by JS */
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0));
}

.hero {
    background: #0d1117; /* Dark base background */
    position: relative;
    color: #c9d1d9;
    z-index: 10;
    width: 80%;
    max-width: 1000px;
    padding: 70px 40px;
    border-radius: 12px;
    margin: 5% auto;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    /* Subtle grid pattern */
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 40px 40px; /* size of grid squares */
    animation: fadeIn 1s ease forwards;
}

/* Headings */
.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #f0f6fc;
}

.hero h2 {
    font-size: 1.4rem;
    font-weight: 400;
    margin-bottom: 30px;
    color: #8b949e;
}

/* Button */
.hero a {
    background: #238636;
    color: #fff;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 6px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.hero a:hover {
    background: #2ea043;
    transform: translateY(-2px);
}

.servis-Container {
    max-width: 1100px;
    margin: 80px auto;
    padding: 20px;
    text-align: center;
}

.servis-Container h2 {
    font-size: 2.2rem;
    margin-bottom: 50px;
    color: #f0f6fc; /* almost white */
    font-weight: 700;
    border-bottom: 2px solid #238636; /* green accent */
    display: inline-block;
    padding-bottom: 10px;
}

/* Grid layout for services */
.service {
    background: #161b22; /* Dark card background */
    border: 1px solid #30363d; /* subtle border like GitHub */
    border-radius: 10px;
    padding: 25px;
    margin: 15px;
    text-align: left;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    color: #c9d1d9;
}

.service h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: #f0f6fc;
    text-align: center;
}

.service p {
    font-size: 1rem;
    line-height: 1.6;
    color: #8b949e; /* muted gray like GitHub subtitles */
}

/* Hover effect */
.service:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
    border-color: #238636; /* green glow on hover */
}
/* ─────────────── Projects Overview ─────────────── */
.projects-overview {
  max-width: 1100px;
  margin: 60px auto;
  padding: 20px;
}

.projects-overview h2 {
  font-size: 1.8rem;
  font-weight: 600;
  color: #1f2328;
  border-bottom: 2px solid #d0d7de;
  padding-bottom: 10px;
  margin-bottom: 30px;
  text-align: center;
}

/* ─────────────── Project Cards ─────────────── */
.projects-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.project-card {
  background-color: #ffffff;
  border: 1px solid #d0d7de;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(27, 31, 35, 0.04);
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.project-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(27, 31, 35, 0.15);
  border-color: #0969da;
}

.project-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-bottom: 1px solid #d0d7de;
}

.project-card h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 15px 15px 10px;
  color: #1f2328;
}

.project-card p {
  font-size: 0.95rem;
  color: #57606a;
  margin: 0 15px 15px;
  line-height: 1.6;
  flex-grow: 1;
}

.project-card a {
  display: block;
  background-color: #0969da;
  color: #ffffff;
  text-align: center;
  padding: 10px 0;
  font-weight: 600;
  text-decoration: none;
  border-top: 1px solid #d0d7de;
  transition: background-color 0.2s ease;
}

.project-card a:hover {
  background-color: #0550ae;
}

/* ─────────────── Projects Overview ─────────────── */
.projects-overview {
  max-width: 1100px;
  margin: 60px auto;
  padding: 20px;
}

.projects-overview h2 {
  font-size: 1.8rem;
  font-weight: 600;
  color: #1f2328;
  border-bottom: 2px solid #d0d7de;
  padding-bottom: 10px;
  margin-bottom: 30px;
  text-align: center;
}

/* ─────────────── Project Cards ─────────────── */
.projects-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.project-card {
  background-color: #ffffff;
  border: 1px solid #d0d7de;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(27, 31, 35, 0.04);
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.project-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(27, 31, 35, 0.15);
  border-color: #0969da;
}

.project-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-bottom: 1px solid #d0d7de;
}

.project-card h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 15px 15px 10px;
  color: #1f2328;
}

.project-card p {
  font-size: 0.95rem;
  color: #57606a;
  margin: 0 15px 15px;
  line-height: 1.6;
  flex-grow: 1;
}

.project-card a {
  display: block;
  background-color: #0969da;
  color: #ffffff;
  text-align: center;
  padding: 10px 0;
  font-weight: 600;
  text-decoration: none;
  border-top: 1px solid #d0d7de;
  transition: background-color 0.2s ease;
}

.project-card a:hover {
  background-color: #0550ae;
}

/* ─────────────── Modal Preview ─────────────── */
.project-modal {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(3px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 999;
  padding: 20px;
}

.project-modal.active {
  display: flex;
  animation: fadeIn 0.2s ease-in-out;
}

.project-modal-content {
  background-color: #fff;
  border-radius: 10px;
  max-width: 700px;
  width: 100%;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
  position: relative;
  animation: slideUp 0.25s ease;
  height: 90vh;
}

.project-modal img {
  width: auto;
  height: auto;
  max-height: 300px;
  max-width: 300px;
  display: block;
  margin: auto;
  padding: 5px;
  border-radius: 6px;
}

.project-modal h3 {
  font-size: 1.4rem;
  margin: 15px;
  color: #1f2328;
}

.project-modal p {
  font-size: 1rem;
  color: #57606a;
  margin: 0 15px 20px;
  line-height: 1.7;
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 22px;
  color: #555;
  cursor: pointer;
  transition: 0.2s;
}

.modal-close:hover {
  color: #0969da;
}

/* ─────────────── Project Counter Section ─────────────── */
.projects-counter {
  max-width: 700px;
  margin: 60px auto;
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 30px;
  flex-wrap: wrap;
}

.counter-box {
  background-color: #ffffff;
  border: 1px solid #d0d7de;
  border-radius: 10px;
  padding: 25px 35px;
  text-align: center;
  box-shadow: 0 1px 2px rgba(27, 31, 35, 0.04);
  transition: all 0.25s ease;
  min-width: 250px;
  width: 10%;
  flex: 1;
}

.counter-box:hover {
  transform: translateY(-4px);
  border-color: #0969da;
  box-shadow: 0 4px 14px rgba(27, 31, 35, 0.12);
}

.counter-box h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #1f2328;
  margin-bottom: 10px;
}

.counter-box .count {
  display: block;
  font-size: 2.5rem;
  font-weight: 700;
  color: #0969da;
  animation: fadeInCount 0.5s ease-in-out forwards;
}

/* === Arixo Summary Section === */
.arixo-summary-section {
  text-align: center;
  margin: 80px 0 50px;
  padding: 40px 10%;
  background: linear-gradient(135deg, #f8f9fb, #eef1f5);
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.arixo-summary-section:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.1);
}

.arixo-summary-section h2 {
  font-family: "Vazirmatn", sans-serif;
  color: #1f2937;
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.arixo-summary-section p {
  color: #4b5563;
  font-size: 1rem;
  margin-bottom: 20px;
  line-height: 1.8;
}

.contact-sales-btn {
  display: inline-block;
  background: linear-gradient(135deg, #0078d7, #005ea6);
  color: #fff;
  padding: 12px 28px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(0, 120, 215, 0.4);
  transition: background 0.3s ease, transform 0.2s ease;
}

.contact-sales-btn:hover {
  background: linear-gradient(135deg, #1089ff, #006fd1);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0, 120, 215, 0.5);
}
/* === Arixo CTA Section === */
.arixo-cta-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  color: #fff;
  padding: 70px 10%;
  border-radius: 18px;
  margin: 80px auto;
  max-width: 1200px;
  overflow: hidden;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease;
}

/* --- Scroll animation trigger --- */
.arixo-cta-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.cta-text {
  flex: 1;
}

.cta-text h2 {
  font-family: "Vazirmatn", sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 15px;
  color: #ffcc66;
}

.cta-text p {
  color: #ddd;
  line-height: 1.9;
  font-size: 1rem;
  margin-bottom: 25px;
}

.cta-btn {
  background: linear-gradient(135deg, #ffcc66, #ffb84d);
  color: #1e1e2e;
  padding: 12px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(255, 204, 102, 0.3);
  transition: all 0.3s ease;
}

.cta-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(255, 204, 102, 0.4);
  background: linear-gradient(135deg, #ffd87d, #ffc14d);
}

/* --- Image side --- */
.cta-image {
  flex: 1;
  text-align: center;
}

.cta-image img {
  width: 100%;
  max-width: 420px;
  border-radius: 12px;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.4));
  transition: transform 0.4s ease;
}

.cta-image img:hover {
  transform: scale(1.03);
}

/* === Footer Section (Arixo Style) === */
.footer {
  margin-top: 70px;
  background: linear-gradient(135deg, #1e1e2e, #2c2c3a);
  color: #f2f2f2;
  font-family: "Vazirmatn", sans-serif;
  direction: rtl;
  border-top: 2px solid #444;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.3);
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 40px;
  padding: 50px 10%;
  box-sizing: border-box;
}

.footer-section h4 {
  font-size: 1.2rem;
  font-weight: 600;
  color: #ffcc66;
  margin-bottom: 12px;
  position: relative;
}

.footer-section h4::after {
  content: "";
  position: absolute;
  bottom: -5px;
  right: 0;
  width: 40px;
  height: 2px;
  background: #ffcc66;
  border-radius: 10px;
}

.footer-section p {
  color: #ccc;
  line-height: 1.9;
  font-size: 0.95rem;
  margin: 0;
}

.footer-section a {
  color: #ffcc66;
  text-decoration: none;
  transition: 0.2s ease;
}

.footer-section a:hover {
  color: #ffe09e;
  text-shadow: 0 0 8px rgba(255, 204, 102, 0.4);
}

/* === Bottom Footer === */
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  padding: 15px 5%;
  font-size: 0.9rem;
  color: #aaa;
  background: rgba(0, 0, 0, 0.2);
}

.footer-bottom p {
  margin: 0;
}

/* ─────────────── Animations ─────────────── */
@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes slideUp {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeInCount {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes LoadingA{
    to {
        transform: scale(40);
    }
}

@keyframes load {
    0%{
    }
    50%{
        opacity: 1;
    }
    100%{
        opacity: 0;
    }
}

/* Tablet */
@media (max-width: 1024px) {
    .main-container {
        flex-direction: column;
        align-items: center;
        background-image: inherit;
    }
    .Project-Containers {
        width: 80%;
    }
    .reagon-div{
        opacity: 0;
    }
}

/* Mobile */
@media (max-width: 600px) {
    .landing-container {
        background-size: 80% auto;
        padding: 20px;
        text-align: center;
    }
    .reagon-div{
        opacity: 0;
    }
    .main-container {
        flex-direction: column;
        background-image: inherit;
    }
    .Project-Containers {
        width: 95%;
    }
    [class^="item-Container-"] img {
        max-width: 200px;
    }
}

/* Responsiveness */
@media (max-width: 768px) {
    .hero {
        padding: 50px 20px;
    }
    .hero h1 {
        font-size: 2rem;
    }
    .hero h2 {
        font-size: 1.1rem;
    }
    .hero a {
        font-size: 0.9rem;
        padding: 10px 20px;
    }
}


/* Responsive grid */
@media (min-width: 768px) {
    .servis-Container {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        text-align: left;
    }

    .servis-Container h2 {
        grid-column: span 2; /* title spans across columns */
        text-align: center;
    }
}

@media (min-width: 1024px) {
    .servis-Container {
        grid-template-columns: repeat(4, 1fr); /* 4 columns on desktop */
    }

    .servis-Container h2 {
        grid-column: span 4;
    }
}

/* ─────────────── Responsive ─────────────── */
@media (max-width: 768px) {
  .projects-overview {
    padding: 10px;
  }

  .projects-list {
    grid-template-columns: 1fr;
  }

  .project-card img {
    height: 140px;
  }

  .project-modal-content {
    max-width: 95%;
  }
}

/* ─────────────── Dark Mode (GitHub Style) ─────────────── */
@media (prefers-color-scheme: dark) {
  .projects-overview h2 {
    color: #c9d1d9;
    border-bottom-color: #30363d;
  }

  .project-card {
    background-color: #161b22;
    border-color: #30363d;
    box-shadow: none;
  }

  .project-card:hover {
    border-color: #58a6ff;
    box-shadow: 0 4px 12px rgba(56, 139, 253, 0.2);
  }

  .project-card h3 {
    color: #c9d1d9;
  }

  .project-card p {
    color: #8b949e;
  }

  .project-card a {
    background-color: #238636;
    border-top-color: #30363d;
  }

  .project-card a:hover {
    background-color: #2ea043;
  }

  .project-modal-content {
    background-color: #0d1117;
    color: #c9d1d9;
    border: 1px solid #30363d;
  }

  .project-modal h3 {
    color: #c9d1d9;
  }

  .project-modal p {
    color: #8b949e;
  }

  .modal-close {
    color: #8b949e;
  }

  .modal-close:hover {
    color: #58a6ff;
  }
}

/* ─────────────── Dark Mode (GitHub Style) ─────────────── */
@media (prefers-color-scheme: dark) {
  .counter-box {
    background-color: #161b22;
    border-color: #30363d;
    box-shadow: none;
  }
  .counter-box:hover {
    border-color: #58a6ff;
    box-shadow: 0 4px 12px rgba(56, 139, 253, 0.2);
  }
  .counter-box h3 {
    color: #c9d1d9;
  }
  .counter-box .count {
    color: #58a6ff;
  }
}

/* ─────────────── Responsive ─────────────── */
@media (max-width: 600px) {
  .projects-counter {
    flex-direction: column;
    gap: 20px;
  }
  .counter-box {
    margin:auto;
    padding: 0;
    width: 88%;
  }
}

/* === Responsive Design === */
@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    padding: 40px 6%;
  }

  .footer-section h4::after {
    right: 50%;
    transform: translateX(50%);
  }
}

@media (max-width: 480px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-section h4::after {
    right: 50%;
    transform: translateX(50%);
  }
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .arixo-cta-section {
    flex-direction: column-reverse;
    text-align: center;
    padding: 50px 8%;
  }

  .cta-image img {
    max-width: 320px;
  }
}
