html * {
    font-family: Arial !important;
}
html body {
    height: 100%;
    background: #681f92;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    overflow: hidden;
}

/* Navigation bar */
.navbar {
    width: 100%;
    height: min(8vh,100vw/4*3/100*8);
    background-color: #222;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    position: sticky;
    box-sizing: border-box;
    left: 0;
    top: 0;
    z-index: 1;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-logo {
    font-size: 1.4em;
    font-weight: bold;
    color: #f53e4d;
    text-decoration: none;
}

.nav-link {
    color: white;
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: #f53e4d;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.navbar-right input {
    padding: 6px 8px;
    border-radius: 4px;
    border: none;
    outline: none;
}

.navbar-right button {
    background-color: #f53e4d;
    border: none;
    border-radius: 4px;
    padding: 6px 12px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.navbar-right button:hover {
    background-color: #eb2132;
}

/* Mobile Navigation Menu */
.hamburger-icon {
  z-index:2;
  display: none;
  cursor: pointer;
  top: 10px;
  right: 10px;
  position:fixed;
}

.bar1, .bar2, .bar3 {
  width: 35px;
  height: 5px;
  background-color: #eee;
  margin: 6px 0;
  transition: 0.4s;
}

.change .bar1 {
  transform: translate(0, 11px) rotate(-45deg);
}

.change .bar2 {opacity: 0;}

.change .bar3 {
  transform: translate(0, -11px) rotate(45deg);
}

#login-reminder {
    display:none;
}

@media screen and (max-width: 768px) {
    #login-reminder {
        display: flex;
        font-size: x-large;
    }

    .hamburger-icon {
        display: block;
        z-index: 10;
    }

    .hamburger-icon * {
        z-index: 10;
    }

    .navbar-left {
        position: relative;
        top: 0%;
        width: 100%;
        text-align: center;
        margin-top: 30px;
    }
    .navbar-right button {
        background-color: #f53e4d;
        border: none;
        border-radius: 4px;
        padding: 6px 12px;
        font-weight: bold;
        cursor: pointer;
        transition: background-color 0.2s ease;
    }

    .navbar-right button:hover {
        background-color: #e22c3bd2;
    }

    .navbar-right {
        width: 100%;
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
        margin: 20px, 0;
    }

    .navbar-right input {
        padding: 6px 8px;
        border-radius: 4px;
        border: none;
        outline: none;
    }

    .navbar {
        flex-direction: column;
        justify-content: top;
        position: fixed;
        align-items: center;
        height: 0;
        overflow-x: hidden;
        background-color: rgba(0,0,0,0.9);
        justify-content: flex-start;
        background: none;
        box-shadow: none;
    }

    .navbar.hamburger-open {
        height: 100%;
        width: 100%;
        position: fixed; 
        z-index: 1;
        left: 0;
        top: 0;
        background-color: rgb(0,0,0);
        background-color: rgba(0,0,0, 0.9);
        overflow-x: hidden;
        transition: 0.5s;
    }

    .navbar a {
        padding: 8px;
        text-decoration: none;
        font-size: 36px;
        color: #f53e4d;
        display: block;
        transition: 0.3s;
    }

    .navbar a:hover, .navbar a:focus {
        color: #f194a4;
    }

    .navbar-left, .navbar-right {
        flex-direction: column;
        text-align: center;
        gap: 20px;
        margin: 20px 0;
    }
}

/* Overlay, prompting users to generate a bingo board */
.start-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
}

.start-overlay-content {
    color: #fff;
    text-align: center;
    padding: 2rem;
    border-radius: 1rem;
}

.start-overlay-button {
    margin-top: 1rem;
    background: #f53e4d;
    border: none;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
}

.start-overlay-button:hover {
    background: #e22c3bd2;
}

/* Actual Bingo Board */
.board-surrounding {
    margin-top: 3vh;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

table, th, td {
    border: 3px solid black;
    border-collapse: collapse;
    width: 20%;
    height: 20%;
    text-align: center;
}

.bingo-board {
    aspect-ratio: 1 / 1;
    width: min(80vw, 80vh);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 12px;
}

.bingo-board table {
    background: #FFFFFF;
    table-layout: fixed;
    width: 100%;
    height: 100%;
}

[data-clicked = "true"] {
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' version='1.1' preserveAspectRatio='none' viewBox='0 0 100 100'><path d='M100 0 L0 100 ' stroke='red' stroke-width='3'/><path d='M0 0 L100 100 ' stroke='red' stroke-width='3'/></svg>");
    background-repeat:no-repeat;
    background-position:center center;
    background-size: 100% 100%, auto;
}

td:hover{
    background-color: #6c239649;
}

td {
    padding: 0;
    height: min(16vh, 16vw);
    width: min(16vh, 16vw);
    overflow: hidden;
    vertical-align: middle;
    text-align: center;
    position: relative;
}

.cell-text {
    display: inline-block;
    font-size: 100px;
    line-height: 1;
    margin: 0;
    padding: 0;

    word-break: break-word;
    max-width: 100%;
    max-height: 100%;

    overflow-wrap: break-word;
    text-align: center;

    white-space: normal;
}

.cell-wrapper {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;

    display: flex;
    justify-content: center;
    align-items: center;

    padding: 6px;
    box-sizing: border-box;
    overflow: hidden;
    pointer-events: none;
}

/* Bingo / Winning Overlay */
.overlay {
    height: 0;
    width: 100%;
    position: fixed; 
    z-index: 1;
    left: 0;
    top: 0;
    background-color: rgb(0,0,0);
    background-color: rgba(0,0,0, 0.9);
    overflow-x: hidden;
    transition: 0.5s;
}

.overlay-content {
    position: relative;
    top: 25%;
    width: 100%;
    text-align: center;
    margin-top: 30px;
}

.overlay a {
    padding: 8px;
    text-decoration: none;
    font-size: 36px;
    color: #818181;
    display: block;
    transition: 0.3s;
}

.overlay #bingo {
    font-size: min(20vh,20vw);
    pointer-events: none;
}

.overlay a:hover, .overlay a:focus {
    color: #f1f1f1;
}

/* Reset Button at the bottom */
.reset-button {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background: #f53e4d;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 1rem;
}

.reset-button:hover {
    background: #e22c3bd2;
}

/* Confirmation popup for reset button */
.popup {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
}

.popup.hidden {
    display: none;
}

.popup-content {
    background: #fff;
    color: #333;
    padding: 2rem;
    border-radius: 1rem;
    width: 300px;
    text-align: center;
}

.popup-buttons {
    display: flex;
    justify-content: space-around;
    margin-top: 1rem;
}

.popup-confirm {
    background: #f53e4d;
    border: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
}

.popup-confirm:hover {
    background: #c52331;
}

.popup-cancel {
    background: #9e9e9e;
    border: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
}

.popup-cancel:hover {
    background: #707070;
}