/* ============================================
   Royal Curry Club — Classic Club theme
   Loaded after minima's main.css to override
   ============================================ */

/* ---- Colours used throughout
   Cream paper:    #FAF4E6
   Pale band:      #F2E8D0
   Gold rule:      #C9A961
   Dark gold:      #8B6914
   Burgundy:       #6B1E1E
   Body text:      #2C1810
   Muted body:     #4A2C1A
*/

body {
  background: #FAF4E6;
  color: #2C1810;
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
}

/* Generic links throughout the site */
a {
  color: #6B1E1E;
}

a:hover {
  color: #8B1E1E;
  text-decoration: underline;
}

/* ============================================
   HEADER
   ============================================ */

.site-header {
  background: #FAF4E6;
  border-top: none !important;
  border-bottom: 1px solid #C9A961;
  min-height: auto !important;
  padding: 36px 0 0;
}

.site-header-wrapper {
  text-align: center;
  max-width: 800px;
}

.site-title-link {
  display: inline-block;
  text-decoration: none !important;
  color: inherit !important;
}

.site-logo {
  display: block;
  margin: 0 auto 10px;
  width: 240px;
  max-width: 80%;
  height: auto;
}

@media screen and (max-width: 599px) {
  .site-logo {
    width: 180px;
  }
}

.site-est {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 3px;
  color: #8B6914;
  text-align: center;
}

.site-divider {
  margin-top: 14px;
  margin-bottom: 18px;
  font-size: 14px;
  color: #6B1E1E;
}

/* ============================================
   NAV
   ============================================ */

.site-nav {
  background: #F2E8D0;
  border-top: 1px solid #C9A961;
  border-bottom: 1px solid #C9A961;
  padding: 14px 0;
  text-align: center;
  display: block !important;
  position: static !important;
  float: none !important;
  line-height: 1.6 !important;
  margin: 0 !important;
  border-radius: 0 !important;
  text-align: center !important;
}

.site-nav .trigger {
  display: block !important;
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  text-align: center !important;
}

.site-nav .page-link {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 2.5px;
  color: #2C1810 !important;
  text-transform: uppercase;
  margin: 0 16px !important;
  padding: 4px 0;
  text-decoration: none;
  display: inline-block;
}

.site-nav .page-link:hover {
  color: #6B1E1E !important;
  text-decoration: none;
}

/* Hide the mobile hamburger on desktop where we have room */
@media screen and (min-width: 600px) {
  .site-nav .menu-icon,
  .site-nav label[for="nav-trigger"],
  .site-nav input.nav-trigger {
    display: none !important;
  }
}

/* On small screens, restore the hamburger so the nav doesn't overflow */
@media screen and (max-width: 599px) {
  .site-nav {
    padding: 8px 0;
    text-align: right !important;
  }
  .site-nav label[for="nav-trigger"] {
    display: block;
    padding: 6px 12px;
  }
  .site-nav .menu-icon path {
    fill: #6B1E1E;
  }
  .site-nav .trigger {
    display: none !important;
  }
  .site-nav input.nav-trigger:checked ~ .trigger {
    display: block !important;
    text-align: center !important;
  }
  .site-nav .page-link {
    display: block;
    padding: 6px 0;
  }
}

/* ============================================
   HOMEPAGE LAYOUT
   ============================================ */

.classic-home {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 16px;
}

.classic-intro {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 17px;
  font-style: italic;
  line-height: 1.7;
  text-align: center;
  color: #4A2C1A;
  max-width: 560px;
  margin: 36px auto 24px;
}

.classic-intro p {
  margin: 0 0 12px;
}

.featured-visitation {
  border-top: 1px solid #C9A961;
  border-bottom: 1px solid #C9A961;
  padding: 28px 0;
  margin: 28px 0;
  text-align: center;
}

.featured-label {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 3px;
  color: #8B6914;
  margin-bottom: 14px;
}

.featured-title {
  display: block;
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 24px;
  color: #6B1E1E;
  text-decoration: none;
  margin-bottom: 8px;
  line-height: 1.3;
}

.featured-title:hover {
  text-decoration: underline;
}

.featured-meta {
  font-size: 14px;
  color: #4A2C1A;
}

.featured-meta sup {
  font-size: 0.7em;
  vertical-align: super;
  margin-left: 1px;
}

.recent-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 40px;
  font-size: 15px;
  margin: 28px 0;
}

@media screen and (max-width: 599px) {
  .recent-grid {
    grid-template-columns: 1fr;
  }
}

.recent-item {
  border-bottom: 1px dotted #C9A961;
  padding: 10px 0;
  display: block;
  text-decoration: none !important;
  color: #2C1810 !important;
  text-align: left;
}

.recent-item:hover {
  color: #6B1E1E !important;
}

.recent-item:hover .recent-title {
  color: #6B1E1E;
}

.recent-title {
  color: #2C1810;
  font-size: 15px;
  line-height: 1.4;
}

.view-all {
  text-align: center;
  margin: 32px 0 48px;
}

.view-all a {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 2.5px;
  color: #6B1E1E !important;
  text-decoration: none;
}

.view-all a:hover {
  text-decoration: underline;
}

/* ============================================
   POSTS & PAGES (non-home)
   ============================================ */

.post-title,
.page-heading,
.post-list h3 {
  font-family: 'Playfair Display', Georgia, serif !important;
  color: #6B1E1E;
}

.post-title {
  font-style: italic;
}

.post-content h2,
.post-content h3,
.post-content h4,
.page-content h2,
.page-content h3 {
  font-family: 'Playfair Display', Georgia, serif;
  color: #6B1E1E;
}

.post-meta {
  color: #8B6914;
  font-style: italic;
}

.post-list-heading {
  font-family: 'Playfair Display', Georgia, serif !important;
  color: #6B1E1E !important;
  font-style: italic;
}

.post-list > li {
  border-bottom: 1px dotted #C9A961;
  padding-bottom: 16px;
}

.post-link {
  color: #2C1810 !important;
}

.post-link:hover {
  color: #6B1E1E !important;
}

/* Tables (visitations, scores) */
.post-content table,
.page-content table {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid #C9A961;
}

.post-content table th,
.page-content table th {
  background: #F2E8D0;
  color: #2C1810;
  border-bottom: 1px solid #C9A961;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 13px;
  letter-spacing: 1px;
}

.post-content table td,
.page-content table td {
  border-color: #E8DCC0;
}

.post-content table tr:nth-child(even),
.page-content table tr:nth-child(even) {
  background: rgba(242, 232, 208, 0.3);
}

/* ============================================
   FOOTER
   ============================================ */

.site-footer {
  background: #FAF4E6 !important;
  border-top: 1px solid #C9A961 !important;
  color: #4A2C1A;
  font-family: 'Playfair Display', Georgia, serif;
  padding: 36px 0 !important;
  margin-top: 48px;
}

.classic-footer {
  text-align: center;
  max-width: 600px;
}

.footer-divider {
  font-size: 14px;
  color: #6B1E1E;
  margin-bottom: 16px;
}

.footer-tagline {
  font-style: italic;
  font-size: 14px;
  color: #4A2C1A;
  line-height: 1.6;
  margin: 0 0 16px;
}

.footer-links {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 1.5px;
  color: #8B6914;
  text-transform: uppercase;
  margin: 0;
}

.footer-links a {
  color: #6B1E1E;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* ============================================
   TABLE SEARCH (visitations / scores)
   ============================================ */

.table-search-wrapper {
  margin: 16px 0 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.table-search-input {
  flex: 1;
  min-width: 220px;
  max-width: 480px;
  padding: 10px 14px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 15px;
  font-style: italic;
  color: #2C1810;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid #C9A961;
  border-radius: 2px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.table-search-input::placeholder {
  color: #8B6914;
  opacity: 0.8;
}

.table-search-input:focus {
  border-color: #6B1E1E;
  background: rgba(255, 255, 255, 0.9);
}

/* Hide the default 'X' clear button on WebKit (we use ESC instead) - looks tidier */
.table-search-input::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
  height: 14px;
  width: 14px;
  background: linear-gradient(45deg, transparent 45%, #8B6914 45%, #8B6914 55%, transparent 55%),
              linear-gradient(-45deg, transparent 45%, #8B6914 45%, #8B6914 55%, transparent 55%);
  cursor: pointer;
  opacity: 0.6;
}
.table-search-input::-webkit-search-cancel-button:hover {
  opacity: 1;
}

.table-search-count {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 12px;
  letter-spacing: 1.5px;
  color: #8B6914;
  text-transform: uppercase;
  white-space: nowrap;
}

/* ============================================
   PRINT STYLES (Visitations / Scores tables)
   ============================================ */

@media print {
  /* Hide UI chrome - we just want the data */
  .site-header,
  .site-nav,
  .site-footer,
  .table-search-wrapper,
  .table-stat,
  #rccc-post-index,
  script {
    display: none !important;
  }

  /* Page margins */
  @page {
    margin: 18mm 14mm;
  }

  body {
    background: white !important;
    color: black !important;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 10pt;
    line-height: 1.4;
  }

  .post-title {
    font-family: 'Playfair Display', Georgia, serif !important;
    font-style: italic;
    color: #6B1E1E !important;
    font-size: 22pt;
    margin: 0 0 8pt 0;
    page-break-after: avoid;
  }

  /* Add a tagline under the title for print context */
  .post-title::after {
    content: " — The Royal Curry Club of Christchurch, EST. MMXV";
    display: block;
    font-style: normal;
    font-family: -apple-system, "Helvetica", sans-serif;
    font-size: 9pt;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #8B6914;
    margin-top: 4pt;
  }

  /* Table tweaks */
  .post-content table,
  .page-content table {
    width: 100%;
    border-collapse: collapse;
    background: white !important;
    border: 1pt solid #6B1E1E !important;
    page-break-inside: auto;
    font-size: 9pt;
  }

  .post-content table th,
  .page-content table th {
    background: #FAF4E6 !important;
    color: black !important;
    border-bottom: 1pt solid #6B1E1E !important;
    padding: 4pt 6pt;
    text-align: left;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .post-content table td,
  .page-content table td {
    border: 0.5pt solid #ccc !important;
    padding: 3pt 6pt;
  }

  .post-content table tr:nth-child(even),
  .page-content table tr:nth-child(even) {
    background: #FAF4E6 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  /* Don't break rows across pages */
  .post-content table tr,
  .page-content table tr {
    page-break-inside: avoid;
  }

  /* Make links plain text for print (URL printing would be noise) */
  .post-content a,
  .page-content a {
    color: black !important;
    text-decoration: none !important;
  }
}

/* ============================================
   REVIEWS PAGE — year-grouped list
   ============================================ */

.reviews-jumpnav {
  margin: 16px 0 32px;
  padding: 12px 16px;
  background: rgba(242, 232, 208, 0.4);
  border: 1px solid #C9A961;
  border-radius: 2px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 13px;
  color: #4A2C1A;
  text-align: center;
}

.reviews-jumpnav a {
  color: #6B1E1E;
  text-decoration: none;
  font-weight: 500;
  margin: 0 4px;
}

.reviews-jumpnav a:hover {
  text-decoration: underline;
}

.reviews-year {
  margin-bottom: 28px;
}

.reviews-year-heading {
  font-family: 'Playfair Display', Georgia, serif !important;
  font-style: italic;
  font-size: 28px;
  color: #6B1E1E !important;
  margin: 24px 0 12px 0;
  padding-bottom: 6px;
  border-bottom: 1px solid #C9A961;
  scroll-margin-top: 24px; /* offset for in-page anchor jumps */
}

.reviews-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.reviews-list li {
  border-bottom: 1px dotted #C9A961;
  padding: 8px 0;
  margin: 0;
}

.reviews-list li:last-child {
  border-bottom: none;
}

.reviews-list a {
  color: #2C1810 !important;
  text-decoration: none;
  display: block;
  font-size: 16px;
}

.reviews-list a:hover {
  color: #6B1E1E !important;
}

/* ============================================
   AVERAGE SCORE BANNER (Scores page)
   ============================================ */

.table-stat {
  margin: 16px 0 20px;
  padding: 16px 20px;
  background: rgba(242, 232, 208, 0.5);
  border-left: 3px solid #6B1E1E;
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  color: #4A2C1A;
  font-size: 15px;
  line-height: 1.5;
}

.table-stat strong {
  color: #6B1E1E;
  font-style: normal;
  font-weight: 500;
}

/* ============================================
   POST NAVIGATION (previous/next review)
   ============================================ */

.post-nav {
  display: flex;
  gap: 24px;
  margin: 48px 0 24px;
  padding-top: 24px;
  border-top: 1px solid #C9A961;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.post-nav-prev,
.post-nav-next {
  flex: 1;
  min-width: 0;
}

.post-nav-next {
  text-align: right;
}

.post-nav a {
  display: block;
  text-decoration: none !important;
  color: #2C1810 !important;
}

.post-nav a:hover .post-nav-title {
  color: #6B1E1E;
}

.post-nav-label {
  display: block;
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #8B6914;
  margin-bottom: 6px;
}

.post-nav-title {
  display: block;
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 16px;
  color: #2C1810;
  line-height: 1.3;
}

@media (max-width: 599px) {
  .post-nav {
    flex-direction: column;
    gap: 16px;
  }
  .post-nav-next {
    text-align: left;
  }
}

/* ============================================
   LINKED TABLE ROWS (visitations cross-link)
   ============================================ */

/* When the layout's JS injects a link inside a table cell,
   make it look like the rest of the table (no underlines, etc.) */
.post-content table td a,
.page-content table td a {
  color: #6B1E1E;
  text-decoration: none;
  border-bottom: 1px dotted transparent;
}

.post-content table td a:hover,
.page-content table td a:hover {
  border-bottom-color: #6B1E1E;
}
