/* =========================================================
   ARC Institute — Main Stylesheet
   ========================================================= */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --color-primary:   #1a2e4a;
  --color-accent:    #2e7d9e;
  --color-text:      #1f2937;
  --color-muted:     #6b7280;
  --color-bg:        #ffffff;
  --color-bg-light:  #f8f9fa;
  --color-border:    #e5e7eb;
  --font-sans:       'Inter', system-ui, -apple-system, sans-serif;
  --radius:          6px;
  --shadow-sm:       0 1px 3px rgba(0,0,0,.08);
  --shadow-md:       0 4px 12px rgba(0,0,0,.10);
  --max-width:       1200px;
  --transition:      0.2s ease;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  font-size: 1rem;
}

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

/* --- Layout Utilities --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section { padding: 5rem 0; }
.bg-light { background: var(--color-bg-light); }

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.label {
  display: inline-block;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: .75rem;
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: .6rem 1.4rem;
  border-radius: var(--radius);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity var(--transition), background var(--transition);
  border: 2px solid transparent;
}

.btn-primary {
  background: var(--color-primary);
  color: #fff;
}
.btn-primary:hover { opacity: .85; text-decoration: none; }

.btn-outline {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: transparent;
}
.btn-outline:hover { background: var(--color-primary); color: #fff; text-decoration: none; }

/* --- Header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding-top: .9rem;
  padding-bottom: .9rem;
}

.logo {
  flex-shrink: 0;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--color-primary);
  letter-spacing: -.01em;
}
.logo img { height: 36px; width: auto; }

.main-nav {
  display: flex;
  gap: 1.5rem;
  flex: 1;
}
.main-nav a {
  font-size: .875rem;
  font-weight: 500;
  color: var(--color-text);
  transition: color var(--transition);
}
.main-nav a:hover { color: var(--color-accent); text-decoration: none; }

.header-actions {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-shrink: 0;
}

.lang-toggle {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: .3rem .7rem;
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--color-text);
  transition: border-color var(--transition);
}
.lang-toggle:hover { border-color: var(--color-accent); }

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--color-primary);
}

/* --- Hero --- */
.hero {
  padding: 7rem 0 5rem;
  background: linear-gradient(135deg, #1a2e4a 0%, #2e4a6a 100%);
  color: #fff;
  text-align: center;
}

.hero-inner { max-width: 760px; margin: 0 auto; }

.hero h1 {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.25rem;
}

.hero-sub {
  font-size: 1.15rem;
  opacity: .85;
  margin-bottom: 2rem;
}

.hero-ctas { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }
.hero .btn-primary { background: #fff; color: var(--color-primary); }
.hero .btn-primary:hover { opacity: .9; }
.hero .btn-outline { border-color: rgba(255,255,255,.6); color: #fff; }
.hero .btn-outline:hover { background: rgba(255,255,255,.15); }

/* --- About Snapshot --- */
.text-block h2 {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1rem;
}
.text-block p { color: var(--color-muted); margin-bottom: 1.5rem; }
.image-block img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: var(--color-bg-light);
}

/* --- Research Centers --- */
.centers h2 {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 700;
  margin-bottom: 2.5rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
}

.card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: box-shadow var(--transition), transform var(--transition);
}
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.card-icon {
  font-size: 1.5rem;
  color: var(--color-accent);
  margin-bottom: .75rem;
}
.card h3 { font-size: .95rem; font-weight: 600; }

/* --- Milestones --- */
.milestones h2 {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 700;
  margin-bottom: 2.5rem;
}

.milestone-list { display: flex; flex-direction: column; gap: 0; }

.milestone-item {
  display: flex;
  gap: 2rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--color-border);
}
.milestone-item:first-child { border-top: 1px solid var(--color-border); }

.milestone-meta {
  flex-shrink: 0;
  width: 60px;
  font-weight: 700;
  color: var(--color-accent);
  font-size: .875rem;
  padding-top: .2rem;
}

.milestone-body h3 { font-size: 1rem; font-weight: 600; margin-bottom: .4rem; }
.milestone-body p { color: var(--color-muted); font-size: .9rem; }

/* --- Partners --- */
.partners .label { display: block; text-align: center; margin-bottom: 1.5rem; }

.partner-logos {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 3rem;
  padding: 1rem 0;
}
.partner-logos img { height: 56px; width: auto; filter: grayscale(1); opacity: .7; transition: opacity var(--transition), filter var(--transition); }
.partner-logos img:hover { filter: grayscale(0); opacity: 1; }

/* --- News --- */
.news h2 {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 700;
  margin-bottom: 2.5rem;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.news-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: .6rem;
  transition: box-shadow var(--transition);
}
.news-card:hover { box-shadow: var(--shadow-md); }

.news-date { font-size: .78rem; color: var(--color-muted); font-weight: 600; }
.news-card h3 { font-size: .95rem; font-weight: 600; line-height: 1.4; }
.news-card p { font-size: .875rem; color: var(--color-muted); flex: 1; }
.news-card a { font-size: .85rem; font-weight: 600; color: var(--color-accent); align-self: flex-start; }

/* --- Footer --- */
.site-footer {
  background: var(--color-primary);
  color: rgba(255,255,255,.85);
  padding: 3.5rem 0 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255,255,255,.1);
}

.footer-brand .logo { color: #fff; margin-bottom: .5rem; }
.footer-brand p { font-size: .875rem; opacity: .7; }

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.footer-nav a { font-size: .875rem; opacity: .8; transition: opacity var(--transition); }
.footer-nav a:hover { opacity: 1; text-decoration: none; }

.footer-contact p { font-size: .875rem; margin-bottom: .4rem; }
.footer-contact a { color: inherit; opacity: .9; }
.footer-contact a:hover { opacity: 1; }

.footer-bottom {
  text-align: center;
  padding: 1.25rem;
  font-size: .8rem;
  opacity: .5;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .two-col { grid-template-columns: 1fr; gap: 2rem; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .image-block { order: -1; }
}

@media (max-width: 640px) {
  .main-nav { display: none; }
  .main-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--color-bg);
    border-bottom: 1px solid var(--color-border);
    padding: 1rem 1.5rem;
    gap: 1rem;
    box-shadow: var(--shadow-md);
    z-index: 200;
  }
  .menu-toggle { display: block; }
  .btn.btn-primary.header-cta { display: none; }
  .footer-inner { grid-template-columns: 1fr; }
  .hero { padding: 4rem 0 3rem; }
}
