/* =============================================
   PETROLYT — Internal App Stylesheet
   Theme: Dark (#141414) + Gold (#ffcf63)
   ============================================= */

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

:root {
  --bg:          #141414;
  --bg-card:     #1e1e1e;
  --bg-input:    #252525;
  --gold:        #ffcf63;
  --gold-dark:   #c8900c;
  --gold-hover:  #9b700b;
  --amber:       #d0960f;
  --text:        #f0f0f0;
  --text-sub:    wheat;
  --text-muted:  #888;
  --border:      #2e2e2e;
  --border-gold: rgba(255, 207, 99, 0.3);
  --danger:      #e55;
  --success:     #4caf7d;
}

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
  padding-top: 80px; /* offset fixed navbar */
}

/* =============================================
   SCROLLBARS — gold on dark (page + every overflow host)
   Firefox: scrollbar-*; WebKit/Chromium: ::-webkit-scrollbar*
   ============================================= */
html,
body,
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 207, 99, 0.55) rgba(255, 255, 255, 0.05);
}

*::-webkit-scrollbar {
  width: 11px;
  height: 11px;
}
*::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
}
html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track {
  background: #0a0a0a;
  border-radius: 0;
}
*::-webkit-scrollbar-thumb {
  background: linear-gradient(
    180deg,
    rgba(255, 207, 99, 0.72),
    rgba(200, 144, 12, 0.78)
  );
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: padding-box;
  min-height: 36px;
  min-width: 36px;
}
*::-webkit-scrollbar-thumb:horizontal {
  background: linear-gradient(
    90deg,
    rgba(255, 207, 99, 0.72),
    rgba(200, 144, 12, 0.78)
  );
  background-clip: padding-box;
}
*::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(
    180deg,
    rgba(255, 207, 99, 0.95),
    rgba(232, 176, 40, 0.95)
  );
  background-clip: padding-box;
}
*::-webkit-scrollbar-thumb:horizontal:hover {
  background: linear-gradient(
    90deg,
    rgba(255, 207, 99, 0.95),
    rgba(232, 176, 40, 0.95)
  );
  background-clip: padding-box;
}
*::-webkit-scrollbar-corner {
  background: transparent;
}
html::-webkit-scrollbar-corner,
body::-webkit-scrollbar-corner {
  background: #0a0a0a;
}

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-hover); }

/* =============================================
   NAVBAR styles live in static/css/navbar.css and are
   inlined by {% inline_navbar_css %} in main.html so a
   stale Manifest / CDN petrolyt.css hash cannot break the bar.
   ============================================= */

/* Shared CTA used by navbar Sign Up Free / Logout, 404/500, etc.
   Never use a fixed em width — "Sign Up Free" is longer than "Logout"
   and was clipped when width was locked to ~7–9em. */
.button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  background-color: var(--gold);
  color: #000;
  padding: 0.55rem 1.25rem;
  border: none;
  border-radius: 20px;
  height: auto;
  min-height: 2.5em;
  width: auto;
  max-width: none;
  min-width: 0;
  white-space: nowrap;
  overflow: visible;
  box-sizing: border-box;
  font-size: 0.95em;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.15s;
}
.button:hover {
  background-color: var(--gold-hover);
  color: #fff;
  transform: translateY(-1px);
}

.tier-badge {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 20px;
}
.tier-free     { background: #333; color: var(--text-muted); }
.tier-field    { background: rgba(255, 207, 99, 0.2); color: var(--gold); }
.tier-pro      { background: var(--gold-dark); color: #000; }
.tier-enterprise { background: linear-gradient(135deg, var(--gold), var(--amber)); color: #000; }

/* =============================================
   FLASH MESSAGES
   ============================================= */
.messages-container {
  position: sticky;
  top: 80px;
  z-index: 900;
  padding: 0.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.message {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 1.25rem;
  border-radius: 8px;
  font-size: 0.9rem;
  border-left: 4px solid var(--gold);
  background: #1c1a10;
  color: var(--text-sub);
}
.message-error   { border-left-color: var(--danger); background: #1c1010; color: #ffaaaa; }
.message-success { border-left-color: var(--success); background: #101c14; color: #aaffcc; }

/* =============================================
   APP HERO (internal pages top banner)
   ============================================= */
.app-hero {
  background: linear-gradient(135deg, #1a1500 0%, var(--bg) 60%);
  border-bottom: 1px solid var(--border-gold);
  padding: 3.5rem 50px 2rem;
}

.app-hero_container h1 {
  font-size: 2.4rem;
  color: var(--gold);
  margin-bottom: 0.4rem;
}
.app-hero_container p {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* =============================================
   MODE GRID (Tools / Home)
   ============================================= */
.modes-section {
  padding: 3rem 50px 5rem;
  min-height: 60vh;
}

.modes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.75rem;
  max-width: 1100px;
  margin: 0 auto;
}

.mode-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: border-color 0.25s, transform 0.2s, box-shadow 0.25s;
}
.mode-card:hover {
  border-color: var(--border-gold);
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(255, 207, 99, 0.08);
}

.mode-card_icon {
  width: 52px; height: 52px;
  background: rgba(255, 207, 99, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--gold);
}

.mode-card_content h3 {
  font-size: 1.25rem;
  color: var(--text);
  margin-bottom: 0.4rem;
}
.mode-card_content p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.mode-card_btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  color: var(--gold);
  font-weight: 600;
  font-size: 0.95rem;
  transition: gap 0.2s;
}
.mode-card_btn:hover { gap: 0.8rem; color: var(--gold-dark); }

/* =============================================
   AUTH PAGES (Login / Register)
   ============================================= */
.auth-section {
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  background: radial-gradient(ellipse at 50% 0%, rgba(255,207,99,0.06) 0%, transparent 70%);
}

.auth-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  width: 100%;
  max-width: 440px;
  padding: 2.5rem 2rem;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.auth-card_header {
  text-align: center;
  margin-bottom: 2rem;
}
.auth-card_header h2 {
  font-size: 1.75rem;
  color: var(--gold);
  margin-bottom: 0.4rem;
}
.auth-card_header p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.auth-error {
  background: rgba(220, 80, 80, 0.12);
  border: 1px solid rgba(220, 80, 80, 0.35);
  color: #ff9999;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.auth-form { display: flex; flex-direction: column; gap: 1.1rem; }

.form-group { display: flex; flex-direction: column; gap: 0.4rem; }

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-sub);
}

.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  padding: 0.65rem 0.9rem;
  font-size: 0.95rem;
  width: 100%;
  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(255, 207, 99, 0.12);
}

.field-error {
  font-size: 0.8rem;
  color: #ff8888;
}
.field-help {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.auth-btn {
  background: var(--gold);
  color: #000;
  border: none;
  border-radius: 8px;
  padding: 0.8rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
  transition: background 0.2s, transform 0.15s;
  width: 100%;
}
.auth-btn:hover {
  background: var(--gold-dark);
  transform: translateY(-1px);
}

.auth-card_footer {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.88rem;
  color: var(--text-muted);
}
.auth-card_footer a { color: var(--gold); font-weight: 600; }
.auth-card_footer a:hover { color: var(--gold-dark); }

/* =============================================
   UPGRADE REQUIRED
   ============================================= */
.upgrade-section {
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
}

.upgrade-card {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 16px;
  max-width: 520px;
  width: 100%;
  padding: 3rem 2.5rem;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.upgrade-icon {
  width: 72px; height: 72px;
  background: rgba(255, 207, 99, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--gold);
  margin: 0 auto 1.5rem;
}

.upgrade-card h2 {
  font-size: 1.5rem;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.upgrade-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.upgrade-limit-msg {
  background: rgba(255,207,99,0.08);
  border: 1px solid var(--border-gold);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  color: var(--text-sub);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  text-align: left;
}
.upgrade-limit-msg i { color: var(--gold); flex-shrink: 0; margin-top: 2px; }

.upgrade-desc {
  font-weight: 600;
  color: var(--text-sub);
  margin-bottom: 0.75rem;
  text-align: left;
}

.upgrade-features {
  list-style: none;
  text-align: left;
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.upgrade-features li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.9rem;
  color: var(--text-sub);
}
.upgrade-features li i { color: var(--gold); flex-shrink: 0; }

.upgrade-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.upgrade-btn {
  background: var(--gold);
  color: #000;
  font-weight: 700;
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: background 0.2s, transform 0.15s;
}
.upgrade-btn:hover { background: var(--gold-dark); color: #fff; transform: translateY(-1px); }

.back-btn {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: border-color 0.2s, color 0.2s;
}
.back-btn:hover { border-color: var(--gold); color: var(--gold); }

/* =============================================
   DASHBOARD
   ============================================= */
.dashboard-section {
  padding: 3rem 50px 5rem;
}

.dashboard-header {
  margin-bottom: 2.5rem;
}
.dashboard-header h1 {
  font-size: 2rem;
  color: var(--gold);
  margin-bottom: 0.3rem;
}
.dashboard-header p { color: var(--text-muted); }

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
  max-width: 1100px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.stat-card_icon {
  width: 48px; height: 48px;
  background: rgba(255,207,99,0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--gold);
  flex-shrink: 0;
}

.stat-card_label { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 0.2rem; }
.stat-card_value { font-size: 1.5rem; font-weight: 700; color: var(--text); }

/* =============================================
   DECLINE MODES LIST
   ============================================= */
.decline-section {
  padding: 3rem 50px 5rem;
  min-height: 60vh;
}

.section-title {
  font-size: 1.6rem;
  color: var(--gold);
  margin-bottom: 0.3rem;
}
.section-sub {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.analysis-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
  max-width: 1100px;
}

.analysis-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.2s, transform 0.2s;
}
.analysis-card:hover {
  border-color: var(--border-gold);
  transform: translateY(-3px);
}
.analysis-card h4 { font-size: 1rem; color: var(--text); }
.analysis-card p  { font-size: 0.85rem; color: var(--text-muted); }

.badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 20px;
}
.badge-free { background: #2a2a2a; color: var(--text-muted); }
.badge-pro  { background: rgba(200,144,12,0.2); color: var(--gold); border: 1px solid var(--border-gold); }

.analysis-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--gold);
  color: #000;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  margin-top: auto;
  transition: background 0.2s;
  align-self: flex-start;
}
.analysis-btn:hover { background: var(--gold-dark); color: #fff; }

.analysis-btn.locked {
  background: #2a2a2a;
  color: var(--text-muted);
}
.analysis-btn.locked:hover { background: #333; color: var(--text-muted); cursor: not-allowed; }

/* =============================================
   FORMS (Decline analysis inputs)
   ============================================= */
.form-section {
  padding: 3rem 50px 5rem;
}

.form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2.5rem;
  max-width: 720px;
}

.form-card h2 {
  font-size: 1.5rem;
  color: var(--gold);
  margin-bottom: 0.3rem;
}
.form-card .form-desc {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 2rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
}
@media (max-width: 600px) { .form-grid { grid-template-columns: 1fr; } }

.form-full { grid-column: 1 / -1; }

.submit-btn {
  background: var(--gold);
  color: #000;
  border: none;
  border-radius: 8px;
  padding: 0.8rem 2rem;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  transition: background 0.2s, transform 0.15s;
}
.submit-btn:hover { background: var(--gold-dark); transform: translateY(-1px); }

/* =============================================
   RESULTS PAGE
   ============================================= */
.results-section {
  padding: 3rem 50px 5rem;
}

.results-header {
  margin-bottom: 2rem;
}
.results-header h2 {
  font-size: 1.75rem;
  color: var(--gold);
  margin-bottom: 0.3rem;
}
.results-header p { color: var(--text-muted); }

.results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  max-width: 1200px;
}
@media (max-width: 900px) { .results-grid { grid-template-columns: 1fr; } }

.result-chart-card,
.result-data-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.75rem;
}

.result-chart-card h3,
.result-data-card h3 {
  font-size: 1.1rem;
  color: var(--gold);
  margin-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.75rem;
}

.result-chart-card svg { width: 100%; height: auto; border-radius: 6px; }

.kpi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.kpi-item {
  background: var(--bg-input);
  border-radius: 8px;
  padding: 1rem;
}
.kpi-label { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 0.3rem; }
.kpi-value { font-size: 1.2rem; font-weight: 700; color: var(--gold); }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.data-table th {
  text-align: left;
  padding: 0.6rem 0.75rem;
  background: #252525;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}
.data-table td {
  padding: 0.55rem 0.75rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-sub);
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: rgba(255,207,99,0.03); }

.results-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* =============================================
   BREADCRUMB
   ============================================= */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  padding: 1rem 50px;
  border-bottom: 1px solid var(--border);
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb .sep { opacity: 0.4; }
.breadcrumb .current { color: var(--gold); }

/* =============================================
   GENERIC UTILITIES
   ============================================= */
.page-section {
  padding: 3rem 50px 5rem;
  min-height: 60vh;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
}

.text-gold   { color: var(--gold); }
.text-muted  { color: var(--text-muted); }
.text-center { text-align: center; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }

hr.gold-divider {
  border: none;
  border-top: 1px solid var(--border-gold);
  margin: 1.5rem 0;
}

/* =============================================
   FOOTER
   ============================================= */
footer {
  border-top: 1px solid var(--border);
}

.footer-container {
  background-color: #000;
  color: var(--gold);
  padding: 4rem 0 3rem;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  flex-wrap: wrap;
}

#footer-logo {
  color: var(--gold);
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.footer_link-wrapper {
  display: flex;
  margin: 0 2rem;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer_link-items {
  display: flex;
  flex-direction: column;
  min-width: 130px;
}

.footer_link-items h2 {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}

.footer_link-items a {
  color: var(--text-sub);
  text-decoration: none;
  font-size: 0.88rem;
  margin-bottom: 0.6rem;
  transition: color 0.2s;
}
.footer_link-items a:hover { color: var(--gold); }

.social-media {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin: 0 2rem;
}

.social_media-wrap { margin-bottom: 0.5rem; }

.website-rights {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.social-icons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.social_icon-link {
  color: var(--gold);
  font-size: 1.1rem;
  transition: color 0.2s, transform 0.2s;
}
.social_icon-link:hover { color: var(--gold-dark); transform: translateY(-2px); }

@media screen and (max-width: 768px) {
  .footer-container { flex-direction: column; padding: 3rem 1rem; }
  .footer_link-wrapper { margin: 0 0 2rem; }
  .social-media { margin: 0; }
  .website-rights { margin-left: 0; }
  .social-icons { margin-left: 0; }
  .modes-section,
  .decline-section,
  .form-section,
  .results-section,
  .dashboard-section,
  .page-section { padding: 2rem 1rem 4rem; }
  .app-hero { padding: 2rem 1rem 1.5rem; }
  .breadcrumb { padding: 1rem; }
  .results-grid { grid-template-columns: 1fr; }
}

@media screen and (max-width: 480px) {
  .form-grid { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: 1fr; }
  .upgrade-actions { flex-direction: column; }
}

/* =============================================
   PRICING PAGE
   ============================================= */
.pricing-section {
  padding: 3rem 50px 5rem;
  min-height: 60vh;
}

.pricing-header {
  text-align: center;
  margin-bottom: 3rem;
}
.pricing-header h1 {
  font-size: 2.4rem;
  color: var(--gold);
  margin-bottom: 0.5rem;
}
.pricing-header > p {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 2rem;
}

.pricing-toggle {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}
.toggle-container {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.toggle-option {
  font-size: 1rem;
  color: var(--text-sub);
}
.switch {
  position: relative;
  display: inline-block;
  width: 52px;
  height: 28px;
}
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: #333;
  border-radius: 28px;
  transition: 0.3s;
}
.slider:before {
  position: absolute;
  content: "";
  height: 20px; width: 20px;
  left: 4px; bottom: 4px;
  background-color: var(--gold);
  border-radius: 50%;
  transition: 0.3s;
}
input:checked + .slider { background-color: var(--gold-dark); }
input:checked + .slider:before { transform: translateX(24px); }

.save-badge {
  background: rgba(255, 207, 99, 0.15);
  border: 1px solid var(--border-gold);
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  letter-spacing: 0.04em;
  opacity: 0.3;
  transition: opacity 0.2s;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1000px;
  margin: 0 auto 2rem;
  align-items: start;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  position: relative;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.pricing-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-gold);
  box-shadow: 0 10px 40px rgba(255, 207, 99, 0.07);
}
.pricing-card--featured {
  border-color: var(--gold-dark);
  background: linear-gradient(160deg, #201a00 0%, var(--bg-card) 50%);
}

.pricing-card_popular {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: #000;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 14px;
  border-radius: 20px;
  white-space: nowrap;
}

.pricing-card_header h3 {
  font-size: 1.4rem;
  color: var(--text);
  margin-bottom: 0.3rem;
}
.pricing-card_desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  min-height: 2.5rem;
}

.pricing-card_price {
  margin-bottom: 1.25rem;
}
.price-amount {
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
}
.price-period {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-muted);
}
.price-billed {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

.current-plan-badge {
  display: inline-block;
  background: rgba(76,175,125,0.12);
  border: 1px solid rgba(76,175,125,0.35);
  color: #4caf7d;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 6px;
  width: 100%;
  text-align: center;
}

.price-btn {
  display: block;
  width: 100%;
  padding: 0.75rem;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  border: none;
  transition: background 0.2s, transform 0.15s;
  background: var(--gold);
  color: #000;
  text-decoration: none;
}
.price-btn:hover { background: var(--gold-dark); color: #fff; transform: translateY(-1px); }

.price-btn--outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
}
.price-btn--outline:hover { border-color: var(--gold); color: var(--gold); background: transparent; }

.pricing-card_features {
  margin-top: 1.5rem;
  border-top: 1px solid var(--border);
  padding-top: 1.25rem;
}
.pricing-card_features h4 {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.85rem;
}
.pricing-card_features ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.pricing-card_features li {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.88rem;
  color: var(--text-sub);
}
.pricing-card_features li i { margin-top: 2px; flex-shrink: 0; }
.pricing-card_features .fa-check { color: var(--gold); }
.pricing-card_features .fa-xmark { color: var(--text-muted); }

.pricing-footer-note {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.82rem;
  margin-top: 2rem;
}

@media (max-width: 768px) {
  .pricing-section { padding: 2rem 1rem 4rem; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 420px; }
  .pricing-card--featured { order: -1; }
}

/* ---- BILLING / SUBSCRIPTION CARD (dashboard) ---- */
.billing-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 14px;
  padding: 1.5rem 1.75rem;
  margin: 1.5rem 0 2rem;
}
.billing-card_info { flex: 1 1 320px; }
.billing-card_info h3 { color: var(--gold); margin-bottom: 0.5rem; }
.billing-card_info p { color: var(--text-sub); margin-bottom: 0.9rem; }
.billing-card_action form { margin: 0; }

/* Run Analysis — Oil / Gas category shelves */
.analysis-category {
  margin: 2rem 0 2.5rem;
  padding: 1.15rem 1.15rem 0.35rem;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, transparent 40%),
    rgba(0, 0, 0, 0.18);
}
.analysis-category--oil {
  border-color: rgba(34, 197, 94, 0.22);
  box-shadow: inset 0 1px 0 rgba(34, 197, 94, 0.08);
}
.analysis-category--gas {
  border-color: rgba(249, 115, 22, 0.22);
  box-shadow: inset 0 1px 0 rgba(249, 115, 22, 0.08);
}
.analysis-category__header {
  margin: 0 0 1rem;
  padding: 0 0.25rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.analysis-category__title-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.25rem;
}
.analysis-category__swatch {
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  flex-shrink: 0;
}
.analysis-category__swatch--oil { background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18); }
.analysis-category__swatch--gas { background: #f97316; box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.18); }
.analysis-category__title {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text, #f0f0f0);
}
.analysis-category--oil .analysis-category__title { color: #86efac; }
.analysis-category--gas .analysis-category__title { color: #fdba74; }
.analysis-category__sub {
  margin: 0;
  font-size: 0.82rem;
  color: var(--text-muted, #888);
}
.analysis-category .billing-card {
  margin-bottom: 1rem;
}
.analysis-category__empty {
  opacity: 0.92;
}

@media (max-width: 640px) {
  .analysis-category {
    padding: 0.9rem 0.75rem 0.25rem;
  }
}

.usage-bar {
  width: 100%;
  max-width: 420px;
  height: 10px;
  background: var(--bg-input);
  border-radius: 999px;
  overflow: hidden;
  margin: 0.4rem 0 0.4rem;
}
.usage-bar_fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold));
  border-radius: 999px;
  transition: width 0.4s ease;
}
.usage-bar_label { font-size: 0.8rem; color: var(--text-muted); }

/* ---- LOGOUT FORM (navbar) ---- */
.logout-form { margin: 0; display: inline; }
.logout-form .button {
  border: none;
  cursor: pointer;
  font: inherit;
}
.navbar_btn.mobile .logout-form { width: 100%; display: flex; justify-content: center; }
.navbar_btn.mobile .logout-form .button { width: 80%; height: 54px; }

/* =============================================
   DASHBOARD (stats, quick actions, tables)
   ============================================= */
.dashboard { padding: 3rem 50px 5rem; }
.dashboard > h3 {
  font-size: 1.15rem;
  color: var(--gold);
  margin: 2.5rem 0 1rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
  max-width: 1100px;
  margin-bottom: 1rem;
}

/* stat-card here is a label+value column (no icon variant) */
.stat-card { flex-direction: column; align-items: flex-start; gap: 0.35rem; }
.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.stat-value { font-size: 1.6rem; font-weight: 700; color: var(--gold); }
.stat-value small { font-size: 0.78rem; color: var(--text-muted); font-weight: 400; }

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.7rem 1.2rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.2s, transform 0.15s, color 0.2s;
}
.action-btn:hover { border-color: var(--gold); color: var(--gold); transform: translateY(-1px); }

.empty-state {
  background: var(--bg-card);
  border: 1px dashed var(--border);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
}

/* =============================================
   MY WELLS (/wells/)
   ============================================= */
.wells-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  display: block;
  width: 100%;
  min-height: auto;
  height: auto;
}

.wells-page_header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.wells-page_header h1 {
  margin: 0;
  font-size: 1.75rem;
  color: var(--gold);
  line-height: 1.2;
}

.wells-page_sub {
  margin: 0.35rem 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.wells-page_actions {
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
  align-items: center;
}

.wells-page_actions form { margin: 0; }

.wells-page_hint {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin: 0 0 1.5rem;
}

.wells-page_hint a {
  color: var(--text-sub);
  text-decoration: underline;
}

.action-btn--primary {
  background: var(--gold);
  border-color: var(--gold);
  color: #141414;
}
.action-btn--primary:hover {
  background: var(--gold-dark);
  border-color: var(--gold-dark);
  color: #fff;
}

.action-btn--ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-sub);
}

.wells-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.wells-stat {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.wells-stat_label {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.wells-stat_value {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--gold);
  line-height: 1.2;
  word-break: break-word;
}

.wells-stat_value small {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-left: 0.15rem;
}

.wells-stat_value--warn { color: #f59e0b; }

.wells-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
}

.wells-toolbar_links {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.wells-toolbar_note,
.wells-toolbar_seats {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.wells-toolbar_note a { color: var(--gold); }

.wells-messages { margin-bottom: 1.25rem; }

.wells-message {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left-width: 3px;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: var(--text);
}

.wells-message--success { border-left-color: #10b981; }
.wells-message--error { border-left-color: #ef4444; }
.wells-message--warning { border-left-color: #f59e0b; }
.wells-message--info { border-left-color: #6366f1; }

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

.well-card {
  display: block;
  text-decoration: none;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.15rem 1.2rem;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  color: inherit;
}

.well-card:hover {
  border-color: var(--border-gold);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  color: inherit;
}

.well-card_top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.well-card_icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(156, 163, 175, 0.15);
  color: #9ca3af;
  font-size: 1.05rem;
}

.well-card--oil .well-card_icon { background: rgba(34, 197, 94, 0.15); color: #22c55e; }
.well-card--gas .well-card_icon { background: rgba(249, 115, 22, 0.15); color: #f97316; }
.well-card--dual .well-card_icon { background: rgba(99, 102, 241, 0.15); color: #6366f1; }
.well-card--injection .well-card_icon { background: rgba(59, 130, 246, 0.15); color: #3b82f6; }
.well-card--disposal .well-card_icon { background: rgba(156, 163, 175, 0.15); color: #9ca3af; }

.well-card_badges {
  margin-left: auto;
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.well-badge {
  font-size: 0.68rem;
  padding: 0.2rem 0.5rem;
  border-radius: 9999px;
  font-weight: 600;
  background: rgba(156, 163, 175, 0.15);
  color: #9ca3af;
  white-space: nowrap;
}

.well-badge--shared {
  background: rgba(99, 102, 241, 0.18);
  color: #a5b4fc;
}

.well-badge--active { background: rgba(34, 197, 94, 0.15); color: #22c55e; }
.well-badge--shut_in { background: rgba(245, 158, 11, 0.15); color: #f59e0b; }
.well-badge--drilling { background: rgba(99, 102, 241, 0.15); color: #6366f1; }
.well-badge--completing { background: rgba(59, 130, 246, 0.15); color: #3b82f6; }
.well-badge--abandoned { background: rgba(239, 68, 68, 0.15); color: #ef4444; }
.well-badge--idle { background: rgba(156, 163, 175, 0.18); color: #d1d5db; }

.well-card_name {
  margin: 0 0 0.3rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

.well-card_meta {
  margin: 0 0 0.9rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.well-card_owner { color: var(--text-sub); }

.well-card_stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  padding-top: 0.75rem;
}

.well-card_stats i { opacity: 0.65; margin-right: 0.2rem; }
.well-card_flag { color: #f59e0b; }

.wells-empty {
  text-align: center;
  padding: 3.5rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.wells-empty > i {
  font-size: 2.5rem;
  color: var(--text-muted);
  opacity: 0.45;
  margin-bottom: 1rem;
  display: block;
}

.wells-empty h2 {
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  color: var(--text);
}

.wells-empty p {
  color: var(--text-muted);
  margin: 0 auto 1.25rem;
  max-width: 420px;
  font-size: 0.9rem;
}

.wells-empty_actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.wells-empty_actions form { margin: 0; }

.wells-empty_hint {
  font-size: 0.8rem !important;
  margin: 0.75rem 0 0 !important;
}

.wells-empty_hint a {
  color: var(--text-sub);
  text-decoration: underline;
}

@media screen and (max-width: 900px) {
  .wells-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media screen and (max-width: 560px) {
  .wells-page { padding: 1.25rem 1rem 2.5rem; }
  .wells-page_header h1 { font-size: 1.45rem; }
  .wells-stats { grid-template-columns: 1fr; }
  .wells-stat_value { font-size: 1.2rem; }
}

/* =============================================
   DATA TABLES (params / forecast)
   ============================================= */
.params-table,
.forecast-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  margin: 0.5rem 0 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.params-table th,
.forecast-table th {
  text-align: left;
  padding: 0.7rem 1rem;
  background: #252525;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.params-table td,
.forecast-table td {
  padding: 0.65rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-sub);
}
.params-table tr:last-child td,
.forecast-table tr:last-child td { border-bottom: none; }
.forecast-table tbody tr:hover td { background: rgba(255, 207, 99, 0.03); }
.params-table td:first-child { color: var(--text-muted); }
.params-table a,
.forecast-table a { color: var(--gold); font-weight: 600; }
.params-table a:hover,
.forecast-table a:hover { color: var(--gold-dark); }
tr.best-model td { background: rgba(255, 207, 99, 0.08); color: var(--text); font-weight: 600; }

/* =============================================
   DECLINE RESULTS (text blocks, alerts, export)
   ============================================= */
.results-container { padding: 2.5rem 50px 5rem; max-width: 1100px; }
.results-container > h1 { font-size: 1.8rem; color: var(--gold); margin-bottom: 1.5rem; line-height: 1.3; }
.results-container > h2 { font-size: 1.45rem; color: var(--gold); margin: 1.5rem 0 1rem; }
.results-container > h3 { font-size: 1.15rem; color: var(--text); margin: 2rem 0 0.75rem; }
.results-container > p { color: var(--text-sub); margin-bottom: 0.6rem; }

.explanation,
.info {
  background: rgba(255, 207, 99, 0.06);
  border-left: 3px solid var(--border-gold);
  border-radius: 6px;
  padding: 0.85rem 1.1rem;
  color: var(--text-sub);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0.5rem 0 1.5rem;
}

.recommendation {
  background: rgba(76, 175, 125, 0.1);
  border: 1px solid rgba(76, 175, 125, 0.3);
  border-radius: 8px;
  padding: 0.85rem 1.1rem;
  color: #aee0c4;
  font-weight: 600;
  margin: 0.5rem 0 1.5rem;
}

.report {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  color: var(--text-sub);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}
.report strong { color: var(--gold); }

.error-box {
  background: rgba(220, 80, 80, 0.1);
  border: 1px solid rgba(220, 80, 80, 0.35);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  color: #ffaaaa;
  margin: 1rem 0;
}

.warning-banner {
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-left: 5px solid var(--amber);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  color: var(--text-sub);
  line-height: 1.6;
}
.warning-banner strong { color: var(--gold); font-size: 1.02rem; display: block; margin-bottom: 0.5rem; }
.warning-banner p { margin-bottom: 0.5rem; }
.warning-banner ul { margin: 0.5rem 0 0.5rem 1.25rem; }
.warning-banner li { margin-bottom: 0.4rem; }
.warning-banner em { color: var(--gold); font-style: italic; }
.warning-note { margin-top: 0.6rem; font-style: italic; font-size: 0.88rem; color: var(--text-muted); }

.export-section { margin: 2rem 0 1rem; }
.export-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--gold);
  color: #000;
  font-weight: 700;
  padding: 0.7rem 1.4rem;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s;
}
.export-btn:hover { background: var(--gold-dark); color: #fff; transform: translateY(-1px); }

/* =============================================
   RESULTS DETAIL (single calculation)
   ============================================= */
.result-summary-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 1.5rem;
  max-width: 1000px;
}
@media (max-width: 800px) { .result-summary-grid { grid-template-columns: 1fr; } }

.result-headline {
  text-align: center;
  padding: 1rem 0 1.5rem;
}
.result-headline_value {
  font-size: 3rem;
  font-weight: 800;
  color: var(--gold);
  line-height: 1.1;
}
.result-headline_label {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
}

.input-list { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.input-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.9rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border);
}
.input-list li:last-child { border-bottom: none; }
.input-list .input-key { color: var(--text-muted); }
.input-list .input-val { color: var(--text); font-weight: 600; text-align: right; }

.status-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--success);
  margin-top: 1rem;
}
.status-tag.failed { color: var(--danger); }

/* =============================================
   ERROR PAGES (404 / 500)
   ============================================= */
.error-page {
  min-height: calc(100vh - 80px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1rem;
  gap: 1rem;
}
.error-page .error-code { font-size: 4.5rem; font-weight: 800; color: var(--gold); line-height: 1; }
.error-page h1 { font-size: 1.6rem; color: var(--text); }
.error-page p { color: var(--text-muted); max-width: 440px; }
.error-page .button { width: auto; padding: 0.7rem 1.6rem; border-radius: 8px; margin-top: 0.5rem; }

/* =============================================
   UTILITIES
   ============================================= */
.hidden { display: none !important; }

@media (max-width: 768px) {
  .dashboard,
  .results-container { padding-left: 20px; padding-right: 20px; }
}

/* =============================================
   LEGAL PAGES (Terms, Privacy)
   ============================================= */

.legal-page {
  padding: 2rem 1.5rem 4rem;
  max-width: 860px;
  margin: 0 auto;
}

.legal-container h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.25rem;
}

.legal-updated {
  color: #8b9cb5;
  font-size: 0.9rem;
  margin-bottom: 2rem;
}

.legal-toc {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  margin-bottom: 2.5rem;
}

.legal-toc h3 {
  font-size: 1rem;
  color: #ffffff;
  margin-bottom: 0.75rem;
}

.legal-toc ol {
  padding-left: 1.25rem;
  columns: 2;
  column-gap: 2rem;
}

.legal-toc li {
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
  color: #8b9cb5;
}

.legal-toc a {
  color: #60a5fa;
  text-decoration: none;
  transition: color 0.2s;
}

.legal-toc a:hover {
  color: #93c5fd;
  text-decoration: underline;
}

.legal-section {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.legal-section:last-of-type { border-bottom: none; }

.legal-section h2 {
  font-size: 1.3rem;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 1rem;
  scroll-margin-top: 80px;
}

.legal-section p {
  color: #c8d6e5;
  line-height: 1.7;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.legal-section ul,
.legal-section ol {
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.legal-section li {
  color: #c8d6e5;
  line-height: 1.7;
  margin-bottom: 0.4rem;
  font-size: 0.95rem;
}

.legal-section a { color: #60a5fa; text-decoration: none; }
.legal-section a:hover { text-decoration: underline; }

.legal-section--critical {
  background: rgba(239, 68, 68, 0.05);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  margin-left: -1rem;
  margin-right: -1rem;
}

.legal-warning {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  color: #fca5a5;
  font-size: 0.9rem;
}

.legal-warning i { font-size: 1.2rem; color: #ef4444; }

.legal-contact {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  margin-top: 0.75rem;
}

.legal-contact p { margin-bottom: 0.3rem; font-size: 0.9rem; }

.legal-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.9rem;
}

.legal-table th,
.legal-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.legal-table th {
  color: #ffffff;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.legal-table td { color: #c8d6e5; }

.legal-footer {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.legal-footer p { color: #8b9cb5; font-size: 0.9rem; }

@media (max-width: 640px) {
  .legal-page { padding: 1.5rem 1rem 3rem; }
  .legal-toc ol { columns: 1; }
  .legal-section--critical { margin-left: -0.5rem; margin-right: -0.5rem; padding: 1.25rem; }
  .legal-table { font-size: 0.8rem; }
  .legal-table th, .legal-table td { padding: 0.5rem 0.6rem; }
}


/* =============================================
   LANDING PAGE STYLES
   ============================================= */

/* ---- Hero Section ---- */
.landing-hero {
  position: relative;
  min-height: calc(100vh - 80px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 4rem 2rem 6rem;
  overflow: hidden;
}

.landing-hero_bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 90% 55% at 50% -5%, rgba(255, 207, 99, 0.11) 0%, transparent 58%),
    radial-gradient(ellipse 50% 40% at 85% 70%, rgba(255, 207, 99, 0.04) 0%, transparent 50%),
    linear-gradient(180deg, #101010 0%, #141414 55%, #161616 100%);
  pointer-events: none;
}

.landing-hero_curve {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: clamp(140px, 28vh, 260px);
  z-index: 0;
  pointer-events: none;
  opacity: 0.95;
}

.landing-hero_curve-line {
  stroke-dasharray: 900;
  stroke-dashoffset: 900;
  animation: landing-draw-curve 1.6s ease-out 0.25s forwards;
}

.landing-hero_curve-fill {
  opacity: 0;
  animation: landing-fade-in 1s ease-out 0.9s forwards;
}

.landing-hero_content {
  position: relative;
  z-index: 1;
  max-width: 820px;
  animation: landing-fade-up 0.7s ease-out both;
}

.landing-hero_brand {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(1.35rem, 2.6vw, 1.85rem);
  font-weight: 700;
  color: var(--gold);
  letter-spacing: 0.04em;
  margin: 0 0 1rem;
}

.landing-hero_title {
  font-size: clamp(2.1rem, 5vw, 3.55rem);
  font-weight: 700;
  color: var(--text);
  line-height: 1.15;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}

.landing-hero_title .gold { color: var(--gold); }

.landing-hero_sub {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto 2.5rem;
  line-height: 1.65;
}

.landing-hero_cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

@keyframes landing-fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes landing-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes landing-draw-curve {
  to { stroke-dashoffset: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .landing-hero_content,
  .landing-hero_curve-line,
  .landing-hero_curve-fill,
  .landing-workflow_item,
  .landing-demo_inner {
    animation: none !important;
  }
  .landing-hero_curve-line { stroke-dashoffset: 0; }
  .landing-hero_curve-fill { opacity: 1; }
}

/* ---- Buttons ---- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--gold);
  color: #000;
  padding: 0.85rem 2rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  white-space: nowrap;
  width: auto;
  max-width: none;
  box-sizing: border-box;
  transition: background 0.2s, transform 0.15s;
}
.btn-primary:hover {
  background: var(--gold-dark);
  color: #fff;
  transform: translateY(-1px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  color: var(--text-sub);
  padding: 0.85rem 2rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  border: 1px solid var(--border);
  transition: border-color 0.2s, color 0.2s;
}
.btn-outline:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.btn-large {
  padding: 1.1rem 2.8rem;
  font-size: 1.15rem;
}

/* ---- Social Proof Bar ---- */
.landing-proof {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 2rem;
  background: rgba(255, 255, 255, 0.01);
}

.landing-proof_inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  max-width: 1000px;
  margin: 0 auto;
}

.proof-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.proof-item i { color: var(--gold); font-size: 1rem; }

.proof-divider {
  width: 1px;
  height: 24px;
  background: var(--border);
}

/* ---- Section Headers ---- */
.landing-section_header {
  text-align: center;
  margin-bottom: 3rem;
}

.landing-section_header h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--text);
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.landing-section_header p {
  color: var(--text-muted);
  font-size: 1.05rem;
}

/* ---- Features Section ---- */
.landing-features {
  padding: 5rem 2rem;
  max-width: 1100px;
  margin: 0 auto;
}

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

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem;
  transition: border-color 0.25s, transform 0.2s;
}
.feature-card:hover {
  border-color: var(--border-gold);
  transform: translateY(-3px);
}

.feature-card_icon {
  width: 48px;
  height: 48px;
  background: rgba(255, 207, 99, 0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: var(--gold);
  margin-bottom: 1.25rem;
}

.feature-card h3 {
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 0.6rem;
}

.feature-card p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* ---- How It Works ---- */
.landing-steps {
  padding: 5rem 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

.landing-steps_grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.step-card {
  text-align: center;
  padding: 2rem 1.5rem;
}

.step-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 207, 99, 0.12);
  border: 2px solid var(--gold);
  color: var(--gold);
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
}

.step-card h3 {
  font-size: 1.1rem;
  color: var(--text);
  margin-bottom: 0.6rem;
}

.step-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ---- Pricing Preview ---- */
.landing-pricing {
  padding: 5rem 2rem;
  text-align: center;
}

.landing-pricing_grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  max-width: 1080px;
  margin: 0 auto 2rem;
}

.landing-pricing_grid--four {
  max-width: 1100px;
}

/* ---- Capabilities (no feature-card clutter) ---- */
.landing-capabilities {
  padding: 5rem 2rem;
  max-width: 920px;
  margin: 0 auto;
}

.landing-capabilities_list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border-top: 1px solid var(--border);
}

.capability-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1.5rem;
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
}

.capability-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  padding-top: 0.2rem;
}

.capability-body h3 {
  font-size: 1.08rem;
  color: var(--text);
  margin: 0 0 0.45rem;
  font-weight: 600;
}

.capability-body p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

.lp-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2rem 1.5rem;
  position: relative;
  text-align: left;
}

.lp-card--featured {
  border-color: var(--gold);
  box-shadow: 0 0 30px rgba(255, 207, 99, 0.06);
}

.lp-popular {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: #000;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 4px 14px;
  border-radius: 20px;
}

.lp-card h3 {
  font-size: 1.2rem;
  color: var(--text);
  margin-bottom: 0.25rem;
}

.lp-job {
  color: var(--text-muted);
  font-size: 0.82rem;
  margin: 0 0 0.85rem;
}

.lp-price {
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 1.25rem;
}
.lp-price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-muted);
}

.lp-card ul {
  list-style: none;
  padding: 0;
  margin-bottom: 1.5rem;
}

.lp-card li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text-sub);
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
}

.lp-card li i { color: var(--gold); font-size: 0.8rem; }

.lp-btn {
  display: block;
  text-align: center;
  padding: 0.7rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  border: 1px solid var(--border);
  color: var(--text-sub);
  transition: border-color 0.2s, color 0.2s;
}
.lp-btn:hover { border-color: var(--gold); color: var(--gold); }

.lp-btn--primary {
  background: var(--gold);
  color: #000;
  border-color: var(--gold);
}
.lp-btn--primary:hover { background: var(--gold-dark); color: #fff; border-color: var(--gold-dark); }

.landing-pricing_note {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}

.landing-pricing_compare {
  color: var(--gold);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.landing-pricing_compare:hover { color: var(--gold-dark); gap: 0.7rem; }

/* ---- Trust Section ---- */
.landing-trust {
  padding: 5rem 2rem;
  max-width: 900px;
  margin: 0 auto;
}

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

.trust-paper {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.trust-model {
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
}

.trust-cite {
  color: var(--text-muted);
  font-size: 0.82rem;
  font-style: italic;
}

.landing-trust_link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--gold);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  text-align: center;
  width: 100%;
  justify-content: center;
}
.landing-trust_link:hover { color: var(--gold-dark); }

/* ---- Landing shells (shared section layout) ---- */
.landing-page .landing-steps,
.landing-page .landing-capabilities,
.landing-page .landing-pricing,
.landing-page .landing-trust,
.landing-page .landing-workflow,
.landing-page .landing-io,
.landing-page .landing-phases,
.landing-page .landing-demo {
  max-width: none;
  margin-left: 0;
  margin-right: 0;
  padding-left: 0;
  padding-right: 0;
}

.landing-page .landing-shell {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.landing-page .landing-shell--narrow { max-width: 820px; }
.landing-page .landing-shell--mid { max-width: 920px; }

.landing-page .landing-band { padding: 5rem 0; }
.landing-page .landing-band--tight { padding: 0 0 5rem; }

/* ---- Typical PE workflow ---- */
.landing-workflow_list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-top: 1px solid var(--border);
}

.landing-workflow_item {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 1.25rem;
  padding: 1.45rem 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
  animation: landing-fade-up 0.55s ease-out both;
}

.landing-workflow_item:nth-child(1) { animation-delay: 0.05s; }
.landing-workflow_item:nth-child(2) { animation-delay: 0.1s; }
.landing-workflow_item:nth-child(3) { animation-delay: 0.15s; }
.landing-workflow_item:nth-child(4) { animation-delay: 0.2s; }
.landing-workflow_item:nth-child(5) { animation-delay: 0.25s; }
.landing-workflow_item:nth-child(6) { animation-delay: 0.3s; }

.wf-num {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255, 207, 99, 0.45);
  color: var(--gold);
  font-weight: 700;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.wf-body h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  color: var(--text);
  font-weight: 600;
}

.wf-body p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* ---- Inputs / outputs ---- */
.landing-io_grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.5rem;
}

.landing-io_col h3 {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  color: var(--gold);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.landing-io_list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-top: 1px solid var(--border);
}

.landing-io_list li {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.55;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
}

.landing-io_list strong {
  color: var(--text-sub);
  font-weight: 600;
}

/* ---- Oil / gas / dual ---- */
.landing-phases_list {
  border-top: 1px solid var(--border);
}

.phase-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 1.5rem;
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--border);
  align-items: start;
}

.phase-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  padding-top: 0.2rem;
}

.phase-body h3 {
  font-size: 1.05rem;
  color: var(--text);
  margin: 0 0 0.4rem;
  font-weight: 600;
}

.phase-body p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* ---- Demo well callout ---- */
.landing-demo_inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  animation: landing-fade-up 0.6s ease-out both;
}

.landing-demo_copy {
  flex: 1 1 260px;
  max-width: 620px;
}

.landing-demo_copy h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.35rem, 2.5vw, 1.7rem);
  color: var(--text);
}

.landing-demo_copy p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.landing-demo_copy strong { color: var(--text-sub); }

.landing-demo_actions { flex: 0 0 auto; }

.landing-pricing_footer { text-align: center; }

/* ---- Comparison Section ---- */
.landing-compare {
  padding: 5rem 2rem;
  background: rgba(255, 207, 99, 0.02);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.landing-compare_inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  max-width: 900px;
  margin: 0 auto;
  align-items: center;
}

.compare-left h2, .compare-right h2 {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: var(--text);
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.compare-left p, .compare-right p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.gold { color: var(--gold); }

/* ---- Final CTA ---- */
.landing-cta {
  padding: 6rem 2rem;
  text-align: center;
}

.landing-cta h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--text);
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.landing-cta_note {
  margin-top: 1.25rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}

/* ---- Landing Page Responsive ---- */
@media (max-width: 900px) {
  .landing-pricing_grid--four {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .landing-hero {
    padding: 3rem 1.5rem 5.5rem;
    min-height: auto;
  }

  .landing-hero_curve { height: 120px; }

  .proof-divider { display: none; }
  .landing-proof_inner { flex-direction: column; gap: 0.75rem; }

  .landing-compare_inner { grid-template-columns: 1fr; gap: 2rem; text-align: center; }

  .capability-row,
  .phase-row,
  .landing-workflow_item {
    grid-template-columns: 1fr;
    gap: 0.4rem;
  }

  .landing-io_grid { grid-template-columns: 1fr; gap: 2rem; }

  .landing-page .landing-band { padding: 3.5rem 0; }
  .landing-page .landing-band--tight { padding: 0 0 3.5rem; }

  .landing-demo_inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 550px) {
  .landing-pricing_grid--four {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .landing-hero_cta { flex-direction: column; align-items: center; }
  .landing-hero_cta .btn-primary,
  .landing-hero_cta .btn-outline { width: 100%; max-width: 280px; justify-content: center; }
}


/* ---- CSS Variable Aliases (for well templates compatibility) ---- */
:root {
  --text-primary: var(--text);
  --text-secondary: var(--text-sub);
  --bg-secondary: var(--bg-card);
}

/* ---- Results Container Z-Index Fix ---- */
.results-container {
  position: relative;
  z-index: 2;
}

/* Decline curve chart: fill container width, no oversized empty right gutter */
.decline-chart-wrap {
  max-width: 100%;
  box-sizing: border-box;
}
.decline-chart-wrap svg {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.petrolyt-zoom-host {
  border-radius: 12px;
}
.petrolyt-zoom-host.is-zoomed .petrolyt-zoom-bar {
  border-color: rgba(255, 207, 99, 0.38);
}
.petrolyt-zoom-slot {
  margin: 0.15rem 0 0.85rem;
  min-height: 0;
}

/* Field+ chart zoom toolbar */
.petrolyt-zoom-bar {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin: 0.75rem 0 0.5rem;
  padding: 0.7rem 0.85rem 0.65rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035) 0%, transparent 55%),
    var(--bg-card, #1e1e1e);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.petrolyt-zoom-bar.is-zoomed {
  border-color: rgba(255, 207, 99, 0.32);
  background:
    linear-gradient(180deg, rgba(255, 207, 99, 0.07) 0%, transparent 50%),
    var(--bg-card, #1e1e1e);
}
.petrolyt-zoom-bar--locked {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.petrolyt-zoom-bar__row {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 0.85rem 1.35rem;
}
.petrolyt-zoom-bar__group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.petrolyt-zoom-bar__group + .petrolyt-zoom-bar__group {
  padding-left: 1.15rem;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
}
.petrolyt-zoom-bar__caption {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted, #888);
  padding-left: 0.15rem;
}
.petrolyt-zoom-bar__label {
  display: inline-flex;
  align-items: center;
  align-self: center;
  gap: 0.5rem;
  min-height: 2.15rem;
  margin-right: 0.25rem;
  padding: 0 0.15rem 0 0;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold, #ffcf63);
}
.petrolyt-zoom-bar__glyph {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 7px;
  background: rgba(255, 207, 99, 0.12);
  border: 1px solid rgba(255, 207, 99, 0.28);
  font-size: 0.85rem;
  line-height: 1;
}
.petrolyt-zoom-bar__tip {
  margin: 0;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.7rem;
  line-height: 1.35;
  color: var(--text-muted, #888);
  letter-spacing: 0.01em;
  text-align: center;
}
.petrolyt-zoom-upgrade {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.85rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 207, 99, 0.35);
  background: rgba(255, 207, 99, 0.1);
  color: var(--gold, #ffcf63) !important;
  font-size: 0.75rem;
  font-weight: 600;
  text-decoration: none !important;
  transition: background 0.15s, border-color 0.15s;
}
.petrolyt-zoom-upgrade:hover {
  background: rgba(255, 207, 99, 0.18);
  border-color: rgba(255, 207, 99, 0.55);
  color: #ffe09a !important;
}

.petrolyt-zoom-seg {
  display: inline-flex;
  align-items: stretch;
  padding: 3px;
  border-radius: 9px;
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.petrolyt-zoom-seg__btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text-muted, #888);
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  min-width: 2.35rem;
  min-height: 2rem;
  padding: 0.35rem 0.7rem;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, box-shadow 0.15s;
}
.petrolyt-zoom-seg__btn:hover {
  color: var(--text, #f0f0f0);
  background: rgba(255, 255, 255, 0.04);
}
.petrolyt-zoom-seg__btn.is-active {
  background: rgba(255, 207, 99, 0.18);
  color: var(--gold, #ffcf63);
  box-shadow: inset 0 0 0 1px rgba(255, 207, 99, 0.28);
}
.petrolyt-zoom-seg__btn:focus-visible {
  outline: 2px solid rgba(255, 207, 99, 0.45);
  outline-offset: 1px;
}

.petrolyt-zoom-stepper {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
  padding: 3px;
  border-radius: 9px;
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.07);
}
.petrolyt-zoom-icon-btn {
  appearance: none;
  width: 2.15rem;
  height: 2.15rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--text-sub, wheat);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.petrolyt-zoom-icon-btn:hover:not(:disabled) {
  background: rgba(255, 207, 99, 0.14);
  color: var(--gold, #ffcf63);
}
.petrolyt-zoom-icon-btn:disabled {
  opacity: 0.32;
  cursor: default;
}
.petrolyt-zoom-icon-btn:focus-visible {
  outline: 2px solid rgba(255, 207, 99, 0.45);
  outline-offset: 1px;
}
.petrolyt-zoom-mag {
  min-width: 3.1rem;
  padding: 0 0.2rem;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text, #f0f0f0);
  letter-spacing: 0.02em;
}

.petrolyt-zoom-reset {
  appearance: none;
  display: inline-flex;
  align-items: center;
  align-self: flex-end;
  margin-left: auto;
  gap: 0.45rem;
  min-height: 2.15rem;
  padding: 0 0.95rem;
  border-radius: 9px;
  border: 1px solid rgba(255, 207, 99, 0.32);
  background: rgba(255, 207, 99, 0.08);
  color: var(--gold, #ffcf63);
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s, color 0.18s, opacity 0.18s, transform 0.15s, box-shadow 0.18s;
}
.petrolyt-zoom-reset > span:first-child {
  font-size: 0.85rem;
  line-height: 1;
}
.petrolyt-zoom-reset:disabled {
  opacity: 0.5;
  cursor: default;
  border-color: rgba(255, 207, 99, 0.18);
  background: rgba(255, 207, 99, 0.04);
  color: rgba(255, 207, 99, 0.55);
  box-shadow: none;
  filter: none;
  transform: none;
}
.petrolyt-zoom-reset.is-active:not(:disabled) {
  border-color: rgba(255, 207, 99, 0.5);
  background: linear-gradient(180deg, #ffd778 0%, var(--gold, #ffcf63) 55%, var(--gold-dark, #c8900c) 100%);
  color: #1a1400;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.28) inset, 0 4px 12px rgba(0, 0, 0, 0.28);
}
.petrolyt-zoom-reset.is-active:not(:disabled):hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
  color: #120e00;
}
.petrolyt-zoom-reset.is-active:not(:disabled):active {
  transform: translateY(0);
  filter: brightness(0.97);
}
.petrolyt-zoom-reset:focus-visible {
  outline: 2px solid rgba(255, 207, 99, 0.5);
  outline-offset: 2px;
}

.petrolyt-chart-panning {
  cursor: grabbing !important;
}
.petrolyt-svg-zoom-viewport {
  width: 100%;
  will-change: transform;
}
.petrolyt-svg-zoom-host {
  position: relative;
  overflow: hidden;
  touch-action: none;
}

@media (max-width: 720px) {
  .petrolyt-zoom-bar {
    padding: 0.65rem 0.7rem 0.55rem;
    gap: 0.45rem;
  }
  .petrolyt-zoom-bar__row {
    gap: 0.65rem 0.75rem;
  }
  .petrolyt-zoom-bar__tip {
    font-size: 0.65rem;
  }
  .petrolyt-zoom-bar__label {
    min-width: 100%;
    min-height: auto;
    margin-bottom: 0.05rem;
  }
  .petrolyt-zoom-reset {
    margin-left: 0;
  }
}

@media (max-width: 480px) {
  .petrolyt-zoom-bar__tip {
    display: none;
  }
  .petrolyt-zoom-bar__caption {
    display: none;
  }
  .petrolyt-zoom-bar__row {
    align-items: center;
  }
  .petrolyt-zoom-reset {
    align-self: center;
    margin-left: auto;
  }
}

/* Legacy class kept so older markup does not break */
.petrolyt-zoom-controls { display: none; }
.petrolyt-zoom-hint { display: none; }

/* Production History phase selector (Oil / Gas / Water / All)
   Source of truth for well_detail is also inlined via {% inline_prod_phase_css %}
   from css/prod-phase-seg.css (Manifest/CDN cache safety). Keep these in sync. */
.prod-phase-seg {
  --phase-oil: #22c55e;
  --phase-gas: #f97316;
  --phase-water: #3b82f6;
  display: inline-flex !important;
  align-items: stretch;
  flex-wrap: nowrap;
  padding: 3px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  background: rgba(0, 0, 0, 0.45) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  gap: 2px;
  vertical-align: middle;
}
.prod-phase-seg__btn {
  -webkit-appearance: none !important;
  appearance: none !important;
  border: 0 !important;
  margin: 0 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 2.05rem;
  padding: 0.35rem 0.85rem !important;
  border-radius: 7px !important;
  background: transparent !important;
  color: #c8c8c8 !important;
  font-family: inherit !important;
  font-size: 0.78rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.03em;
  line-height: 1 !important;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: none !important;
  text-shadow: none !important;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.prod-phase-seg__swatch {
  display: inline-block !important;
  width: 0.55rem !important;
  height: 0.55rem !important;
  border-radius: 50% !important;
  flex-shrink: 0;
  opacity: 0.9;
}
.prod-phase-seg__swatch--all {
  background: linear-gradient(90deg, #22c55e 0%, #f97316 50%, #3b82f6 100%) !important;
}
.prod-phase-seg__swatch--oil { background: #22c55e !important; }
.prod-phase-seg__swatch--gas { background: #f97316 !important; }
.prod-phase-seg__swatch--water { background: #3b82f6 !important; }
.prod-phase-seg__btn:hover {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.08) !important;
}
.prod-phase-seg__btn:focus-visible {
  outline: 2px solid rgba(255, 207, 99, 0.55);
  outline-offset: 2px;
}
.prod-phase-seg__btn--all.is-active {
  background: rgba(255, 207, 99, 0.2) !important;
  color: #ffcf63 !important;
  box-shadow: inset 0 0 0 1px rgba(255, 207, 99, 0.45) !important;
}
.prod-phase-seg__btn--oil.is-active {
  background: rgba(34, 197, 94, 0.22) !important;
  color: #86efac !important;
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.5) !important;
}
.prod-phase-seg__btn--gas.is-active {
  background: rgba(249, 115, 22, 0.22) !important;
  color: #fdba74 !important;
  box-shadow: inset 0 0 0 1px rgba(249, 115, 22, 0.5) !important;
}
.prod-phase-seg__btn--water.is-active {
  background: rgba(59, 130, 246, 0.22) !important;
  color: #93c5fd !important;
  box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.5) !important;
}
.prod-phase-seg__btn.is-active .prod-phase-seg__swatch {
  opacity: 1;
}
@media (max-width: 520px) {
  .prod-phase-seg {
    width: 100%;
  }
  .prod-phase-seg__btn {
    flex: 1 1 0;
    padding-left: 0.45rem !important;
    padding-right: 0.45rem !important;
    font-size: 0.72rem !important;
  }
}

/* =============================================
   CHART "SAVE" BUTTON (PNG / PDF / SVG export) — free on every tier
   ============================================= */
.petrolyt-chart-download {
  position: relative;
  display: inline-flex;
  margin-top: 0.4rem;
}
.petrolyt-chart-download__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--bg-card, #1e1e1e);
  color: var(--text-sub, #ccc);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.petrolyt-chart-download__btn:hover,
.petrolyt-chart-download__btn[aria-expanded="true"] {
  border-color: rgba(255, 207, 99, 0.4);
  color: var(--gold, #ffcf63);
}
.petrolyt-chart-download__menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  min-width: 200px;
  padding: 0.4rem;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--bg-card, #1e1e1e);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}
/* The [hidden] attribute toggles this menu from JS — without this rule,
   the class selector's `display: flex` above (higher specificity than the
   UA stylesheet's bare `[hidden]` rule) would keep it visible anyway. */
.petrolyt-chart-download__menu[hidden] {
  display: none;
}
.petrolyt-chart-download__menu button {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.6rem;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: var(--text, #f5f5f5);
  font-size: 0.8rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s;
}
.petrolyt-chart-download__menu button:hover:not(:disabled) {
  background: rgba(255, 207, 99, 0.08);
}
.petrolyt-chart-download__menu button:disabled {
  opacity: 0.5;
  cursor: default;
}
.petrolyt-chart-download__menu button i {
  color: var(--gold, #ffcf63);
  width: 1rem;
  text-align: center;
}
.petrolyt-chart-download__status {
  margin: 0 0 0.3rem;
  padding: 0.3rem 0.6rem;
  font-size: 0.72rem;
  color: var(--text-muted, #888);
}

/* ---- Breadcrumb Navigation ---- */
.breadcrumb {
  padding: 1rem 50px 0;
  max-width: 1100px;
  font-size: 0.85rem;
  position: relative;
  z-index: 2;
}
.breadcrumb a { color: var(--text-sub); }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb .sep { margin: 0 0.4rem; color: var(--text-muted); }
.breadcrumb .current { color: var(--text); }
