/* ══ TIMILY SHARED STYLES ══ */
/* Shared across all pages: reset, fonts, header, footer, variables */

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

:root {
  --palette-1: #3a5da5;
  --palette-2: #24417C;
  --palette-3: #355575;
  --palette-4: #102136;
  --palette-5: #E7EBEE;
  --palette-6: #F3F5F7;
  --palette-7: #F7FAFD;
  --palette-8: #ffffff;
  --palette-9: #FFE8DA;
  --blue-accent: #2D8BF1;
  --blue-btn: #3B82F6;
  --blue-btn-hover: #2563EB;
  --link-hover: #1e65f1;
  --card-bg: #F2F7FF;
  --footer-bg: #F9FAFB;
  --text-body: #355575;
  --text-dark: #102136;
  --text-desc: #4B5869;
  --star-color: #FFC107;
  --warm-light: #FFF9F0;
  --warm-glow: #FBBF24;
}

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text-body);
  background: #fff;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* ── HEADER ─────────────────────────────── */
.ct-header {
  position: sticky; top: 0; z-index: 100;
  background: #fff;
  transition: box-shadow .3s;
}
.ct-header.scrolled { box-shadow: 0 2px 20px rgba(0,0,0,.06); }

.header-row {
  height: 80px;
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1290px; margin: 0 auto;
  padding: 0 clamp(20px, 5vw, 90px);
}

.site-branding { display: flex; align-items: center; gap: 10px; }
.site-branding a { display: flex; align-items: center; gap: 10px; }
.site-logo-container img { height: 50px; width: 50px; border-radius: 12px; }
.site-title {
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 700; font-size: 25px; line-height: 1.5;
  color: var(--text-dark);
}

.header-menu { display: flex; align-items: center; gap: 31px; }
.header-menu a {
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 700; font-size: 17px; line-height: 1.3;
  text-transform: capitalize; color: var(--text-body);
  transition: color .2s; padding: 8px 0;
  position: relative;
}
.header-menu a:hover { color: var(--link-hover); }
.header-menu a.active { color: var(--link-hover); }
.header-menu a.active::after {
  content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 20px; height: 3px; background: var(--blue-btn); border-radius: 2px;
}

.header-cta {
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 800; font-size: 15px; line-height: 1.5;
  text-transform: capitalize; color: #fff;
  background-color: var(--blue-btn); border: none; border-radius: 50px;
  padding: 12px 24px; min-height: 48px;
  display: inline-flex; align-items: center; cursor: pointer;
  /* Shimmer sweep (Magic-UI inspired) */
  background-image: linear-gradient(
    110deg,
    transparent 0%, transparent 40%,
    rgba(255,255,255,.2) 50%,
    transparent 60%, transparent 100%
  );
  background-size: 200% 100%;
  background-position: 200% 0;
  animation: shimmer-sweep 3.5s ease-in-out infinite;
  transition: background-color .2s, transform .15s;
}
.header-cta:hover {
  background-color: var(--blue-btn-hover); color: #fff;
  animation-play-state: paused;
  transform: translateY(-1px);
}

.mobile-trigger {
  display: none; background: none; border: none; cursor: pointer; padding: 8px;
}
.mobile-trigger svg { fill: var(--blue-accent); }

/* Focus-visible for keyboard navigation */
.header-menu a:focus-visible, .header-cta:focus-visible, .offcanvas-menu a:focus-visible {
  outline: 2px solid var(--blue-btn); outline-offset: 3px; border-radius: 4px;
}

/* Off-canvas */
.offcanvas-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.4); z-index: 200;
  opacity: 0; transition: opacity .3s;
}
.offcanvas-overlay.active { display: block; opacity: 1; }
.offcanvas-panel {
  position: fixed; top: 0; right: 0;
  width: min(85vw, 360px); height: 100%;
  background: #fff; z-index: 201;
  transform: translateX(100%); transition: transform .3s ease;
  display: flex; flex-direction: column; padding: 24px; overflow-y: auto;
}
.offcanvas-panel.active { transform: translateX(0); }
.offcanvas-close {
  align-self: flex-end; background: none; border: none;
  cursor: pointer; padding: 8px; margin-bottom: 20px;
}
.offcanvas-close svg { width: 16px; height: 16px; }
.offcanvas-logo { display: flex; align-items: center; gap: 8px; margin-bottom: 24px; }
.offcanvas-logo img { width: 40px; height: 40px; border-radius: 10px; }
.offcanvas-logo span {
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 700; font-size: 22px; color: var(--text-dark);
}
.offcanvas-menu { display: flex; flex-direction: column; gap: 5px; }
.offcanvas-menu a {
  font-family: 'Nunito Sans', sans-serif;
  font-weight: 700; font-size: 20px; text-transform: capitalize;
  color: var(--text-body); padding: 10px 0; transition: color .2s;
}
.offcanvas-menu a:hover { color: var(--blue-btn); }
.offcanvas-cta { margin-top: 20px; }
.offcanvas-cta .header-cta { width: 100%; justify-content: center; font-size: 15px; padding: 12px 30px; }
.offcanvas-socials { display: flex; gap: 12px; margin-top: 24px; }
.offcanvas-socials a {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--palette-6); display: grid; place-items: center;
  transition: background .2s;
}
.offcanvas-socials a:hover { background: var(--palette-5); }
.offcanvas-socials svg { width: 18px; height: 18px; fill: var(--text-body); }

@media (max-width: 999px) {
  .header-row { height: 70px; }
  .header-menu { display: none; }
  .header-cta-desktop { display: none; }
  .mobile-trigger { display: block; }
  .site-logo-container img { height: 45px; width: 45px; }
}
@media (max-width: 689px) {
  .site-logo-container img { height: 35px; width: 35px; }
  .site-title { font-size: 20px; }
}

/* ── FOOTER ─────────────────────────────── */
.site-footer {
  background-color: #F0F2F5;
  border-top: 1px solid var(--palette-5);
  padding: 48px clamp(20px, 5vw, 90px) 32px;
}
.footer-inner { max-width: 1290px; margin: 0 auto; }
.footer-top { display: flex; gap: 40px; margin-bottom: 32px; }
.footer-brand { flex: 1.5; min-width: 200px; }
.footer-brand-logo { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.footer-brand-logo img { width: 48px; height: 48px; border-radius: 12px; }
.footer-brand-logo span {
  font-family: 'Nunito Sans', sans-serif; font-size: 20px; font-weight: 700; color: var(--text-dark);
}
.footer-brand-tagline { font-size: 15px; font-weight: 500; color: #475569; line-height: 1.6; max-width: 300px; }
.footer-nav-group { flex: 1; min-width: 120px; }
.footer-nav-group h4 {
  font-family: Roboto, sans-serif; font-size: 18px; font-weight: 600;
  color: #222; margin-bottom: 14px;
}
.footer-nav-group ul { display: flex; flex-direction: column; gap: 10px; }
.footer-nav-group a { font-size: 15px; color: #666; transition: color .2s; }
.footer-nav-group a:hover { color: #000; }
.footer-nav-group h4.muted { color: #888; }
.footer-nav-group .muted-links a { color: #888; }
.footer-nav-group .muted-links a:hover { color: #000; }
.footer-nav-wrap { display: flex; gap: 40px; flex: 4; min-width: 0; }
.footer-brand-socials { display: flex; gap: 10px; margin-top: 16px; }
.footer-brand-socials a {
  width: 30px; height: 30px; border-radius: 50%;
  background: #e2e6ea; display: grid; place-items: center;
  transition: background .2s, transform .2s;
}
.footer-brand-socials a:hover { background: #d0d5db; transform: translateY(-2px); }
.footer-brand-socials svg { width: 13px; height: 13px; fill: #555; }

.footer-cta {
  margin-top: 20px;
}
.footer-cta .header-cta { font-size: 14px; padding: 10px 22px; min-height: 42px; }

.footer-bottom-text {
  font-size: 14px; color: #888; line-height: 1.7;
  border-top: 1px solid var(--palette-5); padding-top: 24px; margin-top: 8px;
}
.footer-bottom-text p { margin-bottom: 6px; }

@media (max-width: 768px) {
  .footer-top { flex-wrap: wrap; }
  .footer-brand { flex-basis: 100%; margin-bottom: 8px; }
  .footer-nav-wrap { flex-basis: 100%; flex-wrap: wrap; }
  .footer-nav-group { flex-basis: calc(50% - 20px); }
}
@media (max-width: 480px) {
  .footer-nav-group { flex-basis: 100%; }
  .footer-nav-group + .footer-nav-group { padding-top: 16px; border-top: 1px solid #e2e6ea; }
}

/* ── GLOBAL POLISH (Magic-UI inspired) ──── */

/* Shimmer sweep on CTA buttons */
@keyframes shimmer-sweep {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
/* Universal card hover lift */
.card-hover {
  transition: transform .25s ease, box-shadow .25s ease;
}
.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0,0,0,.08);
}

/* Standardized card shadow */
.shadow-card { box-shadow: 0 2px 16px rgba(0,0,0,.06); }
.shadow-card-sm { box-shadow: 0 2px 12px rgba(0,0,0,.05); }

/* Subtle fade-in on scroll (CSS-only with JS observer) */
.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .6s ease, transform .6s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── PAGE COMMON ────────────────────────── */
.page-hero {
  padding: 50px clamp(20px, 5vw, 90px) 35px;
  background: linear-gradient(180deg, #EDF3FE 0%, #F8FAFF 100%);
  text-align: center;
}
.page-hero h1 {
  font-family: Roboto, sans-serif; font-size: 42px; font-weight: 800;
  color: #12284C; max-width: 800px; margin: 0 auto 16px; line-height: 1.3;
  text-wrap: balance;
}
.page-hero .subtitle {
  font-family: Roboto, sans-serif; font-size: 20px; font-weight: 500;
  color: var(--text-body); max-width: 640px; margin: 0 auto; line-height: 1.6;
}
@media (max-width: 767px) {
  .page-hero h1 { font-size: 28px; }
  .page-hero .subtitle { font-size: 16px; }
}

.page-content {
  max-width: 900px; margin: 0 auto;
  padding: 48px clamp(20px, 5vw, 90px);
}
.page-content h2 {
  font-family: Roboto, sans-serif; font-size: 28px; font-weight: 800;
  color: #333; margin: 40px 0 16px; line-height: 1.3;
  text-wrap: balance;
}
.page-content h3 {
  font-family: Roboto, sans-serif; font-size: 20px; font-weight: 700;
  color: #333; margin: 28px 0 10px;
}
.page-content h4 {
  font-family: 'Nunito Sans', sans-serif; font-size: 17px; font-weight: 700;
  color: #333; margin: 20px 0 8px;
}
.page-content p {
  font-size: 16px; line-height: 1.75; color: var(--text-body); margin-bottom: 14px;
}
.page-content ul, .page-content ol {
  margin: 12px 0 18px 24px; font-size: 16px; line-height: 1.75; color: var(--text-body);
}
.page-content li { margin-bottom: 6px; }
.page-content ul { list-style: disc; }
.page-content ol { list-style: decimal; }
.page-content strong { color: #333; }
.page-content a { color: var(--blue-btn); }
.page-content a:hover { text-decoration: underline; }

/* ── PAGE CTA ─────────────────────────── */
/* Full card CTA — for high-intent pages (how-it-works, why-timily) */
.page-cta {
  max-width: 760px;
  margin: 60px auto 40px;
  padding: 0 clamp(20px, 5vw, 40px);
}
.page-cta-box {
  background: var(--warm-light);
  border: 1px solid #F5E6D3;
  border-radius: 16px;
  padding: 40px 36px;
  text-align: center;
}
.page-cta-box h2 {
  font-family: Roboto, sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--blue-accent);
  margin-bottom: 10px;
}
.page-cta-box p {
  font-family: Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-body);
  margin-bottom: 20px;
}
.page-cta-btn {
  display: inline-block;
  padding: 14px 32px;
  background: var(--blue-btn);
  color: #fff;
  border-radius: 10px;
  font-family: 'Nunito Sans', sans-serif;
  font-size: 16px;
  font-weight: 700;
  transition: background .2s;
}
.page-cta-btn:hover { background: var(--blue-btn-hover); color: #fff; }

/* Light CTA — for support pages (help, about, contact) */
.page-cta-light {
  max-width: 760px;
  margin: 48px auto 32px;
  padding: 0 clamp(20px, 5vw, 40px);
  text-align: center;
}
.page-cta-light p {
  font-family: Roboto, sans-serif;
  font-size: 16px;
  color: var(--text-desc);
  margin-bottom: 16px;
}

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--palette-6); }
::-webkit-scrollbar-thumb { background: #c0c8d4; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #a0aab6; }
