/* GLOBAL */
body {
    margin: 0;
    font-family: "Poppins", sans-serif;
    background: #f5fff5;
    color: #1f3b1f;
}

h1 {
    text-align: center;
    margin-top: 40px;
    font-size: 3rem;
    color: #2faf6a;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* BUTTONS */
.btn {
    display: inline-block;
    padding: 12px 28px;
    background: linear-gradient(135deg, #3ccb4c, #2faf3a);
    color: white;
    border-radius: 40px;
    font-weight: 600;
    text-decoration: none;
    transition: 0.25s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.btn:hover {
    transform: scale(1.07);
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}

/* EVENTS SECTION */
#events {
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
}

#events h2 {
    color: #2faf6a;
    border-left: 6px solid #3ccb4c;
    padding-left: 12px;
    margin-bottom: 20px;
}

/* EVENT GRID */
.event-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* EVENT CARD */
.event-box {
    width: 340px;
    background: white;
    border-radius: 18px;
    overflow: visible;
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
    transition: 0.25s ease;
    margin: 20px auto;
    text-align: center;
    padding: 0;
    position: relative;
}

.event-box:hover {
    transform: translateY(-6px);
    box-shadow: 0 10px 26px rgba(0,0,0,0.25);
}

/* EVENT IMAGE */
.event-image {
    position: relative;
    width: 100%;
    height: 150px;
    overflow: hidden;
    background: #ccc;
}

.event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* DATE BADGE */
.event-date-badge {
    position: absolute;
    bottom: 5px;
    left: 12px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    width: 70px;
    text-align: center;
    overflow: hidden;
    z-index: 9999;
}

.event-date-month {
    background: #e74c3c;
    color: white;
    padding: 4px 0;
    font-size: 0.9rem;
    font-weight: 700;
}

.event-date-day {
    background: #ffffff;
    color: #2c3e50;
    padding: 6px 0;
    font-size: 1.8rem;
    font-weight: 700;
}

/* EVENT INFO */
.event-main-link {
    text-decoration: none;
    color: inherit;
    display: block;
    padding-top: 25px;
}

.event-info {
    padding: 12px;
}

.event-info h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #484b49;
}

.event-info p {
    margin: 4px 0;
    font-size: 0.95rem;
    color: #444;
}

.score-input-btn {
    display: block;
    background: #2faf6a; /* your original green */
    color: white;
    padding: 10px 14px; /* smaller padding */
    border-radius: 0px;
    text-align: center;
    margin-top: 10px;
    font-size: 14px; /* smaller text */
    font-weight: 600;
}


.leaderboard-link {
    background: #e8f9f0;
    color: #2faf6a;
    border: 1px solid #cbeedd;
}

.score-input-btn:hover {
    background: #3ccb4c;
    transform: translateY(-1px);
}

.leaderboard-link:hover {
    background: #dff5ea;
    transform: translateY(-1px);
}

/* ORDER OF MERIT TITLE */
.oom-title {
    text-align: center;
    font-size: 2.4rem;
    font-weight: 900;
    letter-spacing: 3px;
    margin: 40px 0 20px 0;
    color: #2faf6a;
    text-transform: uppercase;
    text-shadow: 0 3px 6px rgba(0,0,0,0.25);
}

/* ORDER OF MERIT TABLE */
#oom-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

#oom-table th {
    background: #3ccb4c;
    color: white;
    padding: 12px;
    text-align: left;
}

#oom-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}

#oom-table tr:hover {
    background: #f0fff0;
}

/* LEADERBOARD TABLE */
.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.leaderboard-table thead {
    background: #3ccb4c;
    color: white;
}

.leaderboard-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.leaderboard-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}

.leaderboard-table tr:hover {
    background: #f0fff0;
}

/* SCORECARD WRAPPER */
.scorecard-wrapper {
    max-width: 1400px;
    width: 95%;
    margin: 40px auto;
    background: white;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
    box-sizing: border-box;
}

/* SCORECARD TABLE */
.scorecard {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    background: white;
    table-layout: fixed;
}

.scorecard thead {
    background: #3ccb4c;
    color: white;
}

.scorecard th {
    padding: 10px;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    border-right: 1px solid rgba(255,255,255,0.2);
}

.scorecard th:last-child {
    border-right: none;
}

.scorecard td {
    padding: 10px;
    text-align: center;
    border-bottom: 1px solid #eee;
    font-size: 0.95rem;
}

.scorecard td:first-child {
    font-weight: 600;
    color: #2faf6a;
    background: #f7fff7;
}

.scorecard input[type="number"] {
    width: 55px;
    padding: 6px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1rem;
    text-align: center;
    transition: 0.2s ease;
}

.scorecard input[type="number"]:focus {
    border-color: #2faf6a;
    box-shadow: 0 0 6px rgba(47,175,106,0.4);
    outline: none;
}

.points {
    margin-top: 4px;
    font-weight: 600;
    color: #2faf6a;
}

#gross-total, #total {
    font-weight: 700;
    color: #2c3e50;
}

.scorecard tbody tr:hover {
    background: #f5fff5;
}

/* POINT COLORS */
.points.green { color: #27ae60; font-weight: 700; }
.points.orange { color: #e67e22; font-weight: 700; }
.points.red { color: #e74c3c; font-weight: 700; }
.points.black { color: #000000; font-weight: 700; }
.points.blue { color: #0c4b92; font-weight: 700; }

/* Remove arrows in Chrome, Edge, Safari */
.scorecard input[type="number"]::-webkit-inner-spin-button,
.scorecard input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Remove arrows in Firefox */
.scorecard input[type="number"] {
    -moz-appearance: textfield;
}

/* -------------------------------------------------- */
/* NEW EVENT PAGE STYLES (MERGED) */
/* -------------------------------------------------- */

/* EVENT DETAILS BOX */
.event-details-box {
    max-width: 600px;
    margin: 20px auto;
    background: white;
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    text-align: center;
}

/* SECTION TITLES */
.section-title {
    text-align: center;
    color: #2faf6a;
    font-size: 2rem;
    margin-top: 40px;
}

/* PLAYER LIST */
.players-list ul {
    list-style: none;
    padding: 0;
    max-width: 500px;
    margin: 0 auto;
}

.players-list li {
    background: white;
    padding: 10px 15px;
    margin: 6px 0;
    border-radius: 10px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* GROUP BUTTONS */
.group-container {
    max-width: 900px;
    margin: 30px auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
}

.group-btn {
    display: block;
    background: linear-gradient(135deg, #3ccb4c, #2faf6a);
    color: white;
    padding: 22px;
    text-align: center;
    border-radius: 18px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;

    /* KEYBOARD-STYLE SHADOW */
    box-shadow:
        0 6px 0 #1d7f45,          /* hard bottom edge */
        0 6px 18px rgba(0,0,0,0.25); /* soft outer shadow */

    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.group-btn:hover {
    transform: translateY(-4px);
    box-shadow:
        0 10px 0 #1d7f45,
        0 12px 26px rgba(0,0,0,0.3);
}

.group-btn:active {
    transform: translateY(2px);
    box-shadow:
        0 3px 0 #1d7f45,
        0 4px 12px rgba(0,0,0,0.2);
}


/* BACK BUTTON WRAPPER */
.back-btn-wrapper {
    text-align: center;
    margin: 40px 0;
}
.section-block {
    max-width: 1200px;
    margin: 40px auto;
    padding: 30px;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 18px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.25);
    backdrop-filter: blur(4px);
}

/* Stronger event card background */
.event-box-bg {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(3px);
}
.disabled-btn {
    color: white;
    padding: 12px 18px;
    border-radius: 0px;
    text-align: center;
    cursor: not-allowed;
}
.live-badge {
    background: #e63946;
    color: white;
    padding: 6px 12px;
    border-radius: 0px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

.countdown-badge {
    background: #1d3557a8;
    color: white;
    padding: 6px 12px;
    border-radius: 0px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

.admin-btn {
    background: #2a9d8f;
}
.active-badge {
    background: #2ecc71; /* green */
    color: white;
    padding: 6px 12px;
    border-radius: 0px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}


/* ALL RYDER CUP BELOW HERE */

/* ========================================================= */
/* RYDER CUP SCORECARD LAYOUT */
/* ========================================================= */

.rydercup-header {
    text-align: center;
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 25px;
    color: #1d3557;
}

.rydercup-teams-wrapper {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 30px;
}

.rydercup-team-box {
    flex: 1;
    background: #f8faff;
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.rydercup-team-box h3 {
    margin-top: 0;
    font-size: 1.4rem;
    font-weight: 800;
    text-align: center;
}

.rydercup-team-a h3 {
    color: #1d4ed8; /* Blue */
}

.rydercup-team-b h3 {
    color: #b91c1c; /* Red */
}

.rydercup-team-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.rydercup-team-box li {
    background: white;
    padding: 10px 14px;
    margin: 6px 0;
    border-radius: 10px;
    text-align: center;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

/* Highlight hole winners later */
.hole-win-a {
    background: #dbeafe !important; /* Light blue */
}

.hole-win-b {
    background: #fee2e2 !important; /* Light red */
}

.hole-halved {
    background: #f3f4f6 !important; /* Neutral grey */
}
