* {
    margin: 0;
    padding: 0;
    color: black;
}

body {
    font-family: "Poppins", serif;
    -webkit-overflow-scrolling: touch; /* Płynne scrollowanie na iOS */
    scroll-behavior: smooth; /* Płynne przewijanie przy linkach kotwicowych */
}

a {
    text-decoration: none;
    color: royalblue;
    font-weight: bold;
}

.container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: whitesmoke;
}

.jumbotron,
.menu,
.list-heading {
    font-family: "Comic Neue", serif;
}

.fish-photo-container {
    position: relative;
    overflow: hidden;
}

.fish-list-item-title {
    font-size: 1rem;
}

.fish-list-item-content,
.fish-list-item-rating {
    font-size: 0.8rem;
}

.main-content {
    flex: 1;
}

.logo,
#toggle-icon {
    color: royalblue;
}

.menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.menu-item {
    width: 100%;
    padding: 16px;
    text-align: center;
    display: none;
}

.menu-notification {
    display: block;
    padding: 16px;
}

.expanded > .menu-item {
    display: block;
}

.expanded > .menu-notification {
    display: none;
}

.menu-logo-container,
.menu-toggle {
    display: block;
    padding: 16px 32px;
    font-size: 20px;
}


.footer {
    padding: 8px;
    text-align: center;
    color: royalblue;
    margin-top: 10px;
}

@media only screen and (min-width: 992px) {

    .menu-toggle {
        display: none;
    }

    .menu-item,
    .menu-notification {
        display: block;
        width: auto;
        border-bottom: 0;
    }

    .menu-logo-container {
        flex: 1;
    }

    .main-content,
    .menu {
        align-self: center;
        width: 960px;
    }

    .fish-list-item-title {
        font-size: 1.2rem;
    }

    .fish-list-item-content,
    .fish-list-item-rating {
        font-size: 0.9rem;
    }

    .fish-favorite {
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        padding-bottom: 10px;
    }

    .fish-list-item-poster {
        border-top-left-radius: 15px;
        border-bottom-left-radius: 15px;
    }

    .fish-detail-photo {
        border-radius: 15px;
    }

    .fish-photo-container {
        position: static;
        overflow: visible;
    }
}


.jumbotron {
    background-image: url("/img/jezioro-a93f327c107f2c6da872f467f081d6d8.jpg");
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    padding: 2rem;
    text-align: center;
}

.jumbotron-header {
    font-size: 3rem;
    margin: 1rem 0;
    color: white;
}

.jumbotron-description {
    font-size: 1.2rem;
    color: white;
}

.list-heading,
.list-description {
    text-align: center;
    margin: 16px 0;
}

.fish-list {
    list-style-type: none;
}

.fish-list-item {
    margin-bottom: 16px;
    display: flex;
    /*border: 2px royalblue solid;*/
    /*border-radius: 0 15px 15px 0;*/
    border-radius: 15px;
    /*border-style: groove;*/
    /*border-width: 2px;*/
    /*min-height: 200px;*/
    background-color: hsl(220, 70%, 95%);
    box-shadow: 8px 8px 16px #bebebe,
    -8px -8px 16px #ffffff;
}

.poster-container {
    margin: auto;
}


.fish-list-item-poster {
    display: block;
    max-width: 200px;
    max-height: 200px;
    margin: auto;

}


.fish-list-item-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 5px;
    width: 100%;
}

.fish-description {
    text-align: center;
}

.fish-list-item-content > * {
    margin: 5px 0;
}

.fish-list-item-title > a {
    color: black;
}


.fish-list-item-rating * {
    color: royalblue;
}

.fish-list-item-rating-and-like {
    display: flex;
    justify-content: space-between;
}

.fish-favorite {
    text-align: center;
    padding-top: 10px;
}

.fish-list-like-favorite {
    margin-top: 2%;
    margin-right: 2%;
    margin-bottom: 2%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;

}

.fish-list-like-favorite > button {
    border: none;
}

.like {
    color: royalblue;
    opacity: 0.7;
    font-size: medium;
}

.like:hover {
    opacity: 1;
}


.fish-details {
    display: flex;
    margin-top: 10px;
}

.fish-detail-photo {
    object-fit: contain;
    max-width: 200px;
    display: block;
    margin-top: 20px;
}


.fish-details-info {
    margin-left: 16px;
}


.fish-detail-item {
    margin: 8px 0;
}


.fish-detail-title {
    font-size: 2rem;
}


.fish-rating-container {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    min-width: 200px;
    border-radius: 15px;
    /*border-style: groove;*/
    /*border-width: 1px;*/
    /*border-color: black;*/
    background-color: hsl(220, 70%, 95%);
    box-shadow: 8px 8px 16px #bebebe,
    -8px -8px 16px #ffffff;
}


.fish-rating-form > p {
    text-align: center;
    margin-bottom: 16px;
}


.fish-rating-value {
    font-size: 1.5rem;
    text-align: center;
}


.fish-rating-button {
    background-color: royalblue;
    border: 0;
    padding: 4px;
    font-size: 1.6rem;
    border-radius: 4px;
    opacity: 0.8;
}

.fish-section-heading-rating {
    font-size: 1rem;
}


.fish-rating-button:hover {
    opacity: 1;
}


.fish-rating-container > * {
    margin: 8px 0;
}

.fish-section {
    margin-top: 16px;
    padding: 16px;
    /*border-radius: 10px;*/
    /*border-style: solid;*/
    /*border-width: 1px;*/
    /*border-color: black;*/
}

.comments-section {
    margin-top: 16px;
    padding: 16px;
}

.fish-section-heading {
    margin-bottom: 8px;
    text-align: center;
}

@media only screen and (min-width: 992px) {
    .fish {
        display: flex;
        justify-content: space-between;
    }

    .fish-rating-buttons {
        display: flex;
        flex-wrap: nowrap;
    }

    .fish-rating-button {
        font-size: 1.2rem;
        margin: 0 4px;
    }

}

.fish-gallery-container {
    display: flex;
    /*align-items: center;*/
    justify-content: center;
    flex-wrap: wrap;
}

.fish-gallery-photo {
    max-height: 200px;
    margin-left: 5px;
    margin-right: 5px;
    border-radius: 15px;
}

.error-container {
    margin: 50px auto;
    text-align: center;
}

.error-header {
    margin-bottom: 20px;
}

.error-photo {
    max-width: 500px;
    max-height: 300px;
    margin-top: 20px;
    width: 100%;
}

.types-list {
    list-style: none;
    margin: auto;
}

.types-list > li {
    font-size: 1.2rem;
    /*border: 1px royalblue solid;*/
    border-radius: 15px;
    border-style: groove;
    padding: 16px;
    text-align: center;
    box-shadow: 8px 8px 16px #bebebe,
    -8px -8px 16px #ffffff;
}

.types-list > li > a {
    color: black;
}

.types-list {
    position: relative;
}

.types-list a {
    display: block;
    width: 100%;
    height: 100%;
}

.notification-list {
    list-style: none;
    margin: auto;
}

.notification-list > li {
    padding: 5px;
    text-align: center;
}

.notification-list > li > a {
    color: blue;
}

.form {
    display: flex;
    flex-direction: column;
    margin: 0 32px;
}

.form > * {
    margin-top: 8px;
}

.form > input,
.form > textarea,
.form > select {
    font-size: 1.2rem;
    padding: 8px;
}

.form-button {
    font-size: 1.2rem;
    padding: 8px;
    margin-top: 20px;
    color: #4584c5;
    font-weight: bold;
}

.form > p {
    color: red;
}

.notification {
    text-align: center;
    color: red;
    padding: 8px 0;
    font-size: large;
    font-weight: bold;
}

#photos-add-container {
    display: flex;
    flex-direction: column;
}

#photos-add-container > label {
    margin-bottom: 5px;
}

#add-photo-button {
    max-width: 150px;
    margin-top: 5px;
}

.error-login-message {
    text-align: center;
    color: red;
}

.register-link {
    text-align: center;
    margin-top: 20px;
}

.fish-favorite {
    margin-left: 10px;
}

.favorite-icon {
    color: red;
}

.fish-comments-container {
    text-align: center;
}

.comment {
    border-radius: 10px;
    border: 1px black solid;
    border-right: none;
    border-left: none;
    border-top: none;
    list-style: none;
    margin-top: 5px;
}

.comments-list {
    margin-bottom: 10px;
}

.comment-nick {
    font-size: x-small;
    font-weight: bold;
}

.comment-content {
    padding-top: 5px;
}

.comment-date {
    font-size: x-small;
    padding-top: 5px;
}

.form-comment {
    display: flex;
    flex-direction: column;
    margin: 0 32px;
}

.form-comment > button {
    margin-top: 5px;
    color: royalblue;
    font-weight: bold;
}

.show-comments {
    font-size: x-small;
    margin-bottom: 5px;
}

/*.user-panel-categories > ul {*/
/*    list-style: none;*/
/*    !*margin: 0;*!*/
/*    !*padding: 0;*!*/
/*    margin: 5px 0;*/
/*    display: flex;*/
/*    justify-content: space-evenly;*/
/*    flex-wrap: wrap; !* dodane zawikanie *!*/
/*}*/

/*!* kafelki mają wypełniać całą przestrzeń i być lekko przezroczyste *!*/
/*.user-panel-categories > ul > li {*/
/*    flex-grow: 1;*/
/*    padding: 0.5rem;*/
/*    font-weight: 500;*/
/*    border: 1px solid;*/
/*    color: white;*/
/*    opacity: 0.8;*/
/*}*/

/*!* po najechaniu na kafelek usuwamy przezroczystość *!*/
/*.user-panel-categories > ul > li:hover {*/
/*    opacity: 1;*/
/*}*/

/*!* wyśrodkowanie tekstu na kafelkach i zmiana koloru linków *!*/
/*.user-panel-categories > ul > li > a {*/
/*    color: inherit;*/
/*    display: block;*/
/*    text-align: center;*/
/*}*/

/*.user-panel-categories > ul > li:nth-child(odd) {*/
/*    background-color: lightskyblue;*/
/*}*/

/*.user-panel-categories > ul > li:nth-child(even) {*/
/*    background-color: cornflowerblue;*/
/*}*/

.user-panel-categories {
    margin: 16px 0;
}

.user-panel-categories > ul {
    list-style: none;
    padding: 0;
    margin: 0 0 5px 0;

    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
}

/* Kategoria (pill) */
.user-panel-categories > ul > li {
    border: 1px solid #d0d8e8;
    border-radius: 999px;
    background: #f6f8fc;
    text-align: center;
    transition: all 0.2s ease;
    /*margin-bottom: 5px;*/
}

/* Link */
.user-panel-categories > ul > li > a {
    display: block;
    padding: 8px 12px;
    text-decoration: none;
    color: #2a3a5e;
    font-weight: 500;
    font-size: 14px;
}

/* Active */
.user-panel-categories > ul > li.active {
    background: #4584c5;
    border-color: #4584c5;
}

.user-panel-categories > ul > li.active > a {
    color: #fff;
}

/* Tap feedback */
.user-panel-categories > ul > li:active {
    transform: scale(0.97);
}

.user-panel-categories > ul > li:hover {
    background-color: powderblue;
}

@media (min-width: 992px) {

    .user-panel-categories > ul {
        grid-template-columns: repeat(6, auto);
        justify-content: center;
        gap: 14px;
    }

    .user-panel-categories > ul > li > a {
        padding: 10px 18px;
        font-size: 15px;
    }
}


.account-button {
    color: red;
}

.fishing-log-container {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
}

.fishing-log-container {
    margin-top: 15px;
}

.find-section {
    border-radius: 5px;
    border-style: groove;
    margin-bottom: 15px;
    background-color: hsl(220, 70%, 95%);
}

.form-user-log {
    display: flex;
    flex-direction: column;
    margin: 5px;
}

.form-user-log > * {
    margin-top: 8px;
}

.form-user-log > button {
    padding: 5px;
    font-weight: bold;
}

.fishing-log-summary {
    margin-top: 15px;
}

.fishing-log-summary > h3 {
    text-align: center;
}

.admin-delete {
    color: red;
    margin: 5px;
}

.form-users {
    display: flex;
    flex-direction: column;
    margin: 0 5px;
}

.form-users > * {
    margin-top: 5px;
    font-size: 1.2rem;
}


.admin-user-item-edit {
    display: flex;
    margin-top: 10px;
}

.form-page {
    display: flex;
    justify-content: center;
}

.form-page > * {
    margin: 5px;
    font-size: small;
}

.fish-title {
    text-align: center;
    margin-top: 16px;
}

.interactive-item {
    transition: transform 0.2s ease;
    will-change: transform, opacity;
}

.interactive-item:hover {
    transform: scale(1.08); /* Delikatne powiększenie */
}

.fish-list-item {
    overflow: hidden; /* Zapobiega wystawaniu elementów po transformacji */
    transition: transform 0.3s ease;
    will-change: transform, opacity;
}

.fish-list-item:hover {
    transform: scale(1.02);
}

.fish-detail-photo {
    transition: transform 0.2s ease;
    will-change: transform, opacity;
}

/*.fish-detail-photo:hover {*/
/*    transform: scale(1.8);*/
/*}*/
.photos-button-container {
    text-align: center;
}

.users-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.users-list > li {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 10px;
    border: 1px groove #aaa;
    border-radius: 5px;
    margin: 6px 5px;
}


.users-list > li .user-info p:nth-of-type(1) {
    font-weight: 600;
    font-size: 16px;
}


.users-list > li .user-info p:nth-of-type(2) {
    font-size: 14px;
    word-break: break-all;
    color: #444;
}


.users-list > li .user-info p:nth-of-type(3),
.users-list > li .user-info p:nth-of-type(4) {
    font-size: 14px;
    color: #555;
    margin-top: 2px;
}

.users-list > li .buttons {
    display: flex;
    gap: 4%;
    margin-top: 6px;
}

.users-list > li .buttons a {
    flex: 1;
    padding: 6px 0;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fafafa;
    text-align: center;
    text-decoration: none;
    box-sizing: border-box;
}

.users-list > li .buttons a.edit {
    color: #2a55ff;
    border-color: #2a55ff;
}

.users-list > li .buttons a.delete {
    color: #b00000;
    border-color: #b00000;
}

@media only screen and (min-width: 992px) {

    .users-list > li {
        display: grid;
        grid-template-columns: 1fr 120px 120px;
        grid-template-rows: auto;
        gap: 10px;
        align-items: center;
        padding: 10px 14px;
    }

    /* Dane użytkownika po lewej */
    .users-list > li .user-info {
        grid-column: 1 / 2;
        display: flex;
        flex-direction: column;
    }

    .users-list > li .user-info p {
        margin: 0;
    }

    .users-list > li .user-info p:nth-of-type(3),
    .users-list > li .user-info p:nth-of-type(4) {
        font-size: 0.9em;
        color: #555;
        margin-top: 2px;
    }

    /* Przyciski po prawej – ta sama linia */
    .users-list > li .buttons {
        display: contents; /* 👈 kluczowe */
    }

    .users-list > li .buttons a {
        padding: 6px 0;
        font-size: 14px;
        font-weight: 500;
        border-radius: 4px;
        background: #fafafa;
        text-align: center;
        text-decoration: none;
    }

    .users-list > li .buttons a.edit {
        color: #2a55ff;
        border: 1px solid #2a55ff;
    }

    .users-list > li .buttons a.delete {
        color: #b00000;
        border: 1px solid #b00000;
    }

    .users-list > li .buttons a:hover {
        background-color: #eef2ff;
    }
}
.gallery-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;

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

    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
}

.gallery-modal.open {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

#galleryImage {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
}

.gallery-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: #fff;
    cursor: pointer;
}

.gallery-prev,
.gallery-next {
    position: absolute;
    font-size: 36px;
    bottom: 80px;
    color: #fff;
    cursor: pointer;
    user-select: none;
    z-index: 10;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.gallery-prev {
    left: 20px;
}

.gallery-next {
    right: 20px;
}

.gallery-prev.hidden,
.gallery-next.hidden {
    opacity: 0; /* ukrywa strzałki */
    pointer-events: none; /* nieklikalne, gdy ukryte */
}

/* DESKTOP */
@media (min-width: 992px) {
    .gallery-prev,
    .gallery-next {
        top: 50%;
        bottom: auto;
        font-size: 60px;
    }

    .gallery-prev {
        left: 30px;
    }

    .gallery-next {
        right: 30px;
    }
}


.gallery-counter {
    position: fixed;
    bottom: env(safe-area-inset-bottom, 20px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    color: #fff;
    font-size: 14px;
    background: rgba(0, 0, 0, 0.6);
    padding: 6px 12px;
    border-radius: 20px;

}

.gallery-image-wrapper {
    position: relative;
    max-width: 100vw;
    max-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ===== Formularz ustawień mailingu ===== */
.form-mailing {
    max-width: 700px;
    margin: 2rem auto;
    padding: 1.5rem;
    background: #f4f8f7; /* jasna woda */
    border-radius: 12px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
    font-family: "Segoe UI", Arial, sans-serif;
}


.form-mailing table {
    width: 100%;
    border-collapse: collapse;
}

/* Nagłówki */
.form-mailing th {
    text-align: left;
    padding: 0.75rem;
    background: #4584c5;
    color: #ffffff;
    font-weight: 600;
    letter-spacing: 0.03em;
}

/* Wiersze */
.form-mailing td {
    padding: 0.75rem;
    border-bottom: 1px solid #d6e4e2;
    color: #2c3e3c;
}

/* Hover wiersza */
.form-mailing tr:hover td {
    background: #e9f3f1;
}

/* ===== Checkbox ===== */
.form-mailing input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #4584c5;
    cursor: pointer;
}

/* ===== Przycisk ===== */
.form-mailing button {
    display: block;
    margin: 1.5rem auto 0 auto;
    padding: 0.7rem 1.6rem;
    background: linear-gradient(135deg, #3aaed6, #0d5398);
    color: #ffffff;
    border: none;
    border-radius: 999px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

/* Hover / active */
.form-mailing button:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.15);
}

.form-mailing button:active {
    transform: translateY(0);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
}

.fish-owner-section {
    text-align: center;
    padding-top: 15px;
}