@tailwind base;
@tailwind components;
@tailwind utilities;

body {
    font-family: system-ui, sans-serif;
}

@font-face {
    font-family: 'ArnoSemibold';
    src: url('https://mtsinsights-assets.s3.us-east-2.amazonaws.com/fonts/arno-pro-semibold.ttf') format('truetype');
    font-weight: 800;
    font-style: normal;
  }
  

.logo-font {
    font-family: 'ArnoSemibold', serif;
}

.macro-summary p {
    margin-bottom: 1rem;
}

.macro-summary ul {
    list-style-type: disc;
    margin-left: 1.5rem;
    margin-top: 0.5rem;
}

.macro-summary li {
    margin-bottom: 0.5rem;
}

.macro-summary img {
    display: block;
    margin-left: auto;
    margin-right: auto;
    max-width: 800px;
    height: auto !important;
}

/* Base styling for tables inside macro summaries */
.macro-summary table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    font-size: 0.875rem; /* ~text-sm */
    line-height: 1.4;
  }
  
  .macro-summary th,
  .macro-summary td {
    border: 1px solid #e2e8f0; /* slate-200 */
    padding: 0.5rem 0.75rem;
    text-align: left;
    vertical-align: top;
  }
  
  .macro-summary th {
    background-color: #dfdfdf; /* slate-50 */
    color: #334155;           /* slate-700 */
    font-weight: 600;
    white-space: nowrap;
  }
  
  .macro-summary tr:nth-child(even) td {
    background-color: #f9fafb; /* subtle row striping */
  }
  
  .macro-summary tr:hover td {
    background-color: #f1f5f9; /* slate-100 hover */
  }
  
  .macro-summary caption {
    caption-side: bottom;
    padding-top: 0.75rem;
    font-size: 0.75rem;
    color: #64748b; /* slate-500 */
    text-align: left;
  }
  

.custom-components div {
    margin: 0.8rem;
}

/* Ensure the container can position the tooltip */
.has-tooltip { position: relative; }

/* Trigger styles */
.tooltip-target {
  text-decoration: underline dotted;
  cursor: help;
}

/* Tooltip box */
.tooltip-box {
  position: absolute;
  left: 0;                 /* anchor to the left of the Frequency text */
  top: 100%;               /* below the line */
  margin-top: 8px;
  width: 18rem;            /* ~288px */
  background: #0f172a;     /* slate-900 */
  color: #fff;
  padding: 12px;
  border-radius: 8px;
  box-shadow: 0 10px 20px rgba(0,0,0,.15);
  z-index: 1000;

  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity .15s ease, transform .15s ease, visibility 0s linear .15s;

  pointer-events: none;    /* prevents flicker on hover */
}

/* Show on hover */
.has-tooltip:hover .tooltip-box {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition-delay: 0s;    /* show immediately */
}

/* Optional: if any parent clips overflow, allow it */
.info-grid, .info-item { overflow: visible; }
