/* Naprawa widoku zdjęcia - ukrycie przycisków i naprawa wyświetlania */

/* Ukryj przyciski Pomniejsz i Przesuń w dół - nadpisz wszystkie style z main.css */
#zoom,
#zoom img,
#zoom a,
#opis,
#opis img,
#opis a,
#show_next-box {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    width: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    position: absolute !important;
    left: -9999px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    background: none !important;
}

/* Upewnij się, że zdjęcie jest widoczne */
#mpic.user_photo,
.image_list #mpic.user_photo,
.image_list a img.user_photo,
#max_ver img.user_photo,
#max_ver a img.user_photo,
#max_ver a {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    max-width: 100% !important;
    height: auto !important;
    position: relative !important;
}

/* Upewnij się, że link z tłem też jest widoczny */
#max_ver a[style*="background"],
#max_ver #photo-link {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-height: 200px !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
}

/* Jeśli zdjęcie jest ustawione jako blank.gif, pokaż tło */
#max_ver a[style*="background"] img[src*="blank.gif"] {
    opacity: 0 !important;
    position: absolute !important;
    width: 100% !important;
    height: 100% !important;
}

/* Naprawa footera - upewnij się, że jest widoczny i poprawnie wyświetlany */
#ft,
#ft footer,
.modern-footer {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    width: 100% !important;
    clear: both !important;
}

/* Naprawa kontenera zdjęcia */
#max_ver,
#max_ver td {
    display: table !important;
    visibility: visible !important;
    width: 100% !important;
}

#max_ver img,
#max_ver a {
    display: block !important;
    visibility: visible !important;
}

/* Upewnij się, że .image_list jest widoczny */
.image_list {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Upewnij się, że link z tłem ma odpowiednie style */
#max_ver a[style*="background"],
#max_ver #photo-link {
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center center !important;
}

/* Ukryj blank.gif, ale pokaż tło */
#max_ver #photo-link img[src*="blank.gif"],
#max_ver a[style*="background"] img[src*="blank.gif"] {
    opacity: 0 !important;
    position: absolute !important;
    width: 100% !important;
    height: 100% !important;
    top: 0 !important;
    left: 0 !important;
}

/* --- Blok meta zdjęcia --- */
.ff-photo-meta {
    padding: 32px 0 24px;
    border-top: 1px solid #333;
    border-bottom: 1px solid #333;
    max-width: 1100px;
    margin: 0 auto;
    color: #f5f5f5;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Tytuł zdjęcia */
.ff-photo-title {
    margin: 0 0 8px;
    font-size: clamp(24px, 2.4vw, 32px);
    font-weight: 600;
    letter-spacing: 0.03em;
    color: #f5f5f5;
}

/* Linia pod tytułem: autor / data / kategoria */
.ff-photo-meta__line {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 16px;
    font-size: 13px;
    color: #bbbbbb;
}

.ff-photo-meta__pill {
    padding: 2px 10px;
    border-radius: 999px;
    border: 1px solid #444;
    background: rgba(255, 255, 255, 0.03);
}

/* Grid z kartami statystyk */
.ff-photo-meta__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-top: 24px;
}

@media (min-width: 768px) {
    .ff-photo-meta__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

/* Pojedyncza karta */
.ff-photo-card {
    padding: 16px 18px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.6);
}

.ff-photo-card--technical {
    background: radial-gradient(circle at top, rgba(247, 210, 80, 0.12), rgba(0, 0, 0, 0.7));
}

.ff-photo-card__title {
    margin: 0 0 10px;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #f7d250; /* złoty akcent Fotoferii */
}

/* Listy statystyk */
.ff-photo-stats {
    margin: 0;
    padding: 0;
}

.ff-photo-stats > div {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    padding: 4px 0;
    font-size: 13px;
}

.ff-photo-stats > div:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.ff-photo-stats dt {
    margin: 0;
    opacity: 0.7;
    font-weight: 400;
    color: #bbbbbb;
}

.ff-photo-stats dd {
    margin: 0;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: #f5f5f5;
}

/* Wersja bardziej zbita (np. techniczne) */
.ff-photo-stats--compact > div {
    font-size: 12px;
}

/* --- Belka z opcjami zdjęcia --- */
.ff-photo-toolbar {
    padding: 24px 0;
    border-top: 1px solid #333;
    border-bottom: 1px solid #333;
    max-width: 1100px;
    margin: 0 auto;
}

.ff-photo-toolbar__grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.ff-toolbar-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    color: #f5f5f5;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.6);
}

.ff-toolbar-btn:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(247, 210, 80, 0.3);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.ff-toolbar-btn img {
    width: 18px;
    height: 18px;
    vertical-align: middle;
    filter: brightness(1.1);
}

.ff-toolbar-btn--icon {
    padding: 10px 14px;
    min-width: 44px;
    justify-content: center;
}

.ff-toolbar-btn--highlight {
    background: radial-gradient(circle at top, rgba(247, 210, 80, 0.15), rgba(0, 0, 0, 0.7));
    border-color: rgba(247, 210, 80, 0.3);
    color: #f7d250;
}

.ff-toolbar-btn--highlight:hover {
    background: radial-gradient(circle at top, rgba(247, 210, 80, 0.25), rgba(0, 0, 0, 0.7));
    border-color: rgba(247, 210, 80, 0.5);
}

.ff-toolbar-btn--rating {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
    cursor: default;
}

.ff-toolbar-btn--rating:hover {
    transform: none;
    background: rgba(255, 255, 255, 0.03);
}

@media (max-width: 768px) {
    .ff-photo-toolbar__grid {
        gap: 8px;
    }
    
    .ff-toolbar-btn {
        padding: 8px 14px;
        font-size: 13px;
    }
    
    .ff-toolbar-btn img {
        width: 16px;
        height: 16px;
    }
}

/* Upewnij się, że tytuł, opis i inne dane zdjęcia są widoczne */
.desc,
.f18,
.f18 *,
.image_list .desc,
.image_list .f18,
.image_list .desc *,
.image_list .f18 * {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    color: #e0e0e0 !important;
}

.f18 {
    font-size: 18px !important;
    font-weight: bold !important;
    margin: 10px 0 !important;
    padding: 0 !important;
}

.desc {
    display: inline-block !important;
    vertical-align: top !important;
    padding-top: 50px !important;
}

/* Upewnij się, że statystyki są widoczne */
.stats,
.stats *,
.tb_gold,
.tb_gold *,
.image_list .stats,
.image_list .stats * {
    display: table !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.stats {
    width: 220px !important;
    padding-right: 50px !important;
}

/* Upewnij się, że toolbar z komentarzami i analizą jest widoczny */
#image-toolbar,
.gradient_box,
#image-toolbar *,
.gradient_box * {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

#image-toolbar {
    margin: 20px 0 !important;
    padding: 10px !important;
}

/* ============================================
   DIALOG TAGOWANIA - NAPRAWA MODALA
   ============================================ */

/* Overlay - ciemne tło modalne */
.ui-widget-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: rgba(0, 0, 0, 0.75) !important;
    z-index: 99998 !important;
    cursor: pointer !important;
}

/* Dialog tagowania - centrowany, na najwyższej warstwie */
/* WAŻNE: jQuery UI dialog tworzy wrapper .ui-dialog, który jest parentem #frame-dialog */
/* Dialog powinien być ukryty domyślnie i pokazywany tylko gdy jest otwarty */
.ui-dialog:has(#frame-dialog),
.ui-dialog:has(#confirmation-dialog),
#frame-dialog.ui-dialog,
#confirmation-dialog.ui-dialog {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    margin: 0 !important;
    z-index: 99999 !important;
    max-width: 95vw !important;
    max-height: 95vh !important;
    overflow: auto !important;
    pointer-events: auto !important;
}

/* Upewnij się, że obraz w dialogu jest interaktywny */
#frame-dialog #frame-image,
#frame-dialog img#frame-image {
    pointer-events: auto !important;
    cursor: crosshair !important;
    position: relative !important;
    z-index: 1 !important;
}

/* Upewnij się, że imgAreaSelect elementy są interaktywne */
.imgareaselect-outer,
.imgareaselect-selection,
.imgareaselect-border1,
.imgareaselect-border2,
.imgareaselect-border3,
.imgareaselect-border4,
.imgareaselect-handle {
    pointer-events: auto !important;
    z-index: 100000 !important;
}

/* Dialogi domyślnie ukryte */
#dialog-wrapper {
    display: none;
}

#frame-dialog,
#confirmation-dialog {
    display: none;
}

/* Gdy dialog jest otwarty, upewnij się że obraz i imgAreaSelect są interaktywne */
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) #frame-image,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-outer,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-selection,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-border1,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-border2,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-border3,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-border4,
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden) .imgareaselect-handle {
    pointer-events: auto !important;
}

/* Dialog ukryty gdy jest zamknięty */
.ui-dialog:has(#frame-dialog).ui-dialog-hidden,
.ui-dialog:has(#confirmation-dialog).ui-dialog-hidden,
#frame-dialog.ui-dialog.ui-dialog-hidden,
#confirmation-dialog.ui-dialog.ui-dialog-hidden,
.ui-dialog:has(#frame-dialog)[style*="display: none"],
.ui-dialog:has(#confirmation-dialog)[style*="display: none"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

/* Alternatywny selektor dla przeglądarek bez wsparcia :has() */
.ui-dialog[aria-describedby="frame-dialog"],
.ui-dialog[aria-describedby="confirmation-dialog"] {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    margin: 0 !important;
    z-index: 99999 !important;
    max-width: 95vw !important;
    max-height: 95vh !important;
    overflow: auto !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Upewnij się, że dialog jest widoczny gdy jest otwarty */
#frame-dialog.ui-dialog:not(.ui-dialog-hidden),
#confirmation-dialog.ui-dialog:not(.ui-dialog-hidden),
.ui-dialog:has(#frame-dialog):not(.ui-dialog-hidden),
.ui-dialog:has(#confirmation-dialog):not(.ui-dialog-hidden) {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Wrapper dialogu - upewnij się, że jest widoczny */
#frame-dialog.ui-dialog-wrapper,
#confirmation-dialog.ui-dialog-wrapper {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 99999 !important;
    pointer-events: none !important;
}

#frame-dialog.ui-dialog-wrapper > .ui-dialog,
#confirmation-dialog.ui-dialog-wrapper > .ui-dialog {
    pointer-events: auto !important;
}

/* Tytuł dialogu */
#frame-dialog.ui-dialog .ui-dialog-titlebar,
#confirmation-dialog.ui-dialog .ui-dialog-titlebar {
    background: #2a2a2a !important;
    border: 1px solid #444 !important;
    color: #fff !important;
    padding: 10px 15px !important;
    cursor: move !important;
}

/* Zawartość dialogu */
#frame-dialog.ui-dialog .ui-dialog-content,
#confirmation-dialog.ui-dialog .ui-dialog-content {
    background: #1a1a1a !important;
    color: #fff !important;
    padding: 20px !important;
    overflow: auto !important;
    max-height: calc(95vh - 120px) !important;
}

/* Przyciski dialogu */
#frame-dialog.ui-dialog .ui-dialog-buttonpane,
#confirmation-dialog.ui-dialog .ui-dialog-buttonpane {
    background: #1a1a1a !important;
    border-top: 1px solid #333 !important;
    padding: 10px 15px !important;
    text-align: right !important;
}

#frame-dialog.ui-dialog .ui-dialog-buttonpane .ui-button,
#confirmation-dialog.ui-dialog .ui-dialog-buttonpane .ui-button {
    background: #c00 !important;
    color: #fff !important;
    border: 1px solid #a00 !important;
    padding: 8px 16px !important;
    margin-left: 8px !important;
    cursor: pointer !important;
    border-radius: 4px !important;
}

#frame-dialog.ui-dialog .ui-dialog-buttonpane .ui-button:hover,
#confirmation-dialog.ui-dialog .ui-dialog-buttonpane .ui-button:hover {
    background: #e00 !important;
}

/* Przycisk zamknięcia (X) */
#frame-dialog.ui-dialog .ui-dialog-titlebar-close,
#confirmation-dialog.ui-dialog .ui-dialog-titlebar-close {
    background: transparent !important;
    border: none !important;
    color: #fff !important;
    cursor: pointer !important;
    font-size: 18px !important;
    width: 30px !important;
    height: 30px !important;
    line-height: 30px !important;
    text-align: center !important;
}

#frame-dialog.ui-dialog .ui-dialog-titlebar-close:hover,
#confirmation-dialog.ui-dialog .ui-dialog-titlebar-close:hover {
    background: #444 !important;
    border-radius: 3px !important;
}

/* Obraz w dialogu */
#frame-dialog #frame-image {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
}

/* Blokada przewijania strony gdy modal jest otwarty */
body.ui-dialog-open {
    overflow: hidden !important;
    position: fixed !important;
    width: 100% !important;
}

/* Upewnij się, że komentarze są widoczne */
#comments,
#comments *,
.comments,
.comments * {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Upewnij się, że footer jest widoczny i na dole strony */
/* Footer musi być poza wszystkimi kontenerami z float */
#ft {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative !important;
    clear: both !important;
    width: 100% !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
}

footer,
.modern-footer {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    clear: both !important;
    width: 100% !important;
    float: none !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

/* Upewnij się, że #bd nie ma float, który mógłby wpływać na footer */
#bd {
    float: none !important;
    display: block !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Upewnij się, że #page nie ma float, który mógłby wpływać na footer */
#page {
    float: none !important;
    display: block !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Upewnij się, że #bodyWrapper nie ma flex, który mógłby wpływać na footer */
#bodyWrapper {
    display: block !important;
    flex-direction: column !important;
}

/* Stopka - jak na stronie głównej */
/* Upewnij się, że stopka nie jest wewnątrz kontenerów komentarzy */
.ff-photo-comments ~ #ft,
.image_list ~ #ft {
    margin-top: 60px !important;
}

/* Upewnij się, że modern-footer działa poprawnie na stronie zdjęcia */
#ft .modern-footer {
    margin-top: 0 !important;
    position: -webkit-sticky !important;
    position: sticky !important;
    bottom: 0 !important;
    z-index: 100 !important;
    width: 100% !important;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.5) !important;
}

/* Upewnij się, że footer-container ma odpowiednie style */
#ft .footer-container {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 0 20px 30px 20px !important;
    display: grid !important;
    grid-template-columns: 2fr 1fr 1fr 1fr !important;
    gap: 30px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
}

/* Responsywność footera na stronie zdjęcia */
@media only screen and (max-width: 992px) {
    #ft .footer-container {
        grid-template-columns: 1fr 1fr;
        gap: 25px;
    }
    
    #ft .footer-brand {
        grid-column: 1 / -1;
        text-align: center;
    }
}

@media only screen and (max-width: 768px) {
    #ft .modern-footer {
        padding: 30px 0 0 0;
        margin-top: 40px;
    }
    
    #ft .footer-container {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 0 15px 20px 15px;
    }
    
    #ft .footer-section {
        text-align: center;
    }
}

/* Formularze komentarzy - zawsze ukryte domyślnie */
#komentarz_form,
#analiza_form {
    display: none !important;
}

#komentarz_form.show,
#analiza_form.show {
    display: table !important;
}

/* Formularz odpowiedzi - zawsze ukryty domyślnie */
.ff-reply-form-wrapper,
[id^="reply-form-"] {
    display: none !important;
}

.ff-reply-form-wrapper.show,
[id^="reply-form-"].show {
    display: block !important;
}

/* Formularz odpowiedzi - ukryj wszystkie oprócz aktywnego */
.ff-reply-form {
    margin-top: 10px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.ff-reply-link {
    color: #f7d250;
    text-decoration: none;
    font-size: 12px;
    cursor: pointer;
}

.ff-reply-link:hover {
    text-decoration: underline;
}

/* ====== NOWY LAYOUT ZDJĘCIA ====== */

/* Karuzela miniatur */
.ff-thumb-carousel-wrapper {
    margin: 20px 0 30px;
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}

.ff-thumb-carousel__title {
    font-size: 14px;
    font-weight: 600;
    color: #f7d250;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin: 0 0 12px;
    padding: 0 20px;
}

.thumb-slider {
    position: relative;
    overflow: hidden;
    background: #1a1a1a;
    padding: 15px 0;
    border-radius: 8px;
}

.thumb-slider__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    overflow-x: auto;
    padding: 0 60px;
    scrollbar-width: thin;
    scrollbar-color: rgba(250, 218, 122, 0.4) rgba(0, 0, 0, 0.6);
}

.thumb-slider__list::-webkit-scrollbar {
    height: 6px;
}

.thumb-slider__list::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.7);
}

.thumb-slider__list::-webkit-scrollbar-thumb {
    background: linear-gradient(to right, #f2c75c, #8c611f);
    border-radius: 3px;
}

.thumb-slider__item {
    flex-shrink: 0;
}

.thumb-slider__link {
    display: block;
    border: 2px solid transparent;
    opacity: 0.7;
    transition: opacity 0.3s, border-color 0.3s;
    border-radius: 4px;
    overflow: hidden;
}

.thumb-slider__link:hover {
    opacity: 1;
    border-color: rgba(250, 218, 122, 0.5);
}

.thumb-slider__link--active {
    border-color: #f0c96b !important;
    opacity: 1 !important;
}

.thumb-slider__link img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    display: block;
}

.thumb-slider .nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    color: #fff;
    font-size: 24px;
    text-decoration: none;
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 15px;
    border-radius: 5px;
    display: none;
    transition: background 0.2s ease;
}

.thumb-slider .nav:hover {
    background: rgba(0, 0, 0, 0.9);
}

.thumb-slider .nav-prev {
    left: 10px;
}

.thumb-slider .nav-next {
    right: 10px;
}

/* Główne zdjęcie */
.ff-photo-main {
    width: 100%;
    margin: 0 auto 32px;
    max-width: 1100px;
}

.ff-photo-main__container {
    text-align: center;
    padding: 0 20px;
}

.ff-photo-main__link {
    display: block !important;
    position: relative;
    margin: 0 auto;
    border-radius: 4px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.8);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ff-photo-main__link:hover {
    transform: translateY(-2px);
    box-shadow: 0 22px 55px rgba(0, 0, 0, 0.9);
}

.ff-photo-main__img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* Przyciski akcji pod tytułem */
.ff-photo-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
    align-items: center;
}

.ff-photo-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    color: #f5f5f5;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.ff-photo-action-btn:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(247, 210, 80, 0.3);
    transform: translateY(-1px);
}

.ff-photo-action-btn--icon {
    padding: 8px 12px;
    min-width: 40px;
    justify-content: center;
}

.ff-photo-action-btn--highlight {
    background: radial-gradient(circle at top, rgba(247, 210, 80, 0.15), rgba(0, 0, 0, 0.7));
    border-color: rgba(247, 210, 80, 0.3);
    color: #f7d250;
}

.ff-photo-action-btn--highlight:hover {
    background: radial-gradient(circle at top, rgba(247, 210, 80, 0.25), rgba(0, 0, 0, 0.7));
    border-color: rgba(247, 210, 80, 0.5);
}

.ff-photo-action-btn--rating {
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.06);
    cursor: default;
    gap: 8px;
}

.ff-photo-action-btn--rating:hover {
    transform: none;
    background: rgba(255, 255, 255, 0.02);
}

.ff-rater-link {
    display: inline-block;
    opacity: 0.7;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.ff-rater-link:hover {
    opacity: 1;
    transform: scale(1.1);
}

.ff-rater-link img {
    height: 18px;
    width: auto;
    vertical-align: middle;
}

/* Podział głosów w karcie */
.ff-vote-breakdown {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.ff-vote-breakdown dt {
    margin-bottom: 6px;
}

.ff-vote-breakdown__list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.ff-vote-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #ddd;
}

/* Komentarze - nowy layout */
.ff-photo-comments {
    max-width: 1100px;
    margin: 40px auto 0;
    padding: 0 20px;
}

/* Przekształcenie istniejących komentarzy na nowy layout */
.ff-photo-comments .comments_cont {
    margin-top: 0;
}

.ff-photo-comments .comments {
    width: 100%;
    border-collapse: collapse;
}

.ff-photo-comments .comments tr {
    display: block;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.ff-photo-comments .comments tr:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.ff-photo-comments .comments td {
    display: block;
    width: 100% !important;
    padding: 0 !important;
}

.ff-photo-comments .avatar_width {
    display: none !important;
}

.ff-photo-comments .comments_dane {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.ff-photo-comments .comments_dane img {
    width: 32px !important;
    height: 32px !important;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    display: block !important;
}

.ff-photo-comments .k_data {
    font-size: 12px;
    color: #999;
    order: 2;
}

.ff-photo-comments .comments_dane b,
.ff-photo-comments .comments_dane a {
    font-weight: 600;
    color: #f5f5f5;
    font-size: 14px;
    text-decoration: none;
    order: 1;
}

.ff-photo-comments .comments_dane a:hover {
    color: #f7d250;
}

.ff-photo-comments .komentarz {
    margin-left: 42px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #e0e0e0;
    font-size: 14px;
    line-height: 1.6;
    position: relative;
}

.ff-photo-comments .comm_tresc {
    margin: 0;
    padding: 0;
}

.ff-photo-comments .comm_tresc p {
    margin: 0 0 8px;
}

.ff-photo-comments .comm_tresc p:last-child {
    margin-bottom: 0;
}

.ff-photo-comments .comments_abuse {
    position: absolute;
    top: 8px;
    right: 8px;
}

.ff-photo-comments .komentarz_ocena {
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.ff-photo-comments .mod_info {
    font-size: 11px;
    color: #999;
    font-style: italic;
    margin-bottom: 4px;
    display: block;
}

.ff-photo-comments .btn_edit_comment {
    margin-bottom: 4px;
}

.ff-photo-comments .btn_edit_comment u {
    font-size: 11px;
    color: #999;
    text-decoration: none;
    cursor: pointer;
}

.ff-photo-comments .btn_edit_comment u:hover {
    color: #f7d250;
}

@media (max-width: 768px) {
    .ff-photo-comments .komentarz {
        margin-left: 0;
        margin-top: 8px;
    }
    
    .ff-photo-comments .comments_dane {
        flex-wrap: wrap;
    }
}

.photo-comment {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.photo-comment:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.photo-comment__header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.photo-comment__avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.photo-comment__meta {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.photo-comment__nick {
    font-weight: 600;
    color: #f5f5f5;
    font-size: 14px;
    text-decoration: none;
}

.photo-comment__nick:hover {
    color: #f7d250;
}

.photo-comment__date {
    font-size: 12px;
    color: #999;
    white-space: nowrap;
}

.photo-comment__moderate {
    margin-left: auto;
    font-size: 11px;
    color: #999;
    text-decoration: none;
    padding: 2px 8px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.photo-comment__moderate:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #f5f5f5;
}

.photo-comment__body {
    margin-left: 42px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #e0e0e0;
    font-size: 14px;
    line-height: 1.6;
}

.photo-comment__body p {
    margin: 0 0 8px;
}

.photo-comment__body p:last-child {
    margin-bottom: 0;
}

/* Responsywność */
@media (max-width: 768px) {
    /* Główne zdjęcie - pełna szerokość, wycentrowane */
    .ff-photo-main {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        margin: 0 auto 20px !important;
    }
    
    .ff-photo-main__container {
        padding: 0 !important;
        text-align: center !important;
    }
    
    .ff-photo-main__link {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        border-radius: 0 !important;
        box-shadow: none !important;
    }
    
    .ff-photo-main__img {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
        margin: 0 !important;
    }
    
    /* Stare zdjęcia - też pełna szerokość */
    #max_ver,
    #mpic,
    .image_list,
    .user_photo {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    #max_ver img,
    #mpic img,
    .user_photo {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    
    .ff-photo-actions {
        gap: 8px;
        padding: 0 10px;
    }
    
    .ff-photo-action-btn {
        padding: 6px 12px;
        font-size: 12px;
    }
    
    .ff-photo-meta {
        padding: 20px 10px;
    }
    
    .ff-photo-meta__grid {
        grid-template-columns: 1fr;
    }
    
    .photo-comment__body {
        margin-left: 0;
        margin-top: 8px;
    }
    
    .ff-photo-comments {
        padding: 0 10px;
    }
}

