/* === MagicCode Base Stylesheet === */
/* Colors: Primary #2F80ED, Accent #F59E0B, Dark #0F172A, Light Blue #4FC3F7 */

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #0F172A;
  background: #fff;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: #2F80ED; text-decoration: none; }
a:hover { text-decoration: underline; }

/* === Header & Navigation === */
.mc-header {
  background: #0F172A;
  padding: 0 1.5rem;
  position: sticky;
  top: 0;
  z-index: 100;
}
.mc-header-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}
.mc-logo {
  font-size: 1.4rem;
  font-weight: 800;
  text-decoration: none;
  letter-spacing: -0.02em;
}
.mc-logo-magic { color: #94a3b8; }
.mc-logo-code { color: #F59E0B; }
.mc-nav {
  display: flex;
  gap: 0.25rem;
  align-items: center;
}
.mc-nav-link {
  color: #cbd5e1;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  text-decoration: none;
  transition: color 0.2s, background 0.2s;
}
.mc-nav-link:hover { color: #fff; background: rgba(255,255,255,0.08); text-decoration: none; }
.mc-nav-link.active { color: #fff; }
.mc-nav-cta {
  background: #F59E0B !important;
  color: #fff !important;
  font-weight: 700;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  margin-left: 0.5rem;
}
.mc-nav-cta:hover { opacity: 0.9; background: #F59E0B; }
.mc-nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}
.mc-nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #cbd5e1;
  border-radius: 2px;
  transition: transform 0.3s;
}

/* === Buttons === */
.mc-btn-amber {
  display: inline-block;
  background: #F59E0B;
  color: #fff;
  font-weight: 700;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.95rem;
  transition: opacity 0.2s;
  box-shadow: 0 4px 14px rgba(245,158,11,0.35);
  white-space: nowrap;
}
.mc-btn-amber:hover { opacity: 0.9; text-decoration: none; }
.mc-btn-blue {
  display: inline-block;
  background: #2F80ED;
  color: #fff;
  font-weight: 700;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.95rem;
  transition: opacity 0.2s;
}
.mc-btn-blue:hover { opacity: 0.85; text-decoration: none; }
.mc-btn-ghost {
  display: inline-block;
  border: 2px solid rgba(255,255,255,0.4);
  color: #fff;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.95rem;
  transition: border-color 0.2s;
  white-space: nowrap;
}
.mc-btn-ghost:hover { border-color: #fff; text-decoration: none; }

/* === Section Layouts === */
.mc-section {
  padding: 4rem 1.5rem;
}
.mc-section-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.mc-section-dark {
  background: linear-gradient(135deg, #0f172a 0%, #0f2044 100%);
  color: #fff;
}
.mc-section-light {
  background: #f8fafc;
}
.mc-section-h {
  text-align: center;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 0.5rem;
}
.mc-section-dark .mc-section-h { color: #fff; }
.mc-section-sub {
  text-align: center;
  color: #64748b;
  font-size: 1rem;
  margin: 0 0 2.5rem;
}

/* === Cards === */
.mc-card {
  background: #fff;
  border-radius: 14px;
  padding: 1.75rem;
  box-shadow: 0 2px 14px rgba(0,0,0,0.07);
  border: 1px solid #e2e8f0;
  transition: transform 0.2s, box-shadow 0.2s;
}
.mc-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}
.mc-card.featured { border: 2px solid #2F80ED; }

/* === Trust Badges === */
.mc-badges {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
  padding: 2rem 1.5rem;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  border-bottom: 1px solid #e2e8f0;
}
.mc-badge {
  text-align: center;
  font-size: 0.85rem;
  color: #475569;
  font-weight: 500;
}
.mc-badge-icon {
  font-size: 1.5rem;
  display: block;
  margin-bottom: 0.25rem;
}

/* === Footer === */
.mc-footer {
  background: #0F172A;
  color: #94a3b8;
  padding: 3rem 1.5rem 0;
}
.mc-footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
}
.mc-footer-brand p {
  font-size: 0.85rem;
  line-height: 1.7;
  margin-top: 0.75rem;
}
.mc-footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.mc-footer-col h4 {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.mc-footer-col a {
  display: block;
  color: #94a3b8;
  font-size: 0.85rem;
  padding: 0.2rem 0;
  text-decoration: none;
}
.mc-footer-col a:hover { color: #fff; }
.mc-footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 1.5rem 0;
  margin-top: 2rem;
  text-align: center;
  font-size: 0.8rem;
}

/* === Blog === */
.mc-blog-list { list-style: none; }
.mc-blog-item {
  border-bottom: 1px solid #e2e8f0;
  padding: 1.5rem 0;
}
.mc-blog-item:last-child { border-bottom: none; }
.mc-blog-date { font-size: 0.85rem; color: #64748b; }
.mc-blog-title { font-size: 1.25rem; font-weight: 700; margin: 0.25rem 0 0.5rem; }
.mc-blog-title a { color: #0F172A; }
.mc-blog-title a:hover { color: #2F80ED; }
.mc-blog-excerpt { color: #475569; font-size: 0.95rem; }

/* === Blog Post Content === */
.mc-post-content {
  max-width: 720px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.8;
}
.mc-post-content h2 { font-size: 1.5rem; margin: 2rem 0 1rem; }
.mc-post-content h3 { font-size: 1.25rem; margin: 1.5rem 0 0.75rem; }
.mc-post-content p { margin-bottom: 1.25rem; }
.mc-post-content ul, .mc-post-content ol { margin-bottom: 1.25rem; padding-left: 1.5rem; }
.mc-post-content li { margin-bottom: 0.5rem; }
.mc-post-content blockquote {
  border-left: 4px solid #2F80ED;
  padding: 1rem 1.5rem;
  background: #f8fafc;
  margin: 1.5rem 0;
  font-style: italic;
}
.mc-post-content img { border-radius: 8px; margin: 1.5rem 0; }

/* === Contact Form === */
.mc-form label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.4rem;
}
.mc-form input[type="text"],
.mc-form input[type="email"],
.mc-form input[type="tel"],
.mc-form textarea,
.mc-form select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  margin-bottom: 1rem;
  transition: border-color 0.2s;
}
.mc-form input:focus, .mc-form textarea:focus, .mc-form select:focus {
  outline: none;
  border-color: #2F80ED;
  box-shadow: 0 0 0 3px rgba(47,128,237,0.1);
}
.mc-form textarea { resize: vertical; min-height: 120px; }
.mc-form button[type="submit"] {
  background: #2F80ED;
  color: #fff;
  font-weight: 700;
  padding: 0.75rem 2rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  cursor: pointer;
  transition: opacity 0.2s;
}
.mc-form button[type="submit"]:hover { opacity: 0.85; }

/* === Responsive === */
@media (max-width: 768px) {
  .mc-nav-toggle { display: flex; }
  .mc-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #0F172A;
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 0;
    border-top: 1px solid rgba(255,255,255,0.1);
  }
  .mc-nav.open { display: flex; }
  .mc-nav-link { padding: 0.75rem 0; width: 100%; }
  .mc-nav-cta { margin-left: 0; margin-top: 0.5rem; text-align: center; }
  .mc-footer-inner { grid-template-columns: 1fr; gap: 2rem; }
  .mc-footer-links { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
  .mc-footer-links { grid-template-columns: 1fr; }
}
