
:root {
    --bs-body-bg: #414549 !important;
    --bs-dark-rgb: 65, 69, 73 !important;
    --bs-dark: #414549 !important;
}


/* LOADER PEŁNOEKRANOWY */
#full-screen-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #fff;
}

/* SEKCJE KROKÓW */
.step-section {
    display: none;
    animation: fadeIn 0.5s;
}

.active-step {
    display: block;
}

/* PRZEŁĄCZNIK JĘZYKA */
.lang-switch {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 1000;
}

/* GALERIA ZDJĘĆ */
.selectable-image {
    cursor: pointer;
    transition: transform 0.2s, border 0.2s;
    border: 3px solid transparent;
    opacity: 0.8;
}

.selectable-image:hover {
    transform: scale(1.05);
    border-color: #0d6efd;
    opacity: 1;
}

/* PODGLĄD OBRAZKA */
.preview-img {
    max-height: 264px;
    object-fit: cover;
    border: 1px solid #444;
}

/* KONTENER WIDEO */
.video-container {
    position: relative;
    padding-bottom: 56.25%;
    /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid #444;
}

.video-container video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Animacja wejścia */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Placeholder inputa w dark mode, żeby był czytelniejszy */
::placeholder {
    color: #888 !important;
    opacity: 1;
}

.custom-cnt {
    position: relative;
}

.custom-cnt .btn-custom {
    position: absolute;
    top: 0px;
    left: 12px;
    background-color: transparent;
    border: 0;
    padding: 6px;
    font-size: 20px;
    line-height: 20px;
    transform: rotate(90deg);
    z-index: 10;
    width: 30px;
    height: 30px;
}

/* MODAL DO POWIĘKSZANIA ZDJĘĆ */
.modal-custom {
    display: none; 
    position: fixed; 
    z-index: 10000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgb(0,0,0); 
    background-color: rgba(0,0,0,0.9); 
}

.modal-content-custom {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 900px;
    max-height: 90vh;
    object-fit: contain;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-name: zoom;
    animation-duration: 0.6s;
}

@keyframes zoom {
    from {transform:translate(-50%, -50%) scale(0)} 
    to {transform:translate(-50%, -50%) scale(1)}
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    z-index: 10001;
    cursor: pointer;
}

.close-modal:hover,
.close-modal:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

/* Responsywność dla modala */
@media only screen and (max-width: 700px){
    .modal-content-custom {
        width: 100%;
    }
}

/* MODAL OBSŁUGI BŁĘDÓW */
.error-modal {
    display: none;
    position: fixed;
    z-index: 10001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(5px);
}

.error-modal-content {
    background-color: #1a1a1a;
    margin: 10% auto;
    padding: 30px;
    border: 1px solid #dc3545;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(220, 53, 69, 0.3);
    animation: errorSlideIn 0.4s ease-out;
    position: relative;
}

@keyframes errorSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.error-modal-icon {
    font-size: 60px;
    margin-bottom: 20px;
    animation: errorPulse 1.5s ease-in-out infinite;
}

@keyframes errorPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.error-modal-title {
    color: #dc3545;
    font-weight: bold;
    margin-bottom: 15px;
    font-size: 24px;
}

.error-modal-message {
    color: #e0e0e0;
    font-size: 16px;
    line-height: 1.5;
    margin-bottom: 25px;
    min-height: 50px;
}

.error-modal-close {
    position: absolute;
    top: 10px;
    right: 20px;
    color: #aaa;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.error-modal-close:hover,
.error-modal-close:focus {
    color: #dc3545;
}

/* Responsywność dla modala błędów */
@media only screen and (max-width: 600px) {
    .error-modal-content {
        width: 95%;
        margin: 20% auto;
        padding: 20px;
    }
    
    .error-modal-icon {
        font-size: 50px;
    }
    
    .error-modal-title {
        font-size: 20px;
    }
    
    .error-modal-message {
        font-size: 14px;
    }
}

/* CUSTOM LAYOUT SELECTOR */
.layout-selector-wrapper {
    position: relative;
    width: 100%;
}

.layout-selector-display {
    display: flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    background-color: var(--bs-body-bg);
    border: 1px solid #6c757d;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.layout-selector-display:hover {
    border-color: #0d6efd;
}

.layout-selector-display.active {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.layout-icon {
    width: 58px;
    height: 28px;
    object-fit: contain;
    margin-right: 24px;
}

.layout-name {
    flex: 1;
    color: #f8f9fa;
}

.layout-arrow {
    color: #6c757d;
    font-size: 12px;
    transition: transform 0.3s ease;
}


/* DROPDOWN (DOMYŚLNIE SCHOWANE) */
.layout-dropdown {
    display: none;                    /* <-- najważniejsze */
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: var(--bs-body-bg);
    border: 1px solid #6c757d;
    border-radius: 0.375rem;
    margin-top: 5px;
    max-height: 250px;
    overflow-y: auto;
    animation: dropdownSlideIn 0.2s ease;
    z-index: 100;
}

@keyframes dropdownSlideIn {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.layout-dropdown.drop-up {
    top: auto;
    bottom: 100%;
    margin-bottom: 5px;
    margin-top: 0;
}

.layout-option {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.layout-option:hover {
    background-color: #343a40;
}

.layout-option.selected {
    background-color: #0d6efd;
}

.layout-option .layout-name {
    color: #f8f9fa;
}

/* Custom scrollbar */
.layout-dropdown::-webkit-scrollbar {
    width: 8px;
}
.layout-dropdown::-webkit-scrollbar-track {
    background: #1a1d20;
    border-radius: 4px;
}
.layout-dropdown::-webkit-scrollbar-thumb {
    background: #495057;
    border-radius: 4px;
}
.layout-dropdown::-webkit-scrollbar-thumb:hover {
    background: #6c757d;
}
