/* ============================================
   The Advisory Register - Stylesheet
   Established 2019
   ============================================ */

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

:root {
  --navy: #0B1D3A;
  --navy-light: #132B52;
  --gold: #8B6914;
  --gold-light: #A67F1E;
  --white: #FFFFFF;
  --off-white: #FAFAFA;
  --gray-50: #F8F9FA;
  --gray-100: #F1F3F5;
  --gray-200: #E9ECEF;
  --gray-300: #DEE2E6;
  --gray-400: #CED4DA;
  --gray-500: #ADB5BD;
  --gray-600: #868E96;
  --gray-700: #495057;
  --gray-800: #343A40;
  --gray-900: #212529;
  --serif: Georgia, 'Times New Roman', Times, serif;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --max-width: 1200px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.1);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  color: var(--gray-800);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 {
  font-family: var(--serif);
  color: var(--navy);
  font-weight: 700;
  line-height: 1.25;
}

h1 { font-size: 2.2rem; }
h2 { font-size: 1.7rem; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }

a {
  color: var(--navy);
  text-decoration: none;
  transition: color 0.2s;
}
a:hover {
  color: var(--gold);
}

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

/* ============================================
   Header
   ============================================ */
.site-header {
  background: var(--navy);
  border-bottom: 2px solid var(--gold);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 64px;
}

.site-logo {
  font-family: var(--serif);
  font-size: 1.2rem;
  color: var(--white);
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.site-logo span {
  color: var(--gold);
}

.main-nav {
  display: flex;
  gap: 32px;
  list-style: none;
}

.main-nav a {
  color: rgba(255,255,255,0.8);
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 4px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--white);
  border-bottom-color: var(--gold);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
}

/* ============================================
   Hero / Home
   ============================================ */
.hero {
  background: var(--gray-50);
  border-bottom: 1px solid var(--gray-200);
  padding: 64px 24px;
  text-align: center;
}

.hero h1 {
  font-size: 2.4rem;
  margin-bottom: 12px;
}

.hero .tagline {
  font-family: var(--serif);
  font-size: 1.15rem;
  color: var(--gray-600);
  font-style: italic;
  margin-bottom: 36px;
}

.search-box {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 14px 20px 14px 44px;
  font-size: 1rem;
  border: 1px solid var(--gray-300);
  border-radius: 4px;
  font-family: var(--sans);
  background: var(--white);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-box input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(139,105,20,0.1);
}

.search-box .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-500);
  font-size: 1.1rem;
}

/* ============================================
   Stats Bar
   ============================================ */
.stats-bar {
  background: var(--navy);
  color: var(--white);
  padding: 20px 24px;
  text-align: center;
}

.stats-bar-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}

.stat-item {
  font-size: 0.92rem;
  letter-spacing: 0.04em;
}

.stat-item strong {
  color: var(--gold);
  font-size: 1.1rem;
  margin-right: 6px;
}

/* ============================================
   Section Containers
   ============================================ */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 56px 24px;
}

.section-alt {
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
}

.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-header h2 {
  margin-bottom: 8px;
}

.section-header p {
  color: var(--gray-600);
  font-size: 0.95rem;
  max-width: 560px;
  margin: 0 auto;
}

/* ============================================
   Advisor Cards
   ============================================ */
.advisor-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.advisor-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 4px;
  padding: 20px;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.advisor-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--gray-300);
}

.advisor-card .advisor-name {
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 2px;
}

.advisor-card .advisor-firm {
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-bottom: 8px;
}

.advisor-card .advisor-meta {
  font-size: 0.82rem;
  color: var(--gray-500);
  margin-bottom: 4px;
}

.advisor-card .advisor-specialty {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gold);
  background: rgba(139,105,20,0.08);
  padding: 3px 8px;
  border-radius: 2px;
  margin-top: 8px;
}

.advisor-card .advisor-desc {
  font-size: 0.84rem;
  color: var(--gray-700);
  margin-top: 10px;
  line-height: 1.5;
}

.advisor-card .advisor-size {
  font-size: 0.8rem;
  color: var(--gray-500);
  margin-top: 6px;
}

/* Featured advisors on home */
.featured-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.featured-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-top: 3px solid var(--gold);
  border-radius: 4px;
  padding: 24px;
  text-align: center;
}

.featured-card .advisor-name {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--navy);
  font-weight: 700;
  margin-bottom: 4px;
}

.featured-card .advisor-firm {
  font-size: 0.85rem;
  color: var(--gray-600);
  margin-bottom: 4px;
}

.featured-card .advisor-location {
  font-size: 0.82rem;
  color: var(--gray-500);
  margin-bottom: 10px;
}

.featured-card .advisor-specialty {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gold);
  background: rgba(139,105,20,0.08);
  padding: 3px 10px;
  border-radius: 2px;
}

/* Recent additions list */
.recent-list {
  max-width: 700px;
  margin: 0 auto;
}

.recent-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--gray-200);
}

.recent-item:last-child {
  border-bottom: none;
}

.recent-item .name {
  font-family: var(--serif);
  font-weight: 700;
  color: var(--navy);
  font-size: 0.95rem;
}

.recent-item .detail {
  font-size: 0.82rem;
  color: var(--gray-500);
}

/* ============================================
   Register Page - Filters
   ============================================ */
.register-header {
  background: var(--gray-50);
  border-bottom: 1px solid var(--gray-200);
  padding: 40px 24px 32px;
  text-align: center;
}

.register-header h1 {
  margin-bottom: 8px;
}

.register-header p {
  color: var(--gray-600);
  font-size: 0.95rem;
}

.filters-bar {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  padding: 16px 24px;
  position: sticky;
  top: 64px;
  z-index: 50;
  box-shadow: var(--shadow-sm);
}

.filters-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.filters-inner input,
.filters-inner select {
  padding: 8px 12px;
  font-size: 0.88rem;
  border: 1px solid var(--gray-300);
  border-radius: 3px;
  font-family: var(--sans);
  background: var(--white);
}

.filters-inner input {
  flex: 1;
  min-width: 200px;
}

.filters-inner select {
  min-width: 160px;
}

.filters-inner input:focus,
.filters-inner select:focus {
  outline: none;
  border-color: var(--gold);
}

.results-count {
  max-width: var(--max-width);
  margin: 16px auto 0;
  padding: 0 24px;
  font-size: 0.88rem;
  color: var(--gray-600);
}

.register-grid {
  max-width: var(--max-width);
  margin: 20px auto 60px;
  padding: 0 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

/* ============================================
   About / Content Pages
   ============================================ */
.page-header {
  background: var(--gray-50);
  border-bottom: 1px solid var(--gray-200);
  padding: 48px 24px;
  text-align: center;
}

.page-header h1 {
  margin-bottom: 8px;
}

.page-header p {
  color: var(--gray-600);
  font-size: 0.95rem;
  max-width: 600px;
  margin: 0 auto;
}

.content-section {
  max-width: 780px;
  margin: 0 auto;
  padding: 48px 24px;
}

.content-section h2 {
  margin-top: 36px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--gray-200);
}

.content-section h2:first-child {
  margin-top: 0;
}

.content-section p {
  margin-bottom: 16px;
  color: var(--gray-700);
  line-height: 1.7;
}

.content-section ul, .content-section ol {
  margin-bottom: 16px;
  padding-left: 24px;
}

.content-section li {
  margin-bottom: 8px;
  color: var(--gray-700);
  line-height: 1.6;
}

/* ============================================
   Form (For Advisors)
   ============================================ */
.form-section {
  max-width: 640px;
  margin: 0 auto;
  padding: 48px 24px;
}

.form-section h2 {
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--gray-800);
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  font-size: 0.92rem;
  border: 1px solid var(--gray-300);
  border-radius: 3px;
  font-family: var(--sans);
  background: var(--white);
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(139,105,20,0.08);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.btn-submit {
  display: inline-block;
  background: var(--navy);
  color: var(--white);
  font-size: 0.92rem;
  font-weight: 600;
  padding: 12px 32px;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.2s;
  font-family: var(--sans);
}

.btn-submit:hover {
  background: var(--navy-light);
}

.form-note {
  font-size: 0.82rem;
  color: var(--gray-500);
  margin-top: 16px;
}

/* ============================================
   Insights / Articles
   ============================================ */
.articles-grid {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 48px 24px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.article-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: 4px;
  padding: 24px;
  transition: box-shadow 0.2s;
}

.article-card:hover {
  box-shadow: var(--shadow-md);
}

.article-card .article-date {
  font-size: 0.78rem;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.article-card h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  line-height: 1.35;
}

.article-card p {
  font-size: 0.88rem;
  color: var(--gray-600);
  line-height: 1.55;
}

.article-card .read-more {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.loading-message {
  text-align: center;
  padding: 48px 24px;
  color: var(--gray-500);
  font-style: italic;
}

/* ============================================
   Footer
   ============================================ */
.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.6);
  padding: 40px 24px;
  font-size: 0.84rem;
  border-top: 2px solid var(--gold);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 32px;
}

.footer-brand {
  max-width: 320px;
}

.footer-brand .logo-text {
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--white);
  font-weight: 700;
  margin-bottom: 8px;
}

.footer-brand p {
  line-height: 1.55;
}

.footer-links h4 {
  font-family: var(--sans);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.4);
  margin-bottom: 12px;
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin-bottom: 6px;
}

.footer-links a {
  color: rgba(255,255,255,0.6);
  font-size: 0.84rem;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--white);
}

.footer-bottom {
  max-width: var(--max-width);
  margin: 32px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.35);
}

/* ============================================
   CTA Banner
   ============================================ */
.cta-banner {
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
  text-align: center;
  padding: 48px 24px;
}

.cta-banner h2 {
  margin-bottom: 8px;
}

.cta-banner p {
  color: var(--gray-600);
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.btn-outline {
  display: inline-block;
  padding: 10px 28px;
  border: 1px solid var(--navy);
  color: var(--navy);
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 3px;
  transition: background 0.2s, color 0.2s;
}

.btn-outline:hover {
  background: var(--navy);
  color: var(--white);
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 900px) {
  .advisor-grid,
  .featured-grid,
  .register-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .articles-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .stats-bar-inner {
    gap: 24px;
  }
}

@media (max-width: 700px) {
  .nav-toggle {
    display: block;
  }
  .main-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--navy);
    flex-direction: column;
    gap: 0;
    padding: 12px 24px;
    border-bottom: 2px solid var(--gold);
  }
  .main-nav.open {
    display: flex;
  }
  .main-nav a {
    padding: 10px 0;
  }
  .advisor-grid,
  .featured-grid,
  .register-grid {
    grid-template-columns: 1fr;
  }
  .articles-grid {
    grid-template-columns: 1fr;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .filters-inner {
    flex-direction: column;
  }
  .filters-inner input,
  .filters-inner select {
    width: 100%;
    min-width: unset;
  }
  .hero h1 {
    font-size: 1.8rem;
  }
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.4rem; }
  .footer-inner {
    flex-direction: column;
  }
}
