/* ---------------------------------------
   General layout
---------------------------------------- */
body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

.result-box {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  padding: 12px;
  border-radius: 6px;
  text-align: center;
}

.result-label {
  font-size: 0.85rem;
  color: #6c757d;
  margin-bottom: 4px;
}

.result-value {
  font-size: 1.25rem;
  font-weight: 600;
}

/* ---------------------------------------
   Holdings table
---------------------------------------- */
#holdingsTable input {
  min-width: 90px;
}

.delete-row {
  padding: 2px 8px;
}

/* ---------------------------------------
   Status message
---------------------------------------- */
#statusMessage {
  font-size: 0.9rem;
  min-height: 20px;
}

/* ---------------------------------------
   Debug log
---------------------------------------- */
#debugLog {
  max-height: 250px;
  overflow-y: auto;
  white-space: pre-wrap;
}

/* ---------------------------------------
   Card spacing tweaks
---------------------------------------- */
.card-header {
  background: #f1f3f5;
  font-weight: 600;
}

.card-body small {
  display: block;
  margin-top: 4px;
  color: #6c757d;
}

/* ---------------------------------------
   Buttons
---------------------------------------- */
#addRowBtn {
  margin-top: 10px;
}

#exportBtn {
  white-space: nowrap;
}
/* Global page background */
body {
  background: #f7f9fc;
  font-family: "Inter", "Segoe UI", sans-serif;
}

/* Card styling */
.card {
  border: none;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* Section headers */
.card-header {
  background: transparent;
  border-bottom: 1px solid #e5e7eb;
  font-weight: 600;
  font-size: 1rem;
}

/* Result values */
.result-value {
  font-size: 1.4rem;
  font-weight: 600;
  color: #111827;
}

/* Result labels */
.result-label {
  font-size: 0.85rem;
  color: #6b7280;
}

/* Narrative text */
#portfolioNarrative p {
  margin-bottom: 0.75rem;
  line-height: 1.5;
}

/* Table styling */
table.table th {
  font-weight: 600;
  color: #374151;
}

table.table td {
  color: #4b5563;
}

/* Tooltip styling override (optional) */
.tooltip-inner {
  max-width: 260px;
  text-align: left;
  font-size: 0.8rem;
  padding: 8px 10px;
}
table.table tbody tr:hover {
  background: #f3f4f6;
}

table.table td, table.table th {
  padding-top: 10px;
  padding-bottom: 10px;
}
#portfolioNarrative {
  font-size: 0.95rem;
  color: #374151;
}
#portfolioNarrative ul {
  margin-top: 0.5rem;
}
#portfolioNarrative li {
  margin-bottom: 0.4rem;
}
.fade-in {
  opacity: 0;
  transform: translateY(4px);
  animation: fadeIn 0.4s ease forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.btn-primary {
  background: #2563eb;
  border-color: #2563eb;
}

.btn-primary:hover {
  background: #1e40af;
  border-color: #1e40af;
}
.result-label .bi-question-circle {
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s ease;
}

.result-label .bi-question-circle:hover {
  opacity: 1;
}
table.table th .bi {
  font-size: 1rem;
}

table.table th .bi-question-circle {
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s ease;
}

table.table th .bi-question-circle:hover {
  opacity: 1;
}
.gradient-wrapper {
  background: linear-gradient(135deg, #003366 0%, #c89b3c 100%);
  min-height: 100vh;
  padding: 40px 0;
}
h3 {
  margin-top: 20px;
  margin-bottom: 8px;
  color: #003366
}
.frost-header {
  background: rgba(255,255,255,0.12);
  backdrop-filter: blur(8px);
  border-radius: 12px;
  padding: 20px 24px;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.15);
}
.accent-header h1 {
  margin-bottom: 0;
  text-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.header-underline {
  width: 80px;
  height: 3px;
  background: #fbbf24; /* soft gold accent */
  border-radius: 2px;
  margin-top: 8px;
}
.page-header {
  padding-top: 20px;
  padding-bottom: 10px;
}

.page-header h1 {
  text-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.page-header p {
  font-size: 1rem;
}
.return-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  margin-bottom: 20px;
  background: #f7f7f7;
  border: 1px solid #ddd;
  border-radius: 6px;
  color: #333;
  text-decoration: none;
  font-size: 0.95rem;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.return-link:hover {
  background: #eee;
  border-color: #c89b3c;
}
.return-link .arrow {
  font-size: 1.1rem;
  margin-right: 4px;
}
h1 {
  margin-top: 0;
  font-size: 1.8rem;
  color: #c89b3c;
  font-weight: 600;
  border-bottom: 2px solid #e6e6e6;
  padding-bottom: 10px;
}
#exportReportBtn {
  display: none;
}
.help-icon-wrapper {
    position: relative;
    display: inline-block;
    margin-left: 10px;
}

.help-icon {
    background: #c89b3c;
    color: #0b1b33;
    font-size: 14px;
    padding: 4px 7px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.help-tooltip {
    position: absolute;
    top: 28px;
    left: 0;
    width: 260px;
    background: rgba(15, 23, 42, 0.95);
    color: #e0e7ff;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid rgba(148,163,184,0.4);
    font-size: 13px;
    line-height: 1.45;
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease;
    z-index: 9999;
}

/* Hover for desktop */
.help-icon-wrapper:hover .help-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Tap-to-open for mobile */
.help-icon-wrapper .help-icon:active + .help-tooltip {
    opacity: 1;
    visibility: visible;
}
.cta-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    margin-left: 10px;
    background: #c89b3c;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    color: #0b1b33;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.cta-link:hover {
    background: #d4a64a;
    border-color: #f0f0f0;
}
