:root {
  --deep: #4A0A14; --kumkum: #A1122B; --kumkum-dark: #8C0F25; --tint: #FAEAE7;
  --turmeric: #F2D58A; --gold: #D9B865; --gold-text: #7A5A10;
  --rice: #FFFBF7; --sandal: #F6EEE3; --white: #FFFFFF; --edge: #EADBD3; --edge-soft: #F1E6E0;
  --ink: #2A1716; --ink-2: #5C4743; --ink-3: #7A6560;
  --serif: 'Playfair Display', 'Noto Serif Tamil', Georgia, serif;
  --sans: 'Mukta Malar', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); font-size: 17px; color: var(--ink); background: var(--rice); line-height: 1.7; -webkit-font-smoothing: antialiased; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.25; }
a { color: var(--kumkum); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 24px; }

nav { position: sticky; top: 0; z-index: 50; background: var(--deep); border-bottom: 1px solid rgba(242, 213, 138, .18); }
.nav-inner { display: flex; align-items: center; gap: 20px; padding: 12px 24px; max-width: 1080px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--sans); font-weight: 700; font-size: 1.25rem; color: var(--rice); }
.brand:hover { text-decoration: none; }
.brand img { width: 32px; height: 32px; filter: brightness(0) invert(96%); }
.brand .ta-name { font-family: 'Noto Serif Tamil', serif; color: var(--turmeric); font-size: 1rem; font-weight: 600; }
.nav-cta { margin-left: auto; display: inline-block; padding: 10px 18px; border-radius: 12px; background: var(--turmeric); color: var(--deep); font-weight: 600; font-size: .95rem; white-space: nowrap; }
.nav-cta:hover { text-decoration: none; background: #F7E2A8; }

.breadcrumb { font-size: .88rem; color: var(--ink-3); padding: 22px 0 0; }
.breadcrumb a { color: var(--ink-2); }

article { padding: 14px 0 40px; }
article .eyebrow { display: block; font-size: 1rem; font-weight: 600; color: var(--gold-text); margin: 22px 0 10px; }
article h1 { font-size: clamp(1.9rem, 4.5vw, 2.7rem); margin-bottom: 16px; }
article h2 { font-size: clamp(1.35rem, 3vw, 1.75rem); margin: 40px 0 14px; color: var(--kumkum); }
article h3 { font-size: 1.2rem; margin: 26px 0 8px; }
article p { margin-bottom: 16px; color: var(--ink); }
article ul, article ol { margin: 0 0 18px 22px; }
article li { margin-bottom: 8px; }
article .lead { font-size: 1.15rem; color: var(--ink-2); }
.ta-summary { background: var(--sandal); border: 1px solid var(--edge); border-radius: 16px; padding: 22px 24px; margin: 8px 0 30px; }
.ta-summary h2 { margin: 0 0 8px; font-size: 1.1rem; color: var(--kumkum); font-family: 'Noto Serif Tamil', serif; }
.ta-summary p { margin: 0; color: var(--ink-2); line-height: 1.85; }
table.porutham { width: 100%; border-collapse: collapse; margin: 8px 0 22px; font-size: .95rem; background: var(--white); border: 1px solid var(--edge); border-radius: 12px; overflow: hidden; }
table.porutham th, table.porutham td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--edge-soft); vertical-align: top; overflow-wrap: break-word; }
/* The Porutham names stay whole; only the description wraps. */
table.porutham th:nth-child(-n+2), table.porutham td:nth-child(-n+2) { white-space: nowrap; }
table.porutham th { background: var(--sandal); color: var(--ink); font-weight: 600; }
.callout { background: var(--tint); border-radius: 18px; padding: 26px 28px; margin: 28px 0; }
.callout h3 { margin: 0 0 8px; color: var(--ink); }
.callout p { margin: 0 0 16px; color: var(--ink-2); }
.btn { display: inline-block; padding: 13px 24px; border-radius: 12px; font-weight: 600; background: var(--kumkum); color: var(--white); }
.btn:hover { text-decoration: none; background: var(--kumkum-dark); }
.related { border-top: 1px solid var(--edge); margin-top: 40px; padding-top: 26px; }
.related h2 { font-size: 1.25rem; margin-bottom: 12px; color: var(--ink); }
.related ul { list-style: none; margin-left: 0; }
.related li { margin-bottom: 8px; }
.note { font-size: .9rem; color: var(--ink-3); }

.guide-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; margin-top: 8px; }
.guide-card { background: var(--white); border: 1px solid var(--edge); border-radius: 16px; padding: 24px; }
.guide-card h2 { margin: 0 0 8px; font-size: 1.25rem; color: var(--ink); }
.guide-card p { color: var(--ink-2); font-size: .98rem; margin: 0 0 14px; }
.guide-card a.more { font-weight: 600; }

footer { background: var(--deep); padding: 34px 0; margin-top: 40px; text-align: center; color: rgba(255, 251, 247, .7); }
footer .foot-links { display: flex; gap: 22px; justify-content: center; flex-wrap: wrap; font-size: .95rem; margin-bottom: 14px; }
footer a { color: rgba(255, 251, 247, .85); font-weight: 500; }
footer a:hover { color: var(--turmeric); }
footer .copyright { color: rgba(255, 251, 247, .55); font-size: .85rem; }

@media (max-width: 480px) {
  .brand .ta-name { display: none; }
  .wrap { padding: 0 18px; }
  table.porutham { font-size: .86rem; }
  table.porutham th, table.porutham td { padding: 8px 7px; }
  /* On a phone the names may wrap at their own spaces and hyphens. */
  table.porutham th:nth-child(-n+2), table.porutham td:nth-child(-n+2) { white-space: normal; }
}
