<?php
/*
<#
.Synopsis
   Stylesheet für das Layout der Dateimanager-Anwendung.
   
   Urheber: Christian Grams, Leiter IuK, Gemeinde Fuldatal
   Alle Rechte vorbehalten
   Erstellt 28.01.2026
.VERSION
   20260129.01
.DESCRIPTION
   Definiert das gesamte visuelle Erscheinungsbild, einschließlich Farben, 
   Typografie, Layout-Strukturen (Sidebar, Main Content) und Komponenten 
   wie Modals und Tabellen im Windows-Explorer-Stil.
.EXAMPLE
   <link rel="stylesheet" href="style.css">
.EXAMPLE
   Das Ändern von --accent-color in :root passt die Hauptfarbe der App an.
.INPUTS
   Keine direkten Eingaben (wird vom Browser interpretiert).
.OUTPUTS
   Visuelles Rendering der HTML-Elemente.
.NOTES
   Nutzt CSS-Variablen für einfaches Theming.

   Urheber: Christian Grams, Leiter IuK
   Gemeinde Fuldatal
   Alle Rechte vorbehalten
   Erstellt 28.01.2026
   Version 1.05
.COMPONENT
   Dateimanager
.ROLE
   Frontend
.FUNCTIONALITY
   Design und Layout
#>
*/

/**
 * style.css
 * * Styling to mimic a clean, Windows Explorer-like interface.
 * Separated from logic for easier theming.
 */

:root {
    --header-height: 60px;
    --footer-height: 30px; /* Neu: Feste Höhe für Footer */
    --sidebar-width: 420px;
    --border-color: #d9d9d9;
    --bg-color: #ffffff;
    --hover-color: #e5f3ff;
    --selected-color: #cce8ff;
    --text-color: #333;
    --primary-color: #0078d4; /* Windows Blue */
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* --- Header --- */
.app-header {
    height: var(--header-height);
    background: #f3f3f3;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    padding: 0 15px;
    flex-shrink: 0;
    justify-content: space-between;
}

.brand {
    display: flex;
    align-items: center;
    font-weight: 600;
    font-size: 18px;
}

.brand img {
    height: 16px;
    margin-right: 10px;
}

.header-actions {
    display: flex;
    gap: 10px;
}

/* --- Main Layout Container --- */
.explorer-container {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* --- Left Sidebar (Tree View) --- */
.sidebar-tree {
    width: var(--sidebar-width);
    background: #f0f0f0;
    border-right: 1px solid var(--border-color);
    overflow-y: auto;
    padding: 10px 0;
    flex-shrink: 0;
    font-size: 14px;
}

.tree-ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.tree-ul .tree-ul {
    padding-left: 28px;
    display: none;
    border-left: 1px solid rgba(0,0,0,0.05);
    margin-left: 10px;
}

.tree-ul .tree-ul.expanded {
    display: block;
}

.tree-item {
    display: flex;
    align-items: center;
    padding: 6px 10px;
    cursor: pointer;
    text-decoration: none;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tree-item:hover {
    background-color: var(--hover-color);
}

.tree-item.active {
    background-color: var(--selected-color);
    border: 1px dotted #999;
}

.tree-icon {
    margin-right: 8px;
    color: #ffd04b;
    width: 16px;
    text-align: center;
}

/* --- Right Content (File List) --- */
.main-pane {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: white;
    overflow: hidden;
}

.address-bar {
    padding: 10px 15px;
    border-bottom: 1px solid var(--border-color);
    background: white;
    display: flex;
    align-items: center;
    font-size: 13px;
}

.breadcrumbs a {
    text-decoration: none;
    color: #555;
    padding: 2px 5px;
    border: 1px solid transparent;
}
.breadcrumbs a:hover {
    border: 1px solid var(--border-color);
    background: #f5f5f5;
}

.file-view {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

/* Table Styling */
.file-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.file-table th {
    text-align: left;
    padding: 8px 10px;
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    background: #fff;
    color: #666;
    font-weight: normal;
    position: sticky;
    top: 0;
}

.file-table td {
    padding: 6px 10px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

.file-table tr:hover {
    background-color: var(--hover-color);
}

.name-col { display: flex; align-items: center; }
.name-col i { margin-right: 10px; font-size: 16px; }

/* Buttons */
.btn {
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    background: #fff;
    cursor: pointer;
    font-size: 13px;
    border-radius: 2px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    text-decoration: none;
    color: #333;
    transition: background 0.1s;
}

.btn:hover { background: #f0f0f0; }

.btn-primary, 
a.btn-primary { 
    background-color: var(--primary-color) !important; 
    color: white !important; 
    border-color: #005a9e;
}

.btn-primary:hover,
a.btn-primary:hover { 
    background-color: #005a9e !important; 
    color: white !important;
}

/* --- Footer (Neu) --- */
.app-footer {
    height: var(--footer-height);
    background: #f3f3f3;
    border-top: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: #666;
    gap: 20px;
    flex-shrink: 0;
}

.app-footer a {
    color: #555;
    text-decoration: none;
}

.app-footer a:hover {
    text-decoration: underline;
    color: #000;
}

/* --- Login Styles --- */
.login-container {
    flex: 1; /* Nimmt den restlichen Platz ein, Footer bleibt unten */
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f0f2f5;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    text-align: center;
    width: 320px;
}

.login-logo {
    height: 40px;
    margin-bottom: 20px;
}

.login-input {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
}

.login-btn {
    width: 100%;
    padding: 10px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.login-btn:hover {
    background-color: #005a9e;
}

.error-msg {
    color: #d93025;
    font-size: 13px;
    display: block;
    margin-bottom: 15px;
}