@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ── Design tokens for devzphere.in ── */
:root {
  --background:        #f5f8ff;
  --foreground:        #0c1730;
  --card:              #ffffff;
  --card-foreground:   #0c1730;
  --primary:           #0284c7;
  --primary-foreground:#ffffff;
  --secondary:         #eaf3fb;
  --muted:             #eaf3fb;
  --muted-foreground:  #4a6880;
  --border:            #c9dff0;
  --radius:            0.625rem;
}

.dark {
  --background:        #0c1730;
  --foreground:        #eef4fc;
  --card:              #111f3a;
  --card-foreground:   #eef4fc;
  --primary:           #0284c7;
  --primary-foreground:#ffffff;
  --secondary:         #172844;
  --muted:             #172844;
  --muted-foreground:  #6a9bbf;
  --border:            #1a3355;
}

/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background-color: var(--background);
  color: var(--foreground);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.7;
  font-size: 16px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Navigation ── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--background) 80%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1024px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--foreground);
  font-weight: 700;
  font-size: 1.05rem;
}

.nav-brand:hover { color: var(--foreground); text-decoration: none; }

.brand-badge {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--primary);
  color: var(--primary-foreground);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.875rem;
  flex-shrink: 0;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav-link {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s;
}

.nav-link:hover { color: var(--foreground); text-decoration: none; }
.nav-link:visited { color: var(--muted-foreground); }
.nav-link:hover:visited { color: var(--foreground); }

.theme-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--secondary);
  color: var(--muted-foreground);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}

.theme-btn:hover {
  background: var(--muted);
  color: var(--foreground);
}

.theme-btn svg { width: 16px; height: 16px; }

/* ── Page content ── */
.page-content {
  flex: 1;
  padding: 40px 24px 56px;
}

/* ── Container card ── */
.container {
  background: var(--card);
  color: var(--card-foreground);
  max-width: 820px;
  margin: 0 auto;
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 4px 20px rgba(0,0,0,0.05);
  overflow: hidden;
}

.app-icon {
  width: 72px;
  height: 72px;
  object-fit: contain;
  border-radius: 16px;
  margin-bottom: 16px;
  display: block;
  max-width: 100%;
}

/* ── Card header ── */
.container-header {
  padding: 36px 48px 32px;
  border-bottom: 1px solid var(--border);
  background: var(--secondary);
}

.container-header h1 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--foreground);
  margin: 0 0 6px;
  line-height: 1.25;
}

.effective-date {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  margin: 0;
}

/* ── Card body ── */
.container-body {
  padding: 36px 48px 44px;
}

/* ── Typography ── */
h2 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary);
  margin: 32px 0 10px;
  padding: 9px 14px;
  background: color-mix(in srgb, var(--primary) 8%, transparent);
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius) var(--radius) 0;
}

h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--foreground);
  margin: 22px 0 8px;
  padding: 7px 12px;
  background: var(--secondary);
  border-radius: calc(var(--radius) - 2px);
}

p {
  margin: 0 0 14px;
  color: var(--foreground);
  opacity: 0.85;
}

ul, ol {
  margin: 0 0 14px;
  padding-left: 24px;
}

li {
  margin-bottom: 6px;
  opacity: 0.85;
}

a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

a:hover { text-decoration: underline; }
a:visited { color: var(--primary); }

/* ── Home page app sections ── */
.intro-text {
  color: var(--muted-foreground);
  margin-bottom: 24px;
  font-size: 0.9375rem;
}

.app-section { margin-top: 32px; }
.app-section:first-of-type { margin-top: 0; }
.app-section h2 { margin-top: 0; }

.app-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
}

.app-list li a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--foreground);
  background: var(--secondary);
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
  text-decoration: none;
}

.app-list li a:hover {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 6%, var(--card));
  box-shadow: 0 2px 8px color-mix(in srgb, var(--primary) 15%, transparent);
  text-decoration: none;
  color: var(--foreground);
}

.app-list li a:visited { color: var(--foreground); }

.arrow {
  margin-left: auto;
  color: var(--muted-foreground);
  font-size: 1rem;
  transition: transform 0.15s, color 0.15s;
}

.app-list li a:hover .arrow {
  transform: translateX(3px);
  color: var(--primary);
}

/* ── Footer ── */
.site-footer {
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 48px 24px 24px;
  margin-top: auto;
}

.footer-inner {
  max-width: 1024px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 32px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--foreground);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 10px;
}

.footer-brand:hover { text-decoration: none; color: var(--foreground); }
.footer-tagline { font-size: 0.875rem; color: var(--muted-foreground); margin: 0; }

.footer-col h4 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--foreground);
  margin: 0 0 12px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-col ul li a {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  text-decoration: none;
  font-weight: 400;
  transition: color 0.15s;
}

.footer-col ul li a:hover { color: var(--foreground); text-decoration: none; }
.footer-col ul li a:visited { color: var(--muted-foreground); }

.footer-bottom {
  max-width: 1024px;
  margin: 32px auto 0;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.8125rem;
  color: var(--muted-foreground);
}

/* ── Responsive ── */
@media (max-width: 640px) {
  .page-content { padding: 20px 12px 40px; }

  .container { width: 100%; }

  .container-header,
  .container-body { padding-left: 22px; padding-right: 22px; }

  .app-icon { width: 56px; height: 56px; }

  .container-header h1 { font-size: 1.35rem; }

  .footer-inner { grid-template-columns: 1fr 1fr; }
}
