/* ================================================
   RICLOUD ACADEMY — Shared Styles
   Brand: Purple #c044f5 → Cyan #22d3ee
   ================================================ */

@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap");

:root {
  --purple: #c044f5;
  --cyan: #22d3ee;
  --purple-dark: #8b22d4;
  --cyan-dark: #0ea5c9;
  --bg: #07070f;
  --bg2: #0d0d1a;
  --bg3: #111128;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-hover: rgba(255, 255, 255, 0.08);
  --border: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(192, 68, 245, 0.3);
  --text: #f0f0ff;
  --text-muted: rgba(240, 240, 255, 0.55);
  --text-dim: rgba(240, 240, 255, 0.35);
  --gradient: linear-gradient(135deg, var(--purple), var(--cyan));
  --gradient-text: linear-gradient(90deg, #d164f8, #22d3ee);
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-glow: 0 0 40px rgba(192, 68, 245, 0.15);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Plus Jakarta Sans", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── Typography ── */
h1,
h2,
h3,
h4,
h5 {
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: -0.02em;
}
p {
  color: var(--text-muted);
}
a {
  text-decoration: none;
  color: inherit;
}

.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 50px;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  border: none;
  transition: all 0.3s ease;
  letter-spacing: 0.01em;
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 24px rgba(192, 68, 245, 0.4);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(192, 68, 245, 0.6);
}
.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
}
.btn-ghost:hover {
  background: var(--surface-hover);
  border-color: rgba(192, 68, 245, 0.4);
}

/* ── Navigation ── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  background: rgba(7, 7, 15, 0.7);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}
nav.scrolled {
  background: rgba(7, 7, 15, 0.95);
  border-bottom-color: rgba(192, 68, 245, 0.2);
}
.nav-logo img {
  height: 36px;
}
.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}
.nav-links li {
  position: relative;
}
.nav-links a {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  transition: color 0.2s ease;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}
.nav-links a.active {
  color: var(--cyan);
}
.nav-item-has-submenu {
  display: flex;
  align-items: center;
  gap: 6px;
}
.nav-submenu-toggle {
  width: 22px;
  height: 22px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
}
.nav-submenu-toggle::before {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition:
    transform 0.2s ease,
    color 0.2s ease;
}
.nav-item-has-submenu:hover > .nav-submenu-toggle,
.nav-item-has-submenu:focus-within > .nav-submenu-toggle,
.nav-item-has-submenu.is-active > .nav-submenu-toggle {
  color: var(--text);
}
.nav-item-has-submenu:hover > .nav-submenu-toggle::before,
.nav-item-has-submenu:focus-within > .nav-submenu-toggle::before,
.nav-item-has-submenu.submenu-open > .nav-submenu-toggle::before {
  transform: translateY(1px) rotate(225deg);
}
.nav-submenu {
  position: absolute;
  top: calc(100% + 18px);
  left: 50%;
  min-width: 220px;
  padding: 10px;
  margin: 0;
  list-style: none;
  background: rgba(12, 12, 24, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.34);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-50%, 8px);
  transition:
    opacity 0.18s ease,
    transform 0.18s ease,
    visibility 0.18s ease;
}
.nav-submenu::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -18px;
  height: 18px;
}
.nav-item-has-submenu:hover > .nav-submenu,
.nav-item-has-submenu:focus-within > .nav-submenu,
.nav-item-has-submenu.submenu-open > .nav-submenu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translate(-50%, 0);
}
.nav-submenu a {
  display: block;
  padding: 11px 12px;
  border-radius: 6px;
  color: var(--text-muted);
  letter-spacing: 0;
}
.nav-submenu a:hover,
.nav-submenu a.active {
  color: var(--text);
  background: rgba(34, 211, 238, 0.1);
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.nav-actions .btn {
  padding: 10px 22px;
  font-size: 14px;
}
.nav-mobile-actions {
  display: none;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

/* ── Mobile Nav ── */
@media (max-width: 768px) {
  nav {
    padding: 0 20px;
  }
  .hamburger {
    display: flex;
  }
  .nav-links,
  .nav-actions {
    display: none;
  }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(7, 7, 15, 0.98);
    border-bottom: 1px solid var(--border);
    padding: 12px 20px 18px;
    height: calc(100vh - 72px);
    overflow-y: auto;
  }
  .nav-links.open > li {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }
  .nav-links.open > li:last-child {
    border-bottom: 0;
  }
  .nav-links.open a {
    display: block;
    padding: 14px 0;
    font-size: 16px;
  }
  .nav-item-has-submenu {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 42px;
    gap: 0;
    align-items: center;
  }
  .nav-item-has-submenu > .nav-link {
    min-width: 0;
  }
  .nav-submenu-toggle {
    width: 42px;
    height: 42px;
    justify-self: end;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
  }
  .nav-submenu {
    grid-column: 1 / -1;
    position: static;
    min-width: 0;
    width: 100%;
    padding: 0 0 10px 14px;
    margin: -2px 0 0;
    background: transparent;
    border: 0;
    border-left: 1px solid rgba(34, 211, 238, 0.35);
    border-radius: 0;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    display: none;
    transition: none;
  }
  .nav-submenu::before {
    display: none;
  }
  .nav-item-has-submenu:hover > .nav-submenu-toggle::before,
  .nav-item-has-submenu:focus-within > .nav-submenu-toggle::before {
    transform: translateY(-2px) rotate(45deg);
  }
  .nav-item-has-submenu.submenu-open > .nav-submenu-toggle::before {
    transform: translateY(1px) rotate(225deg);
  }
  .nav-item-has-submenu.submenu-open > .nav-submenu {
    display: block;
    transform: unset;
  }
  .nav-submenu a {
    padding: 10px 0;
    font-size: 15px;
  }
  .nav-links.open > .nav-mobile-actions {
    display: grid;
    gap: 10px;
    padding: 18px 0 0;
    border-bottom: 0;
  }
  .nav-links.open > .nav-mobile-actions .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 46px;
    padding: 12px 18px;
    font-size: 15px;
  }
}

/* ── Section commons ── */
section {
  padding: 100px 48px;
}
.section-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.section-tag {
  display: inline-block;
  padding: 6px 16px;
  white-space: nowrap;
  background: rgba(192, 68, 245, 0.12);
  border: 1px solid rgba(192, 68, 245, 0.3);
  border-radius: 50px;
  font-size: 12px;
  font-weight: 700;
  color: var(--purple);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(32px, 4vw, 48px);
  margin-bottom: 16px;
}
.section-sub {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 560px;
  line-height: 1.7;
}

/* ── Cards ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: inherit;
}
.card:hover {
  border-color: rgba(192, 68, 245, 0.4);
  transform: translateY(-4px);
  box-shadow:
    0 20px 40px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(192, 68, 245, 0.1);
}

/* ── Footer ── */
footer {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  padding: 64px 48px 32px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-logo img {
  height: 32px;
  margin-bottom: 16px;
}
.footer-desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.8;
  max-width: 260px;
}
.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 20px;
}
.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-left: 0;
}
.footer-col ul li a {
  font-size: 14px;
  color: var(--text-muted);
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 5px;
}
.footer-col ul li a:hover {
  color: var(--cyan);
}
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
.footer-bottom p {
  font-size: 13px;
  color: var(--text-dim);
}
.social-links {
  display: flex;
  gap: 12px;
}
.social-link {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.social-link:hover {
  border-color: var(--purple);
  background: rgba(192, 68, 245, 0.1);
}
.social-link svg {
  width: 16px;
  height: 16px;
  fill: var(--text-muted);
}

/* ── Scroll reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 {
  transition-delay: 0.1s;
}
.reveal-delay-2 {
  transition-delay: 0.2s;
}
.reveal-delay-3 {
  transition-delay: 0.3s;
}
.reveal-delay-4 {
  transition-delay: 0.4s;
}
.reveal-delay-5 {
  transition-delay: 0.5s;
}

@media (max-width: 768px) {
  section {
    padding: 64px 20px;
  }
  footer {
    padding: 48px 20px 24px;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}
