/* ── Shared styles for standalone legal / info pages ──
   All design tokens (colors, fonts, radii, motion) come
   from theme.css — edit that file to retheme everything. */
@import './theme.css';

*, *::before, *::after { box-sizing: border-box; }
html { height: 100%; }
body {
  font-family: var(--font-body);
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Nav ── */
.page-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  height: 56px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid var(--border);
}
.page-nav-back {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  cursor: pointer;
  color: var(--text-secondary);
  transition: background 0.16s var(--ease-out), color 0.16s, transform 0.14s cubic-bezier(0.34, 1.32, 0.64, 1);
  text-decoration: none;
}
.page-nav-back:hover { background: color-mix(in srgb, var(--primary) 10%, transparent); color: var(--primary); transform: scale(1.08); }
.page-nav-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  user-select: none;
  color: var(--text);
  text-decoration: none;
}
.page-nav-logo img {
  height: 20px;
  width: auto;
  display: block;
}
.page-nav-logo img[src*="logo.svg"] {
  height: 28px;
  width: 28px;
  border-radius: 7px;
  filter: none !important;
}
.page-nav-logo .page-nav-wordmark {
  height: 18px;
}
.dark .page-nav-logo img {
  filter: invert(1);
}
.dark .page-nav-logo img[src*="logo.svg"] {
  filter: none !important;
}

/* ── Language switcher ── */
.page-lang-wrap {
  margin-left: auto;
  position: relative;
  flex-shrink: 0;
}
[dir="rtl"] .page-lang-wrap { margin-left: 0; margin-right: auto; }

.page-lang-btn {
  height: 32px;
  padding: 0 12px;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--border);
  background: transparent;
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background 0.16s var(--ease-out), color 0.16s, border-color 0.16s, transform 0.14s cubic-bezier(0.34, 1.32, 0.64, 1);
}
.page-lang-btn:hover {
  background: color-mix(in srgb, var(--primary) 8%, transparent);
  color: var(--primary);
  border-color: var(--primary);
  transform: scale(1.04);
}

.page-lang-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 150px;
  background: var(--surface-container);
  border: 1px solid var(--border);
  border-radius: var(--radius-m);
  box-shadow: var(--elev-1);
  list-style: none;
  margin: 0;
  padding: 4px;
  z-index: 200;
}
[dir="rtl"] .page-lang-menu { right: auto; left: 0; }

.page-lang-menu li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-s);
  cursor: pointer;
  transition: background 0.14s;
}
.page-lang-menu li:hover,
.page-lang-menu li[aria-selected="true"] {
  background: color-mix(in srgb, var(--primary) 8%, transparent);
}
.page-lang-menu li[aria-selected="true"] .page-lang-code { color: var(--primary); font-weight: 700; }
.page-lang-code {
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--text);
  width: 22px;
  flex-shrink: 0;
}
.page-lang-native {
  font-size: 12.5px;
  color: var(--text-secondary);
}

/* ── Main ── */
.page-main {
  flex: 1;
  padding: 40px 24px 56px;
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
}

/* Help pages: two-column layout with sidebar */
.help-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 28px;
  align-items: start;
}
@media (max-width: 880px) {
  .help-layout { grid-template-columns: 1fr; }
}
.help-sidebar {
  position: sticky;
  top: 76px;
  align-self: start;
  background: var(--surface-container);
  border: 1px solid var(--border);
  border-radius: var(--radius-l);
  padding: 14px;
}
.help-nav { list-style: none; margin: 0; padding: 6px 0; display:flex;flex-direction:column;gap:6px; }
.help-nav a {
  display: block;
  padding: 8px 10px;
  border-radius: var(--radius-s);
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}
.help-nav a:hover { background: color-mix(in srgb, var(--primary) 6%, transparent); color: var(--primary); }
.help-nav a.active { background: color-mix(in srgb, var(--primary) 10%, transparent); color: var(--primary); }


/* ── Card ── */
.page-card {
  background: var(--surface-container);
  border-radius: var(--radius-xl);
  padding: 40px 32px;
  border: 1px solid var(--border);
}
@media (max-width: 480px) {
  .page-card { padding: 24px 18px; border-radius: var(--radius-l); }
}

/* ── Typography ── */
.page-title {
  font-family: var(--font-headline);
  font-size: 38px;
  font-weight: 700;
  letter-spacing: 0.5px;
  line-height: 1.1;
  color: var(--text);
  margin: 0 0 6px;
}
.page-subtitle {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 0 28px;
}
.page-section { margin-bottom: 22px; }
.page-section h2 {
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2px;
  color: var(--text);
  margin: 0 0 6px;
}
.page-section p {
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin: 0;
}
.page-section a {
  color: var(--primary);
  text-decoration: none;
}
.page-section a:hover { text-decoration: underline; }

/* ── Contact cards ── */
.contact-card {
  background: var(--surface-container-h);
  border: 1px solid var(--border);
  border-radius: var(--radius-m);
  padding: 18px;
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.contact-card-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
.contact-icon {
  width: 34px; height: 34px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  color: var(--primary);
  flex-shrink: 0;
}
.contact-card-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}
.contact-card-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
}
.contact-card-link:hover { text-decoration: underline; }
.contact-card-note {
  font-size: 12px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin: 0;
}

/* ── About page ── */
.about-hero-visual {
  margin: 4px 0 28px;
  display: flex;
  justify-content: center;
  line-height: 0;
}
.about-hero-img {
  width: auto;
  max-width: 100%;
  max-height: 280px;
  display: block;
  object-fit: contain;
}
.about-prose {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: 28px;
}
.about-prose p {
  font-size: 15px;
  line-height: 1.85;
  color: var(--text-secondary);
  margin: 0;
}
.about-prose p.about-emphasis {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.1px;
}
.about-prose em { font-style: italic; }

.about-split-list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.about-split-list li {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text-secondary);
  padding-left: 16px;
  position: relative;
}
.about-split-list li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--outline);
}

/* Hadith quote — warm amber accent */
.about-hadith {
  margin: 0 0 28px;
  padding: 18px 22px;
  border-radius: var(--radius-m);
  background: var(--prayer-container);
  border-left: 3px solid var(--prayer-color);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.about-hadith-text {
  font-family: var(--font-display);
  font-size: 15.5px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--on-prayer-container);
  margin: 0;
  font-style: italic;
}
.about-hadith-source {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--prayer-color);
  font-style: normal;
}

/* Quran verse — primary red accent */
.about-quran {
  margin: 0 0 28px;
  padding: 18px 22px;
  border-radius: var(--radius-m);
  background: var(--primary-container);
  border-left: 3px solid var(--primary);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.about-quran-text {
  font-family: var(--font-display);
  font-size: 15.5px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--on-primary-container);
  margin: 0;
  font-style: italic;
}
.about-quran-source {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--primary);
  font-style: normal;
}

.about-divider {
  height: 1px;
  background: var(--border);
  margin: 28px 0;
  border-radius: 1px;
}

.about-values-list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.about-values-list li {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  padding: 8px 14px;
  border-radius: var(--radius-s);
  background: color-mix(in srgb, var(--primary) 6%, transparent);
  border-left: 2px solid var(--primary);
}

.about-closing {
  margin-top: 28px;
  padding: 24px;
  border-radius: var(--radius-l);
  background: color-mix(in srgb, var(--primary) 8%, var(--surface-container));
  border: 1px solid color-mix(in srgb, var(--primary) 20%, transparent);
  text-align: center;
}
.about-closing-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--primary);
  margin: 0 0 10px;
}
.about-closing-text {
  font-family: var(--font-display);
  font-size: 19px;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}
.about-closing-text em { font-style: italic; }

/* ── Footer ── */
.page-footer {
  text-align: center;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}
.page-footer a {
  font-size: 11px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.12s;
}
.page-footer a:hover { color: var(--primary); }
.page-footer-dot {
  font-size: 11px;
  color: var(--outline);
  opacity: 0.4;
}
