:root {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #26352c;
  background: #f6f7f3;
  font-size: 14px;
  line-height: 1.55;
  font-synthesis: none;
  --accent: #315d46;
  --muted: #7b857c;
  --border: #e1e6dc;
}
* { box-sizing: border-box; }
body { margin: 0; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; color: inherit; }
button, a { touch-action: manipulation; }
button { cursor: pointer; border: 0; background: none; }
a { color: inherit; }
button:disabled { opacity: .45; cursor: not-allowed; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid #8aab8d; outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 36px; line-height: 1.2; font-weight: 650; letter-spacing: -1.3px; }
h2 { font-size: 19px; line-height: 1.4; font-weight: 650; letter-spacing: -.5px; }
h3 { font-size: 15px; }
input, select { min-width: 0; }
input { width: 100%; border: 1px solid #d9e0d3; border-radius: 8px; background: #fff; padding: 13px 14px; }
input::placeholder { color: #a0a89d; }
input:focus { border-color: #7a9876; }
select { border: 1px solid var(--border); border-radius: 7px; background: #fff; padding: 9px; }
button, a { transition: background .15s, color .15s, border-color .15s; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.site-header, .page, .site-footer { max-width: 1136px; margin: auto; padding-left: 32px; padding-right: 32px; }
.site-header { height: 91px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; font-size: 23px; font-weight: 700; letter-spacing: -.8px; text-decoration: none; }
.brand-period { color: #779b67; }
.brand-mark { display: inline-flex; align-items: flex-end; gap: 3px; margin-right: 10px; height: 27px; padding: 6px; background: var(--accent); border-radius: 7px; }
.brand-mark i { display: block; width: 3px; background: #edf3e6; border-radius: 1px; }
.brand-mark i:nth-child(1) { height: 6px; }
.brand-mark i:nth-child(2) { height: 10px; }
.brand-mark i:nth-child(3) { height: 15px; }
.platform-label { display: inline-flex; align-items: center; gap: 7px; color: #78816f; font-size: 11px; letter-spacing: .1px; }
.platform-label span { width: 6px; height: 6px; border-radius: 50%; background: #bc9958; }
.intro { padding: 25px 0 29px; }
.intro p { color: var(--muted); margin-top: 11px; font-size: 14px; }
.submission-card { display: grid; grid-template-columns: .85fr 1.25fr; gap: 36px; align-items: center; background: #eef1e8; border: 1px solid #e0e5d8; border-radius: 14px; padding: 27px 29px; margin-bottom: 31px; }
.lookup-copy p { color: #7c8774; margin-top: 7px; font-size: 12px; line-height: 1.75; }
.form-fields { display: grid; grid-template-columns: 1fr auto; gap: 9px; align-items: end; }
.form-fields label { display: block; color: #65735d; font-size: 11px; font-weight: 550; margin-bottom: 7px; }
.form-fields input { background: #fffefb; font-size: 12px; padding-top: 12px; padding-bottom: 12px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 16px; border: 1px solid var(--border); border-radius: 8px; background: #fff; padding: 11px 16px; font-size: 12px; font-weight: 600; line-height: 1.5; white-space: nowrap; text-decoration: none; }
.button-dark, .button-green { background: var(--accent); border-color: var(--accent); color: #f8faf3; }
.button-dark:hover, .button-green:hover { background: #244b35; border-color: #244b35; }
.field-hint { color: #6c7b60; font-size: 10px; margin-top: 9px; }
.form-feedback:not(:empty) { background: #fffdf8; border: 1px solid #d9e0d3; border-radius: 7px; padding: 10px 12px; margin-top: 12px; font-size: 12px; }
.form-feedback.error { color: #a3493c; background: #fff5f1; border-color: #eed9cf; }
.form-feedback.success { color: #315d46; background: #f6faf2; }
.board-panel { background: #fffefb; border: 1px solid var(--border); border-radius: 14px; padding: 25px 25px 5px; box-shadow: 0 3px 15px #2c412607; }
.board-heading { display: flex; align-items: center; gap: 13px; margin-bottom: 21px; }
.board-heading h2 { font-size: 21px; }
#entry-count { color: #6c7b60; font-size: 10px; background: #f1f3ec; border-radius: 5px; padding: 3px 7px; }
.board-controls { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.search-wrap { display: flex; align-items: center; gap: 7px; max-width: 275px; width: 100%; border: 1px solid var(--border); border-radius: 7px; padding: 8px 11px; background: #fcfdf9; margin-right: auto; }
.search-wrap svg { height: 15px; width: 15px; flex-shrink: 0; fill: none; stroke: #a0aa95; stroke-width: 1.5; }
.search-wrap input { padding: 0; border: 0; border-radius: 0; background: none; font-size: 11px; }
.search-wrap:focus-within { outline: 2px solid #9bb392; outline-offset: 2px; }
.search-wrap input:focus { outline: 0; }
.sort-wrap { display: flex; align-items: center; gap: 8px; font-size: 10px; color: #8a9382; }
.sort-wrap select { font-size: 11px; padding: 7px; background: #fffefb; border-color: #e5e9df; }
.text-button { color: #79866e; font-size: 10px; padding: 6px 0; }
.text-button:hover { color: var(--accent); }
.table-scroll { overflow: auto; }
.leaderboard-table { width: 100%; min-width: 640px; border-collapse: collapse; text-align: left; }
.leaderboard-table th { color: #6c7b60; font-size: 10px; font-weight: 500; letter-spacing: .5px; text-transform: uppercase; padding: 11px 14px; border-top: 1px solid #edf0e7; border-bottom: 1px solid #edf0e7; white-space: nowrap; }
.leaderboard-table td { padding: 18px 14px; border-bottom: 1px solid #edf0e7; font-size: 12px; }
.leaderboard-table th:first-child, .leaderboard-table td:first-child { width: 72px; padding-left: 0; }
.leaderboard-table th:last-child, .leaderboard-table td:last-child { text-align: right; padding-right: 0; }
.leaderboard-table tr:last-child td { border-bottom: 0; }
.leaderboard-table tbody tr:hover { background: #f9fbf5; }
.rank-badge { display: inline-flex; justify-content: center; align-items: center; width: 27px; height: 27px; color: #8e9884; font-size: 11px; font-weight: 500; font-variant-numeric: tabular-nums; }
.rank-top { background: #eef3e7; border-radius: 7px; color: #6a8758; }
.coder-button { padding: 0; font-size: 12px; font-weight: 600; overflow-wrap: anywhere; text-align: left; }
.coder-button:hover { color: var(--accent); }
.metric { font-variant-numeric: tabular-nums; color: #76826b; }
.score-pill { display: inline-block; color: #577947; font-size: 11px; font-weight: 650; font-variant-numeric: tabular-nums; background: #eff5e7; border-radius: 5px; padding: 4px 9px; }
.row-action { font-size: 10px; color: #789065; border: 1px solid #e0e8d8; background: #fcfef8; border-radius: 6px; padding: 6px 9px; white-space: nowrap; }
.row-action span { margin-left: 7px; }
.row-action:hover { color: var(--accent); border-color: #b3c5a7; background: #eef5e7; }
.board-pagination { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid #edf0e7; padding: 16px 0; color: #9aa28f; font-size: 10px; }
.board-pagination>div { display: flex; align-items: center; gap: 12px; }
.page-button { color: #839174; font-size: 10px; padding: 5px 7px; }
.board-error { color: #a3493c; font-size: 12px; background: #fff5f1; border-radius: 7px; padding: 12px; margin-bottom: 12px; }
.empty-state { padding: 40px 14px !important; text-align: center !important; }
.empty-state strong { display: block; font-size: 14px; font-weight: 600; }
.empty-state p { color: #8c9782; font-size: 12px; margin-top: 7px; }
.loading-state { padding: 35px !important; color: var(--muted); text-align: center !important; }
.site-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 28px; padding-top: 15px; padding-bottom: 30px; color: #6c7b60; font-size: 10px; }
.site-footer button { color: #6c7b60; padding: 0; font-size: 10px; }
/* Profile and card overlays. */
dialog { width: calc(100% - 32px); max-width: 920px; max-height: 90vh; background: #fffefb; color: #26352c; border: 1px solid #e0e6d8; border-radius: 16px; padding: 0; box-shadow: 0 24px 80px #172e252e; }
dialog::backdrop { background: #1e302d70; }
.dialog-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 23px 26px; border-bottom: 1px solid #e9ede3; }
.dialog-header h2 { font-size: 22px; }
.section-kicker { display: block; color: #6c7b60; font-size: 10px; margin-bottom: 4px; }
.close-button { color: #8b987e; background: #f2f5ed; border-radius: 50%; width: 29px; height: 29px; font-size: 22px; line-height: 1; padding: 0; }
.dialog-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; border-top: 1px solid #e9ede3; padding: 18px 26px; }
.dialog-footer p { color: #6c7b60; font-size: 10px; }
.profile-footer-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.profile-overview { display: grid; grid-template-columns: 180px 1fr; padding: 26px; gap: 18px; }
.profile-index { background: #edf3e5; border-radius: 11px; padding: 19px; color: #5c7849; }
.profile-index>span { font-size: 9px; letter-spacing: .8px; }
.profile-index>strong { display: block; font-size: 46px; font-weight: 600; line-height: 1.4; letter-spacing: -2px; }
.profile-index p { color: #8a9c7b; font-size: 11px; margin-top: 7px; }
.profile-platforms { min-width: 0; }
.platform-detail { border: 1px solid #e5ebde; border-radius: 11px; padding: 19px; }
.platform-detail h3 { font-size: 14px; overflow-wrap: anywhere; }
.platform-detail h3 a { color: #577649; text-decoration: none; }
.detail-rating { font-size: 30px; font-weight: 600; margin: 14px 0; }
.detail-rating>span { color: #6c7b60; font-size: 9px; font-weight: 400; margin-left: 8px; }
.detail-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }
.detail-grid small { display: block; color: #6c7b60; font-size: 10px; }
.detail-grid b { color: #71865e; font-size: 15px; font-weight: 550; }
.difficulty-stats { display: flex; gap: 26px; border-top: 1px solid #e9ede3; padding-top: 13px; margin-top: 14px; color: #8c9c7c; font-size: 10px; }
.difficulty-stats b { display: block; color: #5d7e49; font-size: 14px; }
.profile-chart-section { border: 1px solid #e5ebde; border-radius: 11px; padding: 18px; margin: 0 26px 22px; }
.chart-heading p { color: #6c7b60; font-size: 10px; margin-top: 3px; }
.history-chart { width: 100%; display: block; margin-top: 18px; }
.history-chart .grid { fill: none; stroke: #edf1e7; }
.history-chart text { fill: #a1ad94; font-size: 9px; }
.history-chart .lc-line { fill: none; stroke: #87a96c; stroke-width: 2; }
.profile-note { color: #6c7b60; font-size: 10px; margin: 0 26px 18px; }
.card-dialog { max-width: 900px; }
.card-preview { background: #edf1e7; padding: 20px; }
.card-preview canvas { display: block; width: 100%; height: auto; border-radius: 9px; }
.card-options { display: flex; align-items: center; gap: 15px; padding: 19px 26px; }
.card-options>span { color: #6c7b60; font-size: 10px; }
.card-options>.button { margin-left: auto; }
.segmented-control { display: inline-flex; gap: 2px; background: #f0f3e9; border-radius: 7px; padding: 3px; }
.segmented-control button { font-size: 11px; color: #6c7b60; border-radius: 5px; padding: 6px 12px; }
.segmented-control .is-selected { color: #577847; background: #fffefb; box-shadow: 0 1px 3px #364d2510; }
.card-disclaimer { color: #6c7b60; font-size: 10px; padding: 0 26px 20px; }
.info-dialog { max-width: 620px; }
.prose { color: #849277; font-size: 13px; line-height: 1.8; padding: 24px 26px; }
.prose p+p { margin-top: 12px; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); max-width: calc(100% - 30px); color: #f3f8ed; background: #315d46; border-radius: 8px; padding: 12px 18px; font-size: 12px; text-align: center; z-index: 20; box-shadow: 0 4px 20px #28422c20; }
@media (max-width: 760px) {
  .site-header, .page, .site-footer { padding-left: 19px; padding-right: 19px; }
  .site-header { height: 76px; }
  .brand { font-size: 21px; }
  .platform-label { font-size: 10px; }
  .intro { padding: 19px 0 24px; }
  h1 { font-size: 29px; letter-spacing: -.9px; }
  .intro p { font-size: 12px; max-width: 300px; line-height: 1.75; }
  .submission-card { grid-template-columns: 1fr; padding: 22px; gap: 19px; margin-bottom: 23px; }
  .lookup-copy p br { display: none; }
  .form-fields { grid-template-columns: 1fr auto; }
  .form-fields input { font-size: 11px; }
  .field-hint { font-size: 9px; line-height: 1.7; }
  .board-panel { padding: 20px 17px 3px; }
  .board-heading { margin-bottom: 17px; gap: 10px; }
  .board-heading h2 { font-size: 19px; }
  .board-controls { flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
  .search-wrap { max-width: none; order: 2; flex-basis: 100%; }
  .sort-wrap { margin-right: auto; }
  .profile-overview { grid-template-columns: 1fr; padding: 20px; gap: 14px; }
  .profile-index>strong { display: inline-block; font-size: 34px; margin-left: 15px; }
  .profile-index p { display: inline-block; margin-left: 10px; }
  .platform-detail { padding: 16px; }
  .detail-grid { gap: 10px; }
  .detail-grid small { font-size: 9px; }
  .profile-chart-section { margin: 0 20px 20px; padding: 14px; }
  .profile-note { margin: 0 20px 16px; line-height: 1.7; }
  .dialog-header { padding: 20px; }
  .dialog-header h2 { font-size: 20px; }
  .dialog-footer { padding: 17px 20px; align-items: flex-start; flex-direction: column; }
  .card-preview { padding: 12px; }
  .card-options { flex-wrap: wrap; padding: 17px 20px; }
  .card-options>span { margin-left: auto; }
  .card-options>.button { width: 100%; margin-left: 0; }
  .card-disclaimer { padding: 0 20px 18px; line-height: 1.7; }
  .prose { padding: 20px; }
}
@media (max-width: 400px) {
  .form-fields { grid-template-columns: 1fr; }
  .form-fields .button { width: 100%; }
  .platform-label { font-size: 9px; }
  .profile-index p { display: block; margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
