:root {
  --bg: #060B14;
  --panel: rgba(8, 17, 31, 0.92);
  --text: #f8fbff;
  --muted: #a9b7cd;
  --accent: #2ea8ff;
  --accent-2: #00e5ff;
  --accent-3: #00b8d9;
  --max-width: 1100px;
  --radius: 20px;
  --shadow: 0 24px 64px rgba(0, 147, 255, 0.18);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html, body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background: radial-gradient(circle at 10% 10%, rgba(46, 168, 255, 0.14), transparent 16%),
    radial-gradient(circle at 85% 15%, rgba(0, 229, 255, 0.1), transparent 18%),
    linear-gradient(180deg, #060B14 0%, #08111F 42%, #0B172A 100%);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -2;
}

body::before {
  background-image:
    radial-gradient(circle at 23% 18%, rgba(46, 168, 255, 0.14), transparent 18%),
    radial-gradient(circle at 82% 12%, rgba(0, 229, 255, 0.1), transparent 18%),
    radial-gradient(circle at 60% 75%, rgba(0, 184, 217, 0.08), transparent 16%);
  opacity: 0.95;
}

body::after {
  background-image:
    linear-gradient(120deg, rgba(46, 168, 255, 0.03) 1px, transparent 1px),
    linear-gradient(60deg, rgba(0, 229, 255, 0.02) 1px, transparent 1px);
  background-size: 120px 120px;
  opacity: 0.18;
  animation: driftGrid 42s linear infinite;
}

@keyframes driftGrid {
  from { background-position: 0 0; }
  to { background-position: 240px 240px; }
}

img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, select, textarea {
  font: inherit;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 28px;
}

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 999;
  width: 100%;
  background: rgba(6, 11, 20, 0.14);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid transparent;
  transition: background 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}

.site-header::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: linear-gradient(90deg, rgba(46, 168, 255, 0), rgba(46, 168, 255, 0.35), rgba(0, 229, 255, 0));
  opacity: 0.7;
}

.site-header.scrolled {
  background: rgba(6, 11, 20, 0.88);
  border-color: rgba(46, 168, 255, 0.14);
  box-shadow: 0 24px 68px rgba(0, 0, 0, 0.28);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.brand-logo {
  height: 46px;
  width: auto;
  display: block;
}

.logo-text {
  display: inline-block;
  line-height: 1.05;
}

.primary-nav {
  margin-left: auto;
}

.primary-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 18px;
}

.primary-nav a {
  position: relative;
  color: var(--muted);
  text-decoration: none;
  padding: 10px 0;
  transition: color 0.25s ease, transform 0.25s ease;
}

.primary-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.primary-nav a:hover,
.primary-nav a.active {
  color: var(--text);
}

.primary-nav a:hover::after,
.primary-nav a.active::after {
  opacity: 1;
  transform: translateY(0);
}

.hero {
  position: relative;
  padding: 120px 0 84px;
  overflow: hidden;
  margin-top: 80px;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.hero::before {
  background: radial-gradient(circle at 20% 25%, rgba(46, 168, 255, 0.18), transparent 18%),
    radial-gradient(circle at 80% 10%, rgba(0, 229, 255, 0.12), transparent 18%),
    radial-gradient(circle at 85% 75%, rgba(0, 184, 217, 0.08), transparent 24%);
  mix-blend-mode: screen;
}

.hero::after {
  background-image: linear-gradient(130deg, rgba(2, 11, 20, 0.3), transparent 35%, rgba(0, 112, 192, 0.18) 100%);
  filter: blur(22px);
  opacity: 0.88;
  animation: pulseGlow 14s ease-in-out infinite alternate;
}

.hero .hero-inner {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.hero h1 {
  font-size: clamp(2rem, 4.2vw, 3.6rem);
  margin: 0 0 18px;
  color: var(--text);
  line-height: 1.03;
  text-shadow: 0 18px 50px rgba(0, 70, 130, 0.18);
}

.lede {
  color: rgba(231, 244, 255, 0.84);
  margin-top: 0;
  font-size: 1.05rem;
  max-width: 680px;
}

@keyframes pulseGlow {
  from { transform: scale(1); opacity: 0.86; }
  to { transform: scale(1.02); opacity: 0.96; }
}

@keyframes iconFloat {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-4px) scale(1.03); }
}

@keyframes iconPulse {
  0%, 100% { opacity: 0.45; transform: scale(0.96); }
  50% { opacity: 0.9; transform: scale(1.03); }
}

@keyframes iconWobble {
  0%, 100% { transform: rotate(0deg) translateY(0); }
  25% { transform: rotate(-4deg) translateY(-2px); }
  75% { transform: rotate(4deg) translateY(2px); }
}

@keyframes iconBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

@keyframes iconGlow {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(143, 231, 255, 0)); text-shadow: none; }
  50% { filter: drop-shadow(0 0 6px rgba(143, 231, 255, 0.7)); text-shadow: 0 0 8px rgba(143, 231, 255, 0.35); }
}

.section-title {
  margin: 0 0 18px;
  color: var(--text);
  font-weight: 700;
  font-size: clamp(1.35rem, 2.1vw, 1.8rem);
  letter-spacing: 0.01em;
}

.services-section,
.courses-section,
.form-section {
  position: relative;
  overflow: hidden;
  padding: 64px 0;
}

.services-section::before,
.courses-section::before,
.form-section::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.44;
  pointer-events: none;
  mix-blend-mode: screen;
}

.services-section::before {
  background-image:
    linear-gradient(120deg, rgba(46, 168, 255, 0.06) 1px, transparent 1px),
    linear-gradient(60deg, rgba(0, 229, 255, 0.05) 1px, transparent 1px),
    radial-gradient(circle at 25% 35%, rgba(46, 168, 255, 0.08), transparent 16%),
    radial-gradient(circle at 78% 15%, rgba(0, 229, 255, 0.06), transparent 18%);
  background-size: 120px 120px, 120px 120px, 430px 430px, 320px 320px;
}

.courses-section::before {
  background-image:
    radial-gradient(circle at 18% 20%, rgba(46, 168, 255, 0.08), transparent 14%),
    radial-gradient(circle at 70% 30%, rgba(0, 229, 255, 0.06), transparent 18%),
    linear-gradient(90deg, rgba(2, 11, 20, 0.34), transparent 38%, rgba(0, 112, 192, 0.18) 100%);
  background-size: 360px 360px, 300px 300px, 100% 100%;
}

.form-section::before {
  background-image:
    radial-gradient(circle at 20% 20%, rgba(46, 168, 255, 0.05), transparent 12%),
    radial-gradient(circle at 80% 30%, rgba(0, 229, 255, 0.04), transparent 15%),
    linear-gradient(120deg, rgba(6, 11, 20, 0.8), rgba(8, 17, 34, 0.72));
  background-size: 320px 320px, 280px 280px, 100% 100%;
}

.services-grid,
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  position: relative;
  z-index: 1;
}

.card,
.courses-card,
.contact-block,
.reg-form {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  box-shadow: var(--shadow);
  transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease, background 0.35s ease;
}

.card:hover,
.courses-card:hover,
.contact-block:hover,
.reg-form:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 229, 255, 0.24);
  box-shadow: 0 30px 80px rgba(0, 157, 255, 0.2);
}

.card {
  padding: 24px;
}

.card h3,
.courses-card h3,
.contact-block h4 {
  margin-top: 0;
  color: var(--text);
}

.card p,
.courses-card p,
.contact-block p,
.course-features li {
  color: rgba(231, 244, 255, 0.82);
}

.card.featured {
  border-color: rgba(46, 168, 255, 0.16);
  box-shadow: 0 28px 80px rgba(0, 180, 255, 0.18);
}

.card.featured .card-content {
  display: grid;
  gap: 12px;
}

.courses-card {
  padding: 26px;
  border-radius: 22px;
}

.course-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100%;
}

.course-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.course-icon {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(46, 168, 255, 0.16), rgba(0, 229, 255, 0.12));
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1px rgba(46, 168, 255, 0.06), 0 12px 24px rgba(0, 147, 255, 0.16);
  overflow: hidden;
  animation: iconFloat 3s ease-in-out infinite;
}

.course-icon::before {
  content: '';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  font-size: 24px;
  line-height: 1;
  position: relative;
  z-index: 1;
}

.course-icon::after {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  animation: iconPulse 2.2s ease-in-out infinite;
}

.course-icon-security::before {
  content: '🛡';
  animation: iconWobble 2.6s ease-in-out infinite;
}

.course-icon-python::before {
  content: '';
  background-image: url('images/python-logo.svg');
  background-size: cover;
  background-position: center;
  width: 100%;
  height: 100%;
  border-radius: 16px;
  animation: iconBounce 2.4s ease-in-out infinite;
}

.course-icon-c::before {
  content: 'C';
  color: #8fe7ff;
  font-size: 26px;
  font-weight: 700;
  animation: iconGlow 2.2s ease-in-out infinite;
}

.course-tag {
  margin: 6px 0 0;
  color: rgba(174, 202, 255, 0.76);
  font-size: 0.95rem;
}

.course-copy {
  margin: 0 0 18px;
  color: rgba(231, 244, 255, 0.84);
  line-height: 1.7;
}

.course-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-bottom: 20px;
  color: rgba(174, 202, 255, 0.75);
  font-size: 0.97rem;
}

.course-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.course-meta span {
  background: rgba(255, 255, 255, 0.04);
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(2, 9, 20, 0.82);
  display: none;
  justify-content: center;
  align-items: center;
  padding: 24px;
  z-index: 1200;
}

.modal-overlay.open {
  display: flex;
}

.modal {
  width: min(100%, 900px);
  max-height: 90vh;
  overflow-y: auto;
  background: rgba(5, 13, 29, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  padding: 28px;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-size: 1.5rem;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: scale(1.05);
}

.modal-content h2 {
  margin-top: 0;
  color: var(--text);
}

.modal-content .course-copy {
  margin-bottom: 18px;
}

.modal-content .course-meta {
  margin-bottom: 20px;
}

.modal-sections {
  display: grid;
  gap: 20px;
}

.modal-section h4 {
  margin: 0 0 8px;
  color: var(--text);
}

.modal-section ul {
  margin: 0;
  padding-left: 20px;
  color: rgba(231, 244, 255, 0.84);
}

.modal-section li {
  margin-bottom: 8px;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1px rgba(46, 168, 255, 0.04);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.course-features {
  margin: 14px 0 0 18px;
  color: rgba(231, 244, 255, 0.76);
}

.course-features li {
  margin: 8px 0;
  line-height: 1.58;
}

.contact-block {
  padding: 24px;
  max-width: 440px;
}

.contact-block p {
  color: rgba(231, 244, 255, 0.88);
}

.follow-links {
  margin-top: 22px;
}

.social-title {
  margin: 0 0 12px;
  color: rgba(231, 244, 255, 0.92);
  font-size: 0.98rem;
  font-weight: 600;
}

.social-icons {
  display: flex;
  align-items: center;
  gap: 14px;
}

.social-icon {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 14px 30px rgba(0, 126, 255, 0.08);
  color: var(--text);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}

.social-icon:hover {
  transform: scale(1.1);
  background: rgba(0, 22, 48, 0.95);
  border-color: rgba(46, 168, 255, 0.4);
  box-shadow: 0 20px 36px rgba(46, 168, 255, 0.22);
}

.social-icon svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.reg-form {
  max-width: 640px;
  padding: 26px;
}

.reg-form label {
  display: block;
  margin-bottom: 18px;
  color: rgba(195, 212, 229, 0.78);
  font-size: 0.98rem;
}

.reg-form input,
.reg-form select {
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  margin-top: 8px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.reg-form input:focus,
.reg-form select:focus {
  outline: none;
  box-shadow: 0 0 0 4px rgba(46, 168, 255, 0.14);
  border-color: rgba(46, 168, 255, 0.32);
}

.form-actions {
  text-align: right;
  margin-top: 18px;
}

.btn {
  display: inline-block;
  padding: 14px 22px;
  border-radius: 14px;
  text-decoration: none;
  font-weight: 700;
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.btn-primary {
  background: linear-gradient(135deg, #2ea8ff 0%, #00e5ff 100%);
  color: #041424;
  box-shadow: 0 18px 40px rgba(46, 168, 255, 0.22);
}

.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.35) 0%, transparent 55%);
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 26px 58px rgba(46, 168, 255, 0.28);
}

.btn-primary:hover::after {
  opacity: 0.18;
  transform: scale(1);
}

.btn-primary:active::after {
  opacity: 0.35;
  transform: scale(1.1);
}

.site-footer {
  position: relative;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  padding: 24px 0;
  margin-top: 40px;
  color: rgba(167, 180, 194, 0.72);
  z-index: 1;
}

.footer-inner p {
  margin: 0 0 10px;
}

a:focus,
button:focus,
input:focus,
select:focus {
  outline: 3px solid rgba(14, 165, 164, 0.12);
  outline-offset: 3px;
}

@media (max-width: 920px) {
  .header-inner {
    flex-wrap: wrap;
  }

  .primary-nav {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .primary-nav ul {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 18px;
  }

  .hero {
    padding: 100px 0 64px;
  }
}

@media (max-width: 720px) {
  .container {
    padding: 20px;
  }

  .hero {
    margin-top: 72px;
    padding: 88px 0 50px;
  }

  .hero h1 {
    font-size: clamp(1.9rem, 7vw, 2.8rem);
  }

  .header-inner {
    gap: 12px;
  }

  .primary-nav ul {
    flex-direction: column;
    align-items: center;
  }

  .primary-nav a {
    padding: 10px 0;
  }

  .services-grid,
  .courses-grid {
    grid-template-columns: 1fr;
  }

  .card,
  .courses-card,
  .contact-block,
  .reg-form {
    border-radius: 18px;
  }

  .footer-inner p {
    font-size: 0.95rem;
  }
}
