:root {
  --color-bg: #282421;          /* dark brown/soil */
  --color-bg-alt: #352d24;      /* slightly warmer panel bg */
  --color-surface: #4c5136;     /* window / card background */

  --color-primary: #e0a437;     /* golden graph / highlight */
  --color-primary-dark: #b17f29;

  --color-accent-blue: #b3ced7; /* snowy sky / glass */
  --color-accent-red: #a52222;  /* company red / alerts */
  --color-accent-green: #60A06A;/* foliage / profitable lines */

  --color-text: #f5f2e6;        /* light warm UI text */
  --color-muted: #cfc8b4;       /* secondary labels */
  --color-border: #3f3830;      /* window frames */

  --radius-lg: 18px;
  --radius-md: 12px;
  --shadow-soft: 0 12px 30px rgba(11, 8, 4, 0.6);
  --max-width: 1000px;
}

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

html, body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
}

a { color: var(--color-primary); }
a:hover { color: var(--color-primary-dark); }

/* Layout */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.2rem; }
.section { padding: 4rem 0; position: relative; }
.section-alt { background: var(--color-bg-alt); }
.section h2 { font-size: 1.9rem; margin: 0 0 0.6rem; }
.section-intro { max-width: 640px; margin: 0 0 1.4rem; color: var(--color-muted); }
.two-columns { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 2.2rem; align-items: start; }
.three-columns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.6rem; }
@media (max-width: 900px) { .two-columns, .three-columns { grid-template-columns: 1fr; } }

/* Header */
.site-header { background: rgba(11, 16, 33, 0.9); backdrop-filter: blur(12px); position: sticky; top: 0; z-index: 100; border-bottom: 1px solid rgba(255, 255, 255, 0.04); }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 0.65rem 0; }
.logo { display: flex; align-items: center; gap: 0.45rem; font-weight: 600; }
.logo-mark { width: 28px; height: 28px; border-radius: 8px; background: linear-gradient(135deg, var(--color-primary), var(--color-accent-blue)); display: inline-flex; align-items: center; justify-content: center; color: #0b1021; font-size: 0.8rem; font-weight: 700; }
.logo-text { font-size: 1rem; }
.nav { display: flex; gap: 1rem; font-size: 0.9rem; }
.nav a { text-decoration: none; color: var(--color-muted); padding: 0.3rem 0.35rem; }
.nav a:hover { color: var(--color-text); }
@media (max-width: 720px) { .nav { display: none; } }

/* Hero */
.hero { padding: 4.25rem 0 3.5rem; position: relative; overflow: hidden; }
.hero-background { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; }
.hero-background img { width: 100%; height: 100%; object-fit: cover; }
.hero::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(135deg, rgba(40, 36, 33, 0.85), rgba(40, 36, 33, 0.75)); z-index: 2; }
.hero-content { position: relative; z-index: 3; display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.hero-left { text-align: left; }
.hero-left .pill-row { justify-content: flex-start; }
.hero-right { display: flex; justify-content: flex-end; }
.eyebrow { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.25rem 0.55rem; border-radius: 999px; background: rgba(95, 225, 193, 0.12); color: var(--color-primary); font-weight: 600; font-size: 0.8rem; letter-spacing: 0.3px; text-transform: uppercase; }
.hero-left h1 { font-size: clamp(3.4rem, 4.2vw, 4.2rem); margin: 0.55rem 0 1.2rem; line-height: 1.3; background: linear-gradient(135deg, var(--color-primary), var(--color-accent-blue)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-subtitle { font-size: 1.3rem; color: var(--color-text); max-width: 560px; margin: 0 auto 1.1rem; }
.pill-row { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 auto 0.9rem; justify-content: center; }
.pill { background: rgba(111, 227, 138, 0.12); border: 1px solid rgba(255, 255, 255, 0.06); border-color: rgba(111, 227, 138, 0.35); 
  color: var(--color-text); border-radius: 999px; padding: 0.4rem 0.75rem; font-size: 0.85rem; 
  display: inline-flex; align-items: center; gap: 0.35rem; }
.hero-highlights { list-style: none; padding: 0; margin: 1rem auto 0; font-size: 0.96rem; color: var(--color-muted); max-width: 640px; text-align: left; }
.hero-highlights li { margin-bottom: 0.45rem; padding-left: 1.3rem; position: relative; }
.hero-highlights li::before { content: "\2022"; color: var(--color-accent-red); position: absolute; left: 0; }

.tiny-note {
  font-size: 0.82rem;
  color: var(--color-muted);
  margin: 0.35rem 0 0;
}

/* Signup */
.signup-card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.5rem 0.5rem;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--color-border);
  width: 100%;
  max-width: 640px;
  margin: 2rem auto 0;
}

.signup-card h2 {
  font-size: 1.2rem;
  margin: 0 0 0.5rem;
  text-align: center;
}

.signup-subtitle {
  font-size: 0.95rem;
  color: var(--color-muted);
  margin: 0 0 1.25rem;
  text-align: center;
}

.signup-form {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 0.75rem;
}

.signup-form input[type="email"] {
  flex: 1;
  padding: 0.7rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  background: var(--color-bg-alt);
  color: var(--color-text);
  font-size: 0.9rem;
  transition: border-color 0.2s ease;
}

.signup-form input[type="email"]::placeholder {
  color: var(--color-muted);
}

.signup-form input[type="email"]:focus {
  outline: none;
  border-color: var(--color-primary);
}

.signup-form button {
  border: none;
  border-radius: var(--radius-md);
  padding: 0.7rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent-blue));
  color: var(--color-bg);
  white-space: nowrap;
  transition: opacity 0.2s ease;
}

.signup-form button:hover {
  opacity: 0.9;
}

.signup-footer {
  font-size: 0.8rem;
  color: var(--color-muted);
  margin: 0;
  text-align: center;
}

/* OAuth Signup Styles */
.auth-section {
  margin-bottom: 1.25rem;
}

.oauth-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.oauth-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.2s ease;
  border: 1px solid transparent;
  margin: 0 1rem;
  cursor: pointer;
}

.oauth-logo {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.oauth-button:hover {
  opacity: 0.9;
  text-decoration: none;
}

.google-button {
  background: #ffffff;
  color: #333333;
  border-color: #dadce0;
}

.google-button:hover {
  background: #f8f9fa;
}

.microsoft-button {
  background: #ffffff;
  color: #333333;
  border-color: #dadce0;
}

.microsoft-button:hover {
  background: #f8f9fa;
}

.privacy-note {
  font-size: 0.8rem;
  color: var(--color-muted);
  text-align: center;
  margin: 1.25rem 0 0;
  font-style: italic;
}

/* Align sign out button to the left */
#back-home-btn {
  margin: 0;
}

.button-row {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-top: 2rem;
}

.status-message {
  font-size: 0.85rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-md);
  text-align: center;
  font-weight: 500;
  margin-top: 1rem;
}

.status-message.loading {
  background: rgba(224, 160, 55, 0.1);
  color: var(--color-primary);
  border: 1px solid rgba(224, 160, 55, 0.3);
}

.status-message.success {
  background: #242B25;
  color: var(--color-accent-green);
  border: 1px solid #60A06A;
}

.status-message.error {
  background: #2B2525;
  color: var(--color-accent-red);
  border: 1px solid #a52222;
}

/* Hero visual */
.image-placeholder { border: none; background: none; min-height: auto; padding: 0; }
.hero-image { width: 100%; max-width: 640px; margin: 2rem auto; }
.hero-image img { width: 100%; height: auto; display: block; border-radius: var(--radius-lg); }
.image-placeholder.small { min-height: 160px; }
.image-stack { display: flex; flex-direction: column; gap: 1rem; }

.image-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-surface);
  box-shadow: var(--shadow-soft);
  max-width: 640px;
  margin: 0 auto;
}

.image-card img {
  display: block;
  width: 100%;
  height: auto;
}

/* Steps */
.step-card { background: var(--color-surface); border-radius: var(--radius-md); padding: 1.05rem 1.1rem 1rem; border: 1px solid var(--color-border); }
.step-card h3 { margin: 0.45rem 0 0.35rem; font-size: 1rem; }
.step-card p { margin: 0; font-size: 0.93rem; color: var(--color-muted); }
.step-number { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 999px; 
  background: rgba(95, 225, 193, 0.15); color: var(--color-text); font-size: 0.9rem; font-weight: 700; }

/* Lists */
.bullet-list { padding-left: 1.2rem; margin: 0 0 0.75rem; }
.bullet-list li { margin-bottom: 0.35rem; font-size: 0.95rem; color: var(--color-muted); }

/* Data grid */
.data-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.1rem;
  margin-bottom: 1.5rem;
}
.data-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); padding: 1rem 1rem 0.9rem; }
.data-card h3 { margin: 0 0 0.3rem; font-size: 1rem; }
.data-card p { margin: 0; color: var(--color-muted); font-size: 0.92rem; }
.inline-note { margin-top: 1.15rem; color: var(--color-muted); font-size: 0.9rem; }

/* Code block */
.code-block {
  background: #000;
  color: #fff;
  border-radius: var(--radius-md);
  padding: 1rem 1.1rem;
  overflow-x: auto;
  font-size: 0.85rem;
  line-height: 1.5;
  border: 1px solid #1a1a1a;
  max-width: 640px;
  margin: 1.2rem auto;
}
.code-block code { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }

/* Responsive adjustments */
@media (max-width: 720px) {
  .container { padding: 0 1rem; }
  .section { padding: 3rem 0 2.6rem; }
  .section h2 { font-size: 1.55rem; }
  .section-intro { font-size: 0.95rem; }

  .hero { padding: 3.2rem 0 2.6rem; }
  .hero-content { grid-template-columns: 1fr; gap: 2rem; text-align: center; }
  .hero-background img { object-position: center center; }
  .hero-left { text-align: center; }
  .hero-left .pill-row { justify-content: center; }
  .hero-right { justify-content: center; }
  .hero-left h1 { font-size: clamp(2.4rem, 7vw, 3.0rem); line-height: 1.3; }
  .hero-subtitle { font-size: 0.95rem; color: var(--color-text); max-width: 100%; margin: 0 auto 1rem; padding: 0 0.35rem; }
  .eyebrow { font-size: 0.78rem; padding: 0.22rem 0.55rem; }
  .pill { font-size: 0.82rem; padding: 0.35rem 0.7rem; }
  .hero-highlights { max-width: 100%; font-size: 0.9rem; }

  .signup-card { padding: 1.35rem; margin: 1.6rem auto 0; }
  .signup-form { flex-direction: column; align-items: stretch; gap: 0.65rem; }
  .signup-form button { width: 100%; }

  .oauth-buttons {
    gap: 0.65rem;
  }
  .oauth-button {
    padding: 0.65rem 0.9rem;
    font-size: 0.88rem;
  }
  .send-link-button { font-size: 0.9rem; }
  .status-message { font-size: 0.82rem; padding: 0.45rem 0.7rem; }

  .hero-image { max-width: 100%; margin: 1.6rem auto; }
  .image-card { max-width: 100%; }
  .code-block { max-width: 100%; }

  .step-card { padding: 1rem; }
  .data-grid { gap: 0.9rem; }
}

@media (max-width: 480px) {
  .section { padding: 2.6rem 0 2.2rem; }
  .section h2 { font-size: 1.4rem; }
  .section-intro { font-size: 0.9rem; }

  .hero { padding: 2.8rem 0 2.2rem; }
  .hero-content { grid-template-columns: 1fr; gap: 1.5rem; }
  .hero-background img { object-position: center center; min-height: 100%; }
  .hero-left h1 { font-size: clamp(2.0rem, 7.5vw, 2.4rem); line-height: 1.3; }
  .hero-subtitle { font-size: 0.9rem; color: var(--color-text); padding: 0 0.4rem; }
  .pill { font-size: 0.78rem; padding: 0.32rem 0.65rem; }
  .hero-highlights { font-size: 0.88rem; }

  .signup-card { padding: 1.2rem; }
  .signup-subtitle { font-size: 0.9rem; }
  .signup-form input[type="email"] { font-size: 0.88rem; padding: 0.65rem 0.8rem; }
  .signup-form button { font-size: 0.9rem; }

  .code-block { font-size: 0.82rem; }
}

/* Footer */
.site-footer { border-top: 1px solid rgba(255, 255, 255, 0.08); background: #0b0f1c; padding: 1.4rem 0; margin-top: 1.5rem; font-size: 0.88rem; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }
.footer-links { margin: 0; display: flex; gap: 0.45rem; align-items: center; color: var(--color-muted); }
.footer-links a { color: var(--color-muted); text-decoration: none; }
.footer-links a:hover { color: var(--color-text); }
@media (max-width: 640px) { .footer-inner { flex-direction: column; align-items: flex-start; } }

/* Accessibility */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }

/* About page styles */
.about-content {
  max-width: 1200px;
  margin: 0 auto;
}

.about-header {
  text-align: center;
  margin-bottom: 4rem;
}

.about-header h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  color: var(--color-text);
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.about-card {
  background: var(--color-surface);
  padding: 2rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease;
}

.about-card:hover {
  transform: translateY(-2px);
}

.about-card h2 {
  color: var(--color-primary);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.developer-card {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
  color: var(--color-bg);
}

.developer-card h2,
.developer-card h3 {
  color: var(--color-bg);
}

.developer-info h3 {
  margin: 0 0 1rem 0;
  font-size: 1.8rem;
}

.developer-info p {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.linkedin-section {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.3);
}

.linkedin-button {
  display: inline-flex;
  align-items: center;
  background: #0077b5;
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.2s ease;
}

.linkedin-button:hover {
  background: #005885;
}

.feedback-section {
  background: var(--color-bg-alt);
  padding: 3rem;
  border-radius: var(--radius-lg);
  text-align: center;
}

.feedback-section h2 {
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.feedback-section p {
  margin-bottom: 1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}
