body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f4f7f6;
    color: #333;
    margin: 0;
    padding: 20px;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #ddd;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

h1, h2 {
    color: #0056b3;
}

/* Kontejnery */
.login-container, .upload-container {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    max-width: 500px;
    margin: 40px auto;
}

/* Formuláře */
form {
    display: flex;
    flex-direction: column;
}

label {
    margin-bottom: 5px;
    font-weight: bold;
}

input[type="password"], input[type="file"] {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-bottom: 15px;
    font-size: 1rem;
}

button, .logout-button {
    background-color: #007bff;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.2s;
}

button:hover, .logout-button:hover {
    background-color: #0056b3;
}

/* Video galerie */
.video-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.video-item {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 15px;
    text-align: center;
}

.video-item h3 {
    margin-top: 0;
    font-size: 1.1rem;
    word-wrap: break-word;
}

.video-item video {
    max-width: 100%;
    border-radius: 4px;
}

/* Zprávy */
.error-message {
    color: #d93025;
    font-weight: bold;
    margin-top: 10px;
}
.success-message {
    color: #1e8e3e;
    font-weight: bold;
    margin-top: 10px;
}

hr {
    border: 0;
    border-top: 1px solid #eee;
    margin: 40px 0;
}

/* --- STYLY PRO SDÍLENÍ --- */

.share-button {
    background-color: #28a745;
    margin-top: 15px;
    width: 100%;
}
.share-button:hover {
    background-color: #218838;
}

.share-box {
    display: none; /* Skryté ve výchozím stavu */
    margin-top: 15px;
    padding: 10px;
    background-color: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: left;
}

.share-box label {
    font-size: 0.9rem;
    font-weight: bold;
    display: block;
    margin-top: 10px;
}
.share-box label:first-child {
    margin-top: 0;
}

.share-box input[type="text"] {
    width: 100%;
    padding: 8px;
    margin-top: 5px;
    box-sizing: border-box; /* Důležité pro správné zobrazení šířky */
    border: 1px solid #ccc;
    background-color: #fff;
    font-size: 0.9rem;
}
/* --- STYLY PRO UKAZATEL PRŮBĚHU (PROGRESS BAR) --- */

#progress-container {
    margin-top: 20px;
    width: 100%;
}

.progress-box {
    margin-bottom: 15px;
}

.file-name {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.progress-bar {
    width: 100%;
    background-color: #e9ecef;
    border-radius: 5px;
    height: 20px;
    position: relative;
    overflow: hidden; /* Důležité pro zaoblené rohy vnitřního prvku */
}

.progress-bar-fill {
    height: 100%;
    width: 0%;
    background-color: #007bff;
    border-radius: 5px;
    transition: width 0.2s ease-in-out;
}

.progress-text {
    text-align: center;
    font-weight: bold;
    color: #555;
    font-size: 0.9rem;
    margin-top: -20px; /* Umístí text doprostřed progress baru */
    line-height: 20px; /* Svisle centruje text */
}
/* --- STYLY PRO SLOŽKY A NOVÉ ROZLOŽENÍ --- */
.container-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}
.folder-container {
    background-color: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}
.create-folder-form {
    display: flex;
    gap: 10px;
}
.create-folder-form input {
    flex-grow: 1;
    margin-bottom: 0;
}
.breadcrumbs {
    margin-bottom: 20px;
    padding: 10px;
    background-color: #e9ecef;
    border-radius: 4px;
    font-size: 0.9rem;
}
.breadcrumbs a {
    color: #0056b3;
    text-decoration: none;
}
.breadcrumbs a:hover {
    text-decoration: underline;
}
.folder-item {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 20px;
    text-align: center;
    color: #0056b3;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s, box-shadow 0.2s;
    gap: 10px;
}
.folder-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}
.folder-item i {
    font-size: 3rem; /* Velikost ikony */
    color: #ffc107; /* Barva ikony složky */
}
.folder-item.folder-up-link i {
    color: #6c757d; /* Jiná barva pro "o úroveň výš" */
}
.folder-item span {
    font-weight: bold;
    word-break: break-all;
}
/* Úprava mřížky galerie pro složky */
.video-gallery {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
@media (max-width: 768px) {
    .container-grid {
        grid-template-columns: 1fr;
    }
}
