/* GLOBAL */

html {
    overflow-y: scroll;
}

body {
    margin: 0;
    background-color: #000000;
    color: #ffffff;
    font-family: Arial, sans-serif;
}

a {
    color: #ffffff;
    text-decoration: none;
}

a:hover {
    color: #ff8c00;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: #ff8c00;
}


/* HEADER */

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px;
}


/* LOGO */

.logo {
    flex-shrink: 0;
}

.logo img {
    display: block;
    width: 300px;
    max-width: 100%;
    height: auto;
}


/* HEADER RIGHT */

.header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 20px;
}


/* SOCIAL ICONS */

.header-icons {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 18px;
}

.header-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    color: #ffffff;
    font-size: 20px;
}

.header-icons a:hover {
    color: #ff8c00;
}


/* NAVIGATION */

nav {
    display: flex;
    align-items: center;
}

nav a {
    margin-left: 30px;
    padding-bottom: 5px;
    color: #ffffff;
    border-bottom: 5px solid transparent;
}

nav a:hover {
    color: #ff8c00;
    border-bottom-color: #ff8c00;
}


/* MOBILE MENU */

.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 9px 14px;
    background: transparent;
    color: #ffffff;
    border: 0;
    font-family: Arial, sans-serif;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
}

.menu-toggle i {
    color: #ff8c00;
    font-size: 20px;
}

.menu-toggle:hover {
    background: transparent;
    color: #ff8c00;
    filter: none;
}


/* ADMIN INFO */

.header-admin {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 15px;
    min-height: 20px;
    font-size: 14px;
}

.header-admin span {
    color: #ffffff;
}

.header-admin a {
    color: #ff8c00;
    font-weight: bold;
}

.header-admin a:hover {
    filter: brightness(1.12);
}


/* MAIN */

main {
    max-width: 1200px;
    margin: 60px auto 120px auto;
    padding: 0 30px;
}


/* FOOTER */

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    box-sizing: border-box;
    padding: 20px;
    background-color: #000000;
    color: #ffffff;
    text-align: center;
}

footer a {
    color: #ffffff;
}

footer a:hover {
    color: #ff8c00;
}


/* HOME INTRO */

.home-intro {
    max-width: 800px;
    margin: 0 auto 50px auto;
    text-align: center;
}

.home-intro h1 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 42px;
}

.home-intro-lead {
    margin-bottom: 15px;
    font-size: 22px;
    font-weight: bold;
    line-height: 1.5;
}

.home-intro p {
    font-size: 18px;
    line-height: 1.7;
}


/* HOME PHOTOS */

.home-showcase {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
    margin: 50px 0 80px 0;
}

.home-showcase-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    border-radius: 12px;
}

.home-showcase-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.25s ease;
}

.home-showcase-image img:hover {
    transform: scale(1.04);
}


/* HOME SERVICES */

.home-services {
    margin-top: 40px;
}

.home-services > h2 {
    margin-bottom: 30px;
    text-align: center;
    font-size: 32px;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 25px;
}

.service-card {
    padding: 25px;
    box-sizing: border-box;
    background-color: #080808;
    border-radius: 12px;
}

.service-card h3 {
    margin-top: 0;
    margin-bottom: 12px;
    font-size: 22px;
}

.service-card p {
    margin-bottom: 0;
    line-height: 1.6;
}

.home-services-link {
    margin-top: 30px;
    text-align: center;
}

.home-services-link a {
    color: #ff8c00;
    font-weight: bold;
    text-transform: uppercase;
}

.home-services-link a:hover {
    filter: brightness(1.12);
}


/* OM OSS */

.about-intro {
    max-width: 750px;
    margin-bottom: 50px;
    line-height: 1.6;
}

.team-list {
    display: flex;
    flex-direction: column;
    gap: 35px;
}

.team-member {
    display: flex;
    align-items: flex-start;
    gap: 35px;
    width: 100%;
    padding: 25px;
    box-sizing: border-box;
    background-color: #080808;
}

.team-photo {
    width: 230px;
    height: 280px;
    flex: 0 0 230px;
    overflow: hidden;
    background-color: #000000;
    border-radius: 10px;
}

.team-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.team-info {
    flex: 1;
    min-width: 0;
}

.team-info h2 {
    margin-top: 0;
    margin-bottom: 6px;
    color: #ff8c00;
}

.team-info p {
    max-width: 800px;
    margin-top: 0;
    margin-bottom: 15px;
    line-height: 1.6;
}

.team-email {
    display: inline-block;
    margin-bottom: 18px;
    color: #ff8c00;
    font-weight: bold;
}

.team-email:hover {
    color: #ff8c00;
    text-decoration: underline;
}


/* ARRANGEMENT */

.event-filters {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 20px;
    margin: 25px 0 10px 0;
    padding: 20px;
    background-color: #080808;
    border-radius: 10px;
}

.event-filters label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-weight: bold;
}

.event-filters select {
    min-width: 180px;
}

.event-card {
    display: flex;
    align-items: flex-start;
    gap: 40px;
    margin: 50px 0;
}

.event-image {
    width: 220px;
    flex-shrink: 0;
}

.event-image img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 210 / 297;
    object-fit: contain;
    background-color: #000000;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.event-image img:hover {
    transform: scale(1.03);
}

.event-info {
    flex: 1;
    min-width: 0;
}

.event-info h2 {
    margin-top: 0;
    margin-bottom: 8px;
}

.event-organisers {
    margin-top: 0;
    margin-bottom: 20px;
    color: #cccccc;
    line-height: 1.7;
}

.event-organisers strong {
    color: #ff8c00;
}

.organiser-divider {
    margin: 0 8px;
    color: #666666;
}

.event-description {
    width: 100%;
    margin: 25px 0 20px 0;
    padding: 0;
    box-sizing: border-box;
    white-space: pre-line;
    overflow-wrap: anywhere;
    text-align: left;
    line-height: 1.7;
}


/* EVENT REGISTRATION */

.event-registration {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 25px;
}

.registration-button {
    display: inline-block;
    padding: 10px 18px;
    border-radius: 7px;
    font-family: Arial, sans-serif;
    font-size: 15px;
    font-weight: bold;
    line-height: 1.2;
}

.registration-open {
    background-color: #ff8c00;
    color: #000000;
    border: 2px solid #ff8c00;
    cursor: pointer;
    transition:
        filter 0.2s ease,
        transform 0.1s ease;
}

.registration-open:hover {
    color: #000000;
    filter: brightness(1.12);
}

.registration-open:active {
    transform: translateY(1px);
}

.registration-closed {
    background-color: #cc0000;
    color: #ffffff;
    border: 2px solid #ff0000;
    cursor: default;
}

.registration-dropin {
    background-color: #05d825;
    color: #000000;
    border: 2px solid #05d825;
    cursor: default;
}


/* POSTER OVERLAY */

.poster-overlay {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.92);
    z-index: 9999;
}

.poster-overlay.open {
    display: flex;
}

.poster-overlay img {
    width: auto;
    height: auto;
    max-width: 90vw;
    max-height: 92vh;
    object-fit: contain;
}

.poster-close {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    padding: 0;
    border-radius: 50%;
    font-size: 28px;
    z-index: 10000;
}


/* TJENESTER */

.services-intro {
    max-width: 700px;
    margin-bottom: 50px;
    font-size: 18px;
    line-height: 1.6;
}

.services-page-grid {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.service-section {
    width: 100%;
    padding: 30px 35px;
    box-sizing: border-box;
    background-color: #ff8c00;
    color: #000000;
    border-radius: 12px;
    transition:
        transform 0.2s ease,
        filter 0.2s ease;
}

.service-section:hover {
    transform: translateY(-3px);
    filter: brightness(1.08);
}

.service-section h2 {
    margin-top: 0;
    margin-bottom: 12px;
    color: #000000;
    font-size: 28px;
}

.service-section p {
    max-width: 100%;
    margin: 0;
    color: #000000;
    font-size: 18px;
    line-height: 1.6;
}

.services-contact-button {
    display: block;
    width: fit-content;
    margin: 35px auto 0;
    padding: 15px 24px;
    background-color: #ff8c00;
    color: #000000;
    font-size: 18px;
    font-weight: bold;
    text-decoration: none;
    border-radius: 8px;
    transition:
        transform 0.2s ease,
        filter 0.2s ease;
}

.services-contact-button:hover {
    transform: translateY(-2px);
    filter: brightness(1.08);
    color:#000000;
}

/* KONTAKT */

.contact-info {
    max-width: 600px;
}

.contact-email {
    color: #ff8c00;
    font-weight: bold;
}

.contact-email:hover {
    color: #ff8c00;
    text-decoration: underline;
}


/* FORMS */

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="time"],
input[type="tel"],
input[type="number"],
input[type="url"],
select,
textarea {
    min-height: 40px;
    padding: 8px 10px;
    box-sizing: border-box;
    background-color: #ffffff;
    color: #000000;
    border: 2px solid #cccccc;
    border-radius: 7px;
    font-family: Arial, sans-serif;
    font-size: 16px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="date"]:focus,
input[type="time"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus,
input[type="url"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #ff8c00;
    box-shadow: 0 0 0 1px #ff8c00;
}

textarea[name="description"] {
    width: 600px;
    max-width: 100%;
    min-height: 140px;
    resize: vertical;
}

input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #ff8c00;
    cursor: pointer;
}


/* BUTTONS */

button,
input[type="submit"],
input[type="button"] {
    padding: 9px 16px;
    background-color: #ff8c00;
    color: #000000;
    border: 2px solid #ff8c00;
    border-radius: 7px;
    font-family: Arial, sans-serif;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    transition:
        filter 0.2s ease,
        transform 0.1s ease;
}

button:hover,
input[type="submit"]:hover,
input[type="button"]:hover {
    color: #000000;
    filter: brightness(1.12);
}

button:active,
input[type="submit"]:active,
input[type="button"]:active {
    transform: translateY(1px);
}

a:has(button),
a:has(button):hover {
    color: inherit;
}


/* FILE BUTTON */

input[type="file"]::file-selector-button {
    padding: 9px 16px;
    margin-right: 10px;
    background-color: #ff8c00;
    color: #000000;
    border: 2px solid #ff8c00;
    border-radius: 7px;
    font-family: Arial, sans-serif;
    font-size: 15px;
    font-weight: bold;
    cursor: pointer;
    transition: filter 0.2s ease;
}

input[type="file"]::file-selector-button:hover {
    filter: brightness(1.12);
}


/* SIGNUP */

.signup-page {
    display: flex;
    justify-content: space-between;
    gap: 100px;
    margin-top: 40px;
}

.signup-description {
    white-space: pre-line;
    overflow-wrap: anywhere;
    line-height: 1.7;
}

.competition-info {
    width: 400px;
}

.signup-container {
    width: 400px;
    padding: 30px;
    border-radius: 10px;
}

.signup-message {
    margin-bottom: 20px;
    padding: 12px 15px;
    border-radius: 7px;
    font-weight: bold;
}

.signup-message.success {
    background-color: #05d825;
    color: #000000;
}

.signup-message.error {
    background-color: #cc0000;
    color: #ffffff;
    border: 1px solid #ff0000;
}


/* ADMIN EVENT CREATION */

.event-inline {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 20px;
}

.event-inline label {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.event-inline input[name="name"] {
    width: 220px;
}

.event-inline input[name="start_date"],
.event-inline input[name="end_date"] {
    width: 180px;
}

.event-inline input[name="start_time"],
.event-inline input[name="end_time"] {
    width: 140px;
}

.event-inline input[name="location"] {
    width: 220px;
}

.event-inline input[name="city"] {
    width: 180px;
}

.event-inline select[name="category"] {
    width: 180px;
}

.event-inline input[name="age_range"] {
    width: 180px;
}

.event-inline input[name="price"] {
    width: 140px;
}

.event-inline input[name^="organiser_"] {
    width: 200px;
}


/* ADMIN */

.login-error {
    margin-bottom: 20px;
    color: #ff8c00;
    font-weight: bold;
}

.admin-event {
    width: 100%;
    box-sizing: border-box;
    padding: 20px 25px;
    margin-bottom: 20px;
    border: 1px solid #ff8c00;
    border-radius: 10px;
}

.admin-event > strong {
    font-size: 18px;
}

.admin-event > button,
.admin-event > a {
    margin-right: 8px;
}

.admin-poster-preview {
    width: 150px;
    height: auto;
}

.external-registration-fields,
#external-registration-create {
    margin-top: 5px;
}

.external-registration-fields input,
#external-registration-create input {
    width: 500px;
    max-width: 100%;
}

.admin-action-link {
    display: inline-block;
    padding: 9px 16px;
    background-color: #ff8c00;
    color: #000000;
    border: 2px solid #ff8c00;
    border-radius: 7px;
    font-size: 15px;
    font-weight: bold;
    line-height: normal;
    vertical-align: middle;
    transition:
        filter 0.2s ease,
        transform 0.1s ease;
}

.admin-action-link:hover {
    color: #000000;
    filter: brightness(1.12);
}

.admin-action-link:active {
    transform: translateY(1px);
}


/* NORSE COMPETITION SETTINGS */

.norse-competition-settings {
    margin-top: 10px;
    padding: 15px;
    background-color: #080808;
    border-radius: 8px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    max-width: 100%;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    flex-shrink: 0;
    margin: 0;
}

.norse-competition-options {
    margin-top: 5px;
}


/* DELETE CONFIRMATION */

.delete-confirmation {
    margin-top: 15px;
    padding: 15px;
    color: #ff0000;
    border: 1px solid #ff0000;
    border-radius: 8px;
}

.delete-confirmation p,
.delete-confirmation strong {
    color: #ff0000;
}

.delete-confirmation button {
    margin-right: 8px;
    background-color: #ff0000;
    color: #ffffff;
    border: 2px solid #ff0000;
}

.delete-confirmation button:hover {
    background-color: #cc0000;
    border-color: #cc0000;
    filter: none;
}


/* REGISTRATIONS */

.registrations-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 30px;
    margin-bottom: 30px;
}

.registration-header-buttons {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 10px;
}

.registrations-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.registrations-table {
    width: 100%;
    border-collapse: collapse;
    background-color: #000000;
}

.registrations-table th {
    padding: 12px 15px;
    background-color: #ff8c00;
    color: #000000;
    text-align: left;
}

.registrations-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #444444;
}

.registrations-table tbody tr:hover {
    background-color: #151515;
}


/* EDIT MODALS */

.edit-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 30px;
    box-sizing: border-box;
    background-color: rgba(0, 0, 0, 0.88);
    z-index: 9000;
}

.edit-modal-content {
    position: relative;
    width: 900px;
    max-width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 30px;
    box-sizing: border-box;
    background-color: #000000;
    border: 1px solid #ff8c00;
    border-radius: 12px;
}

.edit-modal-content h2 {
    margin-top: 0;
    padding-right: 50px;
}

.edit-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    font-size: 24px;
}

.edit-modal-fields {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.edit-modal-fields label {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.edit-modal-fields input,
.edit-modal-fields select {
    width: 100%;
}

.edit-modal-content textarea[name="description"] {
    width: 100%;
}


/* PERSONVERN */

.personvern-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
    text-align: left;
}

.personvern-content h1 {
    margin-bottom: 30px;
    text-align: left;
}

.personvern-content h2 {
    margin-top: 30px;
    margin-bottom: 12px;
    text-align: left;
}

.personvern-content p {
    margin-bottom: 20px;
    text-align: left;
    line-height: 1.7;
}

.personvern-content ul {
    margin: 0 0 25px 25px;
    padding: 0;
    text-align: left;
}

.personvern-content li {
    margin-bottom: 8px;
}


/* COMPETITION MANAGEMENT */

.competition-game-card {
    width: 100%;
    margin: 25px 0;
    padding: 22px;
    box-sizing: border-box;
    background-color: #080808;
    border: 1px solid #333333;
    border-radius: 10px;
}

.competition-game-card > h3 {
    margin-top: 0;
}

.competition-game-card > form {
    display: inline-block;
    margin: 0;
}

.competition-game-card > .admin-action-link {
    margin-right: 8px;
}

.placement-point-row {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 15px;
}

.placement-point-row label {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.placement-point-row input[name="placement"],
.placement-point-row input[name="points"] {
    width: 130px;
}

.score-entry-status {
    display: inline-block;
    margin-left: 6px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: bold;
}

.score-entry-status-open {
    background-color: #05d825;
    color: #000000;
}

.score-entry-status-closed {
    background-color: #cc0000;
    color: #ffffff;
    border: 1px solid #ff0000;
}

.score-entry-control-button {
    margin-top: 2px;
}

.score-entry-close-button {
    margin-bottom: 12px;
    background-color: #cc0000;
    color: #ffffff;
    border-color: #ff0000;
}

.score-entry-close-button:hover {
    background-color: #a80000;
    color: #ffffff;
    border-color: #ff0000;
    filter: none;
}

.score-entry-open-button {
    margin-bottom: 12px;
    background-color: #05d825;
    color: #000000;
    border-color: #05d825;
}

.score-entry-open-button:hover {
    background-color: #11ec32;
    color: #000000;
    border-color: #11ec32;
    filter: none;
}


/* GAME EDIT MODAL */

.game-edit-modal {
    width: 900px;
    max-width: calc(100% - 60px);
    max-height: 90vh;
    padding: 0;
    box-sizing: border-box;
    overflow: hidden;
    background-color: #000000;
    color: #ffffff;
    border: 1px solid #ff8c00;
    border-radius: 12px;
}

.game-edit-modal::backdrop {
    background-color: rgba(0, 0, 0, 0.88);
}

.game-edit-modal-content {
    width: 100%;
    max-height: 90vh;
    padding: 30px;
    box-sizing: border-box;
    overflow-y: auto;
}

.game-edit-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 25px;
}

.game-edit-modal-header h2 {
    margin: 0;
}

.game-edit-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    font-size: 24px;
}

.game-edit-modal form input[type="text"],
.game-edit-modal form input[type="number"],
.game-edit-modal form select,
.game-edit-modal form textarea {
    width: 100%;
}

.game-edit-modal form textarea {
    min-height: 140px;
    resize: vertical;
}

.game-edit-modal form button {
    margin-right: 8px;
}


/* COMPETITION SCORE ENTRY */

.competition-score-page {
    width: 100%;
}

.competition-score-page > h1 {
    margin-bottom: 8px;
}

.competition-score-page > h2 {
    margin-top: 0;
    margin-bottom: 5px;
}

.competition-score-page > h3 {
    margin-top: 0;
    color: #ffffff;
}

.score-entry-page-state {
    max-width: 900px;
    margin: 16px 0;
    padding: 12px 15px;
    border-radius: 8px;
    font-weight: bold;
    line-height: 1.5;
}

.score-entry-page-state[data-state="open"] {
    background-color: #08230d;
    color: #d8ffe0;
    border: 1px solid #157a22;
}

.score-entry-page-state[data-state="closed"] {
    background-color: #2a0505;
    color: #ffffff;
    border: 1px solid #cc0000;
}

.competition-score-rules {
    max-width: 900px;
    margin: 16px 0;
    padding: 14px 16px;
    background-color: #080808;
    border: 1px solid #333333;
    border-radius: 9px;
    white-space: pre-line;
    overflow-wrap: anywhere;
    line-height: 1.55;
}

.competition-score-navigation {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 20px 0;
}

.competition-score-page input[type="search"] {
    width: 500px;
    max-width: 100%;
    min-height: 42px;
    padding: 8px 10px;
    box-sizing: border-box;
    background-color: #ffffff;
    color: #000000;
    border: 2px solid #cccccc;
    border-radius: 7px;
    font-family: Arial, sans-serif;
    font-size: 16px;
}

.competition-score-page input[type="search"]:focus {
    outline: none;
    border-color: #ff8c00;
    box-shadow: 0 0 0 1px #ff8c00;
}

.score-participants {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 18px;
}

.score-participant-card {
    width: 100%;
    padding: 0;
    box-sizing: border-box;
    overflow: hidden;
    background-color: #080808;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    transition:
        border-color 0.2s ease,
        background-color 0.2s ease;
}

.score-participant-card:hover {
    border-color: #555555;
}

.score-participant-card.active {
    border-color: #ff8c00;
}

.score-participant-card.disqualified {
    background-color: #240606;
    border-color: #8b0000;
}

.score-participant-summary {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto 22px;
    align-items: center;
    gap: 12px;
    width: 100%;
    min-height: 48px;
    padding: 8px 12px;
    box-sizing: border-box;
    background: transparent;
    color: #ffffff;
    border: 0;
    border-radius: 0;
    text-align: left;
}

.score-participant-summary:hover {
    background-color: #151515;
    color: #ffffff;
    filter: none;
}

.score-participant-summary:disabled {
    background-color: #0a0a0a;
    color: #888888;
    cursor: not-allowed;
    opacity: 0.78;
}

.score-participant-summary:disabled:hover {
    background-color: #0a0a0a;
    color: #888888;
}

.score-participant-card.disqualified
.score-participant-summary:hover {
    background-color: #300909;
}

.score-participant-summary:active {
    transform: none;
}

.score-participant-summary-identity {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.score-participant-name {
    min-width: 180px;
    color: #ff8c00;
    font-size: 16px;
    line-height: 1.2;
}

.score-participant-summary-details {
    min-width: 0;
    color: #cfcfcf;
    font-size: 13px;
    font-weight: normal;
    overflow-wrap: anywhere;
}

.score-participant-summary-status {
    display: inline-block;
    min-width: 88px;
    padding: 5px 9px;
    box-sizing: border-box;
    border-radius: 999px;
    font-size: 12px;
    font-weight: bold;
    text-align: center;
    white-space: nowrap;
}

.score-participant-summary-status.status-finished {
    background-color: #05d825;
    color: #000000;
}

.score-participant-summary-status.status-in-progress {
    background-color: #ff8c00;
    color: #000000;
}

.score-participant-summary-status.status-not-started {
    background-color: #444444;
    color: #dddddd;
}

.score-participant-summary-status.status-disqualified {
    background-color: #cc0000;
    color: #ffffff;
    border: 1px solid #ff0000;
}

.score-participant-arrow {
    color: #ff8c00;
    font-size: 11px;
    text-align: center;
}

.participant-lock-message {
    margin: 0;
    padding: 7px 12px;
    background-color: #5f4200;
    color: #ffffff;
    border-top: 1px solid #ff8c00;
    font-size: 13px;
    font-weight: bold;
}

.score-participant-editor {
    padding: 12px;
    background-color: #050505;
    border-top: 1px solid #252525;
}

.score-attempts {
    display: grid;
    grid-template-columns: repeat(
        auto-fit,
        minmax(120px, 1fr)
    );
    gap: 10px;
    margin-bottom: 10px;
}

.score-attempt-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.score-attempt-field label {
    color: #ffffff;
    font-size: 13px;
    font-weight: bold;
}

.score-input {
    width: 100%;
    min-height: 40px !important;
    padding: 6px 8px !important;
    font-size: 16px !important;
    font-weight: bold;
}

.score-save-status {
    min-height: 15px;
    color: #aaaaaa;
    font-size: 11px;
    font-weight: bold;
    line-height: 1.2;
}

.score-save-status.saved {
    color: #05d825;
}

.score-save-status.error {
    color: #ff4444;
}

.score-tiebreak-section {
    margin-top: 8px;
    padding-top: 10px;
    border-top: 1px solid #2a2a2a;
}

.score-tiebreak-section > strong {
    display: block;
    margin-bottom: 8px;
    color: #ff8c00;
    font-size: 13px;
}

.score-participant-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: 4px;
}

.participant-status-button {
    background-color: transparent;
    color: #ff6666;
    border-color: #7f1d1d;
}

.participant-status-button:hover {
    background-color: #2b0808;
    color: #ff7777;
    border-color: #ff4444;
    filter: none;
}

.participant-status-button-small {
    padding: 5px 9px;
    border-width: 1px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: bold;
}

.restore-participant-button {
    color: #05d825;
    border-color: #157a22;
}

.restore-participant-button:hover {
    background-color: #071d0a;
    color: #05d825;
    border-color: #05d825;
    filter: none;
}

/* COMPETITION RESULTS */

.competition-results-page {
    width: 100%;
}

.competition-results-page > h1 {
    margin-bottom: 8px;
}

.competition-results-page > h2 {
    margin-top: 0;
    margin-bottom: 5px;
}

.competition-results-page > h3 {
    margin-top: 0;
    color: #ffffff;
}

.competition-results-navigation {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 25px 0;
}

.competition-result-settings {
    max-width: 900px;
    margin: 20px 0;
    padding: 18px;
    background-color: #080808;
    border: 1px solid #333333;
    border-radius: 10px;
    line-height: 1.7;
}

.competition-results-filter {
    margin: 25px 0;
}

.competition-results-filter label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.competition-results-filter input[type="search"] {
    width: 500px;
    max-width: 100%;
    min-height: 46px;
    padding: 10px 12px;
    box-sizing: border-box;
    background-color: #ffffff;
    color: #000000;
    border: 2px solid #cccccc;
    border-radius: 7px;
    font-family: Arial, sans-serif;
    font-size: 17px;
}

.competition-results-filter input[type="search"]:focus {
    outline: none;
    border-color: #ff8c00;
    box-shadow: 0 0 0 1px #ff8c00;
}

.results-update-message {
    margin: 15px 0;
    padding: 12px 15px;
    background-color: #05d825;
    color: #000000;
    border-radius: 7px;
    font-weight: bold;
}

.competition-results-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 25px;
}

.competition-result-card {
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr);
    width: 100%;
    padding: 20px 22px;
    box-sizing: border-box;
    background-color: #080808;
    border: 1px solid #333333;
    border-radius: 12px;
}

.competition-result-card.tied-result {
    border: 2px solid #ff8c00;
}

.competition-result-card.disqualified {
    background-color: #2a0505;
    border: 2px solid #ff0000;
}

.competition-result-placement {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-right: 20px;
}

.result-placement-number,
.result-placement-dsq,
.result-placement-none {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 54px;
    min-height: 54px;
    padding: 7px;
    box-sizing: border-box;
    border-radius: 50%;
    font-size: 21px;
    font-weight: bold;
}

.result-placement-number {
    background-color: #ff8c00;
    color: #000000;
}

.result-placement-dsq {
    background-color: #cc0000;
    color: #ffffff;
    border: 1px solid #ff0000;
    font-size: 15px;
}

.result-placement-none {
    background-color: #222222;
    color: #aaaaaa;
}

.competition-result-content {
    min-width: 0;
}

.competition-result-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 15px;
}

.competition-result-header h3 {
    margin: 0 0 6px 0;
    color: #ff8c00;
    font-size: 22px;
}

.competition-result-id {
    color: #cccccc;
    font-weight: bold;
    overflow-wrap: anywhere;
}

.competition-result-badges {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
}

.result-badge {
    display: inline-block;
    padding: 7px 10px;
    border-radius: 7px;
    font-size: 13px;
    font-weight: bold;
}

.result-badge-dsq {
    background-color: #cc0000;
    color: #ffffff;
    border: 1px solid #ff0000;
}

.result-badge-tie {
    background-color: #ff8c00;
    color: #000000;
    border: 1px solid #ff8c00;
}

.result-badge-warning {
    background-color: #5f4200;
    color: #ffffff;
    border: 1px solid #ff8c00;
}

.competition-result-best,
.competition-result-attempts,
.competition-result-tiebreaks {
    margin-top: 12px;
    line-height: 1.6;
}

.competition-result-best strong,
.competition-result-attempts strong,
.competition-result-tiebreaks strong {
    color: #ff8c00;
}

.result-attempt-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.result-attempt {
    display: inline-block;
    padding: 8px 10px;
    background-color: #151515;
    border: 1px solid #333333;
    border-radius: 7px;
    font-weight: bold;
}

.result-tiebreak-attempt {
    border-color: #ff8c00;
}

.result-no-attempts {
    display: inline-block;
    margin-top: 8px;
    color: #aaaaaa;
}


/* COMPACT COMPETITION RESULTS */

.competition-results-compact .competition-results-navigation {
    margin: 16px 0;
}

.competition-result-settings-compact {
    max-width: 900px;
    margin: 14px 0;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.45;
}

.competition-result-settings-divider {
    margin: 0 8px;
    color: #666666;
}

.competition-results-filter-compact {
    margin: 16px 0;
}

.competition-results-filter-compact label {
    margin-bottom: 6px;
    font-size: 14px;
}

.competition-results-filter-compact input[type="search"] {
    min-height: 42px;
    padding: 8px 10px;
    font-size: 16px;
}

.competition-results-filter-compact #result-count {
    margin: 7px 0 0 0;
    color: #aaaaaa;
    font-size: 13px;
}

.competition-results-list-compact {
    gap: 6px;
    margin-top: 16px;
}

.competition-result-card-compact {
    grid-template-columns: 48px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    min-height: 58px;
    padding: 8px 12px;
    border-radius: 8px;
}

.competition-result-card-compact.tied-result {
    border-width: 1px;
    border-color: #ff8c00;
}

.competition-result-card-compact.disqualified {
    border-width: 1px;
}

.competition-result-placement-compact {
    align-items: center;
    justify-content: center;
    padding-right: 0;
}

.result-placement-compact {
    min-width: 34px;
    min-height: 34px;
    padding: 4px;
    font-size: 14px;
}

.result-placement-dsq.result-placement-compact {
    font-size: 10px;
}

.competition-result-main {
    display: grid;
    grid-template-columns: minmax(150px, 220px) minmax(120px, 170px) minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.competition-result-identity {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.competition-result-name {
    color: #ff8c00;
    font-size: 16px;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.competition-result-id {
    color: #cfcfcf;
    font-size: 12px;
    font-weight: normal;
}

.competition-result-summary {
    min-width: 0;
    font-size: 13px;
    white-space: nowrap;
}

.competition-result-best-inline strong {
    color: #ff8c00;
}

.competition-result-attempts-compact {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    min-width: 0;
    margin-top: 0;
    line-height: 1.2;
}

.result-attempt-compact {
    padding: 5px 7px;
    border-radius: 6px;
    font-size: 12px;
}

.competition-result-badges-compact {
    justify-content: flex-end;
    gap: 5px;
}

.competition-result-badges-compact .result-badge {
    padding: 5px 7px;
    border-radius: 6px;
    font-size: 11px;
}

.competition-result-card-compact .result-no-attempts {
    margin-top: 0;
    font-size: 12px;
}


/* RESPONSIVE 1100 */

@media (max-width: 1100px) {

    .service-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}


/* RESPONSIVE 1000 */

@media (max-width: 1000px) {

    .home-showcase {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-showcase-image {
        height: 280px;
    }
}


/* RESPONSIVE 900 */

@media (max-width: 900px) {

    header {
        flex-direction: column;
        align-items: center;
        padding: 20px;
    }

    .logo img {
        width: 220px;
    }

    .header-right {
        width: 100%;
        align-items: center;
        gap: 20px;
    }

    .header-icons {
        justify-content: center;
        margin-top: 30px;
    }

    .menu-toggle {
        display: flex;
        margin-top: 5px;
    }

    nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: center;
        gap: 0;
    }

    nav.open {
        display: flex;
    }

    nav a {
        width: 100%;
        box-sizing: border-box;
        margin: 0;
        padding: 13px 0;
        color: #ffffff;
        border-bottom: 1px solid #222222;
        text-align: center;
        font-size: 15px;
    }

    nav a:hover {
        color: #ff8c00;
        border-bottom-color: #ff8c00;
    }

    .header-admin {
        justify-content: center;
    }

    main {
        margin-top: 30px;
        padding: 0 20px;
    }

    .home-intro h1 {
        font-size: 34px;
    }

    .signup-page {
        flex-direction: column;
        gap: 40px;
    }

    .competition-info,
    .signup-container {
        width: 100%;
        box-sizing: border-box;
    }

    .event-card {
        flex-direction: column;
    }

    .event-image {
        width: 220px;
        max-width: 100%;
    }

    .event-image img {
        width: 100%;
        height: auto;
    }
}


/* RESPONSIVE 800 */

@media (max-width: 800px) {

    .team-member {
        gap: 25px;
    }

    .team-photo {
        width: 190px;
        height: 240px;
        flex-basis: 190px;
    }

    .edit-modal-fields {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .score-attempts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .placement-point-row {
        align-items: stretch;
    }

    .competition-result-card {
        grid-template-columns: 75px minmax(0, 1fr);
        padding: 18px;
    }

    .competition-result-placement {
        padding-right: 15px;
    }
}


/* RESPONSIVE 700 */

@media (max-width: 700px) {

    .event-inline {
        flex-direction: column;
        align-items: stretch;
    }

    .event-inline label {
        width: 100%;
    }

    .event-inline input,
    .event-inline select,
    .event-inline input[name="name"],
    .event-inline input[name="start_date"],
    .event-inline input[name="end_date"],
    .event-inline input[name="start_time"],
    .event-inline input[name="end_time"],
    .event-inline input[name="location"],
    .event-inline input[name="city"],
    .event-inline input[name="age_range"],
    .event-inline input[name="price"],
    .event-inline input[name^="organiser_"],
    .event-inline select[name="category"] {
        width: 100%;
    }

    .event-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .event-filters label,
    .event-filters select {
        width: 100%;
    }

    .event-organisers {
        line-height: 2;
    }

    .registrations-header {
        flex-direction: column;
    }

    .registration-header-buttons {
        justify-content: flex-start;
    }

    .registrations-table {
        min-width: 600px;
    }
}


/* SCORE ENTRY RESPONSIVE 700 */

@media (max-width: 700px) {

    .score-participant-summary-identity {
        gap: 8px;
    }

    .score-participant-name {
        min-width: 140px;
    }

    .score-participant-summary-status {
        min-width: 80px;
    }
}


/* COMPACT RESULTS RESPONSIVE 800 */

@media (max-width: 800px) {

    .competition-result-card-compact {
        grid-template-columns: 44px minmax(0, 1fr);
    }

    .competition-result-main {
        grid-template-columns: minmax(140px, 200px) minmax(110px, 150px) minmax(0, 1fr);
    }

    .competition-result-badges-compact {
        grid-column: 2;
        justify-content: flex-start;
        margin-top: 4px;
    }
}


/* RESPONSIVE 600 */

@media (max-width: 600px) {

    .home-showcase {
        grid-template-columns: 1fr;
    }

    .home-showcase-image {
        height: 240px;
    }

    .service-grid {
        grid-template-columns: 1fr;
    }

    .team-member {
        flex-direction: column;
        gap: 20px;
        padding: 20px;
    }

    .team-photo {
        width: 100%;
        max-width: 280px;
        height: 340px;
        flex-basis: auto;
    }

    .team-info {
        width: 100%;
    }

    .services-intro {
        font-size: 16px;
    }

    .service-section {
        padding: 22px;
    }

    .service-section h2 {
        font-size: 24px;
    }

    .service-section p {
        font-size: 16px;
    }

    .score-participant-summary {
        grid-template-columns: minmax(0, 1fr) auto 22px;
    }

    .score-participant-summary-identity {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }

    .score-participant-name {
        min-width: 0;
    }

    .score-attempts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .placement-point-row {
        flex-direction: column;
    }

    .placement-point-row label,
    .placement-point-row input[name="placement"],
    .placement-point-row input[name="points"],
    .placement-point-row button {
        width: 100%;
        box-sizing: border-box;
    }

    .competition-result-card {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .competition-result-placement {
        justify-content: flex-start;
        padding-right: 0;
    }

    .competition-result-header {
        flex-direction: column;
        gap: 12px;
    }

    .competition-result-badges {
        justify-content: flex-start;
    }

    .competition-results-navigation {
        flex-direction: column;
    }

    .competition-results-navigation .admin-action-link {
        width: 100%;
        box-sizing: border-box;
        text-align: center;
    }
}


/* RESPONSIVE 550 */

@media (max-width: 550px) {

    .edit-modal {
        padding: 15px;
    }

    .edit-modal-content {
        max-height: 94vh;
        padding: 20px;
    }

    .edit-modal-fields {
        grid-template-columns: 1fr;
    }

    .game-edit-modal {
        max-width: calc(100% - 30px);
        max-height: 94vh;
    }

    .game-edit-modal-content {
        max-height: 94vh;
        padding: 20px;
    }
}


/* COMPACT RESULTS RESPONSIVE 600 */

@media (max-width: 600px) {

    .competition-result-card-compact {
        grid-template-columns: 40px minmax(0, 1fr);
        gap: 8px;
        padding: 8px 10px;
    }

    .competition-result-main {
        grid-template-columns: 1fr;
        gap: 5px;
    }

    .competition-result-summary {
        white-space: normal;
    }

    .competition-result-attempts-compact {
        gap: 4px;
    }

    .competition-result-badges-compact {
        grid-column: 2;
        justify-content: flex-start;
    }

    .result-placement-compact {
        min-width: 30px;
        min-height: 30px;
        font-size: 12px;
    }
}


/* RESPONSIVE 500 */

@media (max-width: 500px) {

    header {
        padding: 15px;
    }

    .logo img {
        width: 180px;
    }

    .header-icons {
        margin-top: 25px;
    }

    .header-icons a {
        font-size: 18px;
    }

    main {
        padding: 0 15px;
    }

    .home-intro {
        text-align: left;
    }

    .home-intro h1 {
        font-size: 30px;
    }

    .home-intro-lead {
        font-size: 19px;
    }

    .home-intro p {
        font-size: 16px;
    }

    .home-showcase-image {
        height: 230px;
    }

    .signup-container {
        padding: 20px;
    }

    textarea[name="description"] {
        width: 100%;
    }

    .poster-overlay img {
        max-width: 94vw;
        max-height: 88vh;
    }

    .poster-close {
        top: 12px;
        right: 12px;
        width: 42px;
        height: 42px;
        font-size: 26px;
    }

    .event-filters {
        padding: 15px;
    }

    .organiser-divider {
        margin: 0 4px;
    }

    .event-registration {
        align-items: flex-start;
        flex-direction: column;
    }

    .registration-button {
        box-sizing: border-box;
        width: 100%;
        text-align: center;
    }

    .admin-action-link {
        margin-bottom: 8px;
    }

    .game-edit-modal form button {
        width: 100%;
        margin-right: 0;
        margin-bottom: 8px;
    }

    .score-participant-summary {
        min-height: 46px;
        padding: 8px 10px;
    }

    .score-participant-editor {
        padding: 10px;
    }

    .score-participant-summary-status {
        min-width: 72px;
        padding: 4px 7px;
        font-size: 10px;
    }

    .score-attempts {
        grid-template-columns: 1fr;
    }

    .competition-score-page input[type="search"],
    .competition-results-filter input[type="search"] {
        width: 100%;
    }

    .competition-result-card {
        padding: 15px;
    }

    .competition-result-header h3 {
        font-size: 20px;
    }

    .result-attempt-list {
        flex-direction: column;
    }

    .result-attempt {
        width: 100%;
        box-sizing: border-box;
    }
}
