/* ===========================================================================
   RANKING PAGES
   Shared by every ranking menu and every ranking table, through
   _includes/rank_menu.php and _includes/rank_page.php.
   The division colour arrives as the custom property --rank on the page
   wrapper, so nothing here is written out once per division.
   =========================================================================== */

.rk{--rank:#2340a0;}

/* Heading block ---------------------------------------------------------- */
.rk-head{border-left:6px solid var(--rank);padding:0.1em 0 0.1em 0.9em;margin:0.5em 0 1.2em;}
.rk-div{color:var(--rank);font-size:0.8em;font-weight:bold;letter-spacing:0.08em;text-transform:uppercase;}
.rk-title{font-size:1.6em;font-weight:bold;color:#222;line-height:1.2;margin-top:0.1em;}
.rk-sub{color:#555;font-size:0.9em;margin-top:0.3em;line-height:1.5;}

/* Buttons on the menu pages ---------------------------------------------- */
.rk-list{max-width:560px;margin:0 auto 2em;}
a.rk-btn,a.rk-btn:link,a.rk-btn:visited{display:block;box-sizing:border-box;width:100%;margin:0 0 0.7em;padding:0.85em 1em;border:1px solid var(--rank);border-radius:6px;background:var(--rank);color:#fff !important;font-size:1.05em;font-weight:bold;text-align:center;text-decoration:none;}
a.rk-btn:hover{background:#fff;color:var(--rank) !important;text-decoration:none;box-shadow:none;}
a.rk-btn.rk-quiet,a.rk-btn.rk-quiet:link,a.rk-btn.rk-quiet:visited{background:#fff;border-color:#b8bccc;color:#354089 !important;font-weight:normal;}
a.rk-btn.rk-quiet:hover{background:#f4f8ff;border-color:#354089;}
.rk-group{margin:1.8em auto 0;max-width:560px;}
.rk-group-head{font-size:0.8em;font-weight:bold;letter-spacing:0.08em;text-transform:uppercase;color:#555;border-bottom:2px solid #ddd;padding-bottom:0.3em;margin-bottom:0.8em;text-align:left;}

/* Tools above the table --------------------------------------------------- */
.rk-tools{display:flex;flex-wrap:wrap;gap:0.6em;align-items:center;justify-content:center;margin:1.2em 0 0.6em;}
.rk-tools select,.rk-tools input[type=text]{background:#fff;border:1px solid #b8bccc;border-radius:4px;padding:0.6em;font-size:1em;font-family:inherit;}
.rk-tools select{flex:1 1 16em;max-width:22em;}
.rk-tools input[type=text]{flex:1 1 16em;max-width:22em;}
.rk-tools select:focus,.rk-tools input[type=text]:focus{outline:none;border-color:var(--rank);box-shadow:0 0 0 3px rgba(53,64,137,0.15);}
.rk-count{text-align:center;color:#555;font-size:0.95em;margin:0.2em 0 1em;}
.rk-count strong{color:#222;}
.rk-asof{text-align:center;color:#777;font-size:small;margin:0 0 1.2em;line-height:1.5;}

/* The ranking table ------------------------------------------------------- */
.rk-table{width:100%;border-collapse:collapse;margin:0 0 1em;}
.rk-table th{background:var(--rank);color:#fff;font-size:0.85em;letter-spacing:0.04em;text-transform:uppercase;padding:0.6em 0.5em;text-align:center;}
.rk-table th.rk-left{text-align:left;}
.rk-table td{padding:0.6em 0.5em;border-bottom:1px solid #e6e6e6;text-align:center;color:#333;}
.rk-table td.rk-left{text-align:left;}
.rk-table tbody tr:nth-child(even){background:#f6f8fc;}
.rk-table tbody tr:hover{background:#eef3ff;}
.rk-rank{font-weight:bold;color:var(--rank);width:3.5em;}
/* The couple name used to be colour:#fff - white on a white table, left over
   from when these pages had a dark background. */
.rk-table a,.rk-table a:link,.rk-table a:visited{color:#0348a9 !important;text-decoration:none;font-weight:bold;}
.rk-table a:hover{color:#c00 !important;text-decoration:underline;}
.rk-none{color:#c00;text-align:center;padding:1.5em 0;font-weight:bold;}

/* Narrow screens: the table keeps its columns but loses the padding, and the
   State column goes - it is in the couple's own row on their history page. */
@media only screen and (max-width:600px){
.rk-table th,.rk-table td{padding:0.5em 0.25em;font-size:0.9em;}
.rk-hide-sm{display:none;}
.rk-title{font-size:1.35em;}
}

/* Ranking history --------------------------------------------------------- */
.rk-hist{border:1px solid #e2e2e2;border-left:5px solid var(--rank);border-radius:5px;background:#fff;padding:0.8em 1em;margin-bottom:0.6em;}
.rk-hist-when{color:#777;font-size:0.8em;}
.rk-hist-comp{font-weight:bold;color:var(--rank);font-size:1.05em;line-height:1.25;margin-top:0.1em;}
.rk-hist-event{color:#333;font-size:0.9em;margin-top:0.2em;}
.rk-hist-res{color:#555;font-size:0.85em;margin-top:0.3em;}
.rk-hist-pts{display:inline-block;margin-top:0.4em;border-radius:999px;padding:0.15em 0.8em;font-size:0.8em;font-weight:bold;background:#e6f4e6;color:#1a6b1a;}
