/* === CloudWave: base === */
:root {
  --c-primary: #8B5CF6;
  --c-primary-dark: #7C3AED;
  --c-secondary: #0A0812;
  --c-accent: #C4B5FD;
  --c-bg: #15111F;
  --c-bg-alt: #1C1730;
  --c-surface: #261E42;
  --c-heading: #F1EDFB;
  --c-text: #CFC7E5;
  --c-text-muted: #9289B0;
  --c-border: #342B4E;
  --c-footer-text: #B4ABD1;
  --c-footer-border: #2E2541;
  --c-footer-legal: #7A729A;

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --s-1: 4px;  --s-2: 8px;  --s-3: 16px; --s-4: 24px;
  --s-5: 32px; --s-6: 48px; --s-7: 64px; --s-8: 96px;

  --radius: 8px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.35), 0 1px 3px rgba(0,0,0,.4);
  --shadow-md: 0 4px 6px rgba(0,0,0,.35), 0 10px 15px rgba(0,0,0,.45);

  --bp-md: 768px;
  --bp-lg: 1024px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--c-text);
  background: var(--c-bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--c-primary); text-decoration: none; }
a:hover { color: var(--c-primary-dark); text-decoration: underline; }

h1, h2, h3, h4 { color: var(--c-heading); line-height: 1.2; margin: 0 0 var(--s-3); }
h1 { font-size: clamp(2rem, 4vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); }
h3 { font-size: 1.25rem; }
p  { margin: 0 0 var(--s-3); }

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 var(--s-4);
}

.section { padding: var(--s-7) 0; }
.section--alt { background: var(--c-bg-alt); }
.section-title { text-align: center; margin-bottom: var(--s-5); }
.section-lead  { text-align: center; max-width: 720px; margin: 0 auto var(--s-6); color: var(--c-text-muted); }

.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color .15s, color .15s, border-color .15s;
  text-decoration: none;
}
.btn--primary { background: var(--c-primary); color: #fff; }
.btn--primary:hover { background: var(--c-primary-dark); color: #fff; text-decoration: none; }
.btn--ghost { background: transparent; color: var(--c-primary); border-color: var(--c-primary); }
.btn--ghost:hover { background: var(--c-primary); color: #fff; text-decoration: none; }

.grid { display: grid; gap: var(--s-4); }
@media (min-width: 768px)  { .grid--2 { grid-template-columns: repeat(2, 1fr); } .grid--3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .grid--4 { grid-template-columns: repeat(4, 1fr); } }
/* === CloudWave: header / nav === */
.skip-link {
  position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden;
}
.skip-link:focus {
  position: fixed; top: 8px; left: 8px; width: auto; height: auto; padding: 8px 16px;
  background: var(--c-secondary); color: #fff; z-index: 1000; border-radius: 4px;
}
.screen-reader-text {
  position: absolute !important; clip: rect(1px, 1px, 1px, 1px); width: 1px; height: 1px; overflow: hidden;
}

.site-header {
  background: var(--c-bg);
  border-bottom: 1px solid var(--c-border);
  position: sticky; top: 0; z-index: 50;
}
.site-header__row {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: var(--s-3); padding-bottom: var(--s-3);
}
.site-logo { display: inline-flex; }

.nav-toggle {
  display: inline-flex; flex-direction: column; gap: 5px;
  background: none; border: 0; padding: 8px; cursor: pointer;
}
.nav-toggle__bar { display: block; width: 24px; height: 2px; background: var(--c-heading); }

.primary-nav { display: none; }
.primary-nav.is-open { display: block; }
.primary-nav__list {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: var(--s-2);
  background: var(--c-surface); padding: var(--s-3) var(--s-4);
  position: absolute; left: 0; right: 0; top: 100%;
  box-shadow: var(--shadow-md);
}
.primary-nav__list a {
  display: block; padding: 8px 0; color: var(--c-heading); font-weight: 500;
}
.primary-nav__list a:hover { color: var(--c-primary); text-decoration: none; }

@media (min-width: 768px) {
  .nav-toggle { display: none; }
  .primary-nav, .primary-nav.is-open { display: block; }
  .primary-nav__list {
    flex-direction: row; gap: var(--s-5);
    position: static; padding: 0; box-shadow: none;
  }
}
/* === CloudWave: footer === */
.site-footer {
  background: var(--c-secondary);
  color: var(--c-footer-text);
  padding: var(--s-7) 0 var(--s-4);
  margin-top: var(--s-8);
}
.site-footer h4 { color: #fff; margin-bottom: var(--s-3); }
.site-footer a  { color: var(--c-footer-text); }
.site-footer a:hover { color: #fff; text-decoration: underline; }

.site-footer__grid {
  display: grid; gap: var(--s-5); margin-bottom: var(--s-5);
}
@media (min-width: 768px) {
  .site-footer__grid { grid-template-columns: 2fr 1fr 1fr; }
}

.site-footer__list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s-2); }

.site-footer__legal {
  border-top: 1px solid var(--c-footer-border);
  padding-top: var(--s-4);
  font-size: .9rem;
  color: var(--c-footer-legal);
}
/* === CloudWave: article / post-list === */
.article { max-width: 760px; padding-top: var(--s-6); padding-bottom: var(--s-6); }
.article__meta { color: var(--c-text-muted); margin-bottom: var(--s-4); }
.article__body p { margin-bottom: var(--s-3); }

.post-list { padding: var(--s-6) var(--s-4); }
.post-list__header { text-align: center; margin-bottom: var(--s-5); }

.post-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--s-4);
  box-shadow: var(--shadow-sm);
}
.post-card__title { font-size: 1.25rem; margin-bottom: var(--s-2); }
.post-card__title a { color: var(--c-heading); }
.post-card__title a:hover { color: var(--c-primary); text-decoration: none; }
.post-card__meta { color: var(--c-text-muted); font-size: .9rem; margin-bottom: var(--s-2); }
.post-card__excerpt { color: var(--c-text-muted); font-size: .95rem; margin-bottom: var(--s-2); }
.post-card__more { font-weight: 600; }

.pagination { margin-top: var(--s-5); text-align: center; }
.pagination .page-numbers { display: inline-block; padding: 8px 12px; margin: 0 2px; border: 1px solid var(--c-border); border-radius: 4px; }
.pagination .page-numbers.current { background: var(--c-primary); color: #fff; border-color: var(--c-primary); }
/* === CloudWave: feature-card === */
.feature-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column;
}
.feature-card__icon {
  width: 48px; height: 48px;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(139,92,246,.18);
  color: var(--c-primary);
  border-radius: 12px;
  margin-bottom: var(--s-3);
}
.feature-card__icon svg { width: 24px; height: 24px; }
.feature-card__title { margin-bottom: var(--s-2); }
.feature-card__body  { color: var(--c-text-muted); margin-bottom: var(--s-3); flex: 1; }
.feature-card__link  { font-weight: 600; align-self: flex-start; }
/* === CloudWave: pricing-card === */
.pricing-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column;
  position: relative;
}
.pricing-card--highlight {
  border-color: var(--c-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}
.pricing-card__badge {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--c-primary); color: #fff;
  font-size: .8rem; font-weight: 600;
  padding: 4px 12px; border-radius: 999px;
}
.pricing-card__title   { margin-bottom: var(--s-1); }
.pricing-card__tagline { color: var(--c-text-muted); margin-bottom: var(--s-3); }
.pricing-card__price   { margin: var(--s-2) 0 var(--s-4); }
.pricing-card__amount  { font-size: 2.25rem; font-weight: 700; color: var(--c-heading); }
.pricing-card__period  { color: var(--c-text-muted); margin-left: 4px; }
.pricing-card__features {
  list-style: none; padding: 0; margin: 0 0 var(--s-4);
  display: grid; gap: var(--s-2); flex: 1;
}
.pricing-card__features li {
  position: relative; padding-left: 24px; color: var(--c-text);
}
.pricing-card__features li::before {
  content: ""; position: absolute; left: 0; top: 7px;
  width: 14px; height: 8px;
  border-left: 2px solid var(--c-primary);
  border-bottom: 2px solid var(--c-primary);
  transform: rotate(-45deg);
}
.pricing-card .btn { align-self: stretch; text-align: center; }
/* === CloudWave: team-card === */
.team-card { text-align: center; }
.team-card__photo {
  width: 128px; height: 128px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto var(--s-3);
  box-shadow: var(--shadow-sm);
}
.team-card__name { margin-bottom: 2px; font-size: 1.1rem; }
.team-card__role { color: var(--c-primary); font-weight: 600; margin-bottom: var(--s-2); }
.team-card__bio  { color: var(--c-text-muted); }
/* === CloudWave: hero === */
.hero {
  background:
    radial-gradient(circle at 80% 0%, rgba(139,92,246,.35), transparent 55%),
    linear-gradient(180deg, var(--c-bg-alt), var(--c-bg));
  padding: var(--s-8) 0;
  text-align: center;
}
.hero__inner { max-width: 820px; }
.hero__title { color: var(--c-heading); }
.hero__lead { color: var(--c-text-muted); font-size: 1.125rem; margin-bottom: var(--s-5); }
.hero__cta { display: flex; gap: var(--s-3); justify-content: center; flex-wrap: wrap; }
/* === CloudWave: pricing page === */
.billing-toggle {
  display: inline-flex; gap: 4px;
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-radius: 999px; padding: 4px;
  margin-top: var(--s-4);
}
.billing-toggle__btn {
  background: none; border: 0;
  padding: 8px 20px; border-radius: 999px;
  font-weight: 600; color: var(--c-text-muted); cursor: pointer;
  transition: background-color .15s, color .15s;
}
.billing-toggle__btn.is-active {
  background: var(--c-primary); color: #fff;
}
.billing-toggle__save {
  display: inline-block; margin-left: 6px;
  font-size: .75rem; font-weight: 600; opacity: .8;
}

.pricing-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  overflow: hidden;
}
.pricing-table th, .pricing-table td {
  padding: var(--s-3) var(--s-4);
  text-align: left;
  border-bottom: 1px solid var(--c-border);
}
.pricing-table thead th {
  background: var(--c-bg-alt);
  font-size: .85rem; text-transform: uppercase; letter-spacing: .04em;
  color: var(--c-text-muted);
}
.pricing-table tbody th {
  font-weight: 700; color: var(--c-heading);
}
.pricing-table tr.is-featured td,
.pricing-table tr.is-featured th { background: rgba(139,92,246,.12); }

@media (max-width: 767px) {
  .pricing-table { display: block; overflow-x: auto; }
}
/* === CloudWave: about / values === */
.value-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--s-5);
  box-shadow: var(--shadow-sm);
}
.value-card h3 { color: var(--c-primary); margin-bottom: var(--s-2); }
/* === CloudWave: contact === */
.contact-grid {
  display: grid; gap: var(--s-5);
}
@media (min-width: 768px) {
  .contact-grid { grid-template-columns: 2fr 1fr; }
}
.contact-form { display: grid; gap: var(--s-3); }
.form-row { margin: 0; display: grid; gap: 6px; }
.form-row label { font-weight: 600; color: var(--c-heading); }
.form-row input, .form-row textarea {
  font: inherit;
  padding: 10px 12px;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-surface);
  color: var(--c-heading);
}
.form-row input::placeholder, .form-row textarea::placeholder { color: var(--c-text-muted); }
.form-row input:focus, .form-row textarea:focus {
  outline: 2px solid var(--c-primary); outline-offset: 1px;
}
.form-row--actions { margin-top: var(--s-2); }

.contact-info {
  background: var(--c-bg-alt);
  border-radius: var(--radius);
  padding: var(--s-5);
}
.contact-info h3 { margin-bottom: var(--s-3); }
.contact-info p  { margin-bottom: var(--s-2); }
