/* ============================================================
   Old Record — advanced monthly combined chart (homepage)
   Scoped under .rec-section so nothing else on the site changes.
   ============================================================ */

.rec-section{
  --rec-green:#14804a;
  --rec-green-d:#0f6b3d;
  --rec-blue:#1565c0;
  --rec-blue-d:#0d47a1;
  --rec-yellow:#ffd400;
  --rec-orange:#eda311;
  --rec-red:#c62828;
  --rec-ink:#141414;
  --rec-line:#e4e4e4;
  max-width:1200px;
  margin:26px auto;
  padding:0 12px;
  box-sizing:border-box;
}
.rec-section *,
.rec-section *::before,
.rec-section *::after{ box-sizing:border-box; }

/* ---------- title ---------- */
.rec-title{
  margin:0 0 14px;
  text-align:center;
  font-size:22px;
  line-height:1.3;
  font-weight:900;
  color:var(--rec-ink);
  letter-spacing:.01em;
  text-transform:uppercase;
}
.rec-title span{
  display:block;
  margin-top:5px;
  font-size:12.5px;
  font-weight:800;
  letter-spacing:.16em;
  color:#6b7280;
}

/* ---------- green header ---------- */
.rec-head{
  background:linear-gradient(135deg,var(--rec-green) 0%,var(--rec-green-d) 100%);
  color:#fff;
  border-radius:8px;
  padding:16px 20px;
  text-align:center;
  font-size:18px;
  line-height:1.45;
  font-weight:800;
  letter-spacing:.01em;
  box-shadow:0 2px 6px rgba(0,0,0,.12);
}

/* ---------- table ---------- */
.rec-table-wrap{
  margin-top:12px;
  border:1px solid var(--rec-line);
  border-radius:8px;
  overflow-x:auto;
  overflow-y:hidden;
  -webkit-overflow-scrolling:touch;
  background:#fff;
}
.rec-table{
  width:100%;
  min-width:640px;
  border-collapse:collapse;
  font-size:14.5px;
  font-variant-numeric:tabular-nums;
}
.rec-table thead th{
  background:var(--rec-orange);
  color:#fff;
  padding:12px 8px;
  font-size:12.5px;
  font-weight:900;
  letter-spacing:.09em;
  text-transform:uppercase;
  text-align:center;
  border-right:1px solid rgba(255,255,255,.28);
  border-bottom:2px solid #d18f06;
  white-space:nowrap;
}
.rec-table thead th:last-child{ border-right:0; }
.rec-table thead th.rec-col-date{ width:112px; }

.rec-table tbody th,
.rec-table tbody td{
  text-align:center;
  padding:9px 8px;
  border-right:1px solid #f1f1f1;
  border-bottom:1px solid #f1f1f1;
}
.rec-table tbody th:last-child,
.rec-table tbody td:last-child{ border-right:0; }

.rec-table tbody th.rec-date{
  width:112px;
  background:#fff3c4;
  color:var(--rec-red);
  font-size:15px;
  font-weight:900;
  letter-spacing:.04em;
  border-right:1px solid var(--rec-line);
}
.rec-table tbody td{
  background:#fff;
  color:#16a34a;
  font-weight:800;
  font-size:15.5px;
}
.rec-table tbody tr:nth-child(even) td{ background:#fffdf0; }
.rec-table tbody tr:hover td{ background:#fff7d6; }
.rec-table tbody td.is-pending{
  color:#9aa0a6;
  font-weight:700;
  letter-spacing:.06em;
}
.rec-table tbody tr.is-today th.rec-date{
  background:var(--rec-yellow);
  box-shadow:inset 0 0 0 2px #e0a800;
}
.rec-table tbody tr.is-today td{
  background:#fffbdc;
  box-shadow:inset 0 0 0 2px #ffe680;
}

/* ---------- month navigation ---------- */
.rec-form{ margin-top:14px; }
.rec-nav{
  display:flex;
  align-items:stretch;
  border-radius:8px;
  overflow:hidden;
  background:var(--rec-blue);
  box-shadow:0 2px 6px rgba(0,0,0,.12);
}
.rec-nav__btn{
  flex:1 1 0;
  min-width:0;
  background:var(--rec-blue);
  color:#fff;
  border:0;
  padding:15px 10px;
  font-family:inherit;
  font-size:15px;
  font-weight:800;
  letter-spacing:.02em;
  cursor:pointer;
  transition:background .15s ease;
}
.rec-nav__btn:hover:not(:disabled){ background:var(--rec-blue-d); }
.rec-nav__btn:disabled{ opacity:.45; cursor:not-allowed; }
.rec-nav__current{
  flex:0 0 auto;
  display:flex;
  align-items:center;
  justify-content:center;
  min-width:160px;
  padding:12px 18px;
  background:#fff;
  color:#111;
  font-size:21px;
  font-weight:900;
  letter-spacing:.01em;
  white-space:nowrap;
}

/* ---------- blue info bar ---------- */
.rec-info{
  display:flex;
  align-items:center;
  gap:14px;
  margin-top:12px;
  padding:12px 16px;
  background:var(--rec-blue);
  color:#fff;
  border-radius:8px;
  font-size:13.5px;
  font-weight:700;
  line-height:1.5;
  box-shadow:0 2px 6px rgba(0,0,0,.12);
}
.rec-info__text{ flex:1 1 auto; }
.rec-info__btn{
  flex:0 0 auto;
  background:var(--rec-yellow);
  color:#111;
  border:0;
  border-radius:5px;
  padding:9px 16px;
  font-family:inherit;
  font-size:12.5px;
  font-weight:900;
  letter-spacing:.04em;
  text-transform:uppercase;
  cursor:pointer;
  transition:filter .15s ease;
}
.rec-info__btn:hover{ filter:brightness(.94); }

/* ---------- yellow selector ---------- */
.rec-selector{
  margin-top:12px;
  padding:20px 16px;
  background:var(--rec-yellow);
  border-radius:8px;
  text-align:center;
  box-shadow:0 2px 6px rgba(0,0,0,.12);
}
.rec-selector__title{
  margin:0 0 18px;
  font-size:15px;
  font-weight:800;
  line-height:1.5;
  color:#111;
}
.rec-selector__row{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:18px;
  margin-bottom:18px;
}
.rec-field{ text-align:left; }
.rec-field label{
  display:block;
  margin-bottom:6px;
  font-size:11px;
  font-weight:900;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:#1a5fb4;
}
.rec-field select{
  min-width:236px;
  padding:12px 14px;
  border:1px solid #e0a800;
  border-radius:6px;
  background:#fff;
  color:#111;
  font-family:inherit;
  font-size:16px;
  font-weight:700;
  cursor:pointer;
}
.rec-field select:focus-visible{
  outline:3px solid #111;
  outline-offset:2px;
}
.rec-actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:12px;
}
.rec-go{
  min-width:86px;
  padding:11px 24px;
  background:#111;
  color:#fff;
  border:0;
  border-radius:5px;
  font-family:inherit;
  font-size:15px;
  font-weight:800;
  cursor:pointer;
  transition:background .15s ease;
}
.rec-go:hover{ background:#000; }
.rec-reset{
  padding:11px 22px;
  background:#fff;
  color:var(--rec-red);
  border:1px solid #e0a800;
  border-radius:5px;
  font-family:inherit;
  font-size:15px;
  font-weight:800;
  cursor:pointer;
  transition:background .15s ease;
}
.rec-reset:hover{ background:#fff5f5; }

/* ---------- year picker bar ---------- */
.rec-pickyear{
  margin-top:14px;
  padding:12px;
  background:#fafafa;
  border:1px solid var(--rec-line);
  border-radius:6px;
  text-align:center;
  font-size:14px;
  font-weight:800;
  color:#222;
}

/* ---------- year pills ---------- */
.rec-years{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  margin-top:14px;
}
.rec-year{
  flex:1 1 auto;
  min-width:78px;
  padding:13px 14px;
  background:var(--rec-red);
  color:#fff;
  border:3px solid transparent;
  border-radius:6px;
  font-family:inherit;
  font-size:15px;
  font-weight:900;
  letter-spacing:.02em;
  cursor:pointer;
  transition:filter .15s ease, transform .15s ease;
}
.rec-year:hover{ filter:brightness(1.08); transform:translateY(-1px); }
.rec-year.is-active{
  border-color:var(--rec-yellow);
  box-shadow:0 0 0 2px rgba(198,40,40,.25);
}

/* ---------- month grid ---------- */
.rec-months{
  display:grid;
  grid-template-columns:repeat(6,minmax(0,1fr));
  gap:10px;
  margin-top:14px;
}
.rec-month{
  padding:15px 8px;
  background:#1e7d32;
  color:#fff;
  border:3px solid transparent;
  border-radius:6px;
  font-family:inherit;
  font-size:15px;
  font-weight:800;
  letter-spacing:.01em;
  cursor:pointer;
  transition:filter .15s ease, transform .15s ease;
}
.rec-month:hover{ filter:brightness(1.1); transform:translateY(-1px); }
.rec-month.is-active{
  border-color:var(--rec-yellow);
  box-shadow:0 0 0 2px rgba(30,125,50,.25);
}

/* ---------- note ---------- */
.rec-note{
  margin:16px 0 0;
  text-align:center;
  font-size:12.5px;
  line-height:1.65;
  color:#6b7280;
}

/* ---------- year-wise market chart links ---------- */
.rec-yearcharts{ margin-top:20px; }
.rec-yearcharts summary{
  padding:11px 14px;
  background:#f4f8ff;
  border:1px solid #d9e6ff;
  border-radius:6px;
  color:var(--rec-blue);
  font-size:13.5px;
  font-weight:800;
  letter-spacing:.02em;
  cursor:pointer;
  list-style:none;
}
.rec-yearcharts summary::-webkit-details-marker{ display:none; }
.rec-yearcharts summary::after{
  content:"+";
  float:right;
  font-size:16px;
  font-weight:900;
}
.rec-yearcharts[open] summary::after{ content:"–"; }
.rec-yc-grid{
  display:grid;
  gap:8px;
  margin-top:10px;
}
.rec-yc-row{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:8px;
  align-items:stretch;
}
.rec-yc-year{
  display:flex;
  align-items:center;
  justify-content:center;
  background:#eef3ff;
  border:1px solid #d9e6ff;
  border-radius:5px;
  color:#374151;
  font-size:12.5px;
  font-weight:900;
}
.rec-yc-row a{
  display:flex;
  align-items:center;
  justify-content:center;
  padding:9px 6px;
  background:#fff;
  border:1px solid #e8e8e8;
  border-radius:5px;
  color:var(--rec-blue);
  font-size:12px;
  font-weight:700;
  text-align:center;
  text-decoration:none;
  transition:background .15s ease, border-color .15s ease;
}
.rec-yc-row a:hover{
  background:#f4f8ff;
  border-color:#b9d2ff;
}

/* ---------- responsive ---------- */
@media (max-width:900px){
  .rec-months{ grid-template-columns:repeat(3,minmax(0,1fr)); }
  .rec-yc-row{ grid-template-columns:repeat(3,minmax(0,1fr)); }
  .rec-head{ font-size:16px; padding:14px 16px; }
}
@media (max-width:640px){
  .rec-title{ font-size:17px; }
  .rec-months{ grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
  .rec-month{ padding:13px 4px; font-size:12.5px; }
  .rec-yc-row{ grid-template-columns:repeat(2,minmax(0,1fr)); }
  .rec-nav__current{ min-width:112px; font-size:16px; padding:10px 10px; }
  .rec-nav__btn{ font-size:12.5px; padding:12px 5px; }
  .rec-info{ flex-direction:column; align-items:stretch; text-align:center; gap:10px; }
  .rec-field select{ min-width:150px; font-size:15px; }
  .rec-selector__row{ gap:12px; }
  .rec-year{ padding:11px 8px; font-size:14px; min-width:64px; }
  .rec-head{ font-size:14.5px; }
  .rec-table{ font-size:12.5px; min-width:0; }
  .rec-table thead th{ padding:9px 4px; font-size:11px; }
  .rec-table tbody th.rec-date{ width:70px; font-size:13px; }
  .rec-table tbody td{ padding:8px 4px; font-size:13px; }
}
@media (prefers-reduced-motion:reduce){
  .rec-year, .rec-month, .rec-go, .rec-reset, .rec-info__btn,
  .rec-nav__btn, .rec-yc-row a{ transition:none; }
  .rec-year:hover, .rec-month:hover{ transform:none; }
}
