:root {
  --bg-dark: #f3a9a9;
  --accent-red: #E10600;
  --accent-cyan: #9b1d06;
  --text-white: #610403;
  --text-gray: #2f0202;
}

.form-title {
  text-align: center;
}

.reg-form {
    max-width: 80%;
    margin-left: 5em;
    margin-right: 5em;
    background: white;
    padding: 35px 40px;
    border-radius: 16px;
    box-shadow:
        0 10px 30px rgba(180, 0, 0, 0.15);
    border-top: 5px solid #c62828;
}

.reg-form div {
  margin: 0.2em;
}

lebel {
    display: block;
    margin-bottom: 8px;
    color: #7f0000;
    font-weight: bold;
}

input:focus,
textarea:focus {
  outline: none;
  border-color: #c62828;
  box-shadow:
    0 0 0 3px rgba(198, 40, 40, 0.15);
}

/* Submit button */
.sub-but {
  width: 100%;
  margin-top: 10px;
  border:#2f0202;
  background: #c62828;
  color: white;
  cursor: pointer;
  transition: background 0.2s;
  font-family: 'Vazirmatn';
  font-size: 1.1em;
  border-radius: 0.5em;
  padding:0.6em 2.2em;
}

button:hover {
  background: #8e0000;
}

input,
textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 12px;
    font-size: 1rem;
    border: 1px solid #e57373;
    border-radius: 8px;
    background: #fffafa;
    transition: border-color 0.2s, box-shadow 0.2s;
}

* {
  box-sizing: border-box;
  margin: 0;
}

body {
--bg-light: #F6F8FA;
  color: var(--text-white);
  font-family: 'Vazirmatn', sans-serif;
  font-size: 20px;   /* ⬅ increase base size (try 18–20px) */
  font-weight: 400;
  overflow-x: hidden; /* prevents mobile overflow */
}

/* Fonts */
@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/webfonts/Vazirmatn-Regular.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

body, p, li, a, h1, h2, h3 {
    font-family: 'Vazirmatn', sans-serif;
}

a {
    text-decoration: none;
}

/* Header */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: var(--bg-dark);
  border-bottom: 1px solid var(--accent-red);
  z-index: 999;
}

/* 1. The CONTAINER handles the fixed positioning and centering */
.logo {
  position: fixed;      /* Moved here */
  top: 3.5em;
  left: 50%;
  transform: translateX(-50%); /* Centering lives here permanently */
  z-index: 999;          /* Keeps it above other content */
}

/* 2. The IMAGE only handles the throb animation */
.logo img {
  display: block;
  height: 90px;
  width: auto;
  opacity: 0.85;
  transition: opacity 0.3s ease;
  /* Only scale is animated here */
  animation: logoThrob 2s infinite ease-in-out;
  filter:
    drop-shadow(0 0 6px var(--accent-red))
    drop-shadow(0 0 12px var(--accent-red));
}

/* 3. Clean keyframes - no centering logic needed */
@keyframes logoThrob {
  0%, 100% { 
    transform: scale(1); 
  }
  50% { 
    transform: scale(1.1); 
  }
}

.listBullet {
  color: rgb(255, 241, 241);
  list-style: none;
  padding: 0;
  margin: 0; 
  display: flex;
  flex-direction: column;
  gap: 0.75rem;          /* space between boxes */
  max-width: 500px;
}

.listBullet li {
  background: #d91515;
  padding: 1rem 1.25rem;
  border-radius: 10px;
  border: 1px solid #f02727;
  box-shadow: 0 2px 4px red;
}

.registration-button {
  color: rgb(240, 154, 120);
  background: #930c0c;
  padding: 1rem 1.25rem;
  border-radius: 10px;
  border: 1px solid #f02727;
  box-shadow: 0 2px 4px rgba(188, 17, 17, 0.04);
}

.ea-content img {
  max-width: 100%;
  width: 100%;
  height: auto;
  display: block;
  box-shadow: none;
  filter: none;
  border: none;
}

.text-list {
  list-style-type: disc;
  padding-right: 1.2rem; /* RTL-safe spacing */
  margin: 1rem 0;
}

.text-list li {
  margin-bottom: 0.5rem;
  line-height: 1.8;
  color: #2b2b2b;
}


@keyframes logoThrob {
  0%,100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

/* Menu wrapper */
.menu-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

/* Nav desktop */
.nav {
  display: flex;
  gap: 1.5rem;
}

.nav a {
  color: var(--accent-red);
  text-decoration: none;
  font-size: 0.91rem;
  font-weight: 600;
  padding: 0.1rem 0.1rem;
  border-radius: 8px; /* smooth corners */
  transition: background-color 0.3s, color 0.3s, text-shadow 0.3s;
}

.nav a:hover {
  background-color: rgba(225, 6, 0, 0.2); /* semi-transparent red background */
  color: var(--text-gray); /* optional, can stay red if preferred */
  text-shadow: 0 0 6px var(--accent-red);
}

/* Burger */
.burger {
  display: none;
  font-size: 2rem;
  color: var(--accent-red);
  cursor: pointer;
  font-size: 1.1rem;   /* ⬅ bigger menu text */
}

.burger-toggle {
  display: none;
}

/* Mobile */
@media (max-width: 768px) {

  .burger {
    display: block;
  }

  .nav {
    display: none;
    position: absolute;

    /* FIX: anchor to burger, not viewport */
    left: 0;
    top: calc(100% + 0.5rem);

    flex-direction: column;
    background: #F6F8FA;
    padding: 1rem 1.25rem;

    border: 1px solid var(--accent-red);
    border-radius: 12px;

    box-shadow:
      0 0 15px rgba(225,6,0,0,0.7),
      0 0 30px rgba(225,6,0,0,0.4);

    min-width: 240px;
    max-width: calc(100vw - 2rem); /* viewport safe */
  }
  
  .nav a {
    font-size: 1.25rem;
  }
  
  #burger-toggle:checked + .burger + .nav {
    display: flex;
  }
}

/* Hero */
.hero {
  padding: 8rem 2rem 2rem 2em;
}

.hero h1 {
  color: var(--accent-red);
  margin-bottom: 1rem;
  font-size: clamp(2rem, 2vw, 3rem);
  font-weight: 900;
}

.hero p {
  color: var(--accent-cyan);
  margin-bottom: 2rem;
  font-size: 1.2rem;
}

.cta-button {
  padding: 0.8rem 2rem;
  border: 2px solid var(--accent-red);
  color: var(--accent-red);
  background: none;
}

/* Services */
.services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  padding: 2rem;
}

.card {
  position: relative;
  color: #fff; /* Ensure text is readable */
  background: #F6F8FA;
  padding: 1.5rem;
  border-radius: 8px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 200px; /* optional, adjust as needed */
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  border-right: 4px solid var(--accent-red);
  background-size: 50%; /* Makes image smaller than the card */
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
  text-align: center;
}

.card.card-java::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 50%;
  background-image: url("../images/java.png");
  background-position: center;
  transform: translate(50%, 50%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  background-position: center; /* center the image */
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-java * {
  position: relative;
  z-index: 1;
}

.card.card-js::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 50%;
  background-image: url("../images/JavaScript.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(50%, 50%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-js * {
  position: relative;
  z-index: 1;
}

.card.card-threejs::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 75%;
  height: 75%;
  background-image: url("../images/threejs.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(20%, 20%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-threejs * {
  position: relative;
  z-index: 1;
}

.card.card-strategy::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("../images/digital_strategy.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(0%, 0%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-strategy * {
  position: relative;
  z-index: 1;
}

.card.card-businessmodel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("../images/business_model_canvas.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(0%, 0%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-businessmodel * {
  position: relative;
  z-index: 1;
}

.card.card-togaf::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 70%;
  height: 70%;
  background-image: url("../images/togaf_adm.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(20%, 20%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-togaf * {
  position: relative;
  z-index: 1;
}

.card.card-archimate::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 80%;
  height: 80%;
  background-image: url("../images/archimate.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(15%, 15%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-archimate * {
  position: relative;
  z-index: 1;
}

.card.card-english::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 82%;
  height: 82%;
  background-image: url("../images/english_infotech.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(12%, 10%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-englishe * {
  position: relative;
  z-index: 1;
}

.card.card-it::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("../images/it_training.png");
  background-size: cover;      /* cover the card */
  background-position: center;
  transform: translate(0%, 0%); /* centers the element exactly */
  background-size: contain;      /* cover the card */
  background-repeat: no-repeat;
  opacity: 0.4;                /* image transparency */
  z-index: 0;                  /* behind text */
}

.card.card-it * {
  position: relative;
  z-index: 1;
}

.card h3 {
  color: var(--accent-red);
  font-size: 1.4rem;
  font-weight: 700;
}

.card p {
  color: var(--text-gray);
  font-size: 1.05rem;
  font-weight: 400;
}

/* Footer */
.footer {
  background-color: var(--bg-dark);
  color: var(--accent-red);
  padding: 2.5rem 2rem;
  text-align: center;
  border-top: 2px solid var(--accent-red);
}

.footer-content {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-section h4 {
  font-family: 'Vazirmatn', sans-serif;
  color: var(--accent-red);
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  text-shadow: 0 0 5px var(--accent-red);
}

.footer-section p {
  font-family: 'Vazirmatn', sans-serif;
  color: var(--text-gray);
  font-size: 1rem;
  line-height: 1.5;
}

/* Footer copy */
.footer-copy {
  width: 100%;
  text-align: center;
  margin-top: 1.5rem;
  color: var(--text-gray);
  font-size: 0.95rem;
}

/* Responsive */
@media (max-width: 768px) {
  .footer-content {
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
  }

  .footer-section {
    text-align: center;
  }
}
/* Prevent mobile menu overlay persistence */
.menu-wrapper label nav {
  cursor: pointer;
}

/* Ensure content always above closed menu */
main {
  position: relative;
  z-index: 1;
}

/* SVG */
svg {
  width: 700px;
  height: 90px; 
}

.neon {
  fill: none;
  stroke: #a50b0d;;
  stroke-width: 2.2;
  filter: drop-shadow(0 0 6px #f44568);
}

@keyframes move {
  to {
    stroke-dashoffset: -100;
  }
}

/* Mobile menu z-index only when open */
@media (max-width: 768px) {
  .nav {
    z-index: 1000;
  }

  #burger-toggle:not(:checked) + .burger + label .nav {
    display: none;
  }
}

/* ===============================
   Enterprise Architecture Content
   =============================== */
.content {
  padding-top: 6rem;
}

.ea-content {
  max-width: 1100px;
  margin: 0 auto;
  padding: 6rem 2rem 4rem;
  line-height: 2.1;
  font-size: 1.15rem;
}

/* Headings */
.ea-content h1 {
  font-size: 3rem;
  color: var(--accent-red);
  margin-bottom: 1.5rem;
}

.ea-content h2 {
  font-size: 2rem;
  color: var(--accent-red);
  margin: 3rem 0 1rem;
  border-right: 4px solid var(--accent-red);
  padding-right: 1rem;
}

/* Paragraphs */
.ea-content p {
  color: #2b2b2b;
  margin-bottom: 1.4rem;
  text-align: justify;
}

/* Section spacing */
.ea-content section {
  margin-bottom: 3rem;
}

/* Header intro text */
.ea-content > header p {
  font-size: 1.15rem;
  color: #1f2933;
}

/* Footer note */
.ea-content footer {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(225, 6, 0, 0.3);
}

.ea-content footer p {
  font-size: 1.1rem;
  color: #374151;
}

/* Responsive tuning */
@media (max-width: 768px) {
  .ea-content {
    padding: 5rem 1.5rem 3rem;
    font-size: 1.05rem;
  }

  .ea-content h1 {
    font-size: 2.3rem;
  }

  .ea-content h2 {
    font-size: 1.6rem;
  }
}

/* Tooltip for technical terms */
.term {
  position: relative;
  cursor: help;
  border-bottom: 1px dotted var(--accent-red);
}

/* Tooltip bubble */
.term::after {
  content: attr(data-tooltip);
  position: absolute;
  top: -20%;
  left: -100%;
  transform: translateX(50%);

  background: #c21919;
  color: #fff7f7;

  margin-left: 1rem;
  padding-left: 1rem;
  padding-top: 2rem;
  padding-bottom: 2rem;
  padding-right: 1rem;
  font-size: 0.8rem;
  line-height: 1.4;

  border-radius: 6px;
  white-space: normal;

  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;

  z-index: 9999;
}

/* Tooltip arrow */
.term::before {
  content: "";
  position: absolute;
  bottom: 135%;
  right: 50%;
  left: 50%;
  transform: translateX(50%);

  border-width: 6px;
  border-style: solid;
  border-color: #1a1a1a transparent transparent transparent;

  opacity: 0;
  transition: opacity 0.25s ease;
  z-index: 9999;
}

/* Hover */
.term:hover::after,
.term:hover::before {
  opacity: 1;
}

.hero,
.ea-content,
section {
  overflow: visible;
}

/* IFRAME */
iframe {
  display:block;
  width: 1230px;
  height: 480px; 
  margin: 0 auto;
  border: none;
}

/* ============== GOTOTOP ============== */
.toTop {
	opacity: 0;
	position: fixed;
	bottom: 4em;
	left: 4em;
	display: none;
	transform: scale(.5);
	transition: transform 200ms 50ms;
}

.wrapper:hover .toTop,
body:hover .toTop,
div#footer2:hover .toTop {
	opacity: .2;
	bottom: 4em;
	left: 4em;
	animation: 3s cubic-bezier(.075, .82, .165, 1) 50ms 1 forwards top-anime;
}

@keyframes top-anime {
	from {
		opacity: .2;
		transform: scale(.5) rotateY(0);
	}

	to {
		opacity: .8;
		filter: drop-shadow(0 0 1px firebrick) drop-shadow(.3em .3em 2px darkred);
		transform: scale(1) rotateY(1turn);
	}
}

/* ============================================
   POPUP STYLES — Red Theme, RTL, Responsive
   Auto-shows on load, scrolls if too tall
   ============================================ */

/* Reset / base */
* {
  box-sizing: border-box;
}

/* Hidden checkbox that powers the popup state */
.popup-toggle {
  display: none;
}

/* --- Popup backdrop --- */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(44, 8, 8, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 1000;
  padding: 16px;
}

/* Show popup when checkbox is checked */
.popup-toggle:checked ~ .popup-overlay {
  opacity: 1;
  visibility: visible;
}

/* --- The popup box --- */
.popup-box {
  background: linear-gradient(180deg, #fff5f5 0%, #ffeaea 100%);
  border: 1px solid #e3b5b5;
  border-radius: 16px;
  box-shadow:
    0 20px 60px rgba(140, 30, 30, 0.25),
    0 4px 12px rgba(140, 30, 30, 0.1);
  width: 100%;
  max-width: 520px;
  max-height: calc(100vh - 32px);   /* never taller than screen */
  display: flex;
  flex-direction: column;
  position: relative;
  transform: translateY(12px) scale(0.98);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  line-height: 1.9;
  color: #4a1a1a;
  font-family: system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
}

.popup-toggle:checked ~ .popup-overlay .popup-box {
  transform: translateY(0) scale(1);
}

/* --- Scrollable content area --- */
.popup-content {
  overflow-y: auto;
  padding: 28px 32px;
  /* Smooth scrolling for iOS */
  -webkit-overflow-scrolling: touch;
}

/* --- Close button (X) --- */
.popup-close {
  position: absolute;
  top: 12px;
  left: 12px;               /* visual left in RTL */
  width: 36px;
  height: 36px;
  background: #f3d4d4;
  color: #8b2e2e;
  border-radius: 50%;
  text-decoration: none;
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 300;
  line-height: 1;
  cursor: pointer;
  z-index: 10;
  flex-shrink: 0;
  transition: background 0.2s, transform 0.2s;
}

.popup-close:hover {
  background: #e8b4b4;
  transform: rotate(90deg);
}

/* --- Typography --- */
.popup-box h2 {
  margin: 0 0 18px 0;
  font-size: 1.35rem;
  color: #922b21;
  font-weight: 700;
}

.popup-box p {
  margin: 0 0 16px 0;
  font-size: 1.05rem;
}

.popup-box p:last-child {
  margin-bottom: 0;
}

/* --- Top accent bar --- */
.popup-accent {
  position: absolute;
  top: 0;
  right: 36px;
  left: 36px;
  height: 4px;
  background: #e74c3c;
  border-radius: 0 0 4px 4px;
  opacity: 0.8;
  pointer-events: none;
}

/* ============================================
   MOBILE ADJUSTMENTS
   ============================================ */
@media (max-width: 480px) {
  .popup-overlay {
    padding: 12px;
    align-items: flex-end;      /* anchor to bottom on small screens */
  }

  .popup-box {
    max-height: calc(100vh - 24px);
    border-radius: 14px;
  }

  .popup-content {
    padding: 24px 20px;
  }

  .popup-box h2 {
    font-size: 1.15rem;
    padding-left: 44px;         /* make room for the X */
  }

  .popup-box p {
    font-size: 0.95rem;
    line-height: 1.85;
  }

  .popup-close {
    top: 10px;
    left: 10px;
  }
}