:root {
    --primary-dark: #03295c;
    --primary-light: #3782e8;
    --accent-cyan: #00ffff;
    --white: #ffffff;
    --light-gray: #f8f9fa;
    --border-gray: #dee2e6;
    --text-dark: #212529;
    --text-muted: #6c757d;
    --success: #28a745;
    --danger: #dc3545;
    --warning: #ffc107;
    --info: #17a2b8;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-lg: 0 4px 20px rgba(0,0,0,0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Tahoma', Arial, sans-serif;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-light) 100%);
    min-height: 100vh;
    color: var(--text-dark);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 20px 320px 20px;
}

.header {
    background: var(--white);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-logout {
    background: var(--accent-cyan);
    color: var(--primary-dark);
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-logout:hover {
    background: #00e6e6;
    color: var(--primary-dark);
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo img {
    height: 50px;
    width: auto;
}

.logo h1 {
    color: var(--primary-dark);
    font-size: 24px;
    font-weight: 600;
}

.breadcrumb {
    color: var(--text-muted);
    font-size: 14px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--white);
    border-radius: 10px;
    padding: 25px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.stat-card .icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 24px;
    font-weight: bold;
    position: relative;
}

.stat-card .icon::before {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    background: var(--white);
    border-radius: 2px;
}

.stat-card .icon.folders::before {
    clip-path: polygon(10% 20%, 40% 20%, 50% 0%, 90% 0%, 90% 80%, 10% 80%);
}

.stat-card .icon.protected::before {
    border-radius: 3px 3px 0 0;
    height: 12px;
    width: 18px;
    border: 2px solid var(--white);
    background: transparent;
}

.stat-card .icon.protected::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 14px;
    background: var(--white);
    border-radius: 2px;
    bottom: 8px;
}

.stat-card .icon.files::before {
    clip-path: polygon(0 0, 70% 0, 100% 30%, 100% 100%, 0 100%);
}

.stat-card .icon.storage::before {
    border-radius: 50%;
    width: 20px;
    height: 20px;
    border: 2px solid var(--white);
    background: transparent;
}

.stat-card .icon.storage::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--white);
    border-radius: 50%;
}

.stat-card .value {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 5px;
}

.stat-card .label {
    color: var(--text-muted);
    font-size: 14px;
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.action-card {
    background: var(--white);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.2s ease;
    cursor: pointer;
}

.action-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.action-card .icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 32px;
    font-weight: bold;
    position: relative;
}

.action-card .icon::before {
    content: '';
    position: absolute;
    background: var(--white);
}

.action-card .icon.add::before {
    width: 32px;
    height: 4px;
    border-radius: 2px;
}

.action-card .icon.add::after {
    content: '';
    position: absolute;
    width: 4px;
    height: 32px;
    background: var(--white);
    border-radius: 2px;
}

.action-card .icon.upload::before {
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 12px solid var(--white);
    border-radius: 0;
    background: transparent;
    top: 28px;
}

.action-card .icon.upload::after {
    content: '';
    position: absolute;
    width: 4px;
    height: 24px;
    background: var(--white);
    border-radius: 2px;
    top: 32px;
}

.action-card .icon.status::before {
    width: 24px;
    height: 24px;
    border: 4px solid var(--white);
    border-radius: 50%;
    background: transparent;
}

/* Horizontal action card layout */
.action-card.horizontal {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    text-align: center;
    padding: 25px;
}

.action-card.horizontal .action-icon {
    display: flex;
    justify-content: center;
    align-items: center;
}

.action-card.horizontal .icon-circle {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 24px;
    font-weight: bold;
}

.action-card.horizontal .action-content {
    width: 100%;
}

.action-card.horizontal h3 {
    margin: 0 0 8px 0;
    color: var(--primary-dark);
    font-size: 18px;
    font-weight: 600;
}

.action-card.horizontal p {
    margin: 0;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.4;
}

/* Specjalny styl dla Instrukcji */
.action-card.instruction {
    background: linear-gradient(135deg, #ff9800 0%, #ff5722 100%);
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(255, 152, 0, 0.3);
}

.action-card.instruction:hover {
    box-shadow: 0 6px 20px rgba(255, 152, 0, 0.4);
    transform: translateY(-3px);
}

.action-card.instruction h3,
.action-card.instruction p {
    color: var(--white);
}

.action-card.instruction .icon-circle {
    background: rgba(255, 255, 255, 0.3) !important;
}

/* Specjalny styl dla Import z FTP */
.action-card.import-ftp {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.action-card.import-ftp:hover {
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.4);
    transform: translateY(-3px);
}

.action-card.import-ftp .icon-circle {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.action-card.import-ftp h3 {
    color: var(--white);
    font-weight: 700;
}

.action-card.import-ftp p {
    color: rgba(255, 255, 255, 0.9);
}

.action-card .icon.status::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--accent-cyan);
    border-radius: 50%;
}

.action-card h3 {
    color: var(--primary-dark);
    margin-bottom: 10px;
    font-size: 20px;
}

.action-card p {
    color: var(--text-muted);
    font-size: 14px;
}

.stats-simple {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-simple {
    background: var(--white);
    border-radius: 10px;
    padding: 20px;
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-simple .value {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 5px;
}

.stat-simple .label {
    color: var(--text-muted);
    font-size: 14px;
}

.search-container {
    margin-bottom: 20px;
}

.search-box {
    width: 100%;
    max-width: 400px;
    padding: 12px 16px;
    border: 1px solid var(--border-gray);
    border-radius: 25px;
    font-size: 14px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.search-box:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 2px rgba(55, 130, 232, 0.1);
}

.folder-card {
    background: var(--white);
    border-radius: 10px;
    padding: 25px;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease;
    position: relative;
}

.folder-card.collapsed {
    padding: 15px 25px;
}

.folder-card.collapsed .folder-info,
.folder-card.collapsed .folder-actions {
    display: none;
}

.folder-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    position: relative;
}

.folder-card.collapsed .folder-header {
    margin-bottom: 0;
}

.btn-delete {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 700;
    background: var(--danger);
    color: white;
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(220, 53, 69, 0.4);
    z-index: 10;
    transition: all 0.2s ease;
}

.btn-delete:hover {
    background: #c82333;
    transform: scale(1.1);
}

.btn-icon-edit {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 16px;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
    opacity: 0.7;
    flex-shrink: 0;
}

.btn-icon-edit:hover {
    background: var(--light-gray);
    opacity: 1;
    transform: scale(1.1);
}

.folders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.folder-card {
    background: var(--white);
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 280px;
}

.folder-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* ID Badge */
.folder-id-badge {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    color: var(--white);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    display: inline-block;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(3, 41, 92, 0.2);
}

/* Tytuł folderu */
.folder-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.folder-title h3 {
    color: var(--primary-dark);
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
    word-break: break-word;
    flex: 1;
}

/* Status Badge */
.folder-status-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 15px;
    letter-spacing: 0.3px;
}

.status-protected {
    background: linear-gradient(135deg, #f8d7da, #f5c2c7);
    color: #721c24;
}

.status-public {
    background: linear-gradient(135deg, #d1edff, #b8e4ff);
    color: #004085;
}

/* Informacje */
.folder-info {
    flex: 1;
    margin-bottom: 15px;
}

.folder-info .info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid var(--light-gray);
}

.folder-info .info-item:last-child {
    border-bottom: none;
}

.folder-info .info-label {
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 500;
}

.folder-info .info-value {
    color: var(--text-dark);
    font-size: 13px;
    font-weight: 600;
}

/* Akcje na dole - ZAWSZE w tym samym miejscu */
.folder-actions {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 15px;
    border-top: 2px solid var(--light-gray);
}

.folder-actions .btn {
    width: 100%;
    text-align: center;
    padding: 10px 12px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.folder-actions .btn-access {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    color: var(--white);
    border: none;
}

.folder-actions .btn-access:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(3, 41, 92, 0.3);
}

.folder-actions .btn-view {
    background: var(--light-gray);
    color: var(--primary-dark);
    border: 2px solid var(--border-gray);
    font-weight: 600;
}

.folder-actions .btn-view:hover {
    background: var(--border-gray);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
}

.folder-actions .btn-green {
    background: #28a745;
    color: white;
    border: none;
}

.folder-actions .btn-green:hover {
    background: #218838;
}

.folder-actions .btn-cyan {
    background: var(--accent-cyan);
    color: var(--primary-dark);
    border: none;
}

.folder-actions .btn-cyan:hover {
    background: #00e6e6;
}

.btn-info {
    background: var(--primary-dark);
    color: var(--white);
    border: none;
}

.btn-info:hover {
    background: #02234d;
    color: var(--white);
}

.btn-success {
    background: #28a745;
    color: var(--white);
    border: none;
}

.btn-success:hover {
    background: #218838;
    color: var(--white);
}

.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s ease;
    text-align: center;
}

.btn-primary {
    background: var(--primary-dark);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-light);
}

.btn-secondary {
    background: var(--light-gray);
    color: var(--text-dark);
    border: 1px solid var(--border-gray);
}

.btn-secondary:hover {
    background: var(--border-gray);
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-success:hover {
    background: #218838;
}

.btn-danger {
    background: var(--danger);
    color: var(--white);
}

.btn-danger:hover {
    background: #c82333;
}

.btn-warning {
    background: var(--warning);
    color: var(--text-dark);
}

.btn-warning:hover {
    background: #e0a800;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-dark);
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-gray);
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 2px rgba(58, 135, 239, 0.1);
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: var(--white);
    border-radius: 10px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-title {
    color: var(--primary-dark);
    font-size: 20px;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-muted);
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: var(--text-dark);
}

.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-danger {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-info {
    background: #cce7ff;
    color: #004085;
    border: 1px solid #b3d7ff;
}

/* Access options dropdown */
.access-options-dropdown {
    position: relative;
    width: 100%;
}

.access-options-dropdown .btn {
    justify-content: center;
    display: flex;
    align-items: center;
    gap: 6px;
}

.dropdown-toggle::after {
    content: "▼";
    font-size: 9px;
    opacity: 0.7;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border: 2px solid var(--primary-light);
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
    z-index: 1000;
    margin-top: 8px;
    overflow: hidden;
}

.dropdown-menu.show {
    display: block;
    animation: slideDown 0.2s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-item {
    display: block;
    padding: 12px 16px;
    color: var(--text-dark);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    border-bottom: 1px solid var(--light-gray);
    transition: all 0.2s ease;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    color: var(--white);
}

.dropdown-item:focus {
    outline: none;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
    color: var(--white);
}

.folder-detail-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.file-upload-area {
    border: 2px dashed var(--border-gray);
    border-radius: 10px;
    padding: 40px;
    text-align: center;
    transition: border-color 0.2s ease;
    cursor: pointer;
}

.file-upload-area.dragover {
    border-color: var(--primary-light);
    background: rgba(58, 135, 239, 0.05);
}

.file-upload-area.has-files {
    padding: 20px;
    border-color: var(--primary-light);
    background: rgba(58, 135, 239, 0.05);
}

.file-upload-area .icon {
    font-size: 48px;
    color: var(--text-muted);
    margin-bottom: 15px;
}

.file-upload-area h3 {
    color: var(--text-dark);
    margin-bottom: 10px;
}

.file-upload-area p {
    color: var(--text-muted);
    font-size: 14px;
}

.file-upload-area.has-files .upload-empty-state {
    display: none;
}

.upload-empty-state .icon {
    font-size: 48px;
    margin-bottom: 10px;
}

.upload-empty-state h3 {
    margin-bottom: 5px;
    color: var(--primary-dark);
}

.upload-empty-state p {
    color: var(--text-muted);
    font-size: 14px;
}

/* Styles for upload instructions in global modal */
.upload-instructions {
    text-align: center;
    position: relative;
}

.upload-instructions .upload-icon {
    font-size: 48px;
    color: var(--text-muted);
    margin-bottom: 15px;
    display: block;
}

.upload-instructions p {
    color: var(--text-dark);
    font-size: 16px;
    margin-bottom: 15px;
}

.upload-instructions small {
    color: var(--text-muted);
    font-size: 12px;
    display: block;
    margin-top: 10px;
}

.upload-instructions .file-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-preview-list {
    display: none;
    text-align: left;
    margin-top: 15px;
}

.file-preview-list.show {
    display: block;
}

.file-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: var(--white);
    border: 1px solid var(--border-gray);
    border-radius: 6px;
    margin-bottom: 6px;
    font-size: 14px;
}

.file-preview-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
}

.file-preview-icon {
    font-size: 16px;
    color: var(--primary-dark);
}

.file-preview-name {
    font-weight: 500;
    color: var(--text-dark);
    word-break: break-word;
}

.file-preview-size {
    color: var(--text-muted);
    font-size: 12px;
}

.file-remove-btn {
    background: var(--danger);
    color: white;
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.file-remove-btn:hover {
    background: #c82333;
}

.upload-summary {
    margin-top: 10px;
    padding: 10px;
    background: var(--light-gray);
    border-radius: 6px;
    font-size: 14px;
    color: var(--text-muted);
    text-align: center;
}

.upload-empty-state {
    display: block;
}

.upload-empty-state.hide {
    display: none;
}

.progress {
    width: 100%;
    height: 8px;
    background: var(--light-gray);
    border-radius: 4px;
    overflow: hidden;
    margin: 10px 0;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-dark), var(--primary-light));
    transition: width 0.3s ease;
}

/* Responsive breakpoints dla folders-grid */
@media (min-width: 769px) and (max-width: 1000px) {
    .folders-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 15px;
    }
}

@media (min-width: 1001px) and (max-width: 1400px) {
    .folders-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 18px;
    }
}

@media (min-width: 1401px) {
    .folders-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .action-grid {
        grid-template-columns: 1fr;
    }
    
    .folders-grid {
        grid-template-columns: 1fr;
    }
    
    .folder-card {
        padding: 20px;
    }
    
    .folder-actions {
        justify-content: center;
    }
    
    .modal-content {
        margin: 20px;
        padding: 20px;
    }
    
    /* Mobile: Search bar pod nagłówkiem "Wszystkie foldery" */
    .folders-section > div[style*="display: flex"] {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 15px;
    }
    
    .folders-section .search-container {
        width: 100%;
    }
    
    .folders-section .search-box {
        width: 100% !important;
        max-width: none !important;
    }
}

@media (max-width: 480px) {
    .btn {
        font-size: 12px;
        padding: 6px 12px;
    }
    
    .folder-actions {
        gap: 5px;
    }
    
    .stat-card {
        padding: 20px;
    }
    
    .action-card {
        padding: 20px;
    }
}

/* Animacje */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

/* Loading spinner */
.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--primary-dark);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-right: 8px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* PDF Viewer Modal */
.pdf-viewer-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
}

.pdf-viewer-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-viewer-content {
    width: 95%;
    height: 95%;
    background: white;
    border-radius: 10px;
    position: relative;
    display: flex;
    flex-direction: column;
}

.pdf-viewer-header {
    padding: 15px 20px;
    background: var(--primary-dark);
    color: white;
    border-radius: 10px 10px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.pdf-viewer-header h3 {
    margin: 0;
    font-size: 18px;
}

.pdf-close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-viewer-frame {
    flex: 1;
    border: none;
    border-radius: 0 0 10px 10px;
}

/* WordPress compatibility - ensure our styles take precedence */
.mm-dysk-portal * {
    box-sizing: border-box;
}

.mm-dysk-portal {
    font-family: 'Tahoma', Arial, sans-serif !important;
}

.client-stats {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.client-stat {
    background: var(--white);
    border-radius: 10px;
    padding: 20px;
    box-shadow: var(--shadow);
    text-align: center;
}

.client-stat .value {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 5px;
}

.client-stat .label {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 10px;
}

.client-stat .action {
    margin-top: 10px;
}

.mm-dysk-portal .form-control {
    background-image: none !important;
    box-shadow: none !important;
    border: 1px solid var(--border-gray) !important;
}

.search-box {
    background: var(--white);
    border: 2px solid var(--border-light);
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 14px;
    width: 100%;
    transition: border-color 0.2s ease;
}

.search-box:focus {
    outline: none;
    border-color: var(--primary-light);
}

.search-container {
    display: flex;
    align-items: center;
    gap: 10px;
}