body {
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background-color: #1a1a1a;
    /* Dark background */
    background-image: radial-gradient(#2c2c2c 1px, transparent 1px);
    background-size: 20px 20px;
    font-family: 'Georgia', 'Courier New', serif;
    /* Vintage font */
    color: #d4af37;
    /* Gold text */
}

#game-container {
    position: relative;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

#board {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
}

.hex {
    position: absolute;
    width: 100px;
    height: 115.47px;
    /* width * 2 / sqrt(3) */
    background-color: #c19a6b;
    /* Tan/Wood default */
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 12px;
    color: #3e2723;
    transition: transform 0.2s;
    filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.5));
    /* Shadow for depth */
}

.hex:hover {
    background-color: #d7ccc8;
    cursor: pointer;
    transform: scale(1.05);
    z-index: 2;
    /* Bring to front */
}

.hex::before {
    content: '';
    position: absolute;
    width: 90%;
    /* Smaller to create a "border" effect with background */
    height: 90%;
    background-color: #c19a6b;
    /* Inner color */
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    z-index: -1;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.2);
    /* Inner shadow */
}

.hex.honeycomb {
    background-color: #5d4037;
    /* Dark Wood */
    color: #fff;
}

.hex.honeycomb::before {
    background-color: #5d4037;
    background-image: repeating-linear-gradient(45deg,
            transparent,
            transparent 5px,
            rgba(0, 0, 0, 0.1) 5px,
            rgba(0, 0, 0, 0.1) 10px);
}

/* Field Types */
.hex.field-pink {
    background-color: #8d6e63;
    /* Muted Rose/Brown */
    color: #fff;
}

.hex.field-pink::before {
    background-color: #a1887f;
}

.hex.field-black {
    background-color: #212121;
    /* Charcoal */
    color: #fff;
}

.hex.field-black::before {
    background-color: #424242;
}

.hex.field-gold {
    background-color: #ffb300;
    /* Antique Gold */
    color: #fff;
}

.hex.field-gold::before {
    background-color: #ffca28;
}

/* Black-Gold Mixed Field (Multiplayer) */
.hex.field-blackgold {
    background: linear-gradient(135deg, #212121 0%, #212121 50%, #ffb300 50%, #ffb300 100%);
    color: #fff;
}

.hex.field-blackgold::before {
    background: linear-gradient(135deg, #424242 0%, #424242 50%, #ffca28 50%, #ffca28 100%);
}


/* Bee Styles */
.bee {
    position: absolute;
    width: 28px;
    height: 38px;
    border-radius: 14px;
    z-index: 20;
    /* Higher than tokens */
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    color: transparent;
    font-size: 0;

    /* Stripes */
    background-image: linear-gradient(to bottom,
            transparent 25%,
            rgba(0, 0, 0, 0.7) 25%,
            rgba(0, 0, 0, 0.7) 40%,
            transparent 40%,
            transparent 60%,
            rgba(0, 0, 0, 0.7) 60%,
            rgba(0, 0, 0, 0.7) 75%,
            transparent 75%);
    background-size: 100% 100%;

    /* Elevation and shadow */
    transform: translateY(-15px);
    box-shadow: 0 15px 8px rgba(0, 0, 0, 0.4);
}

/* Wings */
.bee::before,
.bee::after {
    content: '';
    position: absolute;
    width: 22px;
    height: 14px;
    background-color: rgba(255, 255, 255, 0.8);
    top: 12px;
    z-index: -1;
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: transform 0.2s;
}

.bee::before {
    left: -16px;
    border-radius: 50% 50% 0 50%;
    transform: rotate(25deg);
    transform-origin: right center;
}

.bee::after {
    right: -16px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-25deg);
    transform-origin: left center;
}

/* Hover effect for wings */
.bee:hover::before {
    transform: rotate(35deg);
}

.bee:hover::after {
    transform: rotate(-35deg);
}

.bee.moved {
    opacity: 0.5;
    filter: grayscale(0.5);
    cursor: not-allowed;
}

.bee.player-0 {
    background-color: #bf360c;
    /* Burnt Orange */
    border: 2px solid #d4af37;
    /* Gold border */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

/* Red */
.bee.player-1 {
    background-color: #455a64;
    /* Blue Grey */
    border: 2px solid #d4af37;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

/* Blue */
/* Green */
.bee.player-2 {
    background-color: #33691e;
    /* Olive Green */
    border: 2px solid #d4af37;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

/* Yellow */
.bee.player-3 {
    background-color: #fbc02d;
    /* Darker Yellow for contrast */
    border: 2px solid #3e2723;
    /* Dark Brown border for contrast */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
    color: #3e2723;
    /* Dark text if we ever show it */
}

/* Purple */
.bee.player-4 {
    background-color: #7b1fa2;
    /* Purple */
    border: 2px solid #d4af37;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

/* Orange */
.bee.player-5 {
    background-color: #e65100;
    /* Dark Orange */
    border: 2px solid #d4af37;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

/* UI Panel */
#bee-panel {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    padding: 15px;
    border-radius: 10px;
    color: white;
    display: none;
    /* Hidden by default */
    z-index: 100;
    text-align: center;
}

.token-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 10px;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
}

.action-buttons {
    display: flex;
    gap: 10px;
    margin-top: 8px;
    width: 100%;
    justify-content: center;
}

.boost-btn,
.chain-btn {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
    background: linear-gradient(135deg, #d4af37 0%, #b8860b 100%);
    border: none;
    border-radius: 4px;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    gap: 5px;
}

.boost-btn:hover,
.chain-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    filter: brightness(1.1);
}

.boost-btn:active,
.chain-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Nectar Token Styles */
.nectar-token {
    position: absolute;
    width: 30px;
    /* Slightly smaller */
    height: 30px;
    border-radius: 50%;
    z-index: 5;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    color: #fff;
    font-size: 14px;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.5), 0 2px 3px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.3);
    pointer-events: none;
    /* Allow clicks to pass through to bee/hex */
}

.nectar-1 {
    background-color: #212121;
    /* Charcoal */
    color: #d4af37;
}

/* Status Bar Container */
#status-bar-container {
    position: absolute;
    bottom: 20px;
    left: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 300px;
    z-index: 50;
}

.player-status-bar {
    background: rgba(20, 20, 20, 0.9);
    border: 1px solid #d4af37;
    border-radius: 3px;
    padding: 8px 12px;
    font-family: 'Georgia', serif;
    position: relative;
    overflow: hidden;
}

.player-status-bar .status-label {
    position: relative;
    z-index: 2;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.player-status-bar .status-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    transition: width 0.5s ease;
    opacity: 0.3;
    z-index: 1;
}

/* Bee Hover Tooltip */
.bee-tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    color: #d4af37;
    padding: 4px 8px;
    border-radius: 3px;
    font-family: 'Georgia', serif;
    font-size: 14px;
    font-weight: bold;
    pointer-events: none;
    z-index: 1000;
    white-space: nowrap;
    border: 1px solid #d4af37;
    transform: translate(-50%, -100%);
    margin-top: -5px;
}

/* Black token for 1 */
.nectar-2 {
    background-color: #ffb300;
    /* Gold */
    color: #3e2723;
}

/* Gold token for 2 */
.nectar-4 {
    background-color: #8d6e63;
    /* Rose Brown */
}

/* Pink token for 4 */

/* Score Progress Bars */
.score-bar-container {
    position: absolute;
    width: 15px;
    height: 150px;
    background-color: rgba(62, 39, 35, 0.8);
    /* Dark Brown transparent */
    border: 2px solid #d4af37;
    border-radius: 5px;
    overflow: hidden;
    display: flex;
    flex-direction: column-reverse;
    /* Fill from bottom */
    z-index: 5;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

.score-bar-fill {
    width: 100%;
    height: 0%;
    transition: height 0.5s ease-in-out;
}

/* Score Bar Tooltip */
.score-bar-container::after {
    content: attr(data-score);
    position: absolute;
    top: 50%;
    left: 25px;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.9);
    color: #d4af37;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 14px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    border: 1px solid #d4af37;
}

.score-bar-container:hover::after {
    opacity: 1;
}

/* Menu Screens */
.menu-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background-color: #111;

    /* Static Art Deco Hexagon Pattern SVG */
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='104' viewBox='0 0 60 104' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 0l30 17.32v34.64L30 69.28 0 51.96V17.32L30 0zM30 104l30-17.32V51.96L30 34.64 0 51.96v34.64L30 104z' fill='none' stroke='%23d4af37' stroke-width='1' stroke-opacity='0.15'/%3E%3C/svg%3E");

    background-size: 60px 104px;
    /* Animation removed for static look */
    z-index: 1000;
}

.game-title {
    font-family: 'Georgia', serif;
    font-size: 72px;
    color: #d4af37;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.7);
    margin-bottom: 50px;
    letter-spacing: 8px;
}

.menu-buttons {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.menu-btn {
    font-family: 'Georgia', serif;
    font-size: 24px;
    padding: 15px 50px;
    background-color: #3e2723;
    color: #d4af37;
    border: 2px solid #d4af37;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    letter-spacing: 2px;
}

.menu-btn:hover {
    background-color: #d4af37;
    color: #3e2723;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(212, 175, 55, 0.4);
}

.menu-btn:active {
    transform: translateY(0);
}

/* Player Selection */
.player-buttons {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
}

.player-btn {
    font-family: 'Georgia', serif;
    font-size: 36px;
    width: 80px;
    height: 80px;
    background-color: #3e2723;
    color: #d4af37;
    border: 3px solid #d4af37;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

.player-btn:hover {
    background-color: #d4af37;
    color: #3e2723;
    transform: scale(1.1);
    box-shadow: 0 6px 12px rgba(212, 175, 55, 0.4);
}

/* Player Name Inputs */
.player-name-input {
    width: 100%;
    max-width: 400px;
    margin: 10px auto;
    display: flex;
    align-items: center;
    gap: 15px;
}

.player-name-input label {
    font-family: 'Georgia', serif;
    font-size: 16px;
    min-width: 80px;
    text-align: right;
}

.player-name-input input {
    flex: 1;
    padding: 10px 15px;
    font-family: 'Georgia', serif;
    font-size: 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid #d4af37;
    border-radius: 3px;
    color: white;
}

.player-name-input input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.player-name-input input:focus {
    outline: none;
    border-color: #fff;
    background: rgba(255, 255, 255, 0.15);
}

.back-btn {
    margin-top: 20px;
}

/* Rules Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-content {
    background-color: #1a1a1a;
    border: 3px solid #d4af37;
    border-radius: 10px;
    padding: 40px;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.8);
}

.modal-content h2 {
    font-family: 'Georgia', serif;
    color: #d4af37;
    text-align: center;
    margin-top: 0;
    font-size: 36px;
    letter-spacing: 4px;
}

.modal-content h3 {
    font-family: 'Georgia', serif;
    color: #d4af37;
    margin-top: 20px;
    font-size: 20px;
}

.rules-text {
    font-family: 'Georgia', serif;
    color: #c19a6b;
    line-height: 1.6;
    font-size: 16px;
}

.rules-text p {
    margin: 10px 0;
}

.close-btn {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 36px;
    color: #d4af37;
    cursor: pointer;
    transition: color 0.3s;
}

.close-btn:hover {
    color: #fff;
}

/* Copyright */
.copyright {
    font-family: 'Georgia', serif;
    color: #808080;
    font-size: 14px;
    margin-top: auto;
    margin-bottom: 20px;
    letter-spacing: 1px;
    position: absolute;
    bottom: 10px;
}

/* Sleek Vintage Game Buttons */
.game-btn {
    font-family: 'Georgia', serif;
    font-size: 14px;
    padding: 10px 25px;
    background: rgba(20, 20, 20, 0.8);
    color: #d4af37;
    border: 1px solid #d4af37;
    border-radius: 2px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 2px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.game-btn:hover {
    background: rgba(212, 175, 55, 0.1);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
    transform: translateY(-1px);
}

.game-btn:active {
    transform: translateY(0);
}

.game-btn.disabled {
    opacity: 0.3;
    cursor: not-allowed;
    border-color: #555;
    color: #888;
    box-shadow: none;
}

.game-btn.disabled:hover {
    background: rgba(20, 20, 20, 0.8);
    transform: none;
    box-shadow: none;
}

/* Options Button - Bee Themed */
#options-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 50px;
    /* Hexagon proportions */
    background-color: rgba(20, 20, 20, 0.9);
    border: none;
    color: #d4af37;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    z-index: 1000;
    /* Hexagon Shape */
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    /* Gold Border effect via inset shadow or pseudo element? 
       Clip-path cuts off borders. Let's use a drop-shadow filter for "border" glow */
    filter: drop-shadow(0 0 2px #d4af37);
}

#options-btn::before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    right: 2px;
    bottom: 2px;
    background: transparent;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    z-index: -1;
}

#options-btn:hover {
    background-color: #d4af37;
    color: #1a1a1a;
    transform: rotate(60deg);
    filter: drop-shadow(0 0 5px #d4af37);
}

/* Options Modal Content */
.options-content {
    text-align: center;
    min-width: 300px;
}

.options-content h2 {
    font-size: 48px;
    margin-bottom: 30px;
    text-transform: uppercase;
}

#player-scores-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: 10px;
}

.score-item {
    display: flex;
    justify-content: space-between;
    font-family: 'Georgia', serif;
    font-size: 20px;
    font-weight: bold;
    padding: 5px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.score-item:last-child {
    border-bottom: none;
}

.tip-box {
    margin-bottom: 30px;
    color: #aaa;
    font-size: 14px;
    font-style: italic;
}

.tip-box span {
    color: #fff;
    font-weight: bold;
    border: 1px solid #666;
    padding: 2px 6px;
    border-radius: 4px;
    background: #333;
    font-style: normal;
}

.end-game-btn {
    margin-top: 15px;
    background-color: transparent;
    border: 2px solid #ff4444;
    color: #ff4444;
}

.end-game-btn:hover {
    background-color: #ff4444;
    color: white;
    box-shadow: 0 0 15px rgba(255, 68, 68, 0.4);
}