@import url('https://fonts.googleapis.com/css2?family=Anek+Telugu:wght@200;300;400;500;600;700&display=swap');

/* Chrome is greyscale on purpose. The nine rasa colours are the only colour
   on this site — they arrive as an inline --ink on whatever element carries
   them, so nothing in here competes with a performer's work.

   --ink is the page background. Inside a rasa tile it is overridden inline to
   that rasa's colour, which is what the colour-mix rules below blend toward. */
:root {
  --ink: #f4f2ef;        /* warm off-white, not pure white — easier on the eye */
  --surface: #ffffff;
  --surface-2: #e9e6e1;
  --edge: #ddd9d2;        /* decorative hairlines between cards */
  --edge-strong: #90887c; /* form field borders — these carry meaning, so
                             they clear 3:1 against the page */
  --text: #1b1a1e;
  --muted: #6d6a70;
  --wrap: 1180px;
  --radius: 10px;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: 'Anek Telugu', system-ui, sans-serif;
  font-weight: 300;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
img { max-width: 100%; display: block; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }

:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; }

/* ---------------- masthead ---------------- */

.masthead {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
  padding: 16px 22px;
  border-bottom: 1px solid var(--edge);
  position: sticky;
  top: 0;
  background: rgba(244, 242, 239, .94);
  backdrop-filter: blur(8px);
  z-index: 30;
}

.wordmark {
  font-size: 23px;
  font-weight: 600;
  letter-spacing: -.02em;
  text-decoration: none;
  margin-right: auto;
}

.masthead nav { display: flex; gap: 20px; flex-wrap: wrap; align-items: center; }

.masthead nav a {
  text-decoration: none;
  color: var(--muted);
  font-size: 15.5px;
  font-weight: 400;
}

.masthead nav a:hover, .masthead nav a[aria-current] { color: var(--text); }

/* ---------------- the rasa grid: the hero ---------------- */

.rasa-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--edge);
  border-block: 1px solid var(--edge);
}

.rasa-tile {
  --ink: var(--muted);
  --on-tile: #141216;
  background: var(--ink);
  color: var(--on-tile);
  padding: 30px 24px 22px;
  min-height: 182px;
  display: flex;
  flex-direction: column;
  text-decoration: none;
}

/* Bhayanaka is the one tile dark enough to need light text — fitting for the
   rasa of fear. Every tile is checked against WCAG AA; see config.py. */
.rasa-tile.on-dark { --on-tile: #f0ebe6; }

.rasa-tile:hover { filter: brightness(1.1); }

/* Telugu leads, Latin supports — the hierarchy the whole site follows. */
.rasa-te {
  font-size: 34px;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -.01em;
}

.rasa-en { font-size: 17px; font-weight: 500; margin-top: 2px; color: var(--on-tile); }
/* These were set with opacity, which dropped five of the nine tiles below
   4.5:1. Mixing toward the tile colour instead keeps the recessive look and
   keeps the contrast, with a solid fallback for browsers without color-mix. */
.rasa-gloss {
  font-size: 14.5px;
  margin-top: 10px;
  max-width: 24ch;
  color: var(--on-tile);
  color: color-mix(in srgb, var(--on-tile) 86%, var(--ink));
}

.rasa-count {
  margin-top: auto;
  padding-top: 14px;
  font-size: 13.5px;
  color: var(--on-tile);
  color: color-mix(in srgb, var(--on-tile) 80%, var(--ink));
}

/* ---------------- headings ---------------- */

h1, h2, h3 { font-weight: 600; letter-spacing: -.02em; line-height: 1.15; margin: 0 0 14px; }
h1 { font-size: clamp(32px, 5vw, 48px); }
h2 { font-size: 26px; }
h3 { font-size: 19px; font-weight: 500; }

.lede { font-size: 19px; font-weight: 300; color: var(--muted); max-width: 56ch; }
.muted { color: var(--muted); font-size: 14.5px; }

.section { padding: 56px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-bottom: 22px; }

/* ---------------- video ---------------- */

.clip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(252px, 1fr));
  gap: 22px;
}

.clip {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  display: block;
  border: 1px solid var(--edge);
}

.clip:hover { border-color: var(--muted); }

.clip .shot {
  aspect-ratio: 16 / 9;
  background: var(--surface-2) center/cover no-repeat;
  position: relative;
}

.clip .shot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.55), transparent 45%);
}

.clip .meta { padding: 13px 15px 15px; }
.clip .meta h3 { margin: 0 0 3px; font-size: 16.5px; }
.clip .meta p { margin: 0; color: var(--muted); font-size: 14px; }

.rasa-tag {
  --ink: var(--muted);
  display: inline-block;
  font-size: 12.5px;
  font-weight: 500;
  padding: 2px 9px;
  border-radius: 99px;
  color: #141216;
  background: var(--ink);
  text-decoration: none;
}

.player {
  aspect-ratio: 16 / 9;
  width: 100%;
  border: 0;
  border-radius: var(--radius);
  background: #000;
}

/* ---------------- performer profile ---------------- */

.profile {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 40px;
  align-items: start;
  padding: 44px 0;
}

.headshot {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--surface-2);
}

.facts { margin: 22px 0 0; display: grid; gap: 11px; }
.facts div { display: grid; grid-template-columns: 92px 1fr; gap: 10px; font-size: 15px; }
.facts dt, .facts .k { color: var(--muted); font-weight: 400; }

.rasa-dots { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.rasa-dots span { --ink: var(--edge); width: 13px; height: 13px; border-radius: 50%; background: var(--ink); }

/* ---------------- people ---------------- */

.people-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 22px; }

.person {
  text-decoration: none;
  display: block;
  background: var(--surface);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  overflow: hidden;
}

.person:hover { border-color: var(--muted); }
.person img, .person .noshot { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; background: var(--surface-2); }
.person .meta { padding: 12px 14px 15px; }
.person .meta h3 { margin: 0 0 2px; font-size: 16.5px; }
.person .meta p { margin: 0; color: var(--muted); font-size: 14px; }

/* ---------------- forms ---------------- */

.panel {
  background: var(--surface);
  border: 1px solid var(--edge);
  border-radius: var(--radius);
  padding: 28px;
}

.form { max-width: 560px; }
.form-wide { max-width: 760px; }

label { display: block; font-size: 14.5px; font-weight: 400; color: var(--muted); margin-bottom: 6px; }

input[type=text], input[type=email], input[type=password], input[type=url],
input[type=search], input[type=number], select, textarea {
  width: 100%;
  padding: 11px 13px;
  background: var(--surface);
  border: 1px solid var(--edge-strong);
  border-radius: 7px;
  color: var(--text);
  font: inherit;
}

input::placeholder, textarea::placeholder { color: #767169; }
input:focus, select:focus, textarea:focus { border-color: var(--text); outline: none; }
textarea { resize: vertical; min-height: 110px; }

.field { margin-bottom: 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.checkline { display: flex; gap: 11px; align-items: flex-start; margin-bottom: 14px; font-size: 15px; color: var(--text); }
.checkline input { margin-top: 5px; width: auto; flex: none; }
.checkline label { color: inherit; margin: 0; font-size: inherit; }

.btn {
  display: inline-block;
  border: 0;
  border-radius: 7px;
  background: var(--text);
  color: var(--ink);
  font: inherit;
  font-weight: 500;
  font-size: 16px;
  padding: 11px 22px;
  cursor: pointer;
  text-decoration: none;
}

.btn:hover { background: #000; }
.btn-quiet { background: transparent; color: var(--text); border: 1px solid var(--edge); }
.btn-quiet:hover { background: var(--surface-2); }
.btn-warn { background: #e85d4e; color: #fff; }
.btn-sm { padding: 7px 14px; font-size: 14.5px; }
.btn-row { display: flex; gap: 11px; flex-wrap: wrap; align-items: center; margin-top: 24px; }

/* Radio tiles for picking a rasa or category */
.pick { display: flex; gap: 9px; flex-wrap: wrap; }
.pick input { position: absolute; opacity: 0; pointer-events: none; }
.pick label {
  --ink: var(--edge-strong);
  margin: 0;
  padding: 9px 15px;
  border: 1px solid var(--edge-strong);
  border-radius: 7px;
  cursor: pointer;
  color: var(--text);
  font-size: 15px;
}
.pick input:checked + label { background: var(--ink); border-color: var(--ink); color: #141216; font-weight: 500; }
.pick input:focus-visible + label { outline: 2px solid var(--text); outline-offset: 2px; }

/* ---------------- flashes, tables, misc ---------------- */

.flashes { list-style: none; margin: 0; padding: 14px 22px 0; max-width: var(--wrap); margin-inline: auto; }
.flash { border-left: 3px solid var(--muted); background: var(--surface); padding: 11px 16px; font-size: 15px; border-radius: 0 7px 7px 0; }
.flash + .flash { margin-top: 8px; }
.flash-ok { border-color: #4fb07f; }
.flash-warn { border-color: #f2893f; }

table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 11px 13px; border-bottom: 1px solid var(--edge); vertical-align: top; }
th { color: var(--muted); font-weight: 400; font-size: 13.5px; }

.pill { font-size: 12.5px; padding: 2px 9px; border-radius: 99px; background: var(--surface-2); color: var(--muted); }
.pill-live { background: #4fb07f; color: #141216; }
.pill-wait { background: #f2c14e; color: #141216; }
.pill-no { background: #e85d4e; color: #fff; }

.empty { background: var(--surface); border: 1px dashed var(--edge); border-radius: var(--radius); padding: 40px 28px; }
.empty h3 { margin-bottom: 6px; }

.stats { display: flex; gap: 34px; flex-wrap: wrap; margin-top: 22px; }
.stats b { display: block; font-size: 27px; font-weight: 600; }
.stats span { color: var(--muted); font-size: 14.5px; }

.filters { display: flex; gap: 12px; flex-wrap: wrap; align-items: end; margin-bottom: 24px; }
.filters .field { margin: 0; }

footer { border-top: 1px solid var(--edge); margin-top: 72px; padding: 30px 0 46px; color: var(--muted); font-size: 14.5px; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; }

@media (max-width: 860px) {
  .profile { grid-template-columns: 1fr; gap: 26px; }
  .rasa-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .rasa-grid { grid-template-columns: 1fr; }
  .rasa-tile { min-height: 0; padding: 22px 20px 18px; }
  .field-row { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* ---------------- help widget ---------------- */

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.help-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 0;
  background: var(--text);
  color: var(--ink);
  font-size: 23px;
  font-weight: 600;
  cursor: pointer;
  z-index: 40;
  box-shadow: 0 2px 14px rgba(0, 0, 0, .18);
}

.help-fab:hover { background: #000; }

/* An author `display` beats the UA stylesheet's [hidden] { display: none },
   so without this rule setting .hidden = true changes the attribute and
   nothing else — the panel never closes. */
.help-panel[hidden] { display: none; }

.help-panel {
  position: fixed;
  right: 20px;
  bottom: 84px;
  width: min(370px, calc(100vw - 40px));
  max-height: min(560px, calc(100vh - 120px));
  background: var(--surface);
  border: 1px solid var(--edge-strong);
  border-radius: var(--radius);
  box-shadow: 0 6px 30px rgba(0, 0, 0, .18);
  display: flex;
  flex-direction: column;
  z-index: 41;
  overflow: hidden;
}

.help-panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  border-bottom: 1px solid var(--edge);
}

.help-panel header button {
  border: 0; background: none; color: var(--muted);
  font-size: 22px; line-height: 1; cursor: pointer; padding: 0 2px;
}

.help-panel header button:hover { color: var(--text); }

.help-log {
  flex: 1 1 auto;
  min-height: 90px;
  padding: 14px 16px 4px;
  overflow-y: auto;
  font-size: 14.5px;
  line-height: 1.55;
}

.help-msg { margin-bottom: 12px; }

.help-bot {
  background: var(--surface-2);
  padding: 10px 13px;
  border-radius: 3px 11px 11px 11px;
}

.help-you {
  background: var(--text);
  color: var(--ink);
  padding: 8px 13px;
  border-radius: 11px 11px 3px 11px;
  margin-left: auto;
  width: fit-content;
  max-width: 85%;
  overflow-wrap: anywhere;
}

.help-choices {
  flex: 0 1 auto;
  max-height: 42%;
  overflow-y: auto;
  padding: 4px 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.help-choices button {
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--edge-strong);
  border-radius: 8px;
  padding: 8px 12px;
  font: inherit;
  font-size: 14px;
  color: var(--text);
  cursor: pointer;
}

.help-choices button:hover { background: var(--surface-2); }

.help-panel footer {
  border: 0;
  margin: 0;
  padding: 11px 16px;
  border-top: 1px solid var(--edge);
  font-size: 13.5px;
  color: var(--muted);
}

@media (max-width: 560px) {
  .help-panel { right: 10px; left: 10px; width: auto; bottom: 78px; }
  .help-fab { right: 14px; bottom: 14px; }
}
