/* Loftly Investor Page Styles v2
 * Design system matched to pitch deck (deck.html)
 * WCAG AA compliant contrast ratios
 */

/* ===== Design System Variables ===== */
:root {
  /* Primary Colors */
  --ocean: #1a5276;
  --ocean-dark: #0d3a52;
  --terracotta: #c17555;
  --sand: #e8dcca;
  --olive: #566e3d;
  --turquoise: #45b5aa;
  --cream: #fdfbf7;

  /* Text Colors - WCAG AA compliant */
  --text: #333333;
  --text-light: #555555; /* 7:1 on white */
  --muted: #666666; /* 5.7:1 on white - passes AA */
  --white: #ffffff;

  /* Backgrounds */
  --bg-light: #f5f5f5;
  --bg-alt: #f8f9fa;

  /* Shadows */
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.12);

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  /* Spacing */
  --section-padding: 100px 0;
  --container-max: 1200px;
}

/* ===== Typography ===== */
body {
  font-family: 'Raleway', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  line-height: 1.6;
  font-size: 18px;
  background: var(--white);
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 600;
  line-height: 1.2;
}

h1 {
  font-size: 4rem;
  margin-bottom: 24px;
}

h2 {
  font-size: 2.8rem;
  color: var(--ocean);
  margin-bottom: 20px;
}

h3 {
  font-size: 1.8rem;
  color: var(--ocean);
  margin-bottom: 16px;
}

h4 {
  font-size: 1.4rem;
  color: var(--ocean);
  margin-bottom: 12px;
}

p {
  font-size: 1.1rem;
  margin-bottom: 20px;
  color: var(--text);
}

.kicker {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--terracotta);
  margin-bottom: 12px;
  font-weight: 600;
}

.center-text {
  text-align: center;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== Layout ===== */
.inv-container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 40px;
}

.inv-section {
  padding: var(--section-padding);
}

.inv-section--cream {
  background: var(--cream);
}

.inv-section--light {
  background: var(--bg-light);
}

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

.inv-section--white {
  background: var(--white);
}

/* ===== Hero Section ===== */
.inv-hero {
  min-height: 85vh;
  background: linear-gradient(135deg, rgba(26, 82, 118, 0.75) 0%, rgba(13, 58, 82, 0.85) 100%),
              url('../images/hero/hero-image-sunset-social1.jpeg') center/cover;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 120px 40px;
  color: var(--white);
}

.inv-hero h1 {
  color: var(--white);
  font-size: 4.5rem;
  max-width: 900px;
}

.inv-hero .tagline {
  font-size: 1.4rem;
  max-width: 800px;
  opacity: 0.95;
  margin-bottom: 50px;
  line-height: 1.7;
}

/* ===== Metric Cards ===== */
.inv-metrics {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 30px;
  margin: 50px 0;
}

.inv-metric-card {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 30px 40px;
  border-radius: var(--radius-lg);
  text-align: center;
  min-width: 180px;
}

.inv-metric-card--solid {
  background: var(--white);
  border: none;
  box-shadow: var(--shadow-md);
  color: var(--text);
}

.inv-metric-card h3 {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: inherit;
  opacity: 0.8;
  margin-bottom: 8px;
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
}

.inv-metric-card .value {
  font-family: 'Playfair Display', serif;
  font-size: 2.8rem;
  font-weight: 600;
  color: var(--turquoise);
}

.inv-metric-card--solid .value {
  color: var(--ocean);
}

/* ===== Stat Grid ===== */
.inv-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  margin: 50px 0;
}

.inv-stat-card {
  background: var(--white);
  padding: 35px;
  border-radius: var(--radius-lg);
  text-align: center;
  box-shadow: var(--shadow-md);
}

.inv-stat-card .value {
  font-family: 'Playfair Display', serif;
  font-size: 3rem;
  color: var(--ocean);
  margin-bottom: 8px;
}

.inv-stat-card .label {
  font-size: 1rem;
  color: var(--muted);
}

/* ===== Cards ===== */
.inv-card {
  background: var(--white);
  padding: 35px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.inv-card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 25px;
}

.inv-card--gradient {
  background: linear-gradient(135deg, var(--ocean) 0%, var(--ocean-dark) 100%);
  color: var(--white);
}

.inv-card--gradient h3 {
  color: var(--turquoise);
}

/* ===== Problem Cards ===== */
.inv-problem-card {
  background: var(--white);
  padding: 25px 30px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border-left: 5px solid var(--terracotta);
}

.inv-problem-card h4 {
  color: var(--ocean);
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.inv-problem-card ul {
  margin: 0 0 15px 20px;
  color: var(--text-light);
}

.inv-problem-card li {
  margin-bottom: 6px;
  font-size: 0.95rem;
}

.inv-solution-badge {
  display: inline-block;
  background: rgba(69, 181, 170, 0.12);
  color: var(--turquoise);
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid rgba(69, 181, 170, 0.3);
}

/* ===== Tables ===== */
.inv-table-container {
  overflow-x: auto;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  margin: 40px 0;
}

.inv-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
}

.inv-table th {
  background: var(--ocean);
  color: var(--white);
  padding: 18px 20px;
  text-align: left;
  font-weight: 600;
}

.inv-table td {
  padding: 16px 20px;
  border-bottom: 1px solid #eee;
  color: var(--text);
}

.inv-table tr:nth-child(even) {
  background: var(--bg-alt);
}

.inv-table .highlight-row {
  background: #e8f4ff !important;
  font-weight: 600;
}

.inv-table .highlight-row td {
  color: var(--ocean);
}

/* ===== Allocation Cards ===== */
.inv-allocation-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 40px 0;
}

.inv-allocation-card {
  background: var(--white);
  padding: 25px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.inv-allocation-card h4 {
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 12px;
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
}

.inv-allocation-card .amount {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  color: var(--ocean);
  margin-bottom: 8px;
}

.inv-allocation-card .percentage {
  display: inline-block;
  background: #e8f4ff;
  padding: 6px 14px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--ocean);
}

/* ===== Two Column Layout ===== */
.inv-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: start;
}

/* ===== Feature Lists ===== */
.inv-feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.inv-feature-list li {
  padding: 10px 0;
  padding-left: 30px;
  position: relative;
  font-size: 1.05rem;
  color: var(--text);
}

.inv-feature-list li::before {
  content: '\2713';
  position: absolute;
  left: 0;
  color: var(--turquoise);
  font-weight: bold;
  font-size: 1.1rem;
}

/* ===== Team Section ===== */
.inv-team-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  max-width: 900px;
  margin: 50px auto;
}

.inv-team-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.inv-team-card .photo {
  height: 280px;
  background-size: cover;
  background-position: center top;
}

.inv-team-card .info {
  padding: 25px 30px;
}

.inv-team-card h3 {
  margin: 0 0 5px;
  font-size: 1.5rem;
}

.inv-team-card .role {
  color: var(--terracotta);
  font-weight: 600;
  margin-bottom: 12px;
}

.inv-team-card .bio {
  font-size: 0.95rem;
  color: var(--muted);
  margin: 0;
  line-height: 1.6;
}

/* ===== CTA Section ===== */
.inv-cta {
  background: linear-gradient(135deg, var(--ocean) 0%, var(--ocean-dark) 100%);
  color: var(--white);
  padding: 100px 40px;
  text-align: center;
}

.inv-cta h2 {
  color: var(--white);
  font-size: 3rem;
}

.inv-cta p {
  color: rgba(255, 255, 255, 0.9);
  max-width: 700px;
  margin: 0 auto 30px;
}

/* ===== Buttons ===== */
.inv-btn {
  display: inline-block;
  padding: 16px 36px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
}

.inv-btn--primary {
  background: var(--terracotta);
  color: var(--white);
}

.inv-btn--primary:hover {
  background: #a86245;
  transform: translateY(-2px);
}

.inv-btn--secondary {
  background: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}

.inv-btn--secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.inv-btn--outline {
  background: transparent;
  color: var(--ocean);
  border: 2px solid var(--ocean);
}

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

.inv-btn-group {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===== Forms ===== */
.inv-form {
  background: var(--white);
  padding: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 500px;
  margin: 0 auto;
}

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

.inv-form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: var(--text);
}

.inv-form-group input,
.inv-form-group select,
.inv-form-group textarea {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e0e0e0;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.2s;
}

.inv-form-group input:focus,
.inv-form-group select:focus,
.inv-form-group textarea:focus {
  outline: none;
  border-color: var(--ocean);
}

.inv-form .inv-btn {
  width: 100%;
  padding: 18px;
  font-size: 1.1rem;
}

/* ===== Modal ===== */
.inv-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.inv-modal-overlay.active {
  display: flex;
}

.inv-modal {
  background: var(--white);
  padding: 50px;
  border-radius: var(--radius-lg);
  max-width: 500px;
  width: 100%;
  position: relative;
  animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.inv-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--muted);
  cursor: pointer;
}

.inv-modal-close:hover {
  color: var(--text);
}

.inv-modal h3 {
  text-align: center;
  margin-bottom: 10px;
}

.inv-modal p {
  text-align: center;
  color: var(--muted);
  margin-bottom: 30px;
}

/* ===== Success/Error States ===== */
.inv-success {
  background: #d4edda;
  color: #155724;
  padding: 20px;
  border-radius: var(--radius-sm);
  text-align: center;
}

.inv-error {
  background: #f8d7da;
  color: #721c24;
  padding: 20px;
  border-radius: var(--radius-sm);
  text-align: center;
}

/* ===== Callout Box ===== */
.inv-callout {
  background: #e8f4ff;
  padding: 30px 35px;
  border-radius: var(--radius-md);
  text-align: center;
}

.inv-callout--sand {
  background: var(--sand);
}

.inv-callout p {
  margin: 0;
  font-size: 1.2rem;
}

/* ===== Footnotes ===== */
.inv-footnotes {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 40px;
  line-height: 1.6;
}

.inv-footnotes a {
  color: var(--ocean);
}

.sup {
  font-size: 0.6em;
  vertical-align: super;
  color: var(--terracotta);
  font-weight: bold;
}

/* ===== Image with Overlay Section ===== */
.inv-section--overlay {
  background-size: cover;
  background-position: center;
  position: relative;
  color: var(--white);
}

.inv-section--overlay::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(86, 110, 61, 0.85) 0%, rgba(61, 79, 42, 0.9) 100%);
}

.inv-section--overlay > * {
  position: relative;
  z-index: 1;
}

.inv-section--overlay h2,
.inv-section--overlay h3 {
  color: var(--white);
}

.inv-section--overlay .kicker {
  color: var(--sand);
}

/* ===== Responsive ===== */
@media (max-width: 1200px) {
  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2.2rem;
  }

  .inv-hero h1 {
    font-size: 3.5rem;
  }

  .inv-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .inv-allocation-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .inv-container {
    padding: 0 30px;
  }

  .inv-section {
    padding: 80px 0;
  }

  .inv-two-col {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .inv-card-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  h1 {
    font-size: 2.4rem;
  }

  h2 {
    font-size: 1.8rem;
  }

  .inv-hero {
    min-height: auto;
    padding: 80px 20px;
  }

  .inv-hero h1 {
    font-size: 2.5rem;
  }

  .inv-hero .tagline {
    font-size: 1.1rem;
  }

  .inv-metrics {
    flex-direction: column;
    align-items: center;
  }

  .inv-metric-card {
    width: 100%;
    max-width: 300px;
  }

  .inv-stats-grid {
    grid-template-columns: 1fr;
  }

  .inv-allocation-grid {
    grid-template-columns: 1fr;
  }

  .inv-team-grid {
    grid-template-columns: 1fr;
  }

  .inv-btn-group {
    flex-direction: column;
    align-items: center;
  }

  .inv-btn {
    width: 100%;
    max-width: 300px;
    text-align: center;
  }

  .inv-table {
    font-size: 0.9rem;
  }

  .inv-table th,
  .inv-table td {
    padding: 12px 14px;
  }

  .inv-form {
    padding: 30px 25px;
  }

  .inv-modal {
    padding: 35px 25px;
  }
}

@media (max-width: 480px) {
  .inv-container {
    padding: 0 20px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.6rem;
  }

  .inv-section {
    padding: 60px 0;
  }

  .inv-hero h1 {
    font-size: 2rem;
  }

  .inv-metric-card .value {
    font-size: 2.2rem;
  }
}
