/*
 * Theme Name: Cambridge Associates Replica
 * Author: Codex
 * Description: Cambridge Associates-inspired Typecho theme (English only)
 * Version: 1.0.0
 */

@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:wght@400;700&family=Source+Sans+3:wght@300;400;500;600;700&display=swap');

:root {
  --ink: #1b242b;
  --ink-strong: #0f151a;
  --muted: #5b6a72;
  --muted-2: #7b8a92;
  --accent: #0f5c61;
  --accent-2: #136f74;
  --sand: #f3f1ec;
  --mist: #eef2f3;
  --line: #d7dfe3;
  --surface: #ffffff;
  --shadow: 0 30px 60px rgba(15, 25, 30, 0.12);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --nav-height: 84px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: radial-gradient(1200px 700px at 12% -10%, #f4f7f6 0%, #ffffff 50%, #f2f4f6 100%);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

a:hover { color: var(--accent); }

img { max-width: 100%; display: block; }

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(15, 25, 30, 0.08);
}

.header-inner {
  min-height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.logo {
  font-family: 'Libre Baskerville', Georgia, serif;
  font-size: 1.25rem;
  letter-spacing: 0.02em;
  color: var(--ink-strong);
}

.logo span {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted);
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.primary-nav a {
  padding: 8px 0;
  border-bottom: 2px solid transparent;
}

.primary-nav a:hover {
  border-bottom-color: var(--accent);
}

.nav-utility {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 0.85rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: 1px solid transparent;
}

.btn.secondary {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
}

.site-main {
  padding-bottom: 80px;
}

.hero {
  position: relative;
  padding: 90px 0 80px;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(255,255,255,0.95) 0%, rgba(255,255,255,0.7) 45%, rgba(15, 92, 97, 0.08) 100%);
  z-index: 1;
}

.hero-media {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: saturate(0.9) contrast(1.05);
}

.hero .container {
  position: relative;
  z-index: 2;
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 30px;
  align-items: center;
}

.hero-copy {
  grid-column: span 7;
}

.hero-copy h1 {
  font-family: 'Libre Baskerville', Georgia, serif;
  font-size: clamp(2.6rem, 3vw, 3.8rem);
  margin: 16px 0 18px;
  line-height: 1.1;
  color: var(--ink-strong);
}

.hero-copy p {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 520px;
}

.hero-kicker {
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  color: var(--muted-2);
  font-weight: 600;
}

.hero-actions {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.hero-card {
  grid-column: span 5;
  background: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  padding: 30px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(15, 25, 30, 0.08);
}

.hero-card h3 {
  margin: 0 0 10px;
  font-family: 'Libre Baskerville', Georgia, serif;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.metric {
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: var(--mist);
  font-weight: 600;
  color: var(--ink-strong);
}

.section {
  padding: 70px 0;
}

.section.alt {
  background: var(--sand);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 30px;
}

.section-title {
  font-family: 'Libre Baskerville', Georgia, serif;
  font-size: clamp(1.6rem, 2.5vw, 2.5rem);
  margin: 0;
}

.section-subtitle {
  color: var(--muted);
  max-width: 520px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
}

.card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 26px;
  border: 1px solid rgba(15, 25, 30, 0.08);
  box-shadow: 0 15px 30px rgba(15, 25, 30, 0.08);
}

.card h3 {
  margin: 0 0 10px;
  font-family: 'Libre Baskerville', Georgia, serif;
}

.card p {
  color: var(--muted);
  margin: 0 0 14px;
}

.card-media {
  height: 160px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  background-size: cover;
  background-position: center;
}

.list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.list-item {
  padding: 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: #fff;
}

.insights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.insight {
  background: #fff;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(15, 25, 30, 0.08);
}

.insight-media {
  height: 180px;
  background-size: cover;
  background-position: center;
}

.insight-body {
  padding: 20px;
}

.insight-body h3 {
  margin: 0 0 8px;
  font-family: 'Libre Baskerville', Georgia, serif;
  font-size: 1.1rem;
}

.insight-meta {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--muted-2);
}

.cta-banner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  align-items: center;
  background: linear-gradient(130deg, #0f5c61 0%, #1c7d7c 100%);
  color: #fff;
  padding: 40px;
  border-radius: var(--radius-lg);
}

.cta-banner h3 {
  font-family: 'Libre Baskerville', Georgia, serif;
  margin: 0 0 10px;
}

.cta-banner p {
  margin: 0;
  opacity: 0.85;
}

.footer {
  background: #10161b;
  color: #d5dde2;
  padding: 60px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
}

.footer h4 {
  margin: 0 0 12px;
  font-family: 'Libre Baskerville', Georgia, serif;
  color: #fff;
}

.footer a { color: #d5dde2; }

.footer-bottom {
  margin-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 20px;
  font-size: 0.82rem;
  color: #aab6bd;
}

.notice-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 20, 25, 0.68);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
}

.notice-overlay.active {
  display: flex;
}

.notice-card {
  background: #fff;
  padding: 32px;
  border-radius: var(--radius-lg);
  max-width: 520px;
  box-shadow: var(--shadow);
}

.notice-card h3 {
  margin-top: 0;
  font-family: 'Libre Baskerville', Georgia, serif;
}

.notice-actions {
  display: flex;
  gap: 16px;
  margin-top: 18px;
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  animation: reveal 0.8s ease forwards;
}

.reveal.delay-1 { animation-delay: 0.2s; }
.reveal.delay-2 { animation-delay: 0.4s; }
.reveal.delay-3 { animation-delay: 0.6s; }

@keyframes reveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.page-hero {
  padding: 70px 0 40px;
  background: var(--mist);
}

.page-hero h1 {
  font-family: 'Libre Baskerville', Georgia, serif;
  margin: 0 0 10px;
}

.content-wrap {
  padding: 40px 0 80px;
}

.prose {
  max-width: 760px;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.8;
}

@media (max-width: 960px) {
  .hero-copy { grid-column: span 12; }
  .hero-card { grid-column: span 12; }
  .header-inner { flex-wrap: wrap; }
  .primary-nav, .nav-utility { display: none; }
  .nav-toggle { display: inline-flex; }
  body.nav-open .primary-nav,
  body.nav-open .nav-utility {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding-bottom: 20px;
  }
  body.nav-open .header-inner {
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .hero { padding: 70px 0 60px; }
  .hero-card { padding: 22px; }
  .section { padding: 50px 0; }
  .cta-banner { padding: 30px; }
}

input.text,
textarea.textarea,
textarea,
input[type=\"text\"],
input[type=\"email\"],
input[type=\"url\"] {
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--line);
  padding: 12px 14px;
  font-family: inherit;
  font-size: 0.95rem;
}

#comments .respond {
  margin-top: 32px;
}

#comments h3 {
  font-family: 'Libre Baskerville', Georgia, serif;
}
