body {
  font-family: 'Barlow', sans-serif;
  background: linear-gradient(135deg, #1a472a, #90a955);
  background-attachment: fixed;
  margin: 0;
  padding: 20px;
  padding-top: 45px;  /* Reduced from 75px */
}

.container {
  max-width: 1000px;
  margin: 0 auto;
  background-color: #ffffff;
  padding: 20px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  border-radius: 20px;
  position: relative;
  margin-top: 10px;
  margin-bottom: 25px;
}

.coursename {
  text-align: left;
  font-weight: 600;
  font-size: 1em;
  margin: 0;
  padding: 0;
}

.courselocation {
  text-align: center;
  font-style: italic;
  font-size: 0.8em;
margin: 0;
}

.month-box:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  border-color: #1a472a;
  background: #ffffff;
}

.month-box:hover::before {
  opacity: 0.3;
  transform: scale(1.05);
  transition: all 0.3s ease;
}

.monthtitle {
  text-align: center;
  font-size: 20px;
  font-weight: 600;
  margin: 0;
  padding: 0;
}

.player {
  text-align: left;
  font-size: 1em;
  margin: 0 0 10px 0;
  padding: 0;
}

.player-container {
  display: flex;
  align-items: center;
}

.player-image {
  flex: 0 0 auto;
  margin-left: 5px;
}

th:first-child,
td:first-child {
  width: 200px;
}

.player-image img {
  width: 50px;
  height: 50px;
  object-fit: cover;
}

.player-info {
  margin-left: 10px;
}

.player-info .player-name,
.player-info .hcp-overall {
  display: block;
}

.player-name {
  cursor: pointer;
  transition: color 0.2s ease;
  text-decoration: none;
  color: inherit;
}

.player-name:hover {
  color: #1a472a;
  text-decoration: underline;
}

.player-name a {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: color 0.2s ease;
}

.player-name a:hover {
  color: #1a472a;
  text-decoration: underline;
}

.week {
  text-align: center;
  font-size: 1em;
  margin: 0 0 10px 0;
  padding: 0;
}

.weeklywinner {
  text-align: right;
z-index: 1;
}
.mainwinner {
padding: 10px 0px 0px 0px;
font-weight: 500;
z-index: 1;
margin: 10px 0px 0px 0px;
}
.mainwinner img {
margin: 0px 5px 0px 0px;
vertical-align: middle;
}
.ctpwinner {
padding: 0;
font-weight: 500;
z-index: 1;
margin: 0;
}
.ctpwinner img {
margin: 0px 5px 0px 0px;
vertical-align: middle;
}
.text-offset-winner{
position: relative;
top: 2px; /* change this value as needed */
}
.text-offset-ctp{
  position: relative;
  top: 3px; /* change this value as needed */
  }
h1, h2, h3, h4 {
  text-align: center;
  color: #333;
  margin: 0;
z-index: 1;
}

h4 {
  padding: 0 0 10px 0;
z-index: 1;
}

.cell-content {
  position: relative;
  min-height: 50px;
  width: 100%;
}

.cell-content .asterisk {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  transform: translateY(-30%);
  text-align: center;
}

.cell-content .stroke {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  text-align: center;
  font-size: 1em;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
  margin-bottom: 0px;
  position: relative;
}
.year-grid {
display: grid;
grid-template-columns: 1fr;
gap: 20px;
margin-top: 20px;
}
th, td {
  padding: 5px 0px 5px 0px;
  border: 1px solid #e0e0e0;
  text-align: center;
}

th {
  background-color: #f0f0f0;
  font-weight: 500;
}

tr:nth-child(even) {
  background-color: #fafafa;
}

.hole-row {
  background-color: #cccccc;
}

.par-row {
  background-color: #e0e0e0;
}

.par-row td {
  padding: 5px 0px 5px 0px;
}

.hcp-overall,
.hcp-stroke {
  display: block;
  font-size: 0.75em;
  color: #666;
}

.player-row td {
  padding: 5px 8px 5px 5px;
}


/* Background image for lower four rows */
tbody.player-rows-bg {
  position: relative;
}
tbody.player-rows-bg::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 100%;
  height: 100%;
  opacity: 0.06;
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%) scale(1);
}
tbody.player-rows-bg tr td {
  position: relative;
  z-index: 1;
}

/* New section for monthly boxes */
.month-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 20px;
}

/* Make the entire month box clickable */
.month-grid a {
  display: block;
  text-decoration: none;
  color: inherit;
}
.quarter-grid a {
  display: block;
  text-decoration: none;
  color: inherit;
}
.year-grid a {
  display: block;
  text-decoration: none;
  color: inherit;
}

.month-box {
  background: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 10px;
  text-align: center;
  height: 170px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}
.month-box.winter::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/winter.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.spring::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/spring.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.summer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/summer.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.autumn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/autumn.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.january::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/casadecampo.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.february::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/pebblebeachmain.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.march::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/copperhead4.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box.generic::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('/images/genericcourse.png') no-repeat center center;
  background-size: 100% auto;
  opacity: 0.2;
  z-index: 0;
}
.month-box h3 {
margin-top: 0px;
margin-right: 0;
margin-left: 0;
margin-bottom: 0px;
font-size: 18px;
}
.month-box h4 {
  font-size: 16px;
  font-weight: 500;
}
.month-box p {
margin-top: 0px;
margin-right: 0;
margin-left: 0;
margin-bottom: 0px;
font-size: 14px;
}
.quarter-grid {
display: grid;
grid-template-columns: repeat(4, 1fr);
gap: 20px;
margin-top: 20px;
}
.year-grid .month-box {
aspect-ratio: unset; /* Remove the aspect ratio constraint */
height: 150px;        /* Adjust this value as needed for a shorter box */
}
/* Also update your mobile media query so that both grids become one column on small screens */
@media screen and (max-width: 600px) {
th:not(:nth-child(1)):not(:nth-child(2)):not(:nth-child(3)):not(:nth-child(4)):not(:nth-child(5)),
td:not(:nth-child(1)):not(:nth-child(2)):not(:nth-child(3)):not(:nth-child(4)):not(:nth-child(5)) {
display: none;
}

.month-grid,
.quarter-grid {
display: grid;
grid-template-columns: 1fr;
}
}

.first {
padding-top: 20px;
}
.tab-buttons {
  display: flex;
  gap: 5px;
  margin-bottom: 20px;
  justify-content: center;
  max-width: 100%;
  padding: 0 5px;
}

.tab-button {
  padding: 8px 5px;
  border: none;
  background: rgba(144, 169, 85, 0.8);
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  border-radius: 5px;
  font-family: 'Barlow', sans-serif;
  font-size: 0.9em;
  transition: all 0.3s ease;
  min-width: 60px;
  flex: 1;
  max-width: 100px;
  border: 1px solid rgba(26, 71, 42, 0.3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tab-button:hover {
  background: rgba(26, 71, 42, 0.9);
  color: white;
}

.tab-button.active {
  background: rgba(26, 71, 42, 1);
  color: white;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.tab-content {
display: none;
}

#standings {
display: block;
}

#history {
position: relative;
height: 40vh;
min-height: 200px;
margin-bottom: 25px;
}

@media screen and (max-width: 600px) {
#history {
height: 45vh;
}
}

#handicaps {
position: relative;
height: 40vh;
min-height: 200px;
margin-bottom: 25px;
}

@media screen and (max-width: 600px) {
#handicaps {
height: 45vh;
}
}

.corbin-image {
border: 2px solid #fb58af;
border-radius: 50%;
}

.ab-image {
border: 2px solid #3897f5;
border-radius: 50%;
}

.matt-image {
border: 2px solid #8de55d;
border-radius: 50%;
}

.julian-image {
border: 2px solid #b84af8;
border-radius: 50%;
}

td img[src*="gold"],
td img[src*="silver"],
td img[src*="bronze"] {
    padding: 0;
    margin: 0;
    vertical-align: middle;
}

table th:nth-child(n+4), 
    table td:nth-child(n+4) {
      padding-left: 0;
      padding-right: 0;
    }

table th:nth-child(n+2), 
    table td:nth-child(n+2) {
      padding-left: 0;
      padding-right: 0;
    }
table th:nth-child(n+3), 
    table td:nth-child(n+3) {
      padding-left: 0;
      padding-right: 0;
    }

.header-logo {
  position: absolute;
  left: -50px;
  width: 150px;
  top: -50px;
  z-index: 1;
}

.container {
  position: relative;
}

.logo-header {
  position: relative;
  top: -65px;
  left: 50%;
  transform: translateX(-50%);
  margin-bottom: -65px;
  width: 100px;
  z-index: 2;
}

@media screen and (max-width: 600px) {
  .tab-button {
    font-size: 0.8em;
    padding: 8px 3px;
    min-width: 50px;
  }
  
  .tab-buttons {
    gap: 3px;
  }
}

#pointsChart {
    height: 400px !important;
    width: 100% !important;
}