:root {
  --bg: #0b1220;
  --bg-soft: #121b2e;
  --card: rgba(18, 27, 46, 0.72);
  --text: #eef2ff;
  --muted: #b7c3e0;
  --brand: #6d8dff;
  --brand-2: #53e0c2;
  --accent: #ff7edb;
  --border: rgba(255, 255, 255, 0.14);
  --shadow: 0 20px 40px rgba(8, 12, 22, 0.45);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  font-family: "Inter", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text);
  background: radial-gradient(circle at 10% 20%, #172340 0%, var(--bg) 45%, #080d18 100%);
  min-height: 100%;
  scroll-behavior: smooth;
}

html[dir="rtl"] body {
  direction: rtl;
  text-align: right;
}

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

.container {
  width: min(1140px, 92%);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(16px);
  background: linear-gradient(120deg, rgba(6, 11, 20, 0.88), rgba(18, 27, 46, 0.72));
  border-bottom: 1px solid rgba(109, 141, 255, 0.28);
  box-shadow: 0 10px 28px rgba(4, 8, 16, 0.45);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border: 1px solid rgba(109, 141, 255, 0.4);
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  font-size: 1.25rem;
  cursor: pointer;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 82px;
  gap: 18px;
}

.logo {
  position: relative;
  padding: 10px 16px;
  border: 1px solid rgba(109, 141, 255, 0.35);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  font-weight: 800;
  letter-spacing: 0.3px;
  font-size: 1.06rem;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.logo::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(120deg, rgba(109, 141, 255, 0.4), rgba(83, 224, 194, 0.3));
  filter: blur(10px);
  opacity: 0.55;
  z-index: -1;
}

.logo span {
  background: linear-gradient(120deg, var(--brand), var(--brand-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.logo:hover {
  transform: translateY(-1px);
  border-color: rgba(109, 141, 255, 0.65);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
}

.nav a {
  padding: 9px 13px;
  border-radius: 999px;
  color: var(--muted);
  border: 1px solid transparent;
  transition: 0.25s ease;
}

.nav a:hover,
.nav a.active {
  color: #fff;
  border-color: rgba(109, 141, 255, 0.35);
  background: linear-gradient(120deg, rgba(109, 141, 255, 0.3), rgba(83, 224, 194, 0.22));
}

.hero {
  padding: 72px 0 48px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 22px;
  align-items: center;
}

.hero h1 {
  margin: 0 0 16px;
  font-size: clamp(2rem, 4vw, 3.3rem);
  line-height: 1.15;
}

.hero p {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: 1.04rem;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.cta-row--center {
  justify-content: center;
  width: 100%;
}

.btn {
  border: 1px solid var(--border);
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: 600;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand), #4fcbf4);
  color: #fff;
  border: none;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.03);
}

.glass-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-card {
  padding: 20px;
  animation: floatY 4.5s ease-in-out infinite;
}

.hero-card h3 {
  margin-top: 0;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.stat {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 12px;
}

.stat strong {
  display: block;
  font-size: 1.3rem;
}

.section {
  padding: 24px 0 58px;
}

.section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.section h2 {
  margin: 0;
  font-size: clamp(1.45rem, 2.4vw, 2rem);
}

.course-grid,
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.course-card {
  padding: 18px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.course-card__media {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-soft);
  border: 1px solid rgba(255, 255, 255, 0.08);
  align-self: center;
  margin-bottom: 12px;
}

.course-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.course-card__body {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.course-card__body .btn {
  margin-top: auto;
}

.blog-card {
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.blog-card__media {
  aspect-ratio: 1 / 1;
  width: 100%;
  flex-shrink: 0;
  background: var(--bg-soft);
}

.blog-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.blog-card__body {
  padding: 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.blog-card__body .btn {
  margin-top: auto;
}

.course-card:hover,
.blog-card:hover {
  transform: translateY(-4px);
  border-color: rgba(109, 141, 255, 0.65);
}

.course-card h3,
.blog-card h3 {
  margin-top: 6px;
  margin-bottom: 10px;
}

.muted {
  color: var(--muted);
}

.tag {
  font-size: 0.78rem;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: var(--brand-2);
}

.page-head {
  padding: 54px 0 26px;
}

.page-head h1 {
  margin: 0 0 8px;
}

.button-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.part-btn {
  min-height: 58px;
  font-size: 0.95rem;
  background: linear-gradient(125deg, rgba(109, 141, 255, 0.16), rgba(83, 224, 194, 0.12));
}

.part-btn:hover {
  background: linear-gradient(125deg, rgba(109, 141, 255, 0.33), rgba(83, 224, 194, 0.2));
}

.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 36px;
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 20px 0 34px;
  color: var(--muted);
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.article-wrap {
  width: min(760px, 94%);
  margin: 0 auto;
}

.social-post {
  padding: 20px;
}

.post-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
  margin-bottom: 14px;
}

.author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--accent));
}

.author-meta strong {
  display: block;
  font-size: 0.98rem;
}

.author-meta span {
  color: var(--muted);
  font-size: 0.85rem;
}

.post-content h2 {
  margin: 0 0 8px;
}

.post-content p {
  color: #e6edff;
  line-height: 1.7;
}

.post-highlight {
  border-right: 3px solid var(--brand-2);
  border-left: none;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  margin: 14px 0;
}

.post-stats {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 10px 0;
  margin: 16px 0 10px;
  font-size: 0.92rem;
}

.post-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.action-btn {
  text-align: center;
  padding: 10px;
  border-radius: 10px;
  color: var(--muted);
  border: 1px solid transparent;
  transition: 0.25s ease;
}

.action-btn:hover {
  color: #fff;
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.04);
}

.comment-list {
  margin-top: 18px;
  display: grid;
  gap: 10px;
}

.comment {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 10px 12px;
}

.comment strong {
  display: block;
  margin-bottom: 4px;
}

.contact-split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 18px;
  align-items: start;
}

.profile-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at top left, rgba(83, 224, 194, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    var(--card);
}

.profile-card__media-wrap {
  position: relative;
  padding: 18px 18px 0;
}

.profile-card__media {
  width: 100%;
  min-height: 420px;
  display: grid;
  place-items: center;
  padding: 18px;
  background:
    linear-gradient(145deg, rgba(109, 141, 255, 0.14), rgba(83, 224, 194, 0.08)),
    rgba(8, 13, 24, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 22px;
}

.profile-card__media img {
  width: 100%;
  height: 100%;
  max-height: 380px;
  object-fit: contain;
  display: block;
}

.profile-card__badge {
  position: absolute;
  right: 30px;
  bottom: -12px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(135deg, rgba(109, 141, 255, 0.92), rgba(83, 224, 194, 0.82));
  color: #fff;
  font-weight: 700;
  box-shadow: 0 10px 26px rgba(10, 18, 35, 0.35);
}

.profile-card__body {
  padding: 28px 20px 20px;
}

.profile-card__desc {
  margin: 12px 0 0;
  line-height: 1.7;
}

.profile-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.profile-highlights span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #f3f6ff;
  font-size: 0.9rem;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.profile-stat {
  padding: 14px 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.profile-stat strong {
  display: block;
  margin-bottom: 4px;
  font-size: 1rem;
  color: #fff;
}

.profile-stat span {
  color: var(--muted);
  font-size: 0.85rem;
}

.team-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.team-card {
  padding: 16px;
}

.team-card__head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

.contact-form {
  padding: 22px;
  background:
    radial-gradient(circle at top right, rgba(109, 141, 255, 0.16), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.025)),
    var(--card);
}

.contact-form__top {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 16px;
  align-items: stretch;
  margin-bottom: 18px;
}

.contact-form__intro,
.contact-details {
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.035);
}

.contact-form__intro {
  padding: 22px;
}

.contact-form__intro h3 {
  margin: 10px 0 10px;
  font-size: clamp(1.35rem, 2.2vw, 1.9rem);
  line-height: 1.25;
}

.contact-form__intro p {
  margin: 0;
  line-height: 1.75;
}

.contact-details {
  padding: 14px;
  display: grid;
  gap: 12px;
}

.contact-detail {
  padding: 14px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(109, 141, 255, 0.12), rgba(83, 224, 194, 0.08));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.contact-detail strong {
  display: block;
  margin-bottom: 6px;
  color: #fff;
  font-size: 0.96rem;
}

.contact-detail span {
  color: var(--muted);
  line-height: 1.6;
}

.contact-form__body {
  padding: 20px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(8, 13, 24, 0.34);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.field {
  display: grid;
  gap: 9px;
}

.field span {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
}

.field--full {
  grid-column: 1 / -1;
}

input,
textarea {
  width: 100%;
  padding: 14px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  outline: none;
  font-family: inherit;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

textarea {
  resize: vertical;
  min-height: 150px;
}

input::placeholder,
textarea::placeholder {
  color: rgba(183, 195, 224, 0.7);
}

input:focus,
textarea:focus {
  border-color: rgba(109, 141, 255, 0.55);
  box-shadow: 0 0 0 3px rgba(109, 141, 255, 0.12);
  background: rgba(255, 255, 255, 0.065);
  transform: translateY(-1px);
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}

.form-note {
  margin: 14px 0 0;
  font-size: 0.9rem;
}

@keyframes floatY {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@media (max-width: 980px) {
  .hero-grid,
  .course-grid,
  .blog-grid {
    grid-template-columns: 1fr 1fr;
  }

  .contact-split {
    grid-template-columns: 1fr;
  }

  .contact-form__top {
    grid-template-columns: 1fr;
  }

  .profile-card__media {
    min-height: 360px;
  }

  .profile-stats {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .button-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .nav-wrap {
    min-height: 74px;
    position: relative;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    border-radius: 16px;
    padding: 10px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    background: rgba(13, 20, 35, 0.96);
    border: 1px solid rgba(109, 141, 255, 0.34);
  }

  .site-header.nav-open .nav {
    display: flex;
  }

  .nav a {
    text-align: center;
  }

  .hero {
    padding-top: 46px;
  }

  .hero-grid,
  .course-grid,
  .blog-grid,
  .button-grid {
    grid-template-columns: 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .contact-form {
    padding: 16px;
  }

  .contact-form__intro,
  .contact-form__body {
    padding: 16px;
  }

  .profile-card__media-wrap {
    padding: 14px 14px 0;
  }

  .profile-card__media {
    min-height: 300px;
    padding: 12px;
  }

  .profile-card__media img {
    max-height: 280px;
  }

  .profile-card__badge {
    right: 24px;
  }

  .profile-stats {
    grid-template-columns: 1fr;
  }

}
